This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PRU access to ddram on am335x / beaglebone

Other Parts Discussed in Thread: SYSCONFIG, AM3359

I just want to test my understanding.  I wrote a small program that fills main memory (DDR) from the PRU over L3.  It basically looks like this:

#define addr r8
#define size r9
#define fillword r10
#define count r11
        xor r5,r5,r5 // clear a counter to keep track of how many words we have filled
l1:
ST32 fillword, addr // copy the fill word (0xDEADBEEF) to addr
add addr, addr, 4 // point to the next address
add r5, r5, 1 // increment the number of writes counter
sub count, count, 1 // decrement the count of words left
qbne l1, count, 0 // if words left !+ 0, loop and do it again

done:
HALT

Running this little bit, it seems to get stuck at the ST32, with STATUS = 0x00000010 (address of that instruction, which is really an SBBO), and CONTROL = 0x00008003 (which indicates that it is running).

Aside from the fact that there are more efficient ways to do this with PRUv2 (don't have the assembler yet) ... shouldn't this work?

addr = 0x8f240000 (for example - it changes depending on when uio_pruss.ko got loaded).

  • Hi Chris,

    The only official PRUSSv2 feature set supported by TI is the Industrial communications protocols included in the Industrial SDK: http://www.ti.com/tool/sysbiossdk-ind-sitara.

    (However, to answer your question:  The AM335x PRU firmware will hang when reading or writing to an address external to the PRU Subsystem because the OCP master port is in standby and needs to be enabled in the PRUSS CFG register space, SYSCFG [STANDBY_INIT].)

    Regards,

    Melissa

  • Yes, but the PRU is so cool and useful, and the instruction set is so easy to learn, that I'm going to proceed at my own risk and have fun doing it!

    Thanks for your help, Melissa.

    --Chris

  • It works now.  It confused me because it was in "smart idle" / "smart sleep" mode.  I looked through the TRM and found no explanation of what that means.  It sounded good at first (it's smart!) but if it stays asleep even when you need it then it doesn't do what I expected.

    If there's some doc you can refer me to that explains these "smart" modes in PRUSSv2 SYSCONFIG please let me know.  (for AM3359)

    --Chris