File tree 3 files changed +10
-1
lines changed 3 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -65,7 +65,11 @@ void DeRestPluginPrivate::permitJoinTimerFired()
65
65
66
66
if ((gwPermitJoinDuration > 0 ) && (gwPermitJoinDuration < 255 ))
67
67
{
68
- permitJoinFlag = true ;
68
+ if (!permitJoinFlag)
69
+ {
70
+ permitJoinFlag = true ;
71
+ enqueueEvent (Event (RConfig, REventPermitjoinEnabled, 0 ));
72
+ }
69
73
gwPermitJoinDuration--;
70
74
71
75
if ((gwPermitJoinDuration % 10 ) == 0 )
@@ -101,6 +105,7 @@ void DeRestPluginPrivate::permitJoinTimerFired()
101
105
if (gwPermitJoinDuration == 0 && permitJoinFlag)
102
106
{
103
107
permitJoinFlag = false ;
108
+ enqueueEvent (Event (RConfig, REventPermitjoinDisabled, 0 ));
104
109
}
105
110
106
111
if (!isInNetwork ())
Original file line number Diff line number Diff line change @@ -26,6 +26,8 @@ const char *REventBindingTable = "event/binding.table";
26
26
const char *REventBindingTick = " event/binding.tick" ;
27
27
const char *REventDeleted = " event/deleted" ;
28
28
const char *REventDeviceAnnounce = " event/device.anounce" ;
29
+ const char *REventPermitjoinEnabled = " event/permit.join.enabled" ;
30
+ const char *REventPermitjoinDisabled = " event/permit.join.disabled" ;
29
31
const char *REventPoll = " event/poll" ;
30
32
const char *REventValidGroup = " event/validgroup" ;
31
33
const char *REventCheckGroupAnyOn = " event/checkgroupanyon" ;
Original file line number Diff line number Diff line change @@ -43,6 +43,8 @@ extern const char *REventBindingTable;
43
43
extern const char *REventBindingTick;
44
44
extern const char *REventDeleted;
45
45
extern const char *REventDeviceAnnounce;
46
+ extern const char *REventPermitjoinEnabled;
47
+ extern const char *REventPermitjoinDisabled;
46
48
extern const char *REventPoll;
47
49
extern const char *REventValidGroup;
48
50
extern const char *REventCheckGroupAnyOn;
You can’t perform that action at this time.
0 commit comments