Parsing Serial data from PIC to App Dev

Discuss PC Developer and Web Developer projects and features here.
Post Reply
jay_dee
Posts: 215
http://meble-kuchenne.info.pl
Joined: Sun Dec 20, 2020 6:06 pm
Has thanked: 81 times
Been thanked: 56 times

Parsing Serial data from PIC to App Dev

Post by jay_dee »

Hi,
Working on my tool to allow diagnostic strings to be sent from a Micro to App Dev and then Display info on the Console Text Viewer.
This is to allow embedded projects to be quickly checked in the field for status or error codes.

The PIC FC test program, toggles between sending a couple of different simple strings. A example string would be "~4,2,Temp,1234;"
This has a unique character to identify the start of the string. "~"
Console's Cursor Line, example 4
Console's cursor Column. eample 2
Name of the diagnositc variable. example "Temp"
a string of the variables value. example "1234
The end of the message is marked by ";"

The PIC is sending this at a fairly slow 19200 and a terminal program confirms all of the data is sent as expected.

I created a App Dev program to recieve and parse this data and then put it into a Console Viewer, at the specificed Cursor location.
The parser seems to work fairly well, I expect there are better ways but I dont know any better!!

However when I deploy the App, it seems pretty slow and clunky in recieving and processing the data.
It also seems to miss messages.
I appreciate the there are many layers of software involved, are there any inprovments that can be made to the way I handle the incoming serial data in App dev to increase the update rate and reduced the number of dropped messages?
SendDiagnostic_V1.fcfx
Send
(25.85 KiB) Downloaded 231 times
RecieveDiagnositic_V1.fcsx
Recieve
(38.78 KiB) Downloaded 236 times
So... :?
what is the best way to handle incoming Serial Data?
Can the App or console element be made to refresh in a smoother/quicker manner?
Any feedback on improvement to approach to the parser, also much appreciated.
Many thanks, J.

medelec35
Matrix Staff
Posts: 1954
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 626 times
Been thanked: 656 times

Flowcode v10 Re: Parsing Serial data from PIC to App Dev

Post by medelec35 »

Hi J.
Have you seen the new PC developer Apps here?
For example Serial Comms Worked Example - PC Developer , and there are other examples.
PC developer is just renamed App developer.
Martin

Post Reply