samedi 20 août 2016

which design pattern to use in python [on hold]

I never did much programming except for some scripting, in short I know the words, I'm able to read the menu and order but wouldn't come close to writing a book.

My question, in short, i need a program which handles a protocol of some kind. The protocol consists of sequential frames, with the typical construction: - header (start of frame, target address, length) - a body (starting with a type-of-body field) - a trailer (crc and end of frame).

I need to both generate packets (with various arbitrary data) and parse packets, verifying their content.

I am well able to write this in DIY style, but I'd like to learn from it and e.g. force myself to learn a thing about design patterns yet I couldnt figure out which one to rely upon.

Could anyone give me a little push in the right direction?

Thanks

Aucun commentaire:

Enregistrer un commentaire