**** BEGIN LOGGING AT Wed Sep 22 02:59:57 2021 Sep 22 07:50:54 is there a socat like program or library which is BSD-like licensed? Sep 22 07:56:30 Probably not one that would do all, but if there's some specific part of socat you need, then probably yes. Sep 22 07:58:08 yeah, I wouldn't need the whole functionality, just something more basic like opening files, tcp connections and maybe serial ports, without anything fancy at all Sep 22 08:02:54 truth is, my needs are pretty basic so I could really write it myself, but you know, if there's something already there, why would I write it from scratch? Sep 22 08:03:41 netcat can do unix, udp and tcp sockets Sep 22 08:03:56 (but not serial) Sep 22 08:06:31 And you probably want the one from openbsd (unfortunately there is no portable version though) Sep 22 08:10:41 mmm I think I'm gonna need to write my own thing Sep 22 08:10:52 I've just realized I need more than read() and write() over those open descriptors Sep 22 08:11:10 I'd like this to also interface with SPI drivers and also some custom rs232-spi converter Sep 22 08:16:46 Maybe you should write multiple things :) Sep 22 08:17:10 I don't know exactly what I should write Sep 22 08:17:22 multitool Sep 22 08:17:32 Reimplement everything! Sep 22 08:17:34 we're developing a new signal generator board based on an analog devices chip that is programmed by spi Sep 22 08:18:09 we are using it via a custom fpga board too, which has a proper spi controller that will communicate with the chip Sep 22 08:18:18 so I program it using spidev's linux interface from userspace Sep 22 08:19:10 but this same board, will also be interfaced via a rs232-spi converter, so I won't be able to use spidev interface, but a series of ascii commands that will translate to spi transactions Sep 22 08:19:20 so... same device, but interfaced via two different systems Sep 22 14:52:00 https://github.com/agamez/libARTio Sep 22 14:52:02 welp Sep 22 14:52:04 that's the start of it Sep 22 14:54:01 this is going to be a not complete reimplementation of socat in the form of a library Sep 22 14:54:08 so totally a different thing lol Sep 22 14:55:17 but I'm gonna try to use the same addressing as socat, so this socat's example should work in the end $ socat readline /dev/ttyS0,raw,echo=0,crlf Sep 22 14:57:07 but it'll probably be a very simple thing with just a couple of controllers: generic open, serial port, tcp client and the propietary code we use for the rs232-spi converter Sep 23 00:35:03 aiui not only the interfaces differ but also the payload data aka protocol? Then it doesn't make much sense integrating it all into one blob, no? Sep 23 00:39:11 I'd probably implement a device driver for the rs232-spi converter that exposes a /dev/SPIrs232 device interface, Sort of similar to /dev/ttyUSB which hides the USB part of a USB<->rs232 dongle **** ENDING LOGGING AT Thu Sep 23 02:59:57 2021