unrelated request for help

36 views
Skip to first unread message

cncmachineguy

unread,
Mar 16, 2023, 4:08:25 PM3/16/23
to OpenPnP
This is not directly openPNP related, but I know a couple of you can help me. The situation is this:
I have an older machine with a dying control interface (HMI).
It sends data/commands to a magic box across rs232 to give the magic box instructions.

I need to sniff out the data before the control dies altogether as the manufacture no longer supports the control. If I can reverse engineer this communication I can run it from a new puter. The dying control is only a SBC inside a housing. So the hardware side is easy.

I do not have any experience trying to capture data this way so hence my cry for help.

Ian Arkver

unread,
Mar 16, 2023, 4:47:54 PM3/16/23
to OpenPnP
Hi Bert,

If you've a Linux machine and a couple of USB-serial adaptors so you can intercept the connection physically, then I'd recommend socat. socat is pretty handy for this sort of thing.

You should be able to use something like
socat -x /dev/ttyUSB0,b115200,raw,echo=0 /dev/ttyUSB1,b115200,raw,echo=0

This will set the two USB ports to 115200 baud and pass data between them while printing out the traffic in hex (the -x flag).

Below is an example where I'm using TCP sockets instead of UARTs cos I don't have a couple of them handy - shows the idea though.

CU
Ian

Screenshot_SocatSockets.jpg

Ian Arkver

unread,
Mar 16, 2023, 4:58:53 PM3/16/23
to OpenPnP
ps. You might need to experiment with the baud rate and parity settings if you don't know what's on the line.

You can also use the -r and -R options to dump the data to a file to look at later/offline.

bert shivaan

unread,
Mar 16, 2023, 9:30:57 PM3/16/23
to ope...@googlegroups.com
Thanks Ian, I do have some Linux boxes.
I even have some usb to serial adaptors, but prolly I will pick up 2 more. The ones I have are in use talking to machining centers.



--
You received this message because you are subscribed to the Google Groups "OpenPnP" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openpnp+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/openpnp/af68b731-6a8e-48f0-ab1a-d57d3c687c38n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages