Serial communication parsing speed problem

Deploying to Windows? Utilizing VB Script execution? This is the place to ask Windows-specific questions.

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller, robinmiller

Post Reply
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 22
Joined: Tue May 06, 2008 5:33 am
Location: Las Vegas

Serial communication parsing speed problem

Post by tcbcats » Tue Dec 15, 2015 4:20 am

Live code Indy...
PC 3 Ghz, XP or 7 OS.

In Live code 5.53 my app receives and parses a 25 byte data packet @ 9600 baud and places the result into a text field. The packet is received via the read from file... every 800 milliseconds.
Everything works well when the app runs on a real XP PC and XP/PC netbook. The application receives and parses a packet with time to spare before the next packet arrives 800 milliseconds later.

If I create the app (same code) in Live code versions 7 and higher,the parsing or reading from file time becomes about 3 times longer to complete. but it still works on a real PC but not on a netbook.
When the failure happens, the serial buffer in the PC fills up because the app cannot collect and parse the serial packets fast enough and the app or PC hang. The recovery can only be had by the three finger salute.

My hardware for the serial input is a usb to serial device with the latest drivers.
The serial data packet uses no hardware or software handshake so there is no way that I know of the keep the PC serial buffer from overflowing.
The serial speed is 9600 so there should be ample time for the app to read and parse the serial bytes from the packet in near real time.

The live code bug reports seem to have a lot of serial communication issues noted on live code 7 and higher. I tried Live code 8.0 dp11 and the internal speed of my serial and text processing is even slower than 7.XX

All my apps use some form of serial communication and they all work on Live code 5.53 and lower.
Has anyone else using serial communication in Live code seeing any internal processing speed reduction?
What could be running in live code 7 and higher that makes serial data collection (from a file) or parsing collection slower?

Posts: 1577
Joined: Tue May 28, 2013 2:20 pm
Location: Italy

Re: Serial communication parsing speed problem

Post by MaxV » Wed Dec 30, 2015 10:59 am

Did you try this?

Code: Select all

set the serialControlString to "BAUD=9600 DATA=8 STOP=1 PARITY=N xon=off to=off dtr=off rts=off "
Did you read this? ... ta_95.html
Livecode Wiki:
My blog:
To post code use this:

Post Reply

Return to “Windows”