I’m looking to make a radio receiver (433MHz) on the pocketbeagle with code in C.
I have SPI sort of setup with the spidev code, but if there is a better library, I want to know about it!
My problem begins with the interrupt setup (I mean code) , because I’ve only found a javascript sketch for that.
Is there a C library including interrupt support?
Receiving interrupts has nothing to do with SPI, but the GPIO subsystem can pass edge interrupts (configurable: rising edge, falling edge, or both) via a file descriptor which you can then integrate in whatever event loop you like.
I’ve written a tiny C library for sysfs gpio that demonstrates this, including how to integrate with sd-event (libsystemd’s event loop).