10 years, 1 month ago.  This question has been closed. Reason: Answered

Adding target to NVIC_set_all_priorities

I have recently imported a CC3000 project made for a FRDM-KL25Z and a Adafruit Wifi shield.

Trying to change platforms to a Nucleo results in the errors - undefined first/last-IRQ_number in the NVIC_set_all_priorities include library.

I have tried adding this code in the header file

  1. elif defined TARGET_NUCLEO_F401RE first_IRQ_number = SysTick_IRQn, last_IRQ_number = HASH_RNG_IRQn/FPU_IRQn, but this results the error identifier pFunctionPointer_t is undefined.

Can anyone help in adding or changing code to include the Nucleo boards?

Thanks Marcus

1 Answer

10 years, 1 month ago.

Here is a list of IRQs of the F401: https://github.com/mbedmicro/mbed/blob/master/libraries/mbed/targets/cmsis/TARGET_STM/TARGET_NUCLEO_F401RE/stm32f401xe.h. I expect it to work if you add correct one from these (staring from SysTick still, the interrupts before that probably should not be modified). Or you can also do it without that lib, the dipcortex also does not use it.

It is not completely clear if you mean you used that division for last_IRQ_number, or if you tried both. If you made the division, that is not intended. If you tried both, then it should have worked with the FPU_IRQn. The question in that case is, where did the pFunctionPointer_t error happen? Did you update the mbed lib to the latest version?

I set last_IRQ_number = FPU_IRQn, the error message still comes up and is situated in cc3000.h on line 1175. In the main program I have called the class like so: cc3000 wifi(PB_3, PB_4, PB_6, SPI(PA_7, PA_6, PA_5), PORTB); I'm not sure this is correct, could this be it?

posted by Marcus Parker 01 Apr 2014

Update your CC3000 lib (click on it, somewhere is an update button). I think you are using an outdated version. (So the error is also related to what it says, a pFunctionPointer it does not recognise, not the IRQ/constructor).

posted by Erik - 01 Apr 2014

OK thanks, i've got that working. By updating mbed and the CC3000 libraries it compiles.

posted by Marcus Parker 02 Apr 2014