diff --git a/bin/program-release-heltec.sh b/bin/program-release-heltec.sh new file mode 100755 index 000000000..ff6ca034b --- /dev/null +++ b/bin/program-release-heltec.sh @@ -0,0 +1,6 @@ + +set -e + +source bin/version.sh + +esptool.py --baud 921600 write_flash 0x10000 release/firmware-HELTEC-US-$VERSION.bin diff --git a/bin/version.sh b/bin/version.sh new file mode 100644 index 000000000..f7a3dfdae --- /dev/null +++ b/bin/version.sh @@ -0,0 +1,3 @@ + + +export VERSION=0.0.5 \ No newline at end of file diff --git a/src/configuration.h b/src/configuration.h index 9c967f353..049a6c4b5 100644 --- a/src/configuration.h +++ b/src/configuration.h @@ -33,7 +33,7 @@ along with this program. If not, see . // If app version is not specified we assume we are not being invoked by the build script #ifndef APP_VERSION -#define APP_VERSION "0.0.0" // this def normally comes from build-all.sh +#define APP_VERSION 0.0.0 // this def normally comes from build-all.sh #endif diff --git a/src/main.ino b/src/main.ino index e2e661574..3ab046ff5 100644 --- a/src/main.ino +++ b/src/main.ino @@ -240,7 +240,7 @@ void setup() #endif // Hello - DEBUG_MSG("%s %s\n", xstr(APP_NAME), str(APP_VERSION)); + DEBUG_MSG("%s %s\n", str(APP_NAME), xstr(APP_VERSION)); // Don't init display if we don't have one or we are waking headless due to a timer event if (wakeCause == ESP_SLEEP_WAKEUP_TIMER) @@ -270,7 +270,7 @@ void initBluetooth() // FIXME - we are leaking like crazy // AllocatorScope scope(btPool); - BLEServer *serve = initBLE(getDeviceName(), HW_VENDOR, str(APP_VERSION)); // FIXME, use a real name based on the macaddr + BLEServer *serve = initBLE(getDeviceName(), HW_VENDOR, xstr(APP_VERSION)); // FIXME, use a real name based on the macaddr createMeshBluetoothService(serve); // Start advertising - this must be done _after_ creating all services