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

Define BOARD_CUSTOM not working in SDK12 with GCC

I can't seem to add custom pin definitions to my own board in SDK12. I use the BOARD_CUSTOM define and copied my PCA10040 header file to one call custom_board.h and my pin assignments do not change. The only warnings I get are from bad paths to the config folder which is new since moving to SDK12.image description

Parents
  • Look in examples\bsp\boards.h line 45

    #elif defined(BOARD_CUSTOM)
      #include "custom_board.h"
    #else
    

    Defining BOARD_CUSTOM in the makefile causes custom_board.h to be included

    Note

    -DBOARD_PCA10040
    

    occurs in 2 places in the makefile, once for C files and once for assembler files

    I quick way of checking if custom_board.h is being included is just to put

    #error Board is included
    

    into that header

    If the file is being included your compile will stop at that point

    (Or you could use #warning.. I often just write something like AAAAAAAAAAAAAAAAAAAAA into a file, and that fails compilation as well ;-)

Reply
  • Look in examples\bsp\boards.h line 45

    #elif defined(BOARD_CUSTOM)
      #include "custom_board.h"
    #else
    

    Defining BOARD_CUSTOM in the makefile causes custom_board.h to be included

    Note

    -DBOARD_PCA10040
    

    occurs in 2 places in the makefile, once for C files and once for assembler files

    I quick way of checking if custom_board.h is being included is just to put

    #error Board is included
    

    into that header

    If the file is being included your compile will stop at that point

    (Or you could use #warning.. I often just write something like AAAAAAAAAAAAAAAAAAAAA into a file, and that fails compilation as well ;-)

Children
Related