Most time efficient code

clockwork

Member
A project I am working on requires a 08m Picaxe acting as a remote control to send a command (when a button is pressed) via a 433 mhz Transmitter to a Receiver connected to a 18m2 Picax. This then operates LED's, servo's and so on.

My question is what code and setup will provide the shortest delay between pushing the button on the 08m and servo's etc starting to operate?

I also want to be able to press one of four buttons and have four differing sets of commands being implimented.

I appreciate that there must be some delay but I would like it to be kept to the minimum.

Many thanks in advance
 

Andrew Cowan

Senior Member
What sort of delay are you talking about? Would 5mS or so be acceptable?

Typical cheap 433MHz modules require a preamble, qualifier and then the data.

Shorter preambles and shorter qualifiers will make the response faster, but the link less solid - ie the maximum range will be decreased. What sort of range are you looking for?
 

clockwork

Member
5mS would not be a problem.

Also operating distance would average probably 10 foot with a maximum of 20 to 25 foot.
 

Andrew Cowan

Senior Member
In that case, a few standard cheap 433MHz modules will be absolutly fine.

Something like transmitting:
Code:
serout 0,N2400,("UUUUU")
pause 2
serout 0,N2400("AB",b0)
Receiving:
Code:
serin 1,N2400,("AB"),b0
Should give you at least 50 feet range, the option to send values of 0-255 (the range of b0), and a delay of <5mS.

A
 
Top