mirror of https://github.com/arendst/Tasmota.git
Merge branch 'development' into new-windmeter-sensor
This commit is contained in:
commit
1b7ca00714
|
@ -398,6 +398,7 @@
|
|||
#define D_CMND_RGBWWTABLE "RGBWWTable"
|
||||
#define D_CMND_ROTATION "Rotation"
|
||||
#define D_CMND_SCHEME "Scheme"
|
||||
#define D_CMND_SEQUENCE_OFFSET "SequenceOffset"
|
||||
#define D_CMND_SPEED "Speed"
|
||||
#define D_CMND_WAKEUP "Wakeup"
|
||||
#define D_CMND_WAKEUPDURATION "WakeUpDuration"
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_BG_BG_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_CS_CZ_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload Dateien"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "Rauschpegel:"
|
||||
#define D_AS3935_ENERGY "Energie:"
|
||||
#define D_AS3935_DISTANCE "Entfernung:"
|
||||
#define D_AS3935_DISTURBER "Störsingal:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "ca.:"
|
||||
#define D_AS3935_AWAY "entfernt"
|
||||
#define D_AS3935_LIGHT "Blitz"
|
||||
#define D_AS3935_OUT "ausserhalb der Reichweite"
|
||||
#define D_AS3935_NOT "Entfernung nicht ermittelbar"
|
||||
#define D_AS3935_ABOVE "Blitz überhalb"
|
||||
#define D_AS3935_NOISE "Rauschen entdeckt"
|
||||
#define D_AS3935_DISTDET "Störer entdeckt"
|
||||
#define D_AS3935_INTNOEV "Interrupt ohne Grund!"
|
||||
#define D_AS3935_NOMESS "lausche..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "Kalibrierung fehlerhaft"
|
||||
#define D_AS3935_CAL_OK "Cap gesetzt auf:"
|
||||
|
||||
#endif // _LANGUAGE_DE_DE_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_EL_GR_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_EN_GB_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Cargar"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Cargar Archivos"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_ES_ES_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_FR_FR_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_HE_HE_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_HU_HU_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload file"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_IT_IT_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_KO_KO_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_NL_NL_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_PL_PL_D_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_PT_BR_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_PT_PT_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Încarcă"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Încarcă fișiere"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_RO_RO_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_RU_RU_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_SK_SK_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_SV_SE_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_TR_TR_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Завантажити"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Завантажити файли"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_UK_UA_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_ZH_CN_H_
|
||||
|
|
|
@ -751,4 +751,27 @@
|
|||
#define D_SCRIPT_UPLOAD "Upload"
|
||||
#define D_SCRIPT_UPLOAD_FILES "Upload files"
|
||||
|
||||
//xsns_67_as3935.ino
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
#endif // _LANGUAGE_ZH_TW_H_
|
||||
|
|
|
@ -426,7 +426,7 @@
|
|||
#define DEVICE_GROUPS_PORT 4447 // Device groups multicast port
|
||||
#define USE_DEVICE_GROUPS_SEND // Add support for the DevGroupSend command (+0k6 code)
|
||||
#define USE_PWM_DIMMER // Add support for MJ-SD01/acenx/NTONPOWER PWM dimmers (+2k2 code, DGR=0k4)
|
||||
#define USE_PWM_DIMMER_REMOTE // Add support for remote switches to PWM Dimmer, also adds device groups support (+0k9 code plus device groups size)
|
||||
#define USE_PWM_DIMMER_REMOTE // Add support for remote switches to PWM Dimmer (requires USE_DEVICE_GROUPS) (+0k9 code)
|
||||
//#define USE_KEELOQ // Add support for Jarolift rollers by Keeloq algorithm (+4k5 code)
|
||||
#define USE_SONOFF_D1 // Add support for Sonoff D1 Dimmer (+0k7 code)
|
||||
|
||||
|
@ -441,6 +441,7 @@
|
|||
#define USE_SONOFF_L1 // Add support for Sonoff L1 led control
|
||||
#define USE_ELECTRIQ_MOODL // Add support for ElectriQ iQ-wifiMOODL RGBW LED controller (+0k3 code)
|
||||
#define USE_LIGHT_PALETTE // Add support for color palette (+0k7 code)
|
||||
#define USE_DGR_LIGHT_SEQUENCE // Add support for device group light sequencing (requires USE_DEVICE_GROUPS) (+0k2 code)
|
||||
|
||||
// -- Counter input -------------------------------
|
||||
#define USE_COUNTER // Enable inputs as counter (+0k8 code)
|
||||
|
|
|
@ -350,7 +350,7 @@ void SendReceiveDeviceGroupMessage(struct device_group * device_group, struct de
|
|||
else {
|
||||
switch (item) {
|
||||
case DGR_ITEM_LIGHT_CHANNELS:
|
||||
log_length = snprintf(log_ptr, log_remaining, PSTR("%u,%u,%u,%u,%u"), *message_ptr, *(message_ptr + 1), *(message_ptr + 2), *(message_ptr + 3), *(message_ptr + 4));
|
||||
log_length = snprintf(log_ptr, log_remaining, PSTR("%u,%u,%u,%u,%u,%u"), *message_ptr, *(message_ptr + 1), *(message_ptr + 2), *(message_ptr + 3), *(message_ptr + 4), *(message_ptr + 5));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -549,7 +549,7 @@ bool _SendDeviceGroupMessage(uint8_t device_group_index, DevGroupMessageType mes
|
|||
else {
|
||||
switch (item) {
|
||||
case DGR_ITEM_LIGHT_CHANNELS:
|
||||
for (int i = 0; i < 5; i++) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
*out_ptr++ = strtoul((char *)value_ptr, (char **)&value_ptr, 0);
|
||||
if (*value_ptr == ',') value_ptr++;
|
||||
}
|
||||
|
@ -665,7 +665,7 @@ bool _SendDeviceGroupMessage(uint8_t device_group_index, DevGroupMessageType mes
|
|||
else {
|
||||
switch (item) {
|
||||
case DGR_ITEM_LIGHT_CHANNELS:
|
||||
value = 5;
|
||||
value = 6;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -114,15 +114,10 @@ extern "C" void resetPins();
|
|||
#define MESSZ (MQTT_MAX_PACKET_SIZE -TOPSZ -7) // Max number of characters in JSON message string
|
||||
#endif
|
||||
|
||||
#ifdef USE_PWM_DIMMER_REMOTE
|
||||
#ifdef USE_PWM_DIMMER
|
||||
#ifndef USE_DEVICE_GROUPS
|
||||
#define USE_DEVICE_GROUPS
|
||||
#endif // USE_DEVICE_GROUPS
|
||||
#else // USE_PWM_DIMMER
|
||||
#undef USE_PWM_DIMMER_REMOTE
|
||||
#endif // USE_PWM_DIMMER
|
||||
#endif // USE_PWM_DIMMER_REMOTE
|
||||
#undef USE_DGR_LIGHT_SEQUENCE
|
||||
#endif // USE_DEVICE_GROUPS
|
||||
|
||||
#ifndef DOMOTICZ_UPDATE_TIMER
|
||||
#define DOMOTICZ_UPDATE_TIMER 0 // [DomoticzUpdateTimer] Send relay status (0 = disable, 1 - 3600 seconds) (Optional)
|
||||
|
|
|
@ -257,9 +257,10 @@ const char HTTP_SCRIPT_TEMPLATE[] PROGMEM =
|
|||
"if(eb('s1').value==''){"
|
||||
"eb('s1').value=k;" // Set NAME if not yet set
|
||||
"}"
|
||||
"os=o.shift();" // Complete GPIO sensor list
|
||||
"as=o.shift();" // Complete ADC0 list
|
||||
"g=o.shift().split(',');" // Array separator
|
||||
"g=o.shift().split(',');" // GPIO - Array separator
|
||||
"os=\""; // }2'0'>None (0)}3}2'17'>Button1 (17)}3...
|
||||
const char HTTP_SCRIPT_TEMPLATE2[] PROGMEM =
|
||||
"\";"
|
||||
"j=0;"
|
||||
"for(i=0;i<" STR(MAX_USER_PINS) ";i++){" // Supports 13 GPIOs
|
||||
"if(6==i){j=9;}"
|
||||
|
@ -268,7 +269,9 @@ const char HTTP_SCRIPT_TEMPLATE[] PROGMEM =
|
|||
"j++;"
|
||||
"}"
|
||||
"g=o.shift();" // FLAG
|
||||
"os=as;"
|
||||
"os=\""; // }2'0'>None (0)}3}2'17'>Analog (17)}3...
|
||||
const char HTTP_SCRIPT_TEMPLATE3[] PROGMEM =
|
||||
"\";"
|
||||
"sk(g&15," STR(ADC0_PIN) ");" // Set ADC0
|
||||
"g>>=4;"
|
||||
"for(i=0;i<" STR(GPIO_FLAG_USED) ";i++){"
|
||||
|
@ -286,20 +289,13 @@ const char HTTP_SCRIPT_TEMPLATE[] PROGMEM =
|
|||
"ld(a,x1);" // ?t related to WebGetArg("t", stemp, sizeof(stemp));
|
||||
"}"
|
||||
|
||||
"function x2(a){"
|
||||
"os=a.responseText;"
|
||||
"function sl(){"
|
||||
"os=\""; // }2'0'>Sonoff Basic (1)}3...
|
||||
const char HTTP_SCRIPT_TEMPLATE4[] PROGMEM =
|
||||
"\";"
|
||||
"sk(" STR(WEMOS_MODULE) ",99);" // 17 = WEMOS
|
||||
"st(" STR(USER_MODULE) ");"
|
||||
"}"
|
||||
|
||||
#ifdef USE_JAVASCRIPT_ES6
|
||||
"sl=()=>ld('tp?m=1',x2);" // ?m related to Webserver->hasArg("m")
|
||||
#else
|
||||
"function sl(){"
|
||||
"ld('tp?m=1',x2);" // ?m related to Webserver->hasArg("m")
|
||||
"}"
|
||||
#endif
|
||||
|
||||
"wl(sl);";
|
||||
|
||||
const char HTTP_SCRIPT_INFO_BEGIN[] PROGMEM =
|
||||
|
@ -1405,16 +1401,6 @@ void HandleTemplateConfiguration(void)
|
|||
|
||||
char stemp[30]; // Template number and Sensor name
|
||||
|
||||
if (Webserver->hasArg("m")) {
|
||||
WSContentBegin(200, CT_PLAIN);
|
||||
for (uint32_t i = 0; i < sizeof(kModuleNiceList); i++) { // "}2'%d'>%s (%d)}3" - "}2'0'>Sonoff Basic (1)}3"
|
||||
uint32_t midx = pgm_read_byte(kModuleNiceList + i);
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, midx, AnyModuleName(midx).c_str(), midx +1);
|
||||
}
|
||||
WSContentEnd();
|
||||
return;
|
||||
}
|
||||
|
||||
WebGetArg("t", stemp, sizeof(stemp)); // 0 - 69 Template number
|
||||
if (strlen(stemp)) {
|
||||
uint32_t module = atoi(stemp);
|
||||
|
@ -1427,27 +1413,7 @@ void HandleTemplateConfiguration(void)
|
|||
|
||||
WSContentBegin(200, CT_PLAIN);
|
||||
WSContentSend_P(PSTR("%s}1"), AnyModuleName(module).c_str()); // NAME: Generic
|
||||
|
||||
|
||||
for (uint32_t i = 0; i < sizeof(kGpioNiceList); i++) { // GPIO: }2'0'>None (0)}3}2'17'>Button1 (17)}3...
|
||||
if (1 == i) {
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, 255, D_SENSOR_USER, 255); // }2'255'>User (255)}3
|
||||
}
|
||||
uint32_t midx = pgm_read_byte(kGpioNiceList + i);
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, midx, GetTextIndexed(stemp, sizeof(stemp), midx, kSensorNames), midx);
|
||||
}
|
||||
WSContentSend_P(PSTR("}1")); // Field separator
|
||||
|
||||
|
||||
for (uint32_t i = 0; i < ADC0_END; i++) { // FLAG: }2'0'>None (0)}3}2'17'>Analog (17)}3...
|
||||
if (1 == i) {
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, ADC0_USER, D_SENSOR_USER, ADC0_USER); // }2'15'>User (15)}3
|
||||
}
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, i, GetTextIndexed(stemp, sizeof(stemp), i, kAdc0Names), i);
|
||||
}
|
||||
WSContentSend_P(PSTR("}1")); // Field separator
|
||||
|
||||
for (uint32_t i = 0; i < ARRAY_SIZE(cmodule.io); i++) { // 17,148,29,149,7,255,255,255,138,255,139,255,255
|
||||
for (uint32_t i = 0; i < ARRAY_SIZE(cmodule.io); i++) { // 17,148,29,149,7,255,255,255,138,255,139,255,255
|
||||
if (!FlashPin(i)) {
|
||||
WSContentSend_P(PSTR("%s%d"), (i>0)?",":"", cmodule.io[i]);
|
||||
}
|
||||
|
@ -1461,7 +1427,29 @@ void HandleTemplateConfiguration(void)
|
|||
|
||||
WSContentStart_P(S_CONFIGURE_TEMPLATE);
|
||||
WSContentSend_P(HTTP_SCRIPT_MODULE_TEMPLATE);
|
||||
|
||||
WSContentSend_P(HTTP_SCRIPT_TEMPLATE);
|
||||
for (uint32_t i = 0; i < sizeof(kGpioNiceList); i++) { // GPIO: }2'0'>None (0)}3}2'17'>Button1 (17)}3...
|
||||
if (1 == i) {
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, GPIO_USER, D_SENSOR_USER, GPIO_USER); // }2'255'>User (255)}3
|
||||
}
|
||||
uint32_t midx = pgm_read_byte(kGpioNiceList + i);
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, midx, GetTextIndexed(stemp, sizeof(stemp), midx, kSensorNames), midx);
|
||||
}
|
||||
WSContentSend_P(HTTP_SCRIPT_TEMPLATE2);
|
||||
for (uint32_t i = 0; i < ADC0_END; i++) { // FLAG: }2'0'>None (0)}3}2'17'>Analog (17)}3...
|
||||
if (1 == i) {
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, ADC0_USER, D_SENSOR_USER, ADC0_USER); // }2'15'>User (15)}3
|
||||
}
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, i, GetTextIndexed(stemp, sizeof(stemp), i, kAdc0Names), i);
|
||||
}
|
||||
WSContentSend_P(HTTP_SCRIPT_TEMPLATE3);
|
||||
for (uint32_t i = 0; i < sizeof(kModuleNiceList); i++) { // "}2'%d'>%s (%d)}3" - "}2'0'>Sonoff Basic (1)}3"
|
||||
uint32_t midx = pgm_read_byte(kModuleNiceList + i);
|
||||
WSContentSend_P(HTTP_MODULE_TEMPLATE_REPLACE, midx, AnyModuleName(midx).c_str(), midx +1);
|
||||
}
|
||||
WSContentSend_P(HTTP_SCRIPT_TEMPLATE4);
|
||||
|
||||
WSContentSendStyle();
|
||||
WSContentSend_P(HTTP_FORM_TEMPLATE);
|
||||
WSContentSend_P(HTTP_TABLE100);
|
||||
|
|
|
@ -135,6 +135,9 @@ const char kLightCommands[] PROGMEM = "|" // No prefix
|
|||
#ifdef USE_LIGHT_PALETTE
|
||||
"|" D_CMND_PALETTE
|
||||
#endif // USE_LIGHT_PALETTE
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
"|" D_CMND_SEQUENCE_OFFSET
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
"|UNDOCA" ;
|
||||
|
||||
void (* const LightCommand[])(void) PROGMEM = {
|
||||
|
@ -144,6 +147,9 @@ void (* const LightCommand[])(void) PROGMEM = {
|
|||
#ifdef USE_LIGHT_PALETTE
|
||||
&CmndPalette,
|
||||
#endif // USE_LIGHT_PALETTE
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
&CmndSequenceOffset,
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
&CmndUndocA };
|
||||
|
||||
// Light color mode, either RGB alone, or white-CT alone, or both only available if ct_rgb_linked is false
|
||||
|
@ -284,6 +290,10 @@ struct LIGHT {
|
|||
#ifdef USE_DEVICE_GROUPS
|
||||
uint8_t last_scheme = 0;
|
||||
bool devgrp_no_channels_out = false; // don't share channels with device group (e.g. if scheme set by other device)
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
uint8_t sequence_offset = 0; // number of channel changes this light is behind the master
|
||||
uint8_t * channels_fifo;
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
#endif // USE_DEVICE_GROUPS
|
||||
#ifdef USE_LIGHT_PALETTE
|
||||
uint8_t palette_count = 0; // palette entry count
|
||||
|
@ -2225,16 +2235,22 @@ void calcGammaBulbs(uint16_t cur_col_10[5]) {
|
|||
void LightSendDeviceGroupStatus(bool force)
|
||||
{
|
||||
static uint8_t last_channels[LST_MAX];
|
||||
static uint8_t channels_sequence = 0;
|
||||
static uint8_t last_bri;
|
||||
|
||||
uint8_t bri = light_state.getBri();
|
||||
bool send_bri_update = (force || bri != last_bri);
|
||||
|
||||
if (Light.subtype > LST_SINGLE && !Light.devgrp_no_channels_out) {
|
||||
uint8_t channels[LST_MAX];
|
||||
uint8_t channels[LST_MAX + 1];
|
||||
light_state.getChannels(channels);
|
||||
if (force || memcmp(last_channels, channels, LST_MAX)) {
|
||||
if (force || memcmp(last_channels, channels, LST_MAX)
|
||||
#ifdef USE_LIGHT_PALETTE
|
||||
|| (Settings.light_scheme && Light.palette_count)
|
||||
#endif // USE_LIGHT_PALETTE
|
||||
) {
|
||||
memcpy(last_channels, channels, LST_MAX);
|
||||
channels[LST_MAX] = ++channels_sequence;
|
||||
SendLocalDeviceGroupMessage((send_bri_update ? DGR_MSGTYP_PARTIAL_UPDATE : DGR_MSGTYP_UPDATE), DGR_ITEM_LIGHT_CHANNELS, channels);
|
||||
}
|
||||
}
|
||||
|
@ -2285,7 +2301,30 @@ void LightHandleDevGroupItem(void)
|
|||
}
|
||||
break;
|
||||
case DGR_ITEM_LIGHT_CHANNELS:
|
||||
light_controller.changeChannels((uint8_t *)XdrvMailbox.data);
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
{
|
||||
static uint8_t last_sequence = 0;
|
||||
|
||||
// If a sequence offset is set, set the channels to the ones we received <SequenceOffset>
|
||||
// changes ago.
|
||||
if (Light.sequence_offset) {
|
||||
light_controller.changeChannels(Light.channels_fifo);
|
||||
|
||||
// Shift the fifo down and load the newly received channels at the end for this update and
|
||||
// any updates we missed.
|
||||
int last_entry = (Light.sequence_offset - 1) * LST_MAX;
|
||||
for (uint8_t sequence = (uint8_t)XdrvMailbox.data[LST_MAX]; (uint8_t)(sequence - last_sequence) > 0; last_sequence++) {
|
||||
memmove(Light.channels_fifo, &Light.channels_fifo[LST_MAX], last_entry);
|
||||
memcpy(&Light.channels_fifo[last_entry], XdrvMailbox.data, LST_MAX);
|
||||
}
|
||||
}
|
||||
else {
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
light_controller.changeChannels((uint8_t *)XdrvMailbox.data);
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
}
|
||||
}
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
send_state = true;
|
||||
break;
|
||||
case DGR_ITEM_LIGHT_FIXED_COLOR:
|
||||
|
@ -2922,12 +2961,15 @@ void CmndPalette(void)
|
|||
for (int entry = 0; entry < Light.palette_count; entry++) {
|
||||
if (Settings.flag.decimal_text) { // SetOption17 - Switch between decimal or hexadecimal output
|
||||
*p++ = '"';
|
||||
for (uint32_t i = 0; i < Light.subtype; i++) {
|
||||
p += sprintf_P(p, PSTR("%d,"), *palette_entry++);
|
||||
}
|
||||
*(p - 1) = '"';
|
||||
}
|
||||
memcpy(Light.current_color, palette_entry, Light.subtype);
|
||||
LightGetColor(p);
|
||||
p += strlen(p);
|
||||
if (Settings.flag.decimal_text) { // SetOption17 - Switch between decimal or hexadecimal output
|
||||
*p++ = '"';
|
||||
else {
|
||||
for (uint32_t i = 0; i < Light.subtype; i++) {
|
||||
p += sprintf_P(p, PSTR("%02X"), *palette_entry++);
|
||||
}
|
||||
}
|
||||
*p++ = ',';
|
||||
}
|
||||
|
@ -2939,6 +2981,20 @@ void CmndPalette(void)
|
|||
}
|
||||
#endif // USE_LIGHT_PALETTE
|
||||
|
||||
#ifdef USE_DGR_LIGHT_SEQUENCE
|
||||
void CmndSequenceOffset(void)
|
||||
{
|
||||
if ((XdrvMailbox.payload >= 0) && (XdrvMailbox.payload <= 255)) {
|
||||
if (XdrvMailbox.payload != Light.sequence_offset) {
|
||||
if (Light.sequence_offset) free(Light.channels_fifo);
|
||||
Light.sequence_offset = XdrvMailbox.payload;
|
||||
if (Light.sequence_offset) Light.channels_fifo = (uint8_t *)calloc(Light.sequence_offset, LST_MAX);
|
||||
}
|
||||
}
|
||||
ResponseCmndNumber(Light.sequence_offset);
|
||||
}
|
||||
#endif // USE_DGR_LIGHT_SEQUENCE
|
||||
|
||||
void CmndUndocA(void)
|
||||
{
|
||||
// Theos legacy status
|
||||
|
|
|
@ -61,6 +61,8 @@
|
|||
#define APDS9930_CHIPID_1 0x12 // we will check, if someone got an incorrect sensor
|
||||
#define APDS9930_CHIPID_2 0x39 // there are case reports about "accidentially bought" 9930's
|
||||
|
||||
#define APDS9960_GESTURE // Enable Gesture feature(2k on flash)
|
||||
|
||||
/* Gesture parameters */
|
||||
#define GESTURE_THRESHOLD_OUT 10
|
||||
#define GESTURE_SENSITIVITY_1 50
|
||||
|
@ -72,13 +74,26 @@
|
|||
const char APDS9960_TAG[] = "APDS9960";
|
||||
|
||||
#ifdef USE_WEBSERVER
|
||||
const char HTTP_APDS9960_SNS[] PROGMEM =
|
||||
"{s}" "Red" "{m}%s{e}"
|
||||
"{s}" "Green" "{m}%s{e}"
|
||||
"{s}" "Blue" "{m}%s{e}"
|
||||
"{s}" "Ambient" "{m}%s " D_UNIT_LUX "{e}"
|
||||
"{s}" "CCT" "{m}%s " "K" "{e}" // calculated color temperature in Kelvin
|
||||
"{s}" "Proximity" "{m}%s{e}"; // {s} = <tr><th>, {m} = </th><td>, {e} = </td></tr>
|
||||
#ifdef APDS9960_GESTURE
|
||||
|
||||
#define D_GESTURE "Gesture"
|
||||
|
||||
const char HTTP_SNS_GESTURE[] PROGMEM = "{s}%s " D_GESTURE "{m}%s{e}";
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
#define D_COLOR_RED "Red"
|
||||
#define D_COLOR_GREEN "Green"
|
||||
#define D_COLOR_BLUE "Blue"
|
||||
#define D_CCT "CCT"
|
||||
#define D_PROXIMITY "Proximity"
|
||||
|
||||
const char HTTP_SNS_COLOR_RED[] PROGMEM = "{s}%s " D_COLOR_RED "{m}%u{e}";
|
||||
const char HTTP_SNS_COLOR_GREEN[] PROGMEM = "{s}%s " D_COLOR_GREEN "{m}%u{e}";
|
||||
const char HTTP_SNS_COLOR_BLUE[] PROGMEM = "{s}%s " D_COLOR_BLUE "{m}%u{e}";
|
||||
const char HTTP_SNS_CCT[] PROGMEM = "{s}%s " D_CCT "{m}%u " "K" "{e}";
|
||||
const char HTTP_SNS_PROXIMITY[] PROGMEM = "{s}%s " D_PROXIMITY "{m}%u{e}";
|
||||
|
||||
#endif // USE_WEBSERVER
|
||||
|
||||
/*********************************************************************************************\
|
||||
|
@ -236,7 +251,15 @@ const char HTTP_APDS9960_SNS[] PROGMEM =
|
|||
|
||||
#define APDS9960_ERROR 0xFF
|
||||
|
||||
#ifdef APDS9960_GESTURE
|
||||
/* Direction definitions */
|
||||
const char GESTURE_UP[] PROGMEM = "Up";
|
||||
const char GESTURE_DOWN[] PROGMEM = "Down";
|
||||
const char GESTURE_LEFT[] PROGMEM = "Left";
|
||||
const char GESTURE_RIGHT[] PROGMEM = "Right";
|
||||
const char GESTURE_LONG[] PROGMEM = "Long";
|
||||
const char GESTURE_NONE[] PROGMEM = "None";
|
||||
|
||||
enum {
|
||||
DIR_NONE,
|
||||
DIR_LEFT,
|
||||
|
@ -249,12 +272,14 @@ enum {
|
|||
};
|
||||
|
||||
/* State definitions*/
|
||||
/*
|
||||
enum {
|
||||
APDS9960_NA_STATE,
|
||||
APDS9960_NEAR_STATE,
|
||||
APDS9960_FAR_STATE,
|
||||
APDS9960_ALL_STATE
|
||||
};
|
||||
*/
|
||||
|
||||
/* Container for gesture data */
|
||||
typedef struct gesture_data_type {
|
||||
|
@ -268,8 +293,7 @@ typedef struct gesture_data_type {
|
|||
uint8_t out_threshold;
|
||||
} gesture_data_t;
|
||||
|
||||
typedef struct gesture_type
|
||||
{
|
||||
typedef struct gesture_type {
|
||||
int16_t ud_delta_ = 0;
|
||||
int16_t lr_delta_ = 0;
|
||||
int16_t ud_count_ = 0;
|
||||
|
@ -278,6 +302,8 @@ typedef struct gesture_type
|
|||
int16_t motion_ = DIR_NONE;
|
||||
} gesture_t;
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
typedef struct color_data_type {
|
||||
uint16_t a; // measured ambient
|
||||
uint16_t r; // Red
|
||||
|
@ -289,8 +315,11 @@ typedef struct color_data_type {
|
|||
} color_data_t;
|
||||
|
||||
/*Members*/
|
||||
#ifdef APDS9960_GESTURE
|
||||
gesture_data_t gesture_data;
|
||||
gesture_t gesture;
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
color_data_t color_data;
|
||||
|
||||
volatile uint8_t recovery_loop_counter = 0; // count number of stateloops to switch the sensor off, if needed
|
||||
|
@ -721,6 +750,8 @@ void setProxPhotoMask(uint8_t mask) {
|
|||
I2cWrite8(APDS9960_I2C_ADDR, APDS9960_CONFIG3, val);
|
||||
}
|
||||
|
||||
#ifdef APDS9960_GESTURE
|
||||
|
||||
/**
|
||||
* @brief Gets the entry proximity threshold for gesture sensing
|
||||
*
|
||||
|
@ -924,6 +955,8 @@ void setGestureWaitTime(uint8_t time) {
|
|||
I2cWrite8(APDS9960_I2C_ADDR, APDS9960_GCONF2, val);
|
||||
}
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
/**
|
||||
* @brief Gets the low threshold for ambient light interrupts
|
||||
*
|
||||
|
@ -1238,6 +1271,8 @@ bool APDS9960_init(void) {
|
|||
I2cWrite8(APDS9960_I2C_ADDR, APDS9960_CONFIG3, DEFAULT_CONFIG3);
|
||||
|
||||
/* Set default values for gesture sense registers */
|
||||
#ifdef APDS9960_GESTURE
|
||||
|
||||
setGestureEnterThresh(DEFAULT_GPENTH);
|
||||
setGestureExitThresh(DEFAULT_GEXTH);
|
||||
|
||||
|
@ -1255,6 +1290,8 @@ bool APDS9960_init(void) {
|
|||
I2cWrite8(APDS9960_I2C_ADDR, APDS9960_GCONF3, DEFAULT_GCONF3);
|
||||
|
||||
setGestureIntEnable(DEFAULT_GIEN);
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
disablePower(); // go to sleep
|
||||
|
||||
|
@ -1357,6 +1394,7 @@ void disableProximitySensor(void) {
|
|||
setMode(PROXIMITY, OFF);
|
||||
}
|
||||
|
||||
#ifdef APDS9960_GESTURE
|
||||
/**
|
||||
* @brief Starts the gesture recognition engine on the APDS-9960
|
||||
*
|
||||
|
@ -1451,7 +1489,7 @@ int16_t readGesture(void) {
|
|||
fifo_level = I2cRead8(APDS9960_I2C_ADDR, APDS9960_GFLVL);
|
||||
|
||||
#ifdef USE_DEBUG_DRIVER
|
||||
AddLog_P2(LOG_LEVEL_DEBUG, PSTR("DRV: FIFO Level : %d"), fifo_level);
|
||||
AddLog_P2(LOG_LEVEL_DEBUG, PSTR("DRV: FIFO Level : %d"), fifo_level);
|
||||
#endif // USE_DEBUG_DRIVER
|
||||
|
||||
/* If there's stuff in the FIFO, read it into our data block */
|
||||
|
@ -1504,6 +1542,8 @@ int16_t readGesture(void) {
|
|||
}
|
||||
}
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
/**
|
||||
* Turn the APDS-9960 on
|
||||
*
|
||||
|
@ -1540,6 +1580,8 @@ void readAllColorAndProximityData(void) {
|
|||
* High-level gesture controls
|
||||
\******************************************************************************/
|
||||
|
||||
#ifdef APDS9960_GESTURE
|
||||
|
||||
/**
|
||||
* @brief Resets all the parameters in the gesture data member
|
||||
*/
|
||||
|
@ -1705,28 +1747,28 @@ void handleGesture(void) {
|
|||
if (isGestureAvailable()) {
|
||||
switch (readGesture()) {
|
||||
case DIR_UP:
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("UP"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("Up"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_UP);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_UP);
|
||||
break;
|
||||
case DIR_DOWN:
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("DOWN"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("Down"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_DOWN);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_DOWN);
|
||||
break;
|
||||
case DIR_LEFT:
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("LEFT"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("Left"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_LEFT);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_LEFT);
|
||||
break;
|
||||
case DIR_RIGHT:
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("RIGHT"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("Right"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_RIGHT);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_RIGHT);
|
||||
break;
|
||||
default:
|
||||
if (APDS9960_overload) {
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("LONG"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("Long"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_LONG);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_LONG);
|
||||
} else {
|
||||
AddLog_P(LOG_LEVEL_DEBUG, PSTR("NONE"));
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), PSTR("None"));
|
||||
AddLog_P(LOG_LEVEL_DEBUG, GESTURE_NONE);
|
||||
snprintf_P(currentGesture, sizeof(currentGesture), GESTURE_NONE);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
@ -1734,6 +1776,8 @@ void handleGesture(void) {
|
|||
}
|
||||
}
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
void APDS9960_adjustATime(void) { // not really used atm
|
||||
// readAllColorAndProximityData();
|
||||
I2cValidRead16LE(&color_data.a, APDS9960_I2C_ADDR, APDS9960_CDATAL);
|
||||
|
@ -1766,6 +1810,8 @@ void APDS9960_adjustATime(void) { // not really used atm
|
|||
delay(20);
|
||||
}
|
||||
|
||||
#ifdef APDS9960_GESTURE
|
||||
|
||||
void APDS9960_loop(void) {
|
||||
if (recovery_loop_counter > 0) {
|
||||
recovery_loop_counter -= 1;
|
||||
|
@ -1794,6 +1840,8 @@ void APDS9960_loop(void) {
|
|||
}
|
||||
}
|
||||
|
||||
#endif // APDS9960_GESTURE
|
||||
|
||||
void APDS9960_detect(void) {
|
||||
if (APDS9960type || I2cActive(APDS9960_I2C_ADDR)) { return; }
|
||||
|
||||
|
@ -1809,7 +1857,9 @@ void APDS9960_detect(void) {
|
|||
I2cSetActiveFound(APDS9960_I2C_ADDR, APDS9960_TAG);
|
||||
|
||||
enableProximitySensor();
|
||||
#ifdef APDS9960_GESTURE
|
||||
enableGestureSensor();
|
||||
#endif // APDS9960_GESTURE
|
||||
} else {
|
||||
APDS9960type = 0;
|
||||
}
|
||||
|
@ -1828,41 +1878,48 @@ void APDS9960_show(bool json) {
|
|||
if (!APDS9960type) { return; }
|
||||
|
||||
if (!gesture_mode && !APDS9960_overload) {
|
||||
char red_chr[10];
|
||||
char green_chr[10];
|
||||
char blue_chr[10];
|
||||
char ambient_chr[10];
|
||||
char cct_chr[10];
|
||||
char prox_chr[10];
|
||||
uint16_t ambient;
|
||||
|
||||
readAllColorAndProximityData();
|
||||
|
||||
sprintf(ambient_chr, "%u", color_data.a/4);
|
||||
sprintf(red_chr, "%u", color_data.r);
|
||||
sprintf(green_chr, "%u", color_data.g);
|
||||
sprintf(blue_chr, "%u", color_data.b);
|
||||
sprintf(prox_chr, "%u", color_data.p);
|
||||
ambient = color_data.a/4;
|
||||
|
||||
/* disableLightSensor();
|
||||
I2cWrite8(APDS9960_I2C_ADDR, APDS9960_ATIME, DEFAULT_ATIME); // reset to default
|
||||
enableLightSensor();*/
|
||||
|
||||
calculateColorTemperature(); // and calculate Lux
|
||||
sprintf(cct_chr, "%u", color_data.cct);
|
||||
|
||||
if (json) {
|
||||
ResponseAppend_P(PSTR(",\"%s\":{\"Red\":%s,\"Green\":%s,\"Blue\":%s,\"Ambient\":%s,\"CCT\":%s,\"Proximity\":%s}"),
|
||||
APDS9960_TAG, red_chr, green_chr, blue_chr, ambient_chr, cct_chr, prox_chr);
|
||||
ResponseAppend_P(PSTR(",\"%s\":{\"Red\":%u,\"Green\":%u,\"Blue\":%u,\"Ambient\":%u,\"CCT\":%u,\"Proximity\":%u}"),
|
||||
APDS9960_TAG,
|
||||
color_data.r,
|
||||
color_data.g,
|
||||
color_data.b,
|
||||
ambient,
|
||||
color_data.cct,
|
||||
color_data.p);
|
||||
#ifdef USE_WEBSERVER
|
||||
} else {
|
||||
WSContentSend_PD(HTTP_APDS9960_SNS, red_chr, green_chr, blue_chr, ambient_chr, cct_chr, prox_chr);
|
||||
WSContentSend_PD(HTTP_SNS_COLOR_RED, APDS9960_TAG, color_data.r);
|
||||
WSContentSend_PD(HTTP_SNS_COLOR_GREEN, APDS9960_TAG, color_data.g);
|
||||
WSContentSend_PD(HTTP_SNS_COLOR_BLUE, APDS9960_TAG, color_data.b);
|
||||
WSContentSend_PD(HTTP_SNS_ILLUMINANCE, APDS9960_TAG, ambient);
|
||||
WSContentSend_PD(HTTP_SNS_CCT, APDS9960_TAG, color_data.cct);
|
||||
WSContentSend_PD(HTTP_SNS_PROXIMITY, APDS9960_TAG, color_data.p);
|
||||
#endif // USE_WEBSERVER
|
||||
}
|
||||
#ifdef APDS9960_GESTURE
|
||||
} else {
|
||||
if (json && (currentGesture[0] != '\0' )) {
|
||||
ResponseAppend_P(PSTR(",\"%s\":{\"%s\":1}"), APDS9960_TAG, currentGesture);
|
||||
currentGesture[0] = '\0';
|
||||
if (currentGesture[0] != '\0') {
|
||||
if (json) {
|
||||
ResponseAppend_P(PSTR(",\"%s\":{\"%s\":1}"), APDS9960_TAG, currentGesture);
|
||||
#ifdef USE_WEBSERVER
|
||||
} else {
|
||||
WSContentSend_PD(HTTP_SNS_GESTURE, APDS9960_TAG, currentGesture);
|
||||
#endif // USE_WEBSERVER
|
||||
currentGesture[0] = '\0';
|
||||
}
|
||||
}
|
||||
#endif // APDS9960_GESTURE
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1882,11 +1939,14 @@ bool APDS9960CommandSensor(void) {
|
|||
|
||||
switch (XdrvMailbox.payload) {
|
||||
case 0: // Off
|
||||
#ifdef APDS9960_GESTURE
|
||||
disableGestureSensor();
|
||||
#endif // APDS9960_GESTURE
|
||||
gesture_mode = 0;
|
||||
enableLightSensor();
|
||||
APDS9960_overload = false; // prevent unwanted re-enabling
|
||||
break;
|
||||
#ifdef APDS9960_GESTURE
|
||||
case 1: // On with default gain of 4x
|
||||
if (APDS9960type) {
|
||||
setGestureGain(DEFAULT_GGAIN);
|
||||
|
@ -1905,6 +1965,7 @@ bool APDS9960CommandSensor(void) {
|
|||
gesture_mode = 1;
|
||||
}
|
||||
break;
|
||||
#endif // APDS9960_GESTURE
|
||||
default:
|
||||
int temp_aTime = (uint8_t)XdrvMailbox.payload;
|
||||
if (temp_aTime > 2 && temp_aTime < 256) {
|
||||
|
@ -1933,9 +1994,11 @@ bool Xsns27(uint8_t function) {
|
|||
APDS9960_detect();
|
||||
} else if (APDS9960type) {
|
||||
switch (function) {
|
||||
#ifdef APDS9960_GESTURE
|
||||
case FUNC_EVERY_50_MSECOND:
|
||||
APDS9960_loop();
|
||||
break;
|
||||
#endif // APDS9960_GESTURE
|
||||
case FUNC_COMMAND_SENSOR:
|
||||
if (XSNS_27 == XdrvMailbox.index) {
|
||||
result = APDS9960CommandSensor();
|
||||
|
|
|
@ -51,31 +51,7 @@
|
|||
#define INDOORS 0x24
|
||||
#define OUTDOORS 0x1C
|
||||
|
||||
// Translation
|
||||
// http
|
||||
#define D_AS3935_GAIN "gain:"
|
||||
#define D_AS3935_ENERGY "energy:"
|
||||
#define D_AS3935_DISTANCE "distance:"
|
||||
#define D_AS3935_DISTURBER "disturber:"
|
||||
#define D_AS3935_VRMS "µVrms:"
|
||||
// http Message
|
||||
#define D_AS3935_APRX "aprx.:"
|
||||
#define D_AS3935_AWAY "away"
|
||||
#define D_AS3935_LIGHT "lightning"
|
||||
#define D_AS3935_OUT "lightning out of range"
|
||||
#define D_AS3935_NOT "distance not determined"
|
||||
#define D_AS3935_ABOVE "lightning overhead"
|
||||
#define D_AS3935_NOISE "noise detected"
|
||||
#define D_AS3935_DISTDET "disturber detected"
|
||||
#define D_AS3935_INTNOEV "Interrupt with no Event!"
|
||||
#define D_AS3935_NOMESS "listening..."
|
||||
// CMD Status
|
||||
#define D_AS3935_ON "On"
|
||||
#define D_AS3935_OFF "Off"
|
||||
#define D_AS3935_INDOORS "Indoors"
|
||||
#define D_AS3935_OUTDOORS "Outdoors"
|
||||
#define D_AS3935_CAL_FAIL "calibration failed"
|
||||
#define D_AS3935_CAL_OK "calibration set to:"
|
||||
|
||||
|
||||
// Global
|
||||
const char HTTP_SNS_UNIT_KILOMETER[] PROGMEM = D_UNIT_KILOMETER;
|
||||
|
|
Loading…
Reference in New Issue