src/cWiFi.cpp
// send GET/POST request to WiFi module.
// See example usage in cSmartFarm::send_line_message() function in MTEC_smartfarm.cpp.
send GET/POST request to WiFi module.
send GET / POST request to WiFi module .
void cWiFi::send_request( const char *host, const char *msg ){
  Log.info("send_request : host=");
  Log.infoln(host);
  if( !_b_enable || !_b_init )
    return;
  send_command("\r\nREQ:");
  send_command(host, true);
  send_command(":1:", true);
  send_command(strlen(msg), true);
  send_command(";\r\n", true);
  send_command(msg, true);
}
void cWiFi :: send_request ( const char * host , const char * msg ) { Log . info ( " " ) ; Log . infoln ( host ) ; if ( ! _b_enable || ! _b_init ) return ; send_command ( " \r \n " ) ; send_command ( host , true ) ; send_command ( " " , true ) ; send_command ( strlen ( msg ) , true ) ; send_command ( " \r \n " , true ) ; send_command ( msg , true ) ; }
send GET/POST request to WiFi module.
send GET / POST request to WiFi module .