I’m trying to get my Beaglebone Black Rev C to toggle P9_27, and I haven’t been able to get it to work. I followed the instructions above and got the 06io example to build and run from the pru-cookbook-code. My code is quite short:
// This code accesses GPIO without using R30 and R31
#include <stdint.h>
#include <pru_cfg.h>
#include "resource_table_empty.h"
#include "prugpio.h"
volatile register uint32_t __R30;
volatile register uint32_t __R31;
void main(void)
{
uint32_t *gpio = (uint32_t *)GPIO3;
while(1) {
gpio[GPIO_SETDATAOUT] = P9_27;
__delay_cycles(100000000);
gpio[GPIO_CLEARDATAOUT] = P9_27;
__delay_cycles(100000000);
}
}
My other thread is here: pru coding and Debian 13 It seems almost like linux isn’t configuring the mode correctly, but I’m not sure how to lookup the mode for the pin in the 6.19. The old pin-config tools don’t work.