Skip to content

Instantly share code, notes, and snippets.

@ajangrahmat
Created February 14, 2024 04:49
Show Gist options
  • Save ajangrahmat/7c4e25ba3841e14dd89cc4d18a43c08f to your computer and use it in GitHub Desktop.
Save ajangrahmat/7c4e25ba3841e14dd89cc4d18a43c08f to your computer and use it in GitHub Desktop.
#include <AViShaWiFi.h>
const char* ssid = "WiFiName";
const char* pass = "WiFiPassword";
const char *url = "http://104.237.9.196:5055";
const char *id = "431212121";
AViShaWiFi wifi;
String latitude = "-6.5234367";
String longitude = "107.1224681";
String speed = "120";
void setup() {
Serial.begin(115200);
wifi.begin(ssid, password);
delay(1500);
}
void loop() {
delay(5000);
String path = String() + url + "/?id=" + id +
"&lat=" + latitude + "&lon=" +
longitude + "&speed=" + speed;
String response = wifi.httpGET(path.c_str());
Serial.println(response);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment