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

nrf52840 802.15.4 start command

Hi,

I'm trying to use the command "mlme_start_req" to setup the device as a pan coordinator to send beacons to the others devices in the network, but after submit the command the callback is not called. For instance, if I don't set a short address before the start the callback is called with the error code 153 (should be the 236, based on the struct mac_status_t), this means that the callback is working but only when something is wrong.

This is the start request:

    static void a_start(void * p_data)
        {
        	mlme_start_req_t startReq =
        	{
        			.pan_id  = 0x1234,
        			.logical_channel = 17,
        			.start_time = 0x000000,
        			.beacon_order = 0,
        			.superframe_order = 0,
        			.pan_coordinator = true,
        			.battery_life_extension = false,
        			.coord_realignment = false,
        	};
        	mlme_start_req( &startReq, mlme_start_conf);
}

This is the call back:

static void mlme_start_conf(mlme_start_conf_t * conf)
{
    fsm_event_data_t data =
    {
        .m_start_conf = conf,
    };
    fsm_event_post(E_START_DONE, &data);
}

Anyone have idea of what is happening?

fsm.c fsm.h main.c

Regards, Jose

Parents
  • When I've got the error 153, I wasn't doing anything before calling the "mlme_start_req". I'm using the same example and I've just changed the state machine to just call this action. But if before I call the "start" action I call the action to define the short address as specified in IEEE Std 802.15.4-2006, section 7.1.14.1.2, the start request never return again. The callback is never called again and the device doesn't to anything after that point.

    Perhaps if send you the files will be easier for you, how can I send you the files?

    Thank you

Reply
  • When I've got the error 153, I wasn't doing anything before calling the "mlme_start_req". I'm using the same example and I've just changed the state machine to just call this action. But if before I call the "start" action I call the action to define the short address as specified in IEEE Std 802.15.4-2006, section 7.1.14.1.2, the start request never return again. The callback is never called again and the device doesn't to anything after that point.

    Perhaps if send you the files will be easier for you, how can I send you the files?

    Thank you

Children
No Data
Related