'bikeamph.bas for Picaxe-08M driven 'CATEYE Velo1' bike computer conversion. 'Suits educational output current monitoring of small 1W PV or wind gene 'via simple 1W 1 Ohm supply shunt resistor, with voltage readadc10 measured. 'Schematic (draft)=> www.picaxe.orcon.net.nz/bikeamph.gif -suits breadboard! 'Initial solderless small PV layout =>www.picaxe.orcon.net.nz/bikeamph.jpg 'Thanks to Glen's A1 wind gene site => www.thebackshed.com for initial ideas 'For 'Silicon Chip' article Feb. 2007. Via=> stan.swan@gmail.com 23/12/2006 shunt: readadc10 1, w1 ' approx w1 range 1 at 5mA to 30 at 100mA thru' 1 Ohm 'sertxd (#w1,13,10) ' useful w1 'F8' check point-comment in/out as need be if w1 <=1 then shunt ' gives bike comp. zero reading on very low I (~<5mA) w2=600/w1 ' adjust top '600'for Picaxe supply calib. (600=~4.5V) high 4 ' Output pulse code for bike computer,fed to pin 4 pause w2 ' via 100nF capacitor & parallel LED. Some scope for low 4 ' tweaking,but bike comp.times out if pause >~1000ms pause w2 ' and upper detection range ~30mS (~100km/hr) goto shunt