Problem:
The embedded system that I work on can generate MegaBytes of data per second. I am looking to automatically analyze the captured bus data for sequence errors.
For instance, one of the protocols is for file transfer which includes transactions between:
- clients
- file server
- storage device
Making the problem tougher is that:
- protocols can be complex, be recursive, and need to remember state data, i.e. reading file 1 block at a time
- transactions from multiple clients occur simultaneously.
- bus contains multiple protocols, i.e. file server, processor control, health statusing, etc. and then lots of data that is a dont care.
My first thought was to write explicit code to walk through state machines. Problem is that each state machine would be a small complex project in itself and probably could not be off loaded to other users on my team.
Next thought is to write a script that will parse a set of protocol rules and generate PERL for Parse::RecDescent. (Maybe a little slow but good for prototyping.)
Very simple non-recursive file transfer example might look like:
Msg : File_Request -- client to file server Type Read File_ID 44 Offset 0 Size 400 Program 50 Msg : File_Response -- file server to client Type Read File_ID 44 Program 50 Status Request_ACK Msg : Get_File -- server to storage device Type Read File_ID 44 Offset 0 Size 400 Address 1AF3000 Msg : File_Data -- server to client Data 0000 ... Data FEF2 Msg : Get_File_Response -- storage device to server File_ID 44 ACK_NACK Complete Msg : Get_File_Response -- server to client File_ID 44 ACK_NACK Complete Msg : File_Response -- file server to client Type Read File_ID 44 Program 50 Status Complete
Are there better technics for analyzing protocols and state machines?
Thanks,
Ronny
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |