RPI Pico STDIO (C/C++) UART
ฝัง
- เผยแพร่เมื่อ 30 ก.ย. 2024
- Visit PCBWay, the sponsor of this Video: www.pcbway.com/
The Raspberry PI Pico, Pico-W and any RP2040 board using the Pico SDK can put STDIO over USB or UART. This is a simple change to the CMake file.
Did you know you can also select which GPIO PAD is used for this. So you are not limited to STDIO over `GPIO 0 and GPIO 1.
An example showing this is at: github.com/jon.... Or check out my blog on this at drjonea.co.uk/....
Sponsor: PCBWay: www.pcbway.com/
PCB prototyping, assembly, 3D printing, CNC, sheet metal fabrication and injection moulding. - วิทยาศาสตร์และเทคโนโลยี
Is it possible to have both uart and usb active? Like if I wanted to read something in from RX and then print it over usb is that possible?
Absolutely. That is not much different from what I am doing using USB to run MicroROS while using Uart for telematry.
When I use stdio over usb and UART0 driver pin other then default pins for stdio to read data from sensors, serial monitor does not prints anything.
Serial monitor, does that mean you are using Arduino library? I have only focused on the Pico SDK but not had an issue using both UARTS and on different pins.
@@DrJonEA I'm using pico c/c++ SDK
Me too. I talk through some of this a bit more in my blog: drjonea.co.uk/2023/04/05/rp2040-stdio-over-uart-non-default-gpio/. Hope that helps.