A system that I'm developing will use XBee modules for a point to point connection between a micro-controller and a PC. Data will only be sent only in one direction -Micro to PC and at 10-20fps. The data portion of each frame will be 4 Bytes. XBee modules will be run in transparent mode(to begin with at least). On the PC side I'm using python to grab the data from the serial port.
Initially I wrote a very simple python program to grab data 4 Bytes at a time from the serial Port, which worked fine when tested with a virtual com connection (I haven't run any real world tests yet though), but I decided to experiment and ended up implementing a simple frame structure like this.
sync_flag | Payload_length | frame_number | payload
After some research I discovered HDLC and now I'm considering implementing something similar albeit simpler. Before I endeavor to do so Id like to hear what others have to say.
When is such a protocol merited?
What have you done when you implemented your XBee networks?
Being somewhat new to this area I'm sure there's some relevant specifics Iv left out, but at the same time I didn't want to make the question too narrow / system specific, but if necessary Ill update the question.