Compare commits
2 commits
542351e05e
...
3fc29bee2e
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3fc29bee2e | ||
|
|
3a4f713fcc |
|
|
@ -18,6 +18,7 @@ board_build.filesystem = littlefs
|
|||
monitor_speed = 115200
|
||||
upload_speed = 921600
|
||||
;monitor_filters = send_on_enter
|
||||
extra_scripts = pre:scripts/git_version.py
|
||||
build_src_filter =
|
||||
+<meshberry/>
|
||||
-<chat-relay/>
|
||||
|
|
|
|||
19
scripts/git_version.py
Normal file
19
scripts/git_version.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
Import("env")
|
||||
|
||||
import subprocess
|
||||
|
||||
|
||||
def git(*args):
|
||||
try:
|
||||
return subprocess.check_output(
|
||||
["git"] + list(args), stderr=subprocess.DEVNULL
|
||||
).strip().decode("ascii")
|
||||
except Exception:
|
||||
return None
|
||||
|
||||
# count number of commits.
|
||||
build_number = git("rev-list", "--count", "HEAD") or "0"
|
||||
|
||||
env.Append(BUILD_FLAGS=[
|
||||
"-DBUILD_NUMBER=%s" % build_number
|
||||
])
|
||||
|
|
@ -14,7 +14,7 @@
|
|||
#include <array>
|
||||
|
||||
#define MAX_MSG_LEN 100
|
||||
#define MAX_HISTORY 32
|
||||
#define MAX_HISTORY 128
|
||||
#define MAX_NODES 30
|
||||
|
||||
struct NodePresence {
|
||||
|
|
@ -35,8 +35,8 @@ extern int nodesCount;
|
|||
extern uint8_t broadcastAddressEspNow[6];
|
||||
|
||||
/* Timings */
|
||||
#define TIMEOUT_PRESENCE 2000
|
||||
#define PING_INTERVAL 500
|
||||
#define TIMEOUT_PRESENCE 3000
|
||||
#define PING_INTERVAL 1000
|
||||
extern unsigned long lastPing;
|
||||
|
||||
/* ---------- BUFFER SÉCURISÉ POUR LE CALLBACK ---------- */
|
||||
|
|
|
|||
|
|
@ -11,8 +11,14 @@
|
|||
|
||||
BleKeyboard bleKeyboard;
|
||||
|
||||
#ifndef BUILD_NUMBER
|
||||
#define BUILD_NUMBER 0
|
||||
#endif
|
||||
|
||||
void setup() {
|
||||
Serial.begin(SERIAL_BAUD);
|
||||
Serial.printf("Build #%d\n", BUILD_NUMBER);
|
||||
|
||||
esp_sleep_wakeup_cause_t cause = esp_sleep_get_wakeup_cause();
|
||||
if (cause == ESP_SLEEP_WAKEUP_EXT1 || cause == ESP_SLEEP_WAKEUP_TOUCHPAD) {
|
||||
Serial.println("[wake] resumed from deep sleep");
|
||||
|
|
|
|||
Loading…
Reference in a new issue