Hi,
The main goal is to use a Raspberry Pi Pico to control several devices, send acquisition data and receive commands from a TCP Server (Windows PC) over a wired network.
The Pico would interface the wired network via a UART to Ethernet adapter configured as TCP Client. This will be replicated to more than 100 devices. The messages are a few bytes every other hundreds of milliseconds.
This is the CH9121 based UART to ETH:
https://www.waveshare.com/wiki/2-CH_UART_TO_ETHI managed to inspect and change the adapter configuration via UART and through NetModuleConfig.exe LAN utility. The device responds to pings (ICMP) over the network and DHCP works well.
Wireshark does not show any TCP packets.
The TCP Server code is tested against several TCP Clients on other PC over the same network. Used also other third party TCP Client and Server utilities for debug.
I understand the device configuration parameters and the packet send mechanism (packing buffer full and timeout).
This is an handy building block for the new generation of powerful small MCUs. It blows my mind the lack of online feedback about the usage of these devices (or should have seen the red flag). In my defense CH912X has an entry on Github Cursed Hardware Collection...
My question is. Did anyone managed to make one of these things to work properly?
CH9121 is a chip realizing transparent transmission between network and UART. It integrates TCP/IP protocol stack, which can realize bidirectional transparent transmission between network data packets and serial data. It has 4 working modes: TCP CLIENT, TCP SERVER, UDP CLIENT and UDP SERVER. The serial baud rate can be up to 921600bps. It can be easily configured by upper computer software or serial commands, which is convenient and quick.
● Internal Ethernet MAC layer and PHY layer
● Realize bidirectional transparent transmission between serial data and network data
● Support 10/100M, full/half duplex self-adaption Ethernet interface, compatible with 802.3 protocol
● Support automatic MDI/MDIX line conversion
● Support DHCP automatic access to IP address, and DNS domain name access
● Set the chip working mode, port, IP and other network parameters through upper computer software and serial commands
● Support four working modes: TCP CLIENT, TCP SERVER, UDP CLIENT and UDP SERVER
● Support up to two independent UARTs, independent transparent transmission
● Serial baud rate supports 300bps ~ 921600bps
● Serial TTL level, compatible with 3.3V and 5V
● UART supports full-duplex and half-duplex serial communication, and RS485 transceiving automatic switch
● Support and provide virtual serial software
● Support KEEPALIVE mechanism