[PD] Current best practice for GPIO pins on Raspberry Pi?

Yann Seznec yann at yannseznec.com
Fri Nov 10 11:01:46 CET 2023


Thanks all. I ended up going with Patrice’s solution, making a python script that accesses the GPIO pins and sends the data through OSC. I have no prior knowledge of Python so I had been avoiding this approach, but it turned out to be pretty straightforward. 

If anyone now or in the future would like an extremely bare-bones but functional example that takes button inputs from Raspberry Pi GPIO pins and sends them to Pure Data, I’ve put a minimalist example up on my GitHub along with some documentation. This is primarily for my future self, but perhaps it will be of help to others: https://github.com/yannseznec/gpioOSCpd




> On 8 Nov 2023, at 16:13, Patco <colet.patrice at gmail.com> wrote:
> 
> Hello,
> 
>  an alternative is about using a python script that communicate with PureData through OSC, it can be done with abstractions on pd side and examples provided by python users.
> 
> Best regards,
> 
> patco
> 
>> Le 8 nov. 2023 à 15:14, Yann Seznec <yann at yannseznec.com> a écrit :
>> 
>> Hello,
>> 
>> I’m wondering what the best option is nowadays for using the GPIO pins on a Raspberry Pi in Pure Data. 
>> 
>> Wiring Pi seems to be no longer available, as far as I can tell. I’m not sure what other options there are?
>> 
>> One option suggested elsewhere for inputs was to use the “retrogame” script to turn GPIO pin activity into keyboard presses and use the [key] object in Pd, but I can’t seem to get that script to work properly yet. 
>> 
>> Any suggestions would be great, thanks in advance.
>> 
>> Yann
>> 
>> 
>> _______________________________________________
>> Pd-list at lists.iem.at mailing list
>> UNSUBSCRIBE and account-management -> https://lists.puredata.info/listinfo/pd-list
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20231110/1dadcbed/attachment.htm>


More information about the Pd-list mailing list