JN5169
JN-AN-1217-Zigbee-3-0-Base-Device
Coordinator = DR1174 + DR1199 , End Device = JN5169-001-M00-2
Hello,
Running Coordinator demo works fine. It prints logs on terminal (UART0) and I can send commands (print, form, steer...).
Running End Device demo works fine. It prints logs on terminal (UART0). Sending commands only with buttons.
I would like to send commands to End Device with serial (UART0). I merged Coordinator UART code but End Device never handle serial data interrupts.
APP_isrUart is never called. I tried to change power mode in app.zpscfg to force awake power mode. It fails.
In function ZQ_bQueueReceive , if( psQueueHandle->u32MessageWaiting > 0) is always false.
PUBLIC bool_t ZQ_bQueueReceive ( void* pvQueueHandle, void* pvItemFromQueue )
{
uint32 u32Store;
tszQueue *psQueueHandle = (tszQueue *)pvQueueHandle;
bool bReturn = FALSE;
MICRO_DISABLE_AND_SAVE_INTERRUPTS(u32Store);
if( psQueueHandle->u32MessageWaiting > 0)
{
if( psQueueHandle->pvReadFrom >= (psQueueHandle->pvHead+(psQueueHandle->u32Length*psQueueHandle->u32ItemSize) ))
{
psQueueHandle->pvReadFrom = psQueueHandle->pvHead;
}
( void ) memcpy( pvItemFromQueue, psQueueHandle->pvReadFrom, psQueueHandle->u32ItemSize );
psQueueHandle->pvReadFrom += psQueueHandle->u32ItemSize;
psQueueHandle->u32MessageWaiting--;
/* Decrease power manager activity count */
PWRM_eFinishActivity();
bReturn = TRUE;
}
else
{
bReturn = FALSE;
}
MICRO_RESTORE_INTERRUPTS(u32Store);
return bReturn;
}
I can flash the End Device via UART0, it's not hardware issue.
I would appreciate some advices.
Thanks, Pierre
OK, I forgot to update irq_JN516x.S file. I can now send command to End Device with UART0.
Hi Pierre,
Just to confirm, are you able to send data over the UART successfully?
Regardsm
Mario
Hi Mario,
Yes I am.
Regards,
Pierre