JN-AN-1229-ZBPro-Application-Template
JN5169
Hello,
I added a DIO interrupt switch to the demo, sending DIO level from End Device to Coordinator.
Every 5 seconds, timer1 interrupt wakes up to poll. My data only travels from End Device to Coordinator.
I don't need poll request, nether timer1/timer0 interrupts.
I need DIO interrupt in sleep mode.
I can't find how to remove timer1 (and timer0) interrupts and keep DIO interrupt still working.
If I remove timer1 initialisation (APP_vInitResources => ZQ_vQueueCreate(&zps_TimeEvents, TIMER_QUEUE_SIZE, sizeof(zps_tsTimeEvent), (uint8*)asTimeEvent);
I get APP: Unexpected event in E_NETWORK_JOIN - 21
If I go deep in removing interrupt init, DIO interrupts are disabled too.
Which part of code should I remove, please ?
Regards,
Pierre
Finally, I filtered u32IntSource to process DIO interrupts.
Timer1 is still a mystery, as it always interrupt in
void APP_isrSysCon (void)
{
/* clear pending DIO changed bits by reading register */
uint32 u32IntSource = u32AHI_DioWakeStatus();
uint8 u8WakeInt = u8AHI_WakeTimerFiredStatus();if (u8WakeInt & E_AHI_WAKE_TIMER_MASK_1)
{
/* wake timer interrupt got us here */
DBG_vPrintf(TRACE_APP_SYSCON, "APP: Wake Timer 1 Interrupt\n");
PWRM_vWakeInterruptCallback();
}
on wake up initiated by
PWRM_eScheduleActivity(&sWake, SLEEP_TIME, vWakeCallBack);
I don't understand where Timer1 remaining time is set. In the other hand, Timer0 never interrupt.
Hi Pierre,
Are you sure that is entering the APP_isrSysCon?
That API is defined if you are only using the JN517X.
I am confused, did you disable the timer yet?
Regards,
Mario
Hi Mario,
Yes, I am entering APP_isrSysCon thanks to
#if JENNIC_CHIP_FAMILY == JN517x
void APP_isrSysCon ( uint32 u32Device, uint32 u32ItemBitmap )
{// Disabled code
}
else
void APP_isrSysCon (void)
{// Runs here
}
#endif
Timer is still running. Now I am dealing with interrupt priorities as polling and button press interrupts collides over RF bus.
Regards,
Pierre