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

Drivers from nRF5_SDK to Mesh SDK

Hello,

I would like to add the ST7735 driver from the nRF5_SDK to the Mesh SDK along with the necessary components (SPI,..). I copied the entire components directory to my Mesh SDK. But I have an issue with the cmake operation when trying to build the example as it cannot find the include files.

What is the best way to solve this issue? Should I modify some CMake files?

Thanks.

UPDATE 19/01/2018: mesh_pwm.zip Screenshot Mesh_PWM.png

Parents
  • Hi Hung, I tried to do that but I don't know if I am doing it the right way as there are a lot of dependencies so a lot of files to link. For example, I am adding the st7735 driver to the ligher_server example in Mesh SDK. I am modifying the CMakeLists.txt file in examples/light_switch/server. I added the following:

    `add_executable(${target}
        "${CMAKE_SOURCE_DIR}/components/drivers_ext/st7735/st7735.c"
        "${CMAKE_SOURCE_DIR}/components/drivers_nrf/spi_master/nrf_drv_spi.c" )`
    
    `target_include_directories(${target} PUBLIC
        "${CMAKE_SOURCE_DIR}/components/drivers_ext/st7735"
        "${CMAKE_SOURCE_DIR}/components/libraries/util"
        "${CMAKE_SOURCE_DIR}/external/thedotfactory_fonts"
    )`
    

    Note: I didn't copy all the lines I added but basically I tried to link the c and h files for each function that was undefined during the make command. But I still get a lot of errors when compiling.

Reply
  • Hi Hung, I tried to do that but I don't know if I am doing it the right way as there are a lot of dependencies so a lot of files to link. For example, I am adding the st7735 driver to the ligher_server example in Mesh SDK. I am modifying the CMakeLists.txt file in examples/light_switch/server. I added the following:

    `add_executable(${target}
        "${CMAKE_SOURCE_DIR}/components/drivers_ext/st7735/st7735.c"
        "${CMAKE_SOURCE_DIR}/components/drivers_nrf/spi_master/nrf_drv_spi.c" )`
    
    `target_include_directories(${target} PUBLIC
        "${CMAKE_SOURCE_DIR}/components/drivers_ext/st7735"
        "${CMAKE_SOURCE_DIR}/components/libraries/util"
        "${CMAKE_SOURCE_DIR}/external/thedotfactory_fonts"
    )`
    

    Note: I didn't copy all the lines I added but basically I tried to link the c and h files for each function that was undefined during the make command. But I still get a lot of errors when compiling.

Children
No Data
Related