Forum Discussion
Altera_Forum
Honored Contributor
21 years agoPIO devices under uClinux
I'm having a problem getting the PIO ports to work under uClinux. If I try to access the PIO by reading or writing to the memory location, pointed to by the pio struct, then nothing seems t...
Altera_Forum
Honored Contributor
21 years agoI got it working!!!
The problem was entirely mine and present in my code. I apologize for any time that was wasted. Just for anyone else's benefit, the simplest method that worked for me was just to declare a pointer of type np_pio. I then used the variables within the structure to address the peripheral directly. It works great. I DID NOT have to remove DCACHE either, so the MSB of the address being set truly does bypass the cache. The error in my code was the use of a "<" instead of a "<<" to perform a bit-shift operation. I have done this thousands of times, but it was a simple typo. Thanks for your help.