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

[Merge Project] Making twi_sensor example work with Mesh SDK proxy_client

Hi all,

I'm working on a project which will automatically send data from LM75 sensor through mesh proxy_client to proxy_server. So, I did merge two examples twi_sensor and proxy_client. Until now I can make the twi_sensor's main.c worked in the proxy_client project. But I don't know how to automatically send data through it. I tried to keep the loop(twi_sensor's main.c) and publish the value. It can send the Celsius degrees(showed on my Jlink RTT Viewer) while provisioning. But after provisoned. It stopped working.

I know that keep the main loop is wrong but I don't know how to write a new event handler because twi_sensor example already has one. Could you show me the way. Thanks!

This is my main.c after merge. The provisioning progress happened normally.



This is my Debug Terminal

Parents Reply
  • Hi Swanny,
    You have to make the TWI example work in the Mesh SDK location. 


    Step 1: Replace the main.c file of proxy_client by TWI exmaple's main.c
    Step 2: You have to merge the Preprocessor of two projects(Common-> Preprocessor) your self.
    Step 3: Attach necessary .c files of TWI example in to proxy_client (which shows on the project explorer). In this step, if you want to know which file is necessary, you have to build the project a lot of times. If not, you can just include all the files. This step bases on your skill and costs a lot of time.
    Step 4: Merge two sdk_config files. 

    Good luck!

Children
Related