I need Max to talk with a service running on another machine. It speaks a proprietary protocol over both UDP and TCP. I have a library that constructs the packet payloads. They are stored in buffers of unsigned bytes; the message length varies from message to message but is always known.
My initial goal is to write a simple external (in C) that, upon receiving a bang on its sole inlet, will output the raw message data on its outlet packaged such that it can be sent via mxj net.udp.send.
So, I'm pretty new to Max and writing externals--I've written a couple very simple ones--and I'm not sure how I should be packaging my data for output from this external. Any advice would be greatly appreciated. Examples even more so.