Hello.
I am looking into using a few CM4 as remote sensor loggers and controllers. That means a built-in web server (written in c) and just 2x UARTs. One of the UARTs will be used for half-duplex RS485/MODBUS RTU (3rd party modules and sensors) and the other UART as plain onboard module communication (3rd party onboard module/gateway).
I have tried without success to find some specific info concerning the CM4 UARTs.
So if anyone is kind enough to share his experience on the matter i would like to know the following :
1) What is the Compute Module 4 Rx and Tx hardware FIFO buffer size? Since both MODBUS packets and also the gateway's packets will be of specific size, anything higher than 16 bytes (ex. 32) will be enough to avoid buffer overflows.
2) Is the FIFO separate or is it shared for each UART?
3) Does Raspberry Pi's CPU have a built-in half-duplex mode capable of automatically controlling line direction (ex. toggling RTS)? I mean does it support the Linux Kernel RS485 driver? https://docs.kernel.org/driver-api/seri ... rs485.html
4) If there is no hardware direction control for the RS485 transceiver, is there another optimal way to implement direction control with the necessary timing (ex. custom GPIO control with sleep or delay or even cpu cycle burning)?
Again thank you for your time.
I am looking into using a few CM4 as remote sensor loggers and controllers. That means a built-in web server (written in c) and just 2x UARTs. One of the UARTs will be used for half-duplex RS485/MODBUS RTU (3rd party modules and sensors) and the other UART as plain onboard module communication (3rd party onboard module/gateway).
I have tried without success to find some specific info concerning the CM4 UARTs.
So if anyone is kind enough to share his experience on the matter i would like to know the following :
1) What is the Compute Module 4 Rx and Tx hardware FIFO buffer size? Since both MODBUS packets and also the gateway's packets will be of specific size, anything higher than 16 bytes (ex. 32) will be enough to avoid buffer overflows.
2) Is the FIFO separate or is it shared for each UART?
3) Does Raspberry Pi's CPU have a built-in half-duplex mode capable of automatically controlling line direction (ex. toggling RTS)? I mean does it support the Linux Kernel RS485 driver? https://docs.kernel.org/driver-api/seri ... rs485.html
4) If there is no hardware direction control for the RS485 transceiver, is there another optimal way to implement direction control with the necessary timing (ex. custom GPIO control with sleep or delay or even cpu cycle burning)?
Again thank you for your time.
Statistics: Posted by georgatos7 — Wed Apr 10, 2024 10:37 pm — Replies 1 — Views 19