I managed to access GPIO registers according to the datasheet by mmaping the peripherals-base-address provided from "/proc/device-tree/soc/ranges"and made my own user-space library and just wondering if this is applicable for any other peripheral registers like these from DMA, PWM, TIMER, INTERRUPTS and such. Can I access them the same way as the GPIO registers and create a user-space library to manage these peripherals? ... to do DMA operations, to manage SPI/I2C peripherals, to manage PWM ...



For instance my pigpio library.

Also see Minimal GPIO access.

This C code has a minimal set of functions needed to control the GPIO and other Broadcom peripherals. The program requires root privileges to run. See Tiny GPIO access for an alternative which controls the GPIO (but not the other peripherals) and does not require root access.

| improve this answer | |
  • hardware timed PWM on all of GPIO 0-31 ... this is what I was trying to do ... on at least 8 GPIOs. Thank you! – Memos Electron Jan 22 '18 at 18:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.