Author Topic: Calling SimbleeCOM_OnReceive in another function  (Read 73 times)

jdlin

  • RFduino Newbie
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Calling SimbleeCOM_OnReceive in another function
« on: March 10, 2017, 06:47:05 PM »
Hi, I'm trying to set up two-way communication between 2 Simblee chips. One is "roaming" and the other is connected ("tethered") to PC. The roaming chip is constantly sending data to the tethered chip. I have control signals that I print to the Serial Monitor from Matlab that the tethered chip reads. I do this by using a timer that interrupts ever 100ms. I send these control signals to the roaming chip through SimbleeCOM.send.

My problem is that the roaming chip seems to never execute SimbleeCOM_OnReceive. It just stays in the main loop where it is sending data to the tethered chip. I want to fix this by using a timer interrupt again. However, I don't know how to call SimbleeCOM_OnReceive within the interrupt function. I also don't know if it is even possible?

tolson

  • Global Moderator
  • *****
  • Posts: 804
  • Karma: +18/-0
    • View Profile
    • Thomas Olson Consulting
Re: Calling SimbleeCOM_OnReceive in another function
« Reply #1 on: March 10, 2017, 07:52:44 PM »
_onReceive is itself an interrupt handler. You don't call it.

Perhaps you can show sketches for what you think should be working.
« Last Edit: March 10, 2017, 07:57:40 PM by tolson »