Skip to content

Instantly share code, notes, and snippets.

View aaronbrown1988's full-sized avatar

Aaron Brown aaronbrown1988

View GitHub Profile
@jperkin
jperkin / rpio.md
Last active October 13, 2023 16:56
Raspberry Pi GPIO Comparison

Comparing node.js GPIO implementations

Here are two simple programs testing the performance of my rpio library against popular alternatives which use the /sys interface (with the number of npm stars indicated for a rough idea of popularity).

rpi-gpio (9 stars)

This test is based on an example on the rpi-gpio page.

As modules which uses /sys depend upon asynchronous behaviour they require callbacks to ensure that the next operation starts only when the previous one has completed.