M575 Serial connection using the IO_1 Expansion 3HC
-
Hello.
I am trying to make communication between a wemos ESP board and Duet 3 boards in order to pilot WLED instance directly from GCODE (M118 P5)I managed to declare a serial connection using the AUX2 UART port on the mainboard 6XD with the command M575 in my config.g file
M575 P2 B115200 S2 ; declare the serial communication between Wemos and Duet 3 EB 3HC on second UART
TX from Duet 6XD on IO_1 (io1.out) wired to the RX pin on the Wemos
And the M118 P5 transfer serial order to my WLED board.And it is working very well !!!!
Now I would like, instead of using the 6XD mainboard (all the IO are busy), using the IO_1 of the Expansion Board 3HC.
I have read that the IO_1 is UART capable.
But how to set serial comms parameters with the M575 for an expansion Board ?
I have tried M575 P1.2 ... It is not working....Is-it possible to use an expansion board for that purpose ?
Or do I have to reorganise my wiring to use the mainboard for that ?Thank you
Jeff -
@jeffouille the M575 command currently only supports main board UARTs.
What commands do you want to send to the UART on the 3HC? If it's strings of just a few characters and transmit-only then we may be able to implement that fairly soon.
-
@dc42 Thank you for your answer.
So for the moment, I will wire the serial port to the IO_1 of the mainboard 6XD as it is working and move my button (in this io for the moment) toward the expansion board. It is not a problem I think.The commands that I send to the UART are just json data.
The WLED support json API via Serial : https://kno.wled.ge/interfaces/json-api/
JSON over Serial
You can send commands to the WLED instance via Serial using the JSON API.
To request a JSON response containing the state and info objects, send {"v":true}.for example I send such command :
; TURN ON ALL THE STRIPS M118 P5 S"{""on"":true}" ;LAUNCH HOMING ANIMATION M118 P5 S"{""ps"":1}" ; LAUNCH ALERT ANIMATION M118 P5 S"{""ps"":99}" ; PUT BRIGHTNESS TO 255 M118 P5 S"{""bri"":255}"