add 'NO_GLOBAL_UPDATE' define to avoid creating global UpdateClass instance (#8500)
Save 180 bytes of ram if UpdateClass instance is not required
This commit is contained in:
parent
dbc060b181
commit
f0910e66a5
2 changed files with 4 additions and 0 deletions
|
|
@ -190,6 +190,8 @@ class UpdateClass {
|
||||||
uint8_t _ledOn;
|
uint8_t _ledOn;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
#if !defined(NO_GLOBAL_INSTANCES) && !defined(NO_GLOBAL_UPDATE)
|
||||||
extern UpdateClass Update;
|
extern UpdateClass Update;
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -414,4 +414,6 @@ bool UpdateClass::_chkDataInBlock(const uint8_t *data, size_t len) const {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if !defined(NO_GLOBAL_INSTANCES) && !defined(NO_GLOBAL_UPDATE)
|
||||||
UpdateClass Update;
|
UpdateClass Update;
|
||||||
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue