MADE WORKING ON HARDWARE
This commit is contained in:
parent
bcf6001c55
commit
4333e35037
@ -1,4 +1,5 @@
|
|||||||
# Name, Type, SubType, Offset, Size, Flags
|
# Name, Type, SubType, Offset, Size, Flags
|
||||||
nvs, data, nvs, 0x9000, 0x6000,
|
nvs, data, nvs, 0x9000, 0x5000,
|
||||||
phy_init, data, phy, 0xf000, 0x1000,
|
otadata, data, ota, 0xE000, 0x2000,
|
||||||
factory, app, factory, 0x10000, 4M
|
app0, app, factory, 0x10000, 0x3E0000,
|
||||||
|
coredump, data, coredump,0x3F0000,0x10000,
|
||||||
|
@ -2,6 +2,10 @@
|
|||||||
platform = espressif32
|
platform = espressif32
|
||||||
board = esp32dev
|
board = esp32dev
|
||||||
framework = arduino
|
framework = arduino
|
||||||
|
upload_port = /dev/ttyUSB0
|
||||||
|
upload_speed = 921600
|
||||||
|
monitor_port = /dev/ttyUSB0
|
||||||
|
monitor_speed = 115200
|
||||||
board_build.partitions = partitions-4m-factory.csv
|
board_build.partitions = partitions-4m-factory.csv
|
||||||
lib_deps = https://github.com/pschatzmann/arduino-snapclient
|
lib_deps = https://github.com/pschatzmann/arduino-snapclient
|
||||||
https://github.com/pschatzmann/arduino-audio-tools
|
https://github.com/pschatzmann/arduino-audio-tools
|
||||||
@ -9,3 +13,4 @@ lib_deps = https://github.com/pschatzmann/arduino-snapclient
|
|||||||
https://github.com/pschatzmann/arduino-libopus
|
https://github.com/pschatzmann/arduino-libopus
|
||||||
https://github.com/bblanchon/ArduinoJson
|
https://github.com/bblanchon/ArduinoJson
|
||||||
https://github.com/pschatzmann/arduino-libhelix
|
https://github.com/pschatzmann/arduino-libhelix
|
||||||
|
https://github.com/me-no-dev/ESPAsyncWebServer
|
||||||
@ -42,7 +42,7 @@ void audioStop() {
|
|||||||
opusDecoder.end();
|
opusDecoder.end();
|
||||||
icy.end();
|
icy.end();
|
||||||
file.close();
|
file.close();
|
||||||
snap.end();
|
// snap.end(); // TODO
|
||||||
}
|
}
|
||||||
|
|
||||||
bool audioPlayInit(const Entry &entry) {
|
bool audioPlayInit(const Entry &entry) {
|
||||||
|
|||||||
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
bool playlistRepeatOne = false;
|
bool playlistRepeatOne = false;
|
||||||
|
|
||||||
bool playlistRepeatAll = false;
|
bool playlistRepeatAll = true;
|
||||||
|
|
||||||
bool playlistRandom = false;
|
bool playlistRandom = false;
|
||||||
|
|
||||||
|
|||||||
@ -19,12 +19,16 @@ void wifiLoop() {
|
|||||||
wifiLastMillis = 0;
|
wifiLastMillis = 0;
|
||||||
Serial.printf("WIFI connected: %s\n", WiFi.localIP().toString().c_str());
|
Serial.printf("WIFI connected: %s\n", WiFi.localIP().toString().c_str());
|
||||||
} else if (wifiLastMillis == 0 || millis() - wifiLastMillis > 10000) {
|
} else if (wifiLastMillis == 0 || millis() - wifiLastMillis > 10000) {
|
||||||
|
WiFi.disconnect();
|
||||||
|
yield();
|
||||||
if (wifiLastMillis != 0) {
|
if (wifiLastMillis != 0) {
|
||||||
Serial.printf("WIFI connect timeout!\n");
|
Serial.printf("WIFI connect timeout!\n");
|
||||||
}
|
}
|
||||||
wifiLastMillis = max(1UL, millis());
|
wifiLastMillis = max(1UL, millis());
|
||||||
Serial.printf("WIFI connecting: %s\n", WiFi.SSID().c_str());
|
const auto ssid = "HappyNet";
|
||||||
WiFi.begin("HappyNet", "1Grausame!Sackratte7");
|
Serial.printf("WIFI connecting: %s\n", ssid);
|
||||||
|
WiFi.begin(ssid, "1Grausame!Sackratte7");
|
||||||
|
yield();
|
||||||
} else {
|
} else {
|
||||||
// connecting
|
// connecting
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user