Pulsout/Serout question
jcferguson
Posts: 86
Hi there,
I am sending information via RF 433 units and wonder if anyone has more information about the Pulsout that goes before the Serout.
as in:
PULSOUT rfpin, 2200
SEROUT rfpin, 240, [noparse][[/noparse] "1", DrivePotVal.HIGHbyte, DrivePotVal.lowbyte, TiltPotVal.HIGHbyte, TiltPotVal.lowbyte, RelayOnCar ]
The text for the RF unit (from parallax) has a value of 1200 for the pulsout - but I switched to a bs2sx and the value doesn't work. How do I pick the "right" value? The text is lacking in this area. Some values seem to make my transmission stutter a bit ( I am driving servos ). Should I just experiment or is there a way to figure this.
Thanks!
Carlos
(here is the text from the parallax website)
Calibration
When initiating communication between the RF modules, a sync pulse should be sent to re-establish the
radio connection between the modules. Sending several characters can accomplish this, however
sending a pulse (which maintains a high state during the synchronization) is more efficient:
√ For BS1s the following code line sends an appropriate sync pulse:
PULSOUT 1, 300
√ For BS2s the following code line sends an appropriate sync pulse:
PULSOUT 8, 1200
I am sending information via RF 433 units and wonder if anyone has more information about the Pulsout that goes before the Serout.
as in:
PULSOUT rfpin, 2200
SEROUT rfpin, 240, [noparse][[/noparse] "1", DrivePotVal.HIGHbyte, DrivePotVal.lowbyte, TiltPotVal.HIGHbyte, TiltPotVal.lowbyte, RelayOnCar ]
The text for the RF unit (from parallax) has a value of 1200 for the pulsout - but I switched to a bs2sx and the value doesn't work. How do I pick the "right" value? The text is lacking in this area. Some values seem to make my transmission stutter a bit ( I am driving servos ). Should I just experiment or is there a way to figure this.
Thanks!
Carlos
(here is the text from the parallax website)
Calibration
When initiating communication between the RF modules, a sync pulse should be sent to re-establish the
radio connection between the modules. Sending several characters can accomplish this, however
sending a pulse (which maintains a high state during the synchronization) is more efficient:
√ For BS1s the following code line sends an appropriate sync pulse:
PULSOUT 1, 300
√ For BS2s the following code line sends an appropriate sync pulse:
PULSOUT 8, 1200
Comments
The best trick here is to use conditional compilation to set constants for values you will use in these commands. That way when you compile for any kind of Stamp your code will work without changes.
Here's some sample code with conditional compilation and constants for pulsout that might show what I mean a little better:
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
When the going gets weird, the weird turn pro. -- HST
I did think that I could just multiply my pulsout value by the unit value for the bs2sx, but it didn't quite seem to work right - I guess I'll just stick with that though...
I wonder if I should use a pull down resistor on the output (data) pin for the rf transmitter (which is active high) to "clean it up"? Or would that be a bad idea?
Carlos