DS_CAP_APP_ID - denis-stepanov/esp-ds-system GitHub Wiki
This capability adds support for application identification. The following fields are implemented:
| Field | Description | Default Value |
|---|---|---|
const char *System::app_name |
Application Name | My Program |
const char *System::app_version |
Application Version | 0.1 |
const char *System::app_build |
Application Build |
__DATE__ " " __TIME__ (e.g., Sep 22 2020 22:40:48) |
const char *System::app_url |
Application Web Site | (empty) |
None.
-
DS_CAP_APP_LOG && DS_CAP_SYS_TIME — if both application log and time are enabled, application identification will be logged on startup. Example:
2020/10/10 17:08:30: Started ESP8266 DS Mailbox Automation; Local Module v1.8.1, build Sep 22 2020 22:40:48 -
DS_CAP_SYS_LOG_HW — if syslog is enabled, application identification will be printed on startup.
-
DS_CAP_WEBSERVER — if web server is enabled, its "System Information" page will include "Program" line with application identification.
None.
MySystem.h:
#define DS_CAP_APP_ID // Enable application identification
#include "System.h" // System global definitions
sketch.ino:
#include "MySystem.h"
using namespace ds;
const char *System::app_name = "Pi Calculator";
const char *System::app_version = "3.14.159";
const char *System::app_url = "http://www.pi314.net/";
void setup() {
}
void loop() {
}
System::begin() |
Not required |
System::update() |
Not required |
- Default build string
__DATE__ " " __TIME__will be compiled inSystem.oon first compilation. In absence of modifications toSystem.cppor its dependencies, the file will not be recompiled. This means, if you only change your.ino, the build string will not change. The workaround to this is to setapp_buildfrom your sketch explicitly, or just restart the Arduino IDE in order to force complete recompilation of the sketch.
Version 1.0 or later.
None.