W5100S requestion

I have a problem with this component.
For example,
If I make a requestion
“192.168.1.157/Readings”
and then I make a new requestion
“192.168.1.157/index.html”
it will return the frist request
“192.168.1.157/Readings”
its looks like that it does a cache

1 Like

hello.

What code are you using?
It’s hard to figure out the problem from what you’ve told us

Thanks

Hey There,
I can see that there is caching problem with the W5100S component. When you make a new request, it returns the previous response instead of the expected one. To fix this, you might need to disable caching or ensure that each request gets a fresh response. This could involve adjusting the component’s settings or modifying your request headers. You could also check for any firmware updates that address caching issues.

Hi!
Thanks!
How can I disable caching?

Hi!
This is my request code.

  extern "C" void EthernetLoop()
   {
        bool Result = Listen();
        if(Result == false)
              return;     
  
     memset(Request, 0x00, sizeof(Request));
     wiz_recv_data(HTTP_SOCKET, (uint8_t*)Request, sizeof(Request));//Recebe até 255 Caracter
     wiz_recv_ignore(HTTP_SOCKET, sizeof(Request));
  
     char* url_start = strstr((char*)Request, "GET /?");
     if (url_start)
     {
              url_start += 6;
              char* url_end = strchr(url_start, ' ');
              
              if (url_end)
              {
                    *url_end = '\0';
                    bool Result = VerificaRecParametros(url_start);
                    if(Result == true)
                    {
                          RespondeOK200(204U);
                          SinalizaRecComando();
                          disconnect(HTTP_SOCKET);
                          close(HTTP_SOCKET);
                          return;
                    }
                    else
                    {
                          RespondeOK200(404U);
                          disconnect(HTTP_SOCKET);
                          close(HTTP_SOCKET);
                          return;
                    }
              }
     }
     else
     {
            Request[511] = '\0';
              if (strstr(Request, "leituras") != NULL)
              {                       
                    SendJSON();                   
                    return;
              }

              if (strstr(Request, "GetNomeUps") != NULL)
              {
                    SendNomeUPS();
                    return;
              }

              if (strstr(Request, "GetLogs") != NULL)
              {
                    SendLogEventos();
                    return;
              }
     }
  }