Skip to content

Commit

Permalink
release R2310
Browse files Browse the repository at this point in the history
  • Loading branch information
maierkomor committed Oct 26, 2023
1 parent 032e503 commit 30a48ce
Show file tree
Hide file tree
Showing 81 changed files with 8,059 additions and 1,600 deletions.
10 changes: 10 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
R2310:
======
- fixes for SGP30: re-initialize after error, false detection
- FTPd fixes
- bugfixes for SSD1309
- fixes for ESP32-C6
- added hold/unhold actions for GPIOs and LEDs
- added OPT3001 driver
- added SH1106 driver

R2309:
======
- fix SNTP for IDFv5.1 64bit timeval struct
Expand Down
67 changes: 34 additions & 33 deletions components/logging/modules.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include "modules.h"

const char ModNames[] =
"<undef>\0action\0adc\0alarms\0apds\0bh1750\0bmx\0button\0cam\0ccs811b\0cfg\0con\0cyclic\0dht\0dim\0disp\0ds18b20\0event\0fs\0ftpd\0gpio\0hcsr04\0hd44780u\0hdc1000\0hlw8012\0ht16k33\0http\0i2c\0ili9341\0ina219\0influx\0init\0led\0ledc\0log\0lua\0lwtcp\0max7219\0mcp230xx\0mqtt\0nightsky\0ns\0nvm\0ota\0owb\0pca9685\0pcf8574\0relay\0rgbleds\0romfs\0screen\0sgp30\0shell\0si7021\0sm\0sntp\0spi\0ssd130x\0sx1276\0tca9555\0telnet\0ti\0timefuse\0tlc5916\0tlc5947\0tp\0uart\0udns\0udpctrl\0usb\0wlan\0ws2812\0www\0xio\0xpt2046\0";
"<undef>\0action\0adc\0alarms\0apds\0bh1750\0bmx\0button\0cam\0ccs811b\0cfg\0con\0cyclic\0dht\0dim\0disp\0ds18b20\0event\0fs\0ftpd\0gpio\0hcsr04\0hd44780u\0hdc1000\0hlw8012\0ht16k33\0http\0i2c\0ili9341\0ina219\0influx\0init\0led\0ledc\0log\0lua\0lwtcp\0max7219\0mcp230xx\0mqtt\0nightsky\0ns\0nvm\0opt3001\0ota\0owb\0pca9685\0pcf8574\0relay\0rgbleds\0romfs\0screen\0sgp30\0shell\0si7021\0sm\0sntp\0spi\0ssd130x\0sx1276\0tca9555\0telnet\0ti\0timefuse\0tlc5916\0tlc5947\0tp\0uart\0udns\0udpctrl\0usb\0wlan\0ws2812\0www\0xio\0xpt2046\0";

const uint16_t ModNameOff[] = {
0,
Expand Down Expand Up @@ -65,36 +65,37 @@ const uint16_t ModNameOff[] = {
237, // nightsky
246, // ns
249, // nvm
253, // ota
257, // owb
261, // pca9685
269, // pcf8574
277, // relay
283, // rgbleds
291, // romfs
297, // screen
304, // sgp30
310, // shell
316, // si7021
323, // sm
326, // sntp
331, // spi
335, // ssd130x
343, // sx1276
350, // tca9555
358, // telnet
365, // ti
368, // timefuse
377, // tlc5916
385, // tlc5947
393, // tp
396, // uart
401, // udns
406, // udpctrl
414, // usb
418, // wlan
423, // ws2812
430, // www
434, // xio
438, // xpt2046
253, // opt3001
261, // ota
265, // owb
269, // pca9685
277, // pcf8574
285, // relay
291, // rgbleds
299, // romfs
305, // screen
312, // sgp30
318, // shell
324, // si7021
331, // sm
334, // sntp
339, // spi
343, // ssd130x
351, // sx1276
358, // tca9555
366, // telnet
373, // ti
376, // timefuse
385, // tlc5916
393, // tlc5947
401, // tp
404, // uart
409, // udns
414, // udpctrl
422, // usb
426, // wlan
431, // ws2812
438, // www
442, // xio
446, // xpt2046
};
6 changes: 4 additions & 2 deletions components/logging/modules.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ typedef enum logmod_e {
logmod_nightsky,
logmod_ns,
logmod_nvm,
logmod_opt3001,
logmod_ota,
logmod_owb,
logmod_pca9685,
Expand Down Expand Up @@ -148,6 +149,7 @@ typedef enum logmod_e {
#define MODULE_NIGHTSKY logmod_nightsky
#define MODULE_NS logmod_ns
#define MODULE_NVM logmod_nvm
#define MODULE_OPT3001 logmod_opt3001
#define MODULE_OTA logmod_ota
#define MODULE_OWB logmod_owb
#define MODULE_PCA9685 logmod_pca9685
Expand Down Expand Up @@ -180,8 +182,8 @@ typedef enum logmod_e {
#define MODULE_WWW logmod_www
#define MODULE_XIO logmod_xio
#define MODULE_XPT2046 logmod_xpt2046
#define MAX_MODULE_ID 74
#define NUM_MODULES 75
#define MAX_MODULE_ID 75
#define NUM_MODULES 76

#ifdef USE_MODULE
#define TAG USE_MODULE
Expand Down
4 changes: 2 additions & 2 deletions components/logging/profiling.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,11 @@ TimeStats *TimeStats::First = 0;

int prof(Terminal &term, int argc, const char *args[])
{
term.printf("%8s %9s %10s %8s %5s %s\n","low","avg","high","total","calls","function");
term.printf("%8s %9s %10s %10s %5s %s\n","low","avg","high","total","calls","function");
TimeStats *s = TimeStats::First;
while (s) {
if (s->count)
term.printf("%8lu %9lu %10lu %8lu %5lu %s\n",s->low,(long unsigned)(s->total/s->count),(long unsigned)s->high,(long unsigned)s->total,(long unsigned)s->count,s->name);
term.printf("%8lu %9lu %10lu %10lu %5lu %s\n",s->low,(long unsigned)(s->total/s->count),(long unsigned)s->high,(long unsigned)s->total,(long unsigned)s->count,s->name);
s = s->next;
}
return 0;
Expand Down
2 changes: 1 addition & 1 deletion components/netsvc/lwtcp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -355,7 +355,6 @@ err_t LwTcp::handle_connect(void *arg, struct tcp_pcb *pcb, err_t x)

int LwTcp::read(char *buf, size_t l, unsigned timeout)
{
PROFILE_FUNCTION();
int r;
struct pbuf *tofree = 0;
if ((m_pcb == 0) && (m_pbuf == 0)) {
Expand All @@ -365,6 +364,7 @@ int LwTcp::read(char *buf, size_t l, unsigned timeout)
log_local(TAG,"read@%u(%u,%u) fill=%u,pbuf=%u",m_port,l,timeout,m_fill,m_pbuf?m_pbuf->tot_len:0);
if (pdTRUE != xSemaphoreTakeRecursive(m_mtx,MUTEX_ABORT_TIMEOUT))
abort_on_mutex(m_mtx,__FUNCTION__);
PROFILE_FUNCTION();
if (m_pbuf) {
unsigned avail = m_pbuf->tot_len - m_taken;
unsigned copy = l > avail ? avail : l;
Expand Down
5 changes: 4 additions & 1 deletion components/streams/estring.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2021, Thomas Maier-Komor
* Copyright (C) 2020-2023, Thomas Maier-Komor
*
* This source file belongs to Wire-Format-Compiler.
*
Expand Down Expand Up @@ -82,6 +82,9 @@ class estring
{ if (len == 0) return 0; else return str[len-1]; }

void push_back(char c);

void pop_back()
{ if (len) --len; }

const char *data() const
{ return str; }
Expand Down
12 changes: 11 additions & 1 deletion components/wfc/hwcfg_esp32.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Copyright: 2018-2023
* Author : Thomas Maier-Komor
*
* Code generated on 2023-07-31, 21:35:41 (CET).
* Code generated on 2023-10-24, 21:26:41 (CET).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -292,6 +292,7 @@ static const char *i2cdrv_t_names[] = {
"i2cdrv_pca9685_xclk_npn",
"i2cdrv_pca9685_xclk_pnp",
"i2cdrv_pcf8574",
"i2cdrv_sh1106",
"i2cdrv_si7021",
"i2cdrv_ssd1306",
"i2cdrv_tca9555",
Expand All @@ -310,6 +311,7 @@ static i2cdrv_t i2cdrv_t_values[] = {
i2cdrv_pca9685_xclk_npn,
i2cdrv_pca9685_xclk_pnp,
i2cdrv_pcf8574,
i2cdrv_sh1106,
i2cdrv_si7021,
i2cdrv_ssd1306,
i2cdrv_tca9555,
Expand All @@ -332,6 +334,7 @@ size_t parse_ascii_i2cdrv_t(i2cdrv_t *v, const char *s)
{ "i2cdrv_pca9685_xclk_npn", i2cdrv_pca9685_xclk_npn},
{ "i2cdrv_pca9685_xclk_pnp", i2cdrv_pca9685_xclk_pnp},
{ "i2cdrv_pcf8574", i2cdrv_pcf8574},
{ "i2cdrv_sh1106", i2cdrv_sh1106},
{ "i2cdrv_si7021", i2cdrv_si7021},
{ "i2cdrv_ssd1306", i2cdrv_ssd1306},
{ "i2cdrv_tca9555", i2cdrv_tca9555},
Expand Down Expand Up @@ -396,6 +399,8 @@ const char *i2cdrv_t_str(i2cdrv_t e)
return "i2cdrv_tca9555";
case i2cdrv_ssd1306:
return "i2cdrv_ssd1306";
case i2cdrv_sh1106:
return "i2cdrv_sh1106";
}
#endif // !CONFIG_ESPTOOLPY_FLASHSIZE_1MB
#ifdef CONFIG_ESPTOOLPY_FLASHSIZE_1MB
Expand All @@ -414,6 +419,7 @@ static const char *disp_t_names[] = {
"dt_pcf8574_hd44780u",
"dt_sd_14seg",
"dt_sd_7seg",
"dt_sh1106",
"dt_ssd1306",
"dt_ssd1309",
};
Expand All @@ -424,6 +430,7 @@ static disp_t disp_t_values[] = {
dt_pcf8574_hd44780u,
dt_sd_14seg,
dt_sd_7seg,
dt_sh1106,
dt_ssd1306,
dt_ssd1309,
};
Expand All @@ -438,6 +445,7 @@ size_t parse_ascii_disp_t(disp_t *v, const char *s)
{ "dt_pcf8574_hd44780u", dt_pcf8574_hd44780u},
{ "dt_sd_14seg", dt_sd_14seg},
{ "dt_sd_7seg", dt_sd_7seg},
{ "dt_sh1106", dt_sh1106},
{ "dt_ssd1306", dt_ssd1306},
{ "dt_ssd1309", dt_ssd1309},
};
Expand Down Expand Up @@ -483,6 +491,8 @@ const char *disp_t_str(disp_t e)
return "dt_ssd1306";
case dt_ssd1309:
return "dt_ssd1309";
case dt_sh1106:
return "dt_sh1106";
case dt_ili9341:
return "dt_ili9341";
}
Expand Down
4 changes: 3 additions & 1 deletion components/wfc/hwcfg_esp32.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Copyright: 2018-2023
* Author : Thomas Maier-Komor
*
* Code generated on 2023-07-31, 21:35:41 (CET).
* Code generated on 2023-10-24, 21:26:41 (CET).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -175,6 +175,7 @@ typedef enum {
i2cdrv_si7021 = 12,
i2cdrv_tca9555 = 13,
i2cdrv_ssd1306 = 14,
i2cdrv_sh1106 = 15,
} i2cdrv_t;
//! Function to get an ASCII string from a value of a i2cdrv_t.
const char *i2cdrv_t_str(i2cdrv_t e);
Expand All @@ -188,6 +189,7 @@ typedef enum {
dt_pcf8574_hd44780u = 16,
dt_ssd1306 = 32,
dt_ssd1309 = 33,
dt_sh1106 = 34,
dt_ili9341 = 64,
} disp_t;
//! Function to get an ASCII string from a value of a disp_t.
Expand Down
12 changes: 11 additions & 1 deletion components/wfc/hwcfg_esp8266.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Copyright: 2018-2023
* Author : Thomas Maier-Komor
*
* Code generated on 2023-07-31, 21:35:41 (CET).
* Code generated on 2023-10-24, 21:26:41 (CET).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -292,6 +292,7 @@ static const char *i2cdrv_t_names[] = {
"i2cdrv_pca9685_xclk_npn",
"i2cdrv_pca9685_xclk_pnp",
"i2cdrv_pcf8574",
"i2cdrv_sh1106",
"i2cdrv_si7021",
"i2cdrv_ssd1306",
"i2cdrv_tca9555",
Expand All @@ -310,6 +311,7 @@ static i2cdrv_t i2cdrv_t_values[] = {
i2cdrv_pca9685_xclk_npn,
i2cdrv_pca9685_xclk_pnp,
i2cdrv_pcf8574,
i2cdrv_sh1106,
i2cdrv_si7021,
i2cdrv_ssd1306,
i2cdrv_tca9555,
Expand All @@ -332,6 +334,7 @@ size_t parse_ascii_i2cdrv_t(i2cdrv_t *v, const char *s)
{ "i2cdrv_pca9685_xclk_npn", i2cdrv_pca9685_xclk_npn},
{ "i2cdrv_pca9685_xclk_pnp", i2cdrv_pca9685_xclk_pnp},
{ "i2cdrv_pcf8574", i2cdrv_pcf8574},
{ "i2cdrv_sh1106", i2cdrv_sh1106},
{ "i2cdrv_si7021", i2cdrv_si7021},
{ "i2cdrv_ssd1306", i2cdrv_ssd1306},
{ "i2cdrv_tca9555", i2cdrv_tca9555},
Expand Down Expand Up @@ -396,6 +399,8 @@ const char *i2cdrv_t_str(i2cdrv_t e)
return "i2cdrv_tca9555";
case i2cdrv_ssd1306:
return "i2cdrv_ssd1306";
case i2cdrv_sh1106:
return "i2cdrv_sh1106";
}
#endif // !CONFIG_ESPTOOLPY_FLASHSIZE_1MB
#ifdef CONFIG_ESPTOOLPY_FLASHSIZE_1MB
Expand All @@ -414,6 +419,7 @@ static const char *disp_t_names[] = {
"dt_pcf8574_hd44780u",
"dt_sd_14seg",
"dt_sd_7seg",
"dt_sh1106",
"dt_ssd1306",
"dt_ssd1309",
};
Expand All @@ -424,6 +430,7 @@ static disp_t disp_t_values[] = {
dt_pcf8574_hd44780u,
dt_sd_14seg,
dt_sd_7seg,
dt_sh1106,
dt_ssd1306,
dt_ssd1309,
};
Expand All @@ -438,6 +445,7 @@ size_t parse_ascii_disp_t(disp_t *v, const char *s)
{ "dt_pcf8574_hd44780u", dt_pcf8574_hd44780u},
{ "dt_sd_14seg", dt_sd_14seg},
{ "dt_sd_7seg", dt_sd_7seg},
{ "dt_sh1106", dt_sh1106},
{ "dt_ssd1306", dt_ssd1306},
{ "dt_ssd1309", dt_ssd1309},
};
Expand Down Expand Up @@ -483,6 +491,8 @@ const char *disp_t_str(disp_t e)
return "dt_ssd1306";
case dt_ssd1309:
return "dt_ssd1309";
case dt_sh1106:
return "dt_sh1106";
case dt_ili9341:
return "dt_ili9341";
}
Expand Down
4 changes: 3 additions & 1 deletion components/wfc/hwcfg_esp8266.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* Copyright: 2018-2023
* Author : Thomas Maier-Komor
*
* Code generated on 2023-07-31, 21:35:41 (CET).
* Code generated on 2023-10-24, 21:26:41 (CET).
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -176,6 +176,7 @@ typedef enum {
i2cdrv_si7021 = 12,
i2cdrv_tca9555 = 13,
i2cdrv_ssd1306 = 14,
i2cdrv_sh1106 = 15,
} i2cdrv_t;
//! Function to get an ASCII string from a value of a i2cdrv_t.
const char *i2cdrv_t_str(i2cdrv_t e);
Expand All @@ -189,6 +190,7 @@ typedef enum {
dt_pcf8574_hd44780u = 16,
dt_ssd1306 = 32,
dt_ssd1309 = 33,
dt_sh1106 = 34,
dt_ili9341 = 64,
} disp_t;
//! Function to get an ASCII string from a value of a disp_t.
Expand Down
Loading

0 comments on commit 30a48ce

Please sign in to comment.