Problem solved:
Solutions to all my problem were found in: https://opencoursehub.cs.sfu.ca/bfraser/grav-cms/cmpt433/guides/files/PRUGuide.pdf
The first problem ( fatal error #1965: cannot open source file “stdint.h” ) was solved with:
When compiling if you see the error:
"ledFun.c", line 2: fatal error #1965: cannot open source file "stdint.h"
It likely means that the PRU compiler cannot find the headers on the board. You need to add
the following to the INCLUDE define in the project’s Makefile (the one being executed on
the BBG):
--include_path=/usr/share/ti/cgt-pru/include
The second problem I had was ( error: cannot find file “libc.a” ) not being found this solution was also found in this document:
Makefile changed to:
“--search_path=/usr/share/ti/cgt-pru/lib/” before --library=libc.a
“--include_path=/usr/share/ti/cgt-pru/include” at end of INCLUDE define
After changing these make commands my code compiled without error and is working. The skew problem isnt present anymore. The solution to the skew problem can also be found in this document:
When compiling the program, if you see the error:
make: warning: Clock skew detected. Your build may be incomplete.
It means that your BBG’s clock is not in sync with your host. Get your BBG access to the
internet (see previous guides; test with ping google.com) and the network time protocol
(NTP) on the BBG should then automatically update your BBG’s time.
Thanks to Brian Fraser for the PRU guide doc