This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

how to integrate twi code with another spi code

Hi,

I having an nrf52832 board and using gnu arm, nrfjprog to program the device. i reading data from two different sensors using spi and TWI in two different codes. now i need to combine the two project to one, so i tried to add the twi to the spi code but some error as shown below comes up. i have edited the makefile and sdk config files but not sure weather its correctly done.image description

I am editing the makefile and sdk line by line, is there any other way to do this ? something like a gui. i have attached the make fileMakefile and sdk filesdk_config.h(/attachment/f48c8b3e3463ecf6b44cd77adb15caa2)

Parents
  • Many commercial GUI's are available that you could use, e.g. Keil, IAR and Segger Embedded Studio. But I think the cheapest of these is Segger Embedded Studio and the cost is around $1000 USD for a commercial license (rather than a demo license). Keil and IAR are much more expensive

    I doubt if any of the commercial GUI / Toolchains would tell you where the problem is.

    Segger Embedded Studio is just a wrapper for GCC. Keil and IAR both use their own compilers so will give a different output, but it would basically tell you the same thing.

    i.e you have a multiple definition of

    SPIM0_SPIS0_TWIM0_TWIS0_SPI0_TWI0_IRQHandler

    You should look in your code for this function, as you have defined it twice, or somehow included implementations of it twice

    Then probably change your code so that the same function in the two differences has different names, and adjust your setup code accordingly to use the new function names.

    BTW. This is development 101, its not specific to the Nordic products / SDK / API or toolchain

Reply
  • Many commercial GUI's are available that you could use, e.g. Keil, IAR and Segger Embedded Studio. But I think the cheapest of these is Segger Embedded Studio and the cost is around $1000 USD for a commercial license (rather than a demo license). Keil and IAR are much more expensive

    I doubt if any of the commercial GUI / Toolchains would tell you where the problem is.

    Segger Embedded Studio is just a wrapper for GCC. Keil and IAR both use their own compilers so will give a different output, but it would basically tell you the same thing.

    i.e you have a multiple definition of

    SPIM0_SPIS0_TWIM0_TWIS0_SPI0_TWI0_IRQHandler

    You should look in your code for this function, as you have defined it twice, or somehow included implementations of it twice

    Then probably change your code so that the same function in the two differences has different names, and adjust your setup code accordingly to use the new function names.

    BTW. This is development 101, its not specific to the Nordic products / SDK / API or toolchain

Children
Related