v0.7.010
This commit is contained in:
12
README.md
12
README.md
@@ -296,6 +296,10 @@ Work is in progress...
|
|||||||
|
|
||||||
---
|
---
|
||||||
## Version history
|
## Version history
|
||||||
|
#### v0.7.010
|
||||||
|
- fixed choppy of sound when volume adjustment
|
||||||
|
- fixed initialisation of Nextion displays
|
||||||
|
|
||||||
#### v0.7.000
|
#### v0.7.000
|
||||||
- added support for Nextion displays ([more info](nextion/README.md))
|
- added support for Nextion displays ([more info](nextion/README.md))
|
||||||
- fixed work of VU Meter
|
- fixed work of VU Meter
|
||||||
@@ -312,10 +316,10 @@ Work is in progress...
|
|||||||
option ENABLE_VU_METER (see [myoptions.h](exsamples/myoptions.h#L113) for exsample) \
|
option ENABLE_VU_METER (see [myoptions.h](exsamples/myoptions.h#L113) for exsample) \
|
||||||
**!!! Important !!!** \
|
**!!! Important !!!** \
|
||||||
if you enable this feathure on the esp32 wroom, due to lack of memory, you must modify the file Arduino/libraries/AsyncTCP/src/AsyncTCP.cpp \
|
if you enable this feathure on the esp32 wroom, due to lack of memory, you must modify the file Arduino/libraries/AsyncTCP/src/AsyncTCP.cpp \
|
||||||
replace the line 221 \
|
**replace the line 221** \
|
||||||
xTaskCreateUniversal(_async_service_task, "async_tcp", 8192 * 2, NULL, 3, &_async_service_task_handle, CONFIG_ASYNC_TCP_RUNNING_CORE); \
|
_xTaskCreateUniversal(_async_service_task, "async_tcp", 8192 * 2, NULL, 3, &_async_service_task_handle, CONFIG_ASYNC_TCP_RUNNING_CORE);_ \
|
||||||
with \
|
**with** \
|
||||||
xTaskCreateUniversal(_async_service_task, "async_tcp", 8192 / 2, NULL, 3, &_async_service_task_handle, CONFIG_ASYNC_TCP_RUNNING_CORE);
|
_xTaskCreateUniversal(_async_service_task, "async_tcp", 8192 / 2, NULL, 3, &_async_service_task_handle, CONFIG_ASYNC_TCP_RUNNING_CORE);_
|
||||||
|
|
||||||
#### v0.6.450
|
#### v0.6.450
|
||||||
**!!! a [full update](#update-over-web-interface) with Sketch data upload is required. After updating please press CTRL+F5 in browser !!!**
|
**!!! a [full update](#update-over-web-interface) with Sketch data upload is required. After updating please press CTRL+F5 in browser !!!**
|
||||||
|
|||||||
@@ -98,13 +98,13 @@ void Config::saveIR(){
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
byte Config::setVolume(byte val, bool dosave) {
|
void Config::saveVolume(){
|
||||||
|
EEPROM.write(EEPROM_START + sizeof(store.config_set), store.volume);
|
||||||
|
EEPROM.commit();
|
||||||
|
}
|
||||||
|
|
||||||
|
byte Config::setVolume(byte val) {
|
||||||
store.volume = val;
|
store.volume = val;
|
||||||
if (dosave) {
|
|
||||||
//save();
|
|
||||||
EEPROM.write(EEPROM_START + sizeof(store.config_set), store.volume);
|
|
||||||
EEPROM.commit();
|
|
||||||
}
|
|
||||||
return store.volume;
|
return store.volume;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -72,7 +72,8 @@ class Config {
|
|||||||
void saveIR();
|
void saveIR();
|
||||||
#endif
|
#endif
|
||||||
void init();
|
void init();
|
||||||
byte setVolume(byte val, bool dosave);
|
byte setVolume(byte val);
|
||||||
|
void saveVolume();
|
||||||
void setTone(int8_t bass, int8_t middle, int8_t trebble);
|
void setTone(int8_t bass, int8_t middle, int8_t trebble);
|
||||||
void setBalance(int8_t balance);
|
void setBalance(int8_t balance);
|
||||||
byte setLastStation(byte val);
|
byte setLastStation(byte val);
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
#ifndef options_h
|
#ifndef options_h
|
||||||
#define options_h
|
#define options_h
|
||||||
|
|
||||||
#define VERSION "0.7.000"
|
#define VERSION "0.7.010"
|
||||||
|
|
||||||
/*******************************************************
|
/*******************************************************
|
||||||
DO NOT EDIT THIS FILE.
|
DO NOT EDIT THIS FILE.
|
||||||
|
|||||||
@@ -47,6 +47,7 @@ void Player::init() {
|
|||||||
mode = STOPPED;
|
mode = STOPPED;
|
||||||
setOutputPins(false);
|
setOutputPins(false);
|
||||||
requestToStart = true;
|
requestToStart = true;
|
||||||
|
volTimer=false;
|
||||||
zeroRequest();
|
zeroRequest();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -81,13 +82,19 @@ void Player::loop() {
|
|||||||
zeroRequest();
|
zeroRequest();
|
||||||
}
|
}
|
||||||
if (request.volume >= 0) {
|
if (request.volume >= 0) {
|
||||||
config.setVolume(request.volume, request.doSave);
|
config.setVolume(request.volume);
|
||||||
telnet.printf("##CLI.VOL#: %d\n", config.store.volume);
|
telnet.printf("##CLI.VOL#: %d\n", config.store.volume);
|
||||||
Audio::setVolume(volToI2S(request.volume));
|
Audio::setVolume(volToI2S(request.volume));
|
||||||
zeroRequest();
|
zeroRequest();
|
||||||
display.putRequest({DRAWVOL, 0});
|
display.putRequest({DRAWVOL, 0});
|
||||||
netserver.requestOnChange(VOLUME, 0);
|
netserver.requestOnChange(VOLUME, 0);
|
||||||
}
|
}
|
||||||
|
if(volTimer){
|
||||||
|
if((millis()-volTicks)>3000){
|
||||||
|
config.saveVolume();
|
||||||
|
volTimer=false;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Player::zeroRequest() {
|
void Player::zeroRequest() {
|
||||||
@@ -174,6 +181,8 @@ void Player::setVol(byte volume, bool inside) {
|
|||||||
if (inside) {
|
if (inside) {
|
||||||
setVolume(volToI2S(volume));
|
setVolume(volToI2S(volume));
|
||||||
} else {
|
} else {
|
||||||
|
volTicks = millis();
|
||||||
|
volTimer = true;
|
||||||
request.volume = volume;
|
request.volume = volume;
|
||||||
request.doSave = true;
|
request.doSave = true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,6 +16,9 @@ struct audiorequest_t
|
|||||||
bool doSave;
|
bool doSave;
|
||||||
};
|
};
|
||||||
class Player: public Audio {
|
class Player: public Audio {
|
||||||
|
private:
|
||||||
|
uint32_t volTicks; /* delayed volume save */
|
||||||
|
bool volTimer; /* delayed volume save */
|
||||||
public:
|
public:
|
||||||
audioMode_e mode;
|
audioMode_e mode;
|
||||||
audiorequest_t request;
|
audiorequest_t request;
|
||||||
|
|||||||
@@ -74,8 +74,10 @@ void Nextion::begin(bool dummy) {
|
|||||||
rx_pos = 0;
|
rx_pos = 0;
|
||||||
_volInside=false;
|
_volInside=false;
|
||||||
snprintf(_espcoreversion, sizeof(_espcoreversion) - 1, "%d.%d.%d", ESP_ARDUINO_VERSION_MAJOR, ESP_ARDUINO_VERSION_MINOR, ESP_ARDUINO_VERSION_PATCH);
|
snprintf(_espcoreversion, sizeof(_espcoreversion) - 1, "%d.%d.%d", ESP_ARDUINO_VERSION_MAJOR, ESP_ARDUINO_VERSION_MINOR, ESP_ARDUINO_VERSION_PATCH);
|
||||||
|
putcmd("");
|
||||||
putcmd("rest");
|
putcmd("rest");
|
||||||
delay(200);
|
delay(200);
|
||||||
|
putcmd("");
|
||||||
putcmd("bkcmd=0");
|
putcmd("bkcmd=0");
|
||||||
// putcmd("page boot");
|
// putcmd("page boot");
|
||||||
if(dummy) {
|
if(dummy) {
|
||||||
|
|||||||
Reference in New Issue
Block a user