diff --git a/examples/Modules/Base_PoE/LAN_W5500/WebServer/WebServer.ino b/examples/Modules/Base_PoE/LAN_W5500/WebServer/WebServer.ino index 54c1a294..6714424e 100644 --- a/examples/Modules/Base_PoE/LAN_W5500/WebServer/WebServer.ino +++ b/examples/Modules/Base_PoE/LAN_W5500/WebServer/WebServer.ino @@ -1,14 +1,6 @@ -/* - Before compile this example, you have to change line 28 of the ESP32 core's - Server.h from: "virtual void begin(uint16_t port=0) =0;" To: "virtual void - begin() =0;" But that will break anything that uses the ESP32 WiFi library's - WebServer class. - Reference link: - https://community.m5stack.com/topic/3068/lan-module-w5500-with-poe-compilation-error -*/ #include #include -#include +#include #define SCK 18 #define MISO 19 #define MOSI 23 diff --git a/examples/Modules/LAN_W5500/Ethernet2.zip b/examples/Modules/LAN_W5500/Ethernet2.zip deleted file mode 100644 index d81c3cc3..00000000 Binary files a/examples/Modules/LAN_W5500/Ethernet2.zip and /dev/null differ diff --git a/examples/Modules/LAN_W5500/WebServer/WebServer.ino b/examples/Modules/LAN_W5500/WebServer/WebServer.ino index 54c1a294..6714424e 100644 --- a/examples/Modules/LAN_W5500/WebServer/WebServer.ino +++ b/examples/Modules/LAN_W5500/WebServer/WebServer.ino @@ -1,14 +1,6 @@ -/* - Before compile this example, you have to change line 28 of the ESP32 core's - Server.h from: "virtual void begin(uint16_t port=0) =0;" To: "virtual void - begin() =0;" But that will break anything that uses the ESP32 WiFi library's - WebServer class. - Reference link: - https://community.m5stack.com/topic/3068/lan-module-w5500-with-poe-compilation-error -*/ #include #include -#include +#include #define SCK 18 #define MISO 19 #define MOSI 23 diff --git a/examples/Unit/M5BIT/M5BIT.ino b/examples/Unit/M5BIT/M5BIT.ino deleted file mode 100644 index eee2980c..00000000 --- a/examples/Unit/M5BIT/M5BIT.ino +++ /dev/null @@ -1,76 +0,0 @@ -/* - Description: Use UART communication to control the LED matrix on microbit. -*/ -#include - -#define WIDTH 320 -#define HEIGHT 240 -#define BLOCK_SIZE 40 -#define UNIT_WIDTH 5 -#define UNIT_HEIGHT 5 -#define UNIT_SIZE 25 -#define GETX(i) ((i) % (5)) -#define GETY(i) ((i) / (5)) -int world[UNIT_SIZE]; -int i; - -void setup() { - M5.begin(); - M5.Power.begin(); - Wire.begin(); - if (digitalRead(BUTTON_A_PIN) == 0) { - Serial.println("Will load menu binary"); - updateFromFS(SD); - ESP.restart(); - } - Serial2.begin(115200, SERIAL_8N1, 16, 17); - M5.Lcd.fillScreen(BLACK); - M5.Lcd.setTextSize(2); - M5.Lcd.setCursor(35, 220); - M5.Lcd.println(" < * >"); - for (i = 0; i < UNIT_SIZE; i++) { - world[i] = 0; - } - i = UNIT_SIZE / 2; -} - -void loop() { - M5.update(); - int x = GETX(i) + 1; - int y = GETY(i); - if (world[i] > 0) - M5.Lcd.fillRect(x * BLOCK_SIZE + 1, y * BLOCK_SIZE + 1, BLOCK_SIZE - 2, - BLOCK_SIZE - 2, LIGHTGREY); - else - M5.Lcd.fillRect(x * BLOCK_SIZE + 1, y * BLOCK_SIZE + 1, BLOCK_SIZE - 2, - BLOCK_SIZE - 2, BLUE); - if (M5.BtnC.wasPressed()) { - if (world[i] > 0) - M5.Lcd.fillRect(x * BLOCK_SIZE + 1, y * BLOCK_SIZE + 1, - BLOCK_SIZE - 2, BLOCK_SIZE - 2, WHITE); - else - M5.Lcd.fillRect(x * BLOCK_SIZE, y * BLOCK_SIZE, BLOCK_SIZE, - BLOCK_SIZE, BLACK); - ++i; - if (i >= UNIT_SIZE) i = 0; - } - if (M5.BtnA.wasPressed()) { - if (world[i] > 0) - M5.Lcd.fillRect(x * BLOCK_SIZE + 1, y * BLOCK_SIZE + 1, - BLOCK_SIZE - 2, BLOCK_SIZE - 2, WHITE); - else - M5.Lcd.fillRect(x * BLOCK_SIZE, y * BLOCK_SIZE, BLOCK_SIZE, - BLOCK_SIZE, BLACK); - --i; - if (i < 0) i = UNIT_SIZE - 1; - } - if (M5.BtnB.wasPressed()) { - if (world[i] > 0) - world[i] = 0; - else - world[i] = 1; - Serial2.print(world[i]); - Serial2.print(GETX(i)); - Serial2.println(GETY(i)); - } -} diff --git a/library.json b/library.json index b2b66390..7dcf9e04 100644 --- a/library.json +++ b/library.json @@ -10,7 +10,7 @@ "type": "git", "url": "https://github.com/m5stack/m5stack.git" }, - "version": "0.4.4", + "version": "0.4.5", "frameworks": "arduino", "platforms": "espressif32", "headers": "M5Stack.h" diff --git a/library.properties b/library.properties index f5568d08..34ffd5b1 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=M5Stack -version=0.4.4 +version=0.4.5 author=M5Stack maintainer=M5Stack sentence=Library for M5Stack Core development kit @@ -8,4 +8,4 @@ category=Device Control url=https://github.com/m5stack/m5stack architectures=esp32 includes=M5Stack.h -depends=M5Family,M5Module-4Relay,MODULE_GRBL13.2,Ethernet2 \ No newline at end of file +depends=M5Family,M5Module-4Relay,MODULE_GRBL13.2,M5_BMM150 \ No newline at end of file