thomasfla / pico-pio-uart-dma-rs485

Implementing 4x RS485 using pipico PIO and DMA
BSD 3-Clause "New" or "Revised" License
3 stars 0 forks source link

OE offset #2

Closed 0x3333 closed 1 month ago

0x3333 commented 2 months ago

I'm working a project like yours, but with 6 channels, using Pico2 + an ESP32 with Ethernet. Pico2 will do the heavy lifting of communicating with all modules and ESP32 will do the communication.

I read in the code that OE need to be +1 of TX, do you know if this can be -1, like TX 9, OE 8.

Thanks!

image image image
thomasfla commented 2 months ago

Hi,

Nice board,

It should be doable if you change https://github.com/thomasfla/pico-pio-uart-dma-rs485/blob/83979de29e7367074544b1cbcd73a30981da400e/rs485_lib.c#L28 to have the sideset pins begin at OE (the lowest of the two) and change all the sidesets order in rs485.pio. For example

set y, 7 side 0b10 [3] -> set y, 7 side 0b01 [3]