Stuart Longland (VK4MSL)<p>Had my first encounter with a Raspberry Pi Pico today.</p><p>I needed a MCU that could enumerate two USB serial ports to a host, have a UART interface for an external device, and control a heap of GPIOs. The RPi Pico was a little light on GPIOs, but add a couple of I²C expanders, and we were in business. The idea was one USB serial interface (call it port 1) would be for control commands, and serial traffic on the other (port 2).</p><p>The UART on the thing is hooked up to a multiplexing circuit with two RS-485 transceivers and a TTL buffer, so via port 1, I can put port 2 into any of: TTL serial, RS-485 (via either transceiver), or RS-422 (both transceivers, using one for receive and the other for transmit). The GPIOs sense things through optical isolators and tickle devices via reed relays.</p><p>Haven't wired the thing up yet, but TinyUSB has a dual CDC-ACM example that was a doddle to get going on the Pico… so I don't expect it to be a big job.</p><p>Not sure if this can be done in <a href="https://mastodon.longlandclan.id.au/tags/MicroPython" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>MicroPython</span></a> … I think I'll be using C, but that's fine, C will get the job done.</p><p>Tomorrow should be interesting.</p><p><a href="https://mastodon.longlandclan.id.au/tags/RaspberryPi" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RaspberryPi</span></a> <a href="https://mastodon.longlandclan.id.au/tags/RaspberryPiPico" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>RaspberryPiPico</span></a> <a href="https://mastodon.longlandclan.id.au/tags/TinyUSB" class="mention hashtag" rel="nofollow noopener" target="_blank">#<span>TinyUSB</span></a></p>