Discuss on automatic sending with time interval control based on nRF52840

I have figured out a way to realize IR communication,it is same with the way to drive WS2812 with SPI.

[ I can use PWM peripheral and should use it,for I need to change the duty cycle sometime.I will update later. Can't use it : can't change the time interval. DMA does not support timer. I was stunned by myself. Though I can't change the duty cycle, I will use it at this moment. ]

I want to compose the time interval control together: you can only trigger once in many seconds.

I have studied the datasheet, no available mechanism to finish it,so ,I need hardware to support.

No way to disable a Pin with PPI/GPIOTE,the P-MOS switch will do the job,which can be controlled by GPIOTE.

The workflow:

set Pin_Trig IN with Pull

stop Timer_ShotDelay

Enable_Trig_Input

...... -> Pin_Trig low(event)
                 ->PPI->(task)Disable_Trig_Input
                 ->PPI->(task)SPIM TX  {......  ->SPIM endTX(event)}
                 ->PPI->(task)Timer_ShotDelay start  ...  ->Timer_ShotDelay timeout(event)
                                                                                             ->PPI->(task)Enable_Trig_Input

Will it work?

Do I missed anything? 

Related