Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

undefined symbol __PRU_CREG_MEM #6

Open
Guidomo opened this issue Oct 28, 2014 · 3 comments
Open

undefined symbol __PRU_CREG_MEM #6

Guidomo opened this issue Oct 28, 2014 · 3 comments

Comments

@Guidomo
Copy link

Guidomo commented Oct 28, 2014

Hi,
when I try to compile the blinkled_pru.c file I get the following output:

undefined symbol: __PRU_CREG_MEM blinkled_pru.obj
first referenced in file: blinkled_pru.obj

error: unresolved symbols remain
error: errors encountered during linking; "PRU_tests.out" not built

Compilation failure

hope somebody can help me.

@jadonk
Copy link
Contributor

jadonk commented Feb 18, 2015

Any update on this issue?

@jadonk
Copy link
Contributor

jadonk commented Feb 19, 2015

You need to specify the stuff in lnk.cmd and then it works. Here's how I build blinkled.out: https://gist.github.com/jadonk/a6432fde48408e72fdd7

Note that I didn't run the hex conversion at this point because bin.cmd is missing. Also, you'll need to install the PRU compiler on the BeagleBone using 'apt-get update && apt-get install ti-pru-cgt-installer'.

@mattcarpenter
Copy link

@Guidomo To elaborate on @jadonk's suggestion in his Gist, you need to add the PAGE 2 block to your existing lnk.cmd (don't just replace the MEMORY section.) I'm using AM3359_PRU.cmd. Once I made my MEMORY section look like this, I was able to compile and link blinkled:

MEMORY
{
    PAGE 0:
      PRUIMEM:   o = 0x00000000  l = 0x00001000  /* 8kB PRU0 Instruction RAM */
    PAGE 1:
      PRUDMEM:   o = 0x00000000  l = 0x00001000  /* 8kB PRU Data RAM 0 */
    PAGE 2:
       MEM      : org = 0x00026000   len = 0x00002000 CREGISTER=4
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants