#define MUX_VAL(OFFSET,VALUE)\ writel((VALUE), AM335X_CTRL_BASE + (OFFSET));--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to the Google Groups "BeagleBoard" group.
To unsubscribe from this group and stop receiving emails from it, send an email to beagleboard...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Has anyone used the Pin Mux Utility? I'm trying to enable R30 and R31 on my PRUs.
Am Montag, 19. Mai 2014 07:08:21 UTC+2 schrieb foreverska:
Has anyone used the Pin Mux Utility? I'm trying to enable R30 and R31 on my PRUs.
debian@beaglebone:~/Desktop/riot/pru_test$ config-pin -a P8.15 pruincape-universal overlay not foundLoading cape-universal overlaybash: line 0: echo: write error: File existsError loading device tree overlay file: cape-universaldebian@beaglebone:~/Desktop/riot/pru_test$ cat /sys/devices/bone_capemgr.9/slots
0: 54:PF--- 1: 55:PF--- 2: 56:PF--- 3: 57:PF--- 4: ff:P-O-L Bone-LT-eMMC-2G,00A0,Texas Instrument,BB-BONE-EMMC-2G 5: ff:P-O-L Bone-Black-HDMI,00A0,Texas Instrument,BB-BONELT-HDMIdebian@beaglebone:~/Desktop/riot/pru_test$ config-pin overlay cape-universal
Loading cape-universal overlaybash: line 0: echo: write error: File existsError loading device tree overlay file: cape-universaldebian@beaglebone:~/Desktop/riot/pru_test$
#define CONST_PRUDRAM C3
#define TOOTH_COUNTER R5
lpe:ADD TOOTH_COUNTER, TOOTH_COUNTER, 1QBEQ lpe, r31, 0
SBCO TOOTH_COUNTER, CONST_PRUDRAM, 0, 4
debian@beaglebone:~/Desktop/riot_bin$ sudo config-pin -q P8.15P8_15 Mode: pruindebian@beaglebone:~/Desktop/riot_bin$ sudo config-pin -q P8.45Pin is not modifyable: P8_45 lcd_data0debian@beaglebone:~/Desktop/riot_bin$ sudo config-pin -q P8.20cape-univ-emmc overlay not foundrun "config-pin overlay cape-univ-emmc" to load the capedebian@beaglebone:~/Desktop/riot_bin$ config-pin overlay cape-univ-emmcLoading cape-univ-emmc overlaybash: line 0: echo: write error: File existsError loading device tree overlay file: cape-univ-emmc// enable ocp master.
LBCO r0, C4, 4, 4
CLR r0, r0, 4
SBCO r0, C4, 4, 4
// try to set gpio address
// gpio on
mov r1, 0x4000 # gpio 0, bit 14, p9.29
mov r0, 0x44E07194 # gpio 0 set register
SBBO r1, r0, 0, 4
// led on p9.26 light up here, devmem2 shows this address was set
// readback
LBBO r1, r0, 0, 4
// readback matches!
// gpio off
mov r1, 0x4000 # bit 14, p9.29
mov r0, 0x44E07190 # gpio 0 clear register
SBBO r1, r0, 0, 4
// led on p9.26 shuts off here, devmem2 shows this address was set
LBBO r1, r0, 0, 4
// readback matches
// try to set config address, P8.40
mov r1, 0x25
mov r0, 0x44E108B8
// devmem 2 says 0x44E108B8 = 0x5 (what i have it set to in dts)
SBBO r1, r0, 0, 4
// devmem 2 says 0x44E108B8 is still 0x5!
LBBO r1, r0, 0, 4
// readback doesn't match! r1 is now 0x5!
I don't believe the reads/writes to the GPIO registers would have worked without the OCP master being enabled.
Thanks, I'll check out the library to see what magic is missing from that code.
A miss click and a miss post ...
The PRUSS can access the Control Modul pin mux registers. It's working for a lot of libpruio users. Did you enable the OCP master port?
--
For more options, visit http://beagleboard.org/discuss
---
You received this message because you are subscribed to a topic in the Google Groups "BeagleBoard" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/beagleboard/ukPLH3-1hbA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to beagleboard...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.