Other Parts Discussed in Thread: MSP430FR5994, MSP430F5529,
Tool/software: Code Composer Studio
(This is my first time for both working with microcontrollers and posting here, so please let me know if I need to provide additional info or if I need to post elsewhere)
Hi, I am trying to use the CC3100Boost with MSP430F45R994 Launchpad for a school project. First, I started with the provisioning_wps example project in the CC3100SK_1.3.0 and got it running on a MSP430f5529 launchpad that I already had. Now I am trying to that project to the MSP430FR5994 board.
I copied the board, spi, uart, etc. files from the fr5969 example and changed the pins in the files to match what is on the fr5994. I can run the program and output data to the command line interface, but I keep getting stuck in sl_Start() function, specifically in _SlReturnVal_t ret = sl_SyncObjWait(pSyncObj, timeoutVal);
When I run the project on the 5529lp, I notice that the code will run through the while (Timeout>0) loop once and then break on the second time through. On the 5994lp I keep getting stuck here.
I noticed that in the _SlNonOsMainLoopTask() function, the 5529lp program will execute the spawn function on the first time through the loop, but the 5994lp never enters the if statement and executes it. Have I missed a step in the porting process or forgot to include a certain library?
I have attached a zip that includes my project and the platform files I modified.
_SlNonOsRetVal_t _SlNonOsSemGet(_SlNonOsSemObj_t* pSyncObj, _SlNonOsSemObj_t WaitValue, _SlNonOsSemObj_t SetValue, _SlNonOsTime_t Timeout)
{
#if (!defined (SL_TINY)) && (defined(sl_GetTimestamp))
_SlTimeoutParams_t TimeoutInfo={0};
#endif
/* If timeout 0 configured, just detect the value and return */
if ((Timeout ==0) && (WaitValue == *((volatile _u8 *)pSyncObj)) )
{
*pSyncObj = SetValue;
return NONOS_RET_OK;
}
#if (!defined (SL_TINY)) && (defined(sl_GetTimestamp))
if ((Timeout != NONOS_WAIT_FOREVER) && (Timeout != NONOS_NO_WAIT))
{
_SlDrvStartMeasureTimeout(&TimeoutInfo, Timeout);
}
#endif
#ifdef _SlSyncWaitLoopCallback
_SlNonOsTime_t timeOutRequest = Timeout;
#endif
while (Timeout>0)
{
if (WaitValue == *((volatile _u8 *)pSyncObj))
{
*pSyncObj = SetValue;
break;
}
#if (!defined (sl_GetTimestamp)) || (defined (SL_TINY_EXT))
if (Timeout != NONOS_WAIT_FOREVER)
{
Timeout--;
}
#else
if ((Timeout != NONOS_WAIT_FOREVER) && (Timeout != NONOS_NO_WAIT))
{
if (_SlDrvIsTimeoutExpired(&TimeoutInfo))
{
return (_SlNonOsRetVal_t)NONOS_RET_ERR;
}
}
#endif
/* If we are in cmd context and waiting for its cmd response
* do not handle spawn async events as the global lock was already taken */
if (FALSE == g_pCB->IsCmdRespWaited)
{
(void)_SlNonOsMainLoopTask();
}
#ifdef _SlSyncWaitLoopCallback
if( (__NON_OS_SYNC_OBJ_SIGNAL_VALUE == WaitValue) && (timeOutRequest != NONOS_NO_WAIT) )
{
if (WaitValue == *((volatile _u8 *)pSyncObj))
{
*pSyncObj = SetValue;
break;
}
_SlSyncWaitLoopCallback();
}
#endif
}
if (0 == Timeout)
{
return NONOS_RET_ERR;
}
else
{
return NONOS_RET_OK;
}
}