This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Semaphore_pend issue

Other Parts Discussed in Thread: CC3200, CC3100

I am getting the following error on a CC3200 application using TI-RTOS.

Semaphore: line 207: assertion failure: A_badContext: bad calling context. Must be called from a Task.

This happens when a Semaphore_pend occurs. I know that Semaphore_pend must take place within a Task and not HWI or SWI. So suspect this is the issue. Note: I am not creating the Semaphore_pend, this is being performed by the SimpleLink driver.

My application has a handler which is initiated when I press button, it then does established a secure TLS connection, performs a HTTP GET and then a HTTP POST which then sends an SMS message.

My confusion is that on the first button press everything works fine, but on the second press of the button I get the crash as described above on the HTTP POST (no issue with HTTP GET)

Can anyone offer any advise on how to trouble shoot this issue, what should I be looking for?

I am using the HTTP Client Library that comes with the CC3200 SDK to perform my HTTP tasks. 

Glenn.