Baud rate 38k4??
Ok just jot a psc for my robot and need help
when i chnge the baude rate to 38k4. What do i put in the serout for that baud rate????
Serout 15, ????, [noparse][[/noparse]coman dstring]
what does 38k4 mean??··· 3840???
And why do i have to make the baud rate befor any change
serout 15, 396+$8000,[noparse][[/noparse]comand string]
when i chnge the baude rate to 38k4. What do i put in the serout for that baud rate????
Serout 15, ????, [noparse][[/noparse]coman dstring]
what does 38k4 mean??··· 3840???
And why do i have to make the baud rate befor any change
serout 15, 396+$8000,[noparse][[/noparse]comand string]
Comments
On the BS2, the equation is: INT(1,000,000 / baud rate) - 20
So 1e6 / 38e3 == 26, -20 == 6.
1e6 / 26 == 38,461 baud (exactly). So you can't get exactly 38,000. But 38,461 is only 1% off, so it should still work.
Final answer:· "6 + $8000" is the number you would put in.
One of the things that makes my life easier is conditional compilataion -- especially for things like SERIN/SEROUT that have different parameters based on the module used.· In my standard template I have this section that handles serial parameters; I use it all the time and my serial life is a breeze.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Dallas Office
The help file for SEROUT does not show 38400 in the chart. That's why I could not figure that out. I did get it needed to be "6" but didnot realise i still needed the "$8000" with it.
now I know what is is for too.
Maybe the PSC·documents could use more exaples or even that chart.
Serial stuff can be tricky, but I assure you that the details are there.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Dallas Office
Dave
much better than the default.
The only thing I find is that if I turn off the power switch on the BOE I· have to push the rest button. For it to start working again
This might be because I have the baud change statment before the Main loop.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Dallas Office
SERIN DATAPIN,N36400,[noparse][[/noparse]WAIT("@"),SKIP 3, STR GPSD\4, SKIP 5, STR GPSA\4]
Thanks for the info,
Dave
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Jon Williams
Applications Engineer, Parallax
Dallas Office