andyquirot
Member
Hi all i am building a radio control tank. i have forward brushless speed controlers and i am trying to program a picaxe 14m to do the following/example. I want to set the stick on my radio control to centre when i move the stick forward the speed controlers work in forward ok. Now i want to move the stick down and operate a large relay than bits ok i can do this BUT i want the output to think its moving the stick foward to operate the speed controller. I need some help with th maths. Centre stick posion approx 150ms moving the stick forwards/up goes to approx 200ms. i need to move the stick from centre to back/bottom going from 150ms to approx 200ms to simulate the stick moving forward/up. hope you understand what i meen program so far.
code
low 2
low 3
low 4
low 5
start:
pulsin 2,1,w0
if w0 => 145 then
low 2
pulsout 1,w0
pause 20
endif
if w0 =< 145 then high 2
'if w0 = 140 then let w1 = 75
'endif
'if w0 = 135 then let w1 = 80
'endif
'if w0 = 135 then let w1 = 85
endif
pulsout 1,w0
pause 20
goto start
/code
Regards Andy Quirot
P.S. i know i can buy a forward/backwards controler at £85.00 but the 100Amp forward only controlers are only £25.00 + a relay and a bit of work..
code
low 2
low 3
low 4
low 5
start:
pulsin 2,1,w0
if w0 => 145 then
low 2
pulsout 1,w0
pause 20
endif
if w0 =< 145 then high 2
'if w0 = 140 then let w1 = 75
'endif
'if w0 = 135 then let w1 = 80
'endif
'if w0 = 135 then let w1 = 85
endif
pulsout 1,w0
pause 20
goto start
/code
Regards Andy Quirot
P.S. i know i can buy a forward/backwards controler at £85.00 but the 100Amp forward only controlers are only £25.00 + a relay and a bit of work..