So.... got heaps done on the train this morning.
I am moving away from using python lists in the Tuner, and trying to stay with more binary suitable data types. It was suggested to me to use the Structs module, however it doesn't handle variable length packets
Sooo... I decided to convert all the code to use 8 bit strings and avoid looping as much as possible. Python 2.6/3.0 have a binary string data type, but I want to keep it 2.5 compatible.
Spent an hour on it this morning and pretty much have it almost converted. So far I have taken out twice as much code as I have added/modified, and removed almost every loop I have come across. The receive buffer processing code has gone from two monolithic functions, to two tiny ones
I have updated
with my progress (although it hasn't been tested/prob wont run). Should have a working version tomorrow!! Tempted to work out in now at work, but it'll wait until tonight.