This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

SMPL_NOFRAME on SMPL_RECEIVE

I'm stuck again, at first I did not have my radio in EP turned on but now I do with this:

                SMPL_Ioctl( IOCTL_OBJ_RADIO, IOCTL_ACT_RADIO_RXON, 0);
                //wait for reply
                NWK_REPLY_DELAY();

Then I send my message from my AP using this, which returns SUCCESS:

if(SMPL_SUCCESS == SMPL_Send(sLID[sNumCurrentPeers], (unsigned char *) &privateToken, 4)){

Next my EP RX interrupt routine gets called so I figure I must have received the message from the AP, so I set a flag and in my main loop I try this:

            result = SMPL_Receive(apLinkID, msg, &len);
            if (result == SMPL_SUCCESS)
            {
                led_one_on();
            }

But I get SMPL_NOFRAME everytime.  Not sure what I'm doing wrong, I would think the fact that my rx routine  is called would mean I'd received a message from the AP.

Thank you

  • solved my own problem.  I incorrectly assumed that the apLinkID I received from doing the initial SMPL_Link on the EP would be the same link ID that I would get when the AP tried to send my EP a message.   They were different so storing and using the link ID passed to me in the RX interrupt handler fixed the issue.