Hi
While working with stm32f103 and cc3000 chip combination (wifi project) , my code is getting stuck in event handler. Actually it is completing smart configuration and getting some dynamic IP address also. Initially it is getting through event handler , but after half or 1 sec it is getting stuck in event handler of cc3000 and it seems to be waiting for some interrupt. cc3k_int_poll();. and not getting ahead of 1st if-loop.
Initially it works properly and automatically after sometime gets stuck...so what might be the issue? Same is repeating after reset.
some part of event handler code i have written below
UINT8 * hci_event_handler(void *pRetParams, UINT8 *from, UINT8 *fromlen)
{
UINT8 *pucReceivedData, ucArgsize;
UINT16 usLength;
UINT8 *pucReceivedParams;
UINT16 usReceivedEventOpcode = 0;
UINT32 retValue32;
UINT8 * RecvParams;
UINT8 *RetParams;
while (1)
{
cc3k_int_poll();
if (tSLInformation.usEventOrDataReceived != 0)
{
pucReceivedData = (tSLInformation.pucReceivedData);
if (*pucReceivedData == HCI_TYPE_EVNT)
{
// Event Received
STREAM_TO_UINT16((CHAR *)pucReceivedData, HCI_EVENT_OPCODE_OFFSET,
usReceivedEventOpcode);
pucReceivedParams = pucReceivedData + HCI_EVENT_HEADER_SIZE;
RecvParams = pucReceivedParams;
RetParams = pRetParams;
// In case unsolicited event received - here the handling finished
if (hci_unsol_event_handler((CHAR *)pucReceivedData) == 0)
{
STREAM_TO_UINT8(pucReceivedData, HCI_DATA_LENGTH_OFFSET, usLength);
switch(usReceivedEventOpcode)
{