This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

how to add new files to build

I want to use master spi mode ,but when I build the file,it is always error.I operate like this ,First I open the project in ble_peripheral\ble_app_hrs\pca10040\s132\arm5_no_packs,and add nrf_drv_spi.c file in the nRF_Drivers group, then in the main.c files ,I add #include nrf_drv_spi.h, then I build the file,the error is :............\components\drivers_nrf\spi_master\nrf_drv_spi.c(56): error: #35: #error directive: "Wrong configuration." Could you tell me how to add my file in BLE

Parents
  • Why do you think that the problem is with adding a file?

    Read the error message!

    It is telling you that it has hit a #error directive - so go and look at that line, and see what condition(s) would cause that. Then fix it!

    In fact, it tells you that the reason is, ""Wrong configuration"; so look at the code there to see what is wrong with your configuration (what condition triggers the #error) - and correct it!

Reply
  • Why do you think that the problem is with adding a file?

    Read the error message!

    It is telling you that it has hit a #error directive - so go and look at that line, and see what condition(s) would cause that. Then fix it!

    In fact, it tells you that the reason is, ""Wrong configuration"; so look at the code there to see what is wrong with your configuration (what condition triggers the #error) - and correct it!

Children
No Data
Related