Important changes to forums and questions
All forums and questions are now archived. To start a new conversation or read the latest updates go to forums.mbed.com.
9 years, 8 months ago.
spi pin mapping nRF5182.
I have my own custom PCB w/ the nRF51822 and use SPI with different GPIO pins than the standard ones.
My firmware runs fine on the dev kit when I use SPI(p25, p28, p29) which are the recommended pins but when I try using SPI(p0, p2, p3) as I have wired in my PCB it doesn't work. I checked out the source code and it looks like it should work w/ any pin mapping.. ->
mbed/libraries/mbed/targets/hal/TARGET_NORDIC/TARGET_MCU_NRF51822/spi_api.c
Where does the assignment go wrong? IT looks like Nordic supports flexbile pin mapping in there code. Is there any hack I can do to make this work. Why does mbed enforce this limitation? Whats up with this and how can i fix it?
Thanks, Mike
1 Answer
9 years, 8 months ago.
Make sure you have the latest mbed versions. The earlier ones had it enforced on specific pins, the new one should not do this. (Right click update in the online IDE).
After I updated the mbed library I can't compile any programs anymore. I get Error: #error directive: "Device family must be defined. See nrf.h." in "mbed-src/targets/cmsis/TARGET_NORDIC/TARGET_MCU_NRF51822/nrf.h", Line: 40, Col: 6
any idea how to fix this?
posted by 16 Apr 2015I saw some more comments regarding that. But I don't use NRF myself. Are you using mbed-src? Then try regular mbed. If you already use that, try to go one or two revisions back.
Edit: See: http://developer.mbed.org/questions/7091/nordic-platform-cant-be-compiled/
posted by 16 Apr 2015