mirror of
https://github.com/rstrouse/ESPSomfy-RTS.git
synced 2025-12-13 02:52:11 +01:00
Added functionality to support low level triggers for GPIO types #206
This commit is contained in:
parent
0c36c8e746
commit
c0621d82ec
9 changed files with 75 additions and 44 deletions
|
|
@ -7,9 +7,9 @@
|
|||
|
||||
extern Preferences pref;
|
||||
|
||||
#define SHADE_HDR_VER 16
|
||||
#define SHADE_HDR_VER 17
|
||||
#define SHADE_HDR_SIZE 56
|
||||
#define SHADE_REC_SIZE 268
|
||||
#define SHADE_REC_SIZE 272
|
||||
#define GROUP_REC_SIZE 184
|
||||
#define TRANS_REC_SIZE 74
|
||||
|
||||
|
|
@ -667,10 +667,10 @@ bool ShadeConfigFile::readShadeRecord(SomfyShade *shade) {
|
|||
shade->gpioUp = this->readUInt8(shade->gpioUp);
|
||||
shade->gpioDown = this->readUInt8(shade->gpioDown);
|
||||
}
|
||||
if(this->header.version > 15) {
|
||||
if(this->header.version > 15)
|
||||
shade->gpioMy = this->readUInt8(shade->gpioMy);
|
||||
}
|
||||
|
||||
if(this->header.version > 16)
|
||||
shade->gpioFlags = this->readUInt8(shade->gpioFlags);
|
||||
if(shade->getShadeId() == 255) shade->clear();
|
||||
else if(shade->tiltType == tilt_types::tiltonly) {
|
||||
shade->myPos = shade->currentPos = shade->target = 100.0f;
|
||||
|
|
@ -785,7 +785,8 @@ bool ShadeConfigFile::writeShadeRecord(SomfyShade *shade) {
|
|||
this->writeUInt8(shade->sortOrder);
|
||||
this->writeUInt8(shade->gpioUp);
|
||||
this->writeUInt8(shade->gpioDown);
|
||||
this->writeUInt8(shade->gpioMy, CFG_REC_END);
|
||||
this->writeUInt8(shade->gpioMy);
|
||||
this->writeUInt8(shade->gpioFlags, CFG_REC_END);
|
||||
return true;
|
||||
}
|
||||
bool ShadeConfigFile::writeSettingsRecord() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue