cancel
Showing results for 
Search instead for 
Did you mean: 

Cant Compile a project

salah-eddine
Associate II

I am using a NUCLEO-L476 board with X-Nucleo-NFC08A1, attempting to compile the provided example by ST, NFC08A1_PollingTagDetectNDEF. However, I encounter an issue with the file startup_stm32l476xx.s. Every time I compile the project, I receive the following errors:

../startup_stm32l476xx.s:128: Error: bad instruction `dcd TIM6_DAC_IRQHandler'
../startup_stm32l476xx.s:128: Error: bad instruction `tim6 and DAC1&2 underrun errors'
../startup_stm32l476xx.s:129: Error: bad instruction `dcd TIM7_IRQHandler'
../startup_stm32l476xx.s:129: Error: bad instruction `tim7'
../startup_stm32l476xx.s:130: Error: bad instruction `dcd DMA2_Channel1_IRQHandler'
../startup_stm32l476xx.s:130: Error: bad instruction `dma2 Channel 1'
../startup_stm32l476xx.s:131: Error: bad instruction `dcd DMA2_Channel2_IRQHandler'
../startup_stm32l476xx.s:131: Error: bad instruction `dma2 Channel 2'
../startup_stm32l476xx.s:132: Error: bad instruction `dcd DMA2_Channel3_IRQHandler'
../startup_stm32l476xx.s:132: Error: bad instruction `dma2 Channel 3'
../startup_stm32l476xx.s:133: Error: bad instruction `dcd DMA2_Channel4_IRQHandler'

 

It seems like there might be issues with the syntax or directives in the startup_stm32l476xx.s file. I need assistance in resolving these errors to successfully compile the project

1 ACCEPTED SOLUTION

Accepted Solutions
Pavel A.
Evangelist III
10 REPLIES 10
Pavel A.
Evangelist III

Which IDE do you use? If CubeIDE - can you successfully build any other example for this board?

 

TDK
Guru

> ../startup_stm32l476xx.s:128: Error: bad instruction `tim6 and DAC1&2 underrun errors'

Looks like a comment trying to be compiled as an instruction.

Also looks like you have a startup script meant for a different compiler than what you're using. The one meant for GCC doesn't have these directives. That's probably the heart of the issue.

https://github.com/sucrystal-v/NFC_ST25R3911_X-NUCLEO-NFC05A/blob/ec82d6a15c2e2519218961701cd09aa07a657f69/Projects/STM32L476RG-Nucleo/Applications/PollingTagDetect/SW4STM32/startup_stm32l476xx.s

 

If you feel a post has answered your question, please click "Accept as Solution".

I am using attolic and stide both give same error I can't build the project with the file included , if I remove the file from the project I can build it , but I can't flash the board 

Do you have IDE you recommend for me , so I can build it , I am using attolic with  gcc , also I get same error when I use stm32cubeide

Pavel A.
Evangelist III

The "X-CUBE-NFC6 software expansion for STM32Cube" software is meant to be used with CubeIDE or other IDE supported by STM32Cube. Can you use the supported software instead of Atollic?

 

I tried  STM32cube IDE and same issues 

> also I get same error when I use stm32cubeide

As stated before, you're using the wrong startup script for STM32CubeIDE. The fix would be to use the correct one. There is an SW4STM32 project, you should be able to import that and use it.

If you feel a post has answered your question, please click "Accept as Solution".

can you please provide me a link for the correct script or and IDE that can support the script I am using please.

Pavel A.
Evangelist III