How to trigger PPI and transmit using ESB

I send and receive 1:1 using an ESB with nrf52840.
I do not want to "use nrf_esb_start_tx()", but instead use PPI to trigger a specific event to be sent.

I want the PPI event to be a timer event (NRF_TIMER_EVENT_COMPARE0) or a pwm event (NRF_PWM_EVENT_PWMPERIODEND).
However, the ESD does not have a function to get the address of the transmitting task, equivalent to "xxx_task_addr_get()". Other peripherals have a function to get the address of a task, but the ESB does not.
This address is used in the "nrf_drv_ppi_channel_assign()" configuration of the PPI to get the address of the task to be sent.
We assume that the address is necessary to relate the event to the task.

--How should the PPI be configured?
--How can I get the address of the task to be sent in the ESB?
--What is the example of a concrete programme to send an ESB with (NRF_TIMER_EVENT_COMPARE0) or (NRF_PWM_EVENT_PWMPERIODEND) as an event in the PPI?

Parents
  • Hi,

     

    ESB is a protocol that sets up several states, cpu wise, and thus it is not setup to start the radio solely based on PPI.

    If you look into the function itself, you can see that it sets up the radio, buffers, and many other features/requirements towards the RF protocol.

     

    I would recommend that you enable a interrupt on the event you want to trigger a RF transaction on.

     

    Kind regards,

    Håkon

Reply
  • Hi,

     

    ESB is a protocol that sets up several states, cpu wise, and thus it is not setup to start the radio solely based on PPI.

    If you look into the function itself, you can see that it sets up the radio, buffers, and many other features/requirements towards the RF protocol.

     

    I would recommend that you enable a interrupt on the event you want to trigger a RF transaction on.

     

    Kind regards,

    Håkon

Children
  • Hi

    Reply, thank you.


    After I posted my post, I found out that there had been similar content in the past. I found out that it is not possible to start the ESB with PPI alone.
    I am very disappointed because PPI is a powerful feature.


    I will try triggering RF transactions by certain event interrupts as you suggested.


    Thank you very much.

  • Hi,

     

    TML_YT said:

    After I posted my post, I found out that there had been similar content in the past. I found out that it is not possible to start the ESB with PPI alone.
    I am very disappointed because PPI is a powerful feature.

    You are right. PPI is very powerful, but unfortunately ESB requires the CPU to handle the protocol, as most of the features are implemented in software.

    TML_YT said:
    Thank you very much.

    Always happy to help out. I hope you have a wonderful day!

    Kind regards,

    Håkon

Related