Device::PCDuino -- Perl Module for Accessing I/O on the pcDuino
2014-07-21
The Bodgery (my makerspace) was donated a few pcDuinos. These are great little devices, more powerful than the Raspberry Pi, and with a built-in WiFi adapter and Arduino-like pin headers.
One thing it lacked was a Perl interface to the I/O pins. I quickly fixed this oversight with Device::PCDuino.
Currently, GPIO and ADC pins are implemented. PWM should be easy to work out. SPI and I2C look like they’ll be a little more involved (see the Sparkfun examples in C).
Usage is about as simple as can be. Use set_output()
and set_input()
to set the type you want for a given pin, then call output()
and input()
to set or receive values, respectively. See the POD docs and the “examples/“ directory in the distribution for more details.