IR telemetry

xstamp

Senior Member
When sending information from a sensor that’s mounted on a rotating component, the options are normally to use slip rings or radio telemetry. I found that both these techniques have limitations and therefore developed a very cheap and simple optical telemetry link. By connecting an IR diode between the PWM output and serial output pins (via a 180 Ohm current limiting resistor) it possible to produce a 38KHz modulated IR data stream from the PICAXE. Data is interfaced to a PC serial port using an IR receiver and a single buffer transistor. The range is in excess of several metres at a data rate of 1200 baud.

The emitter diode was a TSUS4300 and the receiver was a TSOP4138, both operate at 950nM. The only potential problem is that the receiver has an automatic gain control loop that is pattern sensitive but in practice the link is quite robust over a wide ambient light range. This type of optical telemetry could be useful in many robotics applications, like measuring torque on a drive shaft.
 

manuka

Senior Member
Good idea! IR is often neglected in todays 433/ZigBee era,but is well suited for such applications. Assorted Picaxe IR encoding approaches exist,& are especially 08M friendly- thanks to it's inbuilt 38kHz features that've virtually rewritten the IR book. More circuit details & code? Is this using background PWM? Which Picaxe -08M,18X? Stan


Edited by - manuka on 10/03/2007 09:00:09
 

moxhamj

New Member
A very cunning idea. I've been wondering from some time whether it is also possible to couple small amounts of power to rotating devices - eg using coils/magnets/induction. Tesla did it with high frequecy RF but that would probably fry any nearby electronics. I'm thinking something much simpler - a magnet on a rotating shaft and an iron cored coil on the stationary part - or vice versa.

It could be useful for something - tyre pressure guage, automatic feathering system for a windmill etc.

Keep us all posted!

 

xstamp

Senior Member
The following (untested) 18X code provides an example of what could be done using my simple IR telemetry link. A typical application would be to measure three analog channels and transmit the data to a PC running StampPlot Pro. The example is for a binary format with the checksum option is enabled. The received data is plotted in real-time and automatically shifted, like a strip-chart display. Note that because the configuration information is sent over the IR link, StampPlot Pro must be running and the PC serial port enabled before the PICAXE is powered-up.

Starting the hardware description at the transmitter end of the link, the PWM output free-runs at 38Khz and drives the anode of an IR emitting diode. The diode’s cathode is gated by the serial port to produce a stream of 38Khz-modulated data. Therefore, including a 180 ohm current limiting series resistor, the IR transmitter circuitry only consists of two components.

At the PC end of the link the IR receiver drives the serial input via an inverting NPN transistor. The transistor is necessary because the receiver IC has too high an output impedance to drive the PC input directly. StampPlot Pro has an option to keep RTS high and this could power the IR receiver, using a series resistor and parallel 5.1 volt zener diode. The collector pull-up resistor can be taken directly to the higher RTS voltage. Therefore, only the following three PC serial port pins are used: data in pin 2, ground pin 5 and RTS, pin 7.

IR Telemetry Code for PICAXE-18X

pause 2000
serout 7,N1200,("!RSET",cr)
serout 7,N1200,("!RSET",cr)
serout 7,N1200,("!ERRT OFF",cr)
serout 7,N1200,("!TITL 3-channeltest",cr)
serout 7,N1200,("!TMAX 20",cr)
serout 7,N1200,("!SPAN 0,255",cr)
serout 7,N1200,("!SHFT ON",cr)
serout 7,N1200,("!FLSH ON",cr)
serout 7,N1200,("!NUMB 3",cr)
serout 7,N1200,("!CSUM ON",cr)
serout 7,N1200,("!PLOT ON",cr)
serout 7,N1200,("!USEB ON",cr)
pause 1000

pwmout 3, 25,53

start:
readadc 0, b0
readadc 1, b1
readadc 2, b2
b3 = b0 + b1 + b2
serout 7,N1200, (b0,b1,b2,b3)
goto start




 
Top