Flow control over Bluetooth
Hi. I'm programming the serial communication for a boe-bot project at school (BS2, PBASIC 2.5). I am utilizing the eb500 module for Bluetooth communication. I have successful, non-blocking serial communication between the PC and the boe-bot (over bluetooth) utilizing the serin command:
How should I modify this if I want to implement flow control? The Basic Stamp programming manual discusses this somewhat, but assumes a connection for regular serial (not Bluetooth serial emulation) and I am not sure if it is supposed to work the same and what pins to use.
Thank you for your patience - I am fairly new to PBASIC programming.
command VAR BYTE DO SERIN 0, 84, 20, no_command, [noparse][[/noparse]command] SEROUT 1, 84, [noparse][[/noparse]command] 'repeat the command back ' (do things with the command) LOOP no_command: 'do something if there is no command received, blah blah blah
How should I modify this if I want to implement flow control? The Basic Stamp programming manual discusses this somewhat, but assumes a connection for regular serial (not Bluetooth serial emulation) and I am not sure if it is supposed to work the same and what pins to use.
Thank you for your patience - I am fairly new to PBASIC programming.
Comments
http://forums.parallax.com/showthread.php?p=793833
It has a VB2008 interface for connecting to the Bluetooth and the BS2 code.
I also did not realize that the eb500 had to be switched into flow control mode first through the command interface.
For PC/BASIC Stamp communication, it's best for the BASIC Stamp to tell the PC when it's ready for a message. The PC can just wait patiently until it receives that signal, and then send its message. This protocol arrangement is much more important that flow control.
Good luck with your project.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Andy Lindsay
Education Department
Parallax, Inc.