Hi,
I am facing problem in toggling beagle bone gpio from pru-icss , i am using gpio1_13 (which is pru0_r30_15 in pru-icss) pin in mode 6. Below is my example which i have used, please let me know what is the wrong,
#include <stdint.h>
#include <pru_cfg.h>
#include "resource_table_empty.h"
volatile register uint32_t __R30;
volatile register uint32_t __R31;
void main(){
volatile uint32_t gpo;
/* Clear SYSCFG[STANDBY_INIT] to enable OCP master port */
CT_CFG.SYSCFG_bit.STANDBY_INIT = 0;
// CT_CFG.GPCFG0 = 0;
/* Toggle GPO pins TODO: Figure out which to use */
__R30 = 0x0000;
/* TODO: Create stop condition, else it will toggle indefinitely */
while(1){
gpo = __R30;
gpo ^= 0xF;
__R30 = gpo;
__delay_cycles(100000000);
__delay_cycles(100000000);
}
/* Halt the PRU core */
__halt();
}