Brian Starkey
e91aa0b747
Fix debug build
Reported by ghubcoder in #2 , debug builds were broken due to
incorrect MAX_NARG macro - it should be COMM_MAX_NARG.
před 2 roky
Brian Starkey
9bdc2fded0
Fix some warnings and optimise for size
Looks like removing printf drops about 10kB.
před 2 roky
Brian Starkey
8a71b096b9
tcp_comm: Rework receive handling
Now whatever arrives will get stored, and then used up by as many stages
as possible.
před 2 roky
Brian Starkey
a57cac28f1
Port over all the other commands
...but not it's obvious - we can't assume each packet nicely
encapsulates a single stage, it might all arrive in one go.
So the current "recv" implementation can't work. d'oh!
před 2 roky
Brian Starkey
fc55e221d3
tcp_comm: Make RX length checking more strict
Don't allow data which is too long.
před 2 roky
Brian Starkey
e0da727e96
Factor out the TCP code
Now isolated for easy re-use. Should split it into a separate library.
před 2 roky
Brian Starkey
3bdad9eb2b
Implement "comm", a fairly close port of M0o+'s version
před 2 roky
Brian Starkey
f62b584605
Refactor the example a little
před 2 roky
Brian Starkey
04bd83cae5
Initial basic TCP server
Based on the Pi example
před 2 roky