9 years, 1 month ago.

VodafoneUSBModem doesn't tidy up after itself

I want to have the VodafoneUSBModem part of my code in a separate subroutine that gets called from the 'test' thread. This way each time I do a bit of communications, the VodafoneUSBModem connects and disconnects. The first call to the subroutine is fine and everything works as expected. The second call causes running lights of death.

To recreate, import VodafoneUSBModemHTTPClientTest and edit it as follows:

  1. change the line void test(void const*) to void Voda_routine(void)
  2. delete the while(1) { } at the end of this subroutine
  3. add this code below the Voda_routine subroutine (above main):

void test(void const*)
    int i = 0;
    while(1) {
        printf("-------------------------------------------------------> Attempt %d: \n", i);
        printf("-------------------------------------------------------> Success!\n");

How can this be fixed, is it a bug?

Question relating to:

Be the first to answer this question.