News for hackers. Stuff that matters.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by djbusby on Sunday June 16, 2024 @01:27PM (#40698665)
Are there loads of driver support for those USB/GPIO things? I've only done that on PI and the Python libs made it super easy. Now it's one more thing to solve research rather built-in.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by blacksmith_tb on Sunday June 16, 2024 @01:58PM (#40698878)
I don't think so - if you needed GPIO on a small x86 the easiest way would be to hook an Arduino / RP2040 to it. That seems like it's still the sweet spot for RPi, esp. the Zero W, if you need small, low-power, full OS and GPIO.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by ckemere on Sunday June 16, 2024 @02:52PM (#40699189)
This.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by zrail on Sunday June 16, 2024 @02:52PM (#40699190)
Not really. I've been researching this extensively lately to try to add GPIO to my stack of Dell Wyse 3040s.

Options with mainline linux kernel drivers:

- MCP2221A (i2c + 4x GPIO)

- CP2112 (i2c + GPIO)

Options without kernel support:

- FT232H

- Arduino nano and clones

- Raspberry Pi Pico running some interesting firmware

- ESP32 running something like ESPHome (completely separate from host)

I've chosen the Pico for now and forked the u2if project for firmware and host support[1]. I also put together a generic ESPHome-compatible protocol server in python to tie my widgets to Home Assistant[2].

[1]: https://github.com/peterkeen/u2if

[2]: https://github.com/peterkeen/aioesphomeserver

Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by gsich on Sunday June 16, 2024 @03:06PM (#40699286)
I have seen a I2C implementation on the RP2040 that works with native support.

https://github.com/Nicolai-Electronics/rp2040-i2c-interface

Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by zrail on Sunday June 16, 2024 @03:30PM (#40699461)
Yep, that one is pretty cool too. It only does one i2c bus so it seems like it underuses the hardware a bit, but the mainline driver is pretty valuable.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by numpad0 on Sunday June 16, 2024 @07:36PM (#40701002)
Why do everyone latch onto bit-banging pins from Linux??? Isn't that going to exhibit wildly unpredictable delays? Wouldn't you normally compartmentalize hardware handling into an OS-free or hard-realtime microcontroller and let the uC communicate with host CPU in less-realtime manners?

You can roll your own "RGB temperature sensing modem" and get/set values with `bash` and `expect` over ttyUSB, no one PWM controls RGB LEDs on a gaming keyboard straight from a task tray app. Trying to wrestle GPIO problems that way is going to be unnecessarily hard.

Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by zrail on Sunday June 16, 2024 @08:23PM (#40701235)
Not sure which part you're referring to, but I agree. The u2if firmware I'm using has an interface type that generates the addressable LED bitstream with the RP2040's PIOs. The host software dumps the pixel color values over USB CDC into a buffer on the RP2040, then when it's done the firmware tells the PIO to read the buffer with DMA and stream out the precisely timed LED bitstream.

Currently it's running in "one light string per PIO" mode but there's an inaccessible mode where one PIO can do up to 8 strings simultaneously. The pins have to be physically adjacent, though, so it's a bit more difficult to set up in a generalized way.

Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by chrisjj on Monday June 17, 2024 @12:59AM (#40702447)
> an inaccessible mode where one PIO can do

Clarification please. I thought inaccessible meant cannot do :)

Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by zrail on Monday June 17, 2024 @05:58AM (#40703970)
Well, sure :) It's a function present in the PIO code that isn't called by the current firmware setup.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by chrisjj on Monday June 17, 2024 @07:47AM (#40704625)
Cool. Thanks.
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by bee_rider on Monday June 17, 2024 @12:33AM (#40702317)
Ah, yeah, that’s the right way to do it, but if you can get away with using a Pi you don’t have to write a second program for your Arduino, haha. People who are happy to do it the right way were already well served, right?
Re:The Raspberry Pi 5 Is No Match for a Tini-Mini-Micro PC by -mlv on Sunday June 16, 2024 @06:19PM (#40700590)
A lot of those used cheap Dell minipcs come with serial ports and the slightly biger ones may have a parallel port.