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

802.15.4 and Softdevice Compilation Problem

Hello,

I am trying to use Softdevice and the latest Github version of 802.15.4 support. The make (using linux/armgcc) fails on 

nrf_raal_softdevice.c

because nrf_802154_radio_irq_handler is undefined (implicitly defined) and/or missing. I had thought that by putting some defines into the sdk_config.h that it would be taken care of, so I put these into the sdk_config.h for the make:

// github.com/.../Source-files-and-defines
//
#ifndef RAAL_SINGLE_PHY
#define RAAL_SINGLE_PHY 0
#endif

#ifndef RAAL_SIMULATOR
#define RAAL_SIMULATOR 0
#endif

#ifndef RAAL_SOFTDEVICE
#define RAAL_SOFTDEVICE 1
#endif

#ifndef ENABLE_DEBUG_LOG
#define ENABLE_DEBUG_LOG 0
#endif

#ifndef ENABLE_DEBUG_ASSERT
#define ENABLE_DEBUG_ASSERT 0
#endif

#ifndef ENABLE_DEBUG_GPIO
#define ENABLE_DEBUG_GPIO 0
#endif

#ifndef ENABLE_FEM
#define ENABLE_FEM 0
#endif

#ifndef NRF_802154_INTERNAL_RADIO_IRQ_HANDLING
#define NRF_802154_INTERNAL_RADIO_IRQ_HANDLING 0
#endif

(the last define was needed elsewhere, to get nrf_802154.c to have  nrf_802154_radio_irq_handler in its code).

I might also mention that the names of core components in the page https://github.com/NordicSemiconductor/nRF-IEEE-802.15.4-radio-driver/wiki/Source-files-and-defines seems not to agree with a more recent version of the 802.15.4 code.

Ted Herman

Parents
  • Hello,

    Here is what I am trying. I copied ble_hrs from the ble_peripherals as the base for the experiment. Then I added statements to initialize 802.15.4 and set the channel (based on another program which successfully used raw transmit of 802.15.4 frames) -- these statements come just after setting up BLE, advertising, etc. Then, in the idle loop, I added a call to a procedures that (raw) transmits a packet. Finally, attempting to get this to compile, the Makefile needed all the core components mentioned in the 802.15.4 wiki, although some of these no longer exist, so I had to improvise by searching the current (cloned a week ago) git repo to attempt a compile. Of course the sdk_config.h needed the extra defines, also mentioned in the wiki. It was unclear whether all of these should be defined 1 or 0, so I defined them to be 1. 

    The result of doing all of this is that no matter which way I tried, there was some missing reference to IRQ handling, hence my attempt after studying the code to add that extra define - not mentioned in the wiki.

    Going further, I made a new copy of the entire Nordic SDK and forced manually everything to be defined, so it would compile and I could flash it onto an nRF52840. The result, looking at the UART log, was the the very first 802.15.4 transmit raw gets a result of 1 (tx busy), but all subsequent transmits get 0. None of them actually work. I tried digging deeper with debug mode, but I was unable to get JLink and GDB server missing because of a missing so-lib in Linux, even though that very library is present.

    Sorry if the above is not specific or accurate in all details. Due to the time difference between us, I do not have access to the equipment and code for some hours. I would appreciate suggestions on how to proceed from here. 

    Thank you,

    Ted

Reply
  • Hello,

    Here is what I am trying. I copied ble_hrs from the ble_peripherals as the base for the experiment. Then I added statements to initialize 802.15.4 and set the channel (based on another program which successfully used raw transmit of 802.15.4 frames) -- these statements come just after setting up BLE, advertising, etc. Then, in the idle loop, I added a call to a procedures that (raw) transmits a packet. Finally, attempting to get this to compile, the Makefile needed all the core components mentioned in the 802.15.4 wiki, although some of these no longer exist, so I had to improvise by searching the current (cloned a week ago) git repo to attempt a compile. Of course the sdk_config.h needed the extra defines, also mentioned in the wiki. It was unclear whether all of these should be defined 1 or 0, so I defined them to be 1. 

    The result of doing all of this is that no matter which way I tried, there was some missing reference to IRQ handling, hence my attempt after studying the code to add that extra define - not mentioned in the wiki.

    Going further, I made a new copy of the entire Nordic SDK and forced manually everything to be defined, so it would compile and I could flash it onto an nRF52840. The result, looking at the UART log, was the the very first 802.15.4 transmit raw gets a result of 1 (tx busy), but all subsequent transmits get 0. None of them actually work. I tried digging deeper with debug mode, but I was unable to get JLink and GDB server missing because of a missing so-lib in Linux, even though that very library is present.

    Sorry if the above is not specific or accurate in all details. Due to the time difference between us, I do not have access to the equipment and code for some hours. I would appreciate suggestions on how to proceed from here. 

    Thank you,

    Ted

Children
Related