Skip to content

Instantly share code, notes, and snippets.

@maxpromer
Created March 3, 2025 18:19
Show Gist options
  • Save maxpromer/0c73fd25201fd7426db20f9810c855bd to your computer and use it in GitHub Desktop.
Save maxpromer/0c73fd25201fd7426db20f9810c855bd to your computer and use it in GitHub Desktop.
#include <ArtronShop_LineMessaging.h> // นำเข้าไลบารี่ ArtronShop_LineMessaging
@Petch110505
Copy link

#include <WiFi.h> // นำเข้าไลบรารี่ WiFi

const char* ssid = "your-ssid"; // ชื่อ WiFi
const char* password = "your-password"; // รหัสผ่าน WiFi

void setup() {
Serial.begin(115200); // เริ่มต้นใช้ Serial ที่ความเร็ว 115200
while(!Serial){delay(100);}

// We start by connecting to a WiFi network

Serial.println();
Serial.println("******************************************************");
Serial.print("Connecting to ");
Serial.println(ssid);

WiFi.begin(ssid, password); // เริ่มต้นเชื่อมต่อ WiFi

while (WiFi.status() != WL_CONNECTED) { // วนลูปหากยังเชื่อมต่อ WiFi ไม่สำเร็จ
    delay(500);
    Serial.print(".");
}

Serial.println("");
Serial.println("WiFi connected");
Serial.println("IP address: ");
Serial.println(WiFi.localIP());

}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment