Skip to content

Commit

Permalink
Align naming in Thermostat cluster XML with the spec. (project-chip#2…
Browse files Browse the repository at this point in the history
…4622)

* Align naming in Thermostat cluster XML with the spec.

* Regenerate generated code.
  • Loading branch information
bzbarsky-apple authored Jan 24, 2023
1 parent ecdcbc3 commit 7299a2a
Show file tree
Hide file tree
Showing 19 changed files with 261 additions and 185 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2665,9 +2665,9 @@ server cluster PumpConfigurationAndControl = 512 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -2690,9 +2690,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -2703,21 +2705,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

struct ThermostatScheduleTransition {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ void ProcessThermostatUnicastBindingCommand(BindingCommandData * data, const Emb
switch (data->commandId)
{
case Clusters::Thermostat::Commands::SetpointRaiseLower::Id:
setpointRaiseLowerCommand.mode = static_cast<EmberAfSetpointAdjustMode>(data->args[0]);
setpointRaiseLowerCommand.mode = static_cast<Clusters::Thermostat::SetpointAdjustMode>(data->args[0]);
setpointRaiseLowerCommand.amount = static_cast<int8_t>(data->args[1]);
Controller::InvokeCommandRequest(peer_device->GetExchangeManager(), peer_device->GetSecureSession().Value(), binding.remote,
setpointRaiseLowerCommand, onSuccess, onFailure);
Expand All @@ -171,7 +171,7 @@ void ProcessThermostatGroupBindingCommand(BindingCommandData * data, const Ember
switch (data->commandId)
{
case Clusters::Thermostat::Commands::SetpointRaiseLower::Id:
setpointRaiseLowerCommand.mode = static_cast<EmberAfSetpointAdjustMode>(data->args[0]);
setpointRaiseLowerCommand.mode = static_cast<Clusters::Thermostat::SetpointAdjustMode>(data->args[0]);
setpointRaiseLowerCommand.amount = static_cast<int8_t>(data->args[1]);
Controller::InvokeGroupCommandRequest(&exchangeMgr, binding.fabricIndex, binding.groupId, setpointRaiseLowerCommand);
break;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2262,9 +2262,9 @@ server cluster PumpConfigurationAndControl = 512 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -2287,9 +2287,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -2300,21 +2302,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

struct ThermostatScheduleTransition {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1171,9 +1171,9 @@ server cluster FixedLabel = 64 {

client cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -1196,9 +1196,11 @@ client cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -1209,21 +1211,21 @@ client cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

readonly attribute nullable int16s localTemperature = 0;
Expand Down
20 changes: 11 additions & 9 deletions examples/chef/devices/rootnode_thermostat_bm3fb8dhYi.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1029,9 +1029,9 @@ server cluster FixedLabel = 64 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -1054,9 +1054,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -1067,21 +1069,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

readonly attribute nullable int16s localTemperature = 0;
Expand Down
20 changes: 11 additions & 9 deletions examples/placeholder/linux/apps/app1/config.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1862,9 +1862,9 @@ server cluster PumpConfigurationAndControl = 512 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -1887,9 +1887,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -1900,21 +1902,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

struct ThermostatScheduleTransition {
Expand Down
20 changes: 11 additions & 9 deletions examples/placeholder/linux/apps/app2/config.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1839,9 +1839,9 @@ server cluster PumpConfigurationAndControl = 512 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -1864,9 +1864,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -1877,21 +1879,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

struct ThermostatScheduleTransition {
Expand Down
20 changes: 11 additions & 9 deletions examples/thermostat/thermostat-common/thermostat.matter
Original file line number Diff line number Diff line change
Expand Up @@ -1394,9 +1394,9 @@ server cluster UserLabel = 65 {

server cluster Thermostat = 513 {
enum SetpointAdjustMode : ENUM8 {
kHeatSetpoint = 0;
kCoolSetpoint = 1;
kHeatAndCoolSetpoints = 2;
kHeat = 0;
kCool = 1;
kBoth = 2;
}

enum ThermostatControlSequence : ENUM8 {
Expand All @@ -1419,9 +1419,11 @@ server cluster Thermostat = 513 {
kAuto = 1;
kCool = 3;
kHeat = 4;
kEmergencyHeating = 5;
kEmergencyHeat = 5;
kPrecooling = 6;
kFanOnly = 7;
kDry = 8;
kSleep = 9;
}

bitmap DayOfWeek : BITMAP8 {
Expand All @@ -1432,21 +1434,21 @@ server cluster Thermostat = 513 {
kThursday = 0x10;
kFriday = 0x20;
kSaturday = 0x40;
kAwayOrVacation = 0x80;
kAway = 0x80;
}

bitmap ModeForSequence : BITMAP8 {
kHeatSetpointFieldPresent = 0x1;
kCoolSetpointFieldPresent = 0x2;
kHeatSetpointPresent = 0x1;
kCoolSetpointPresent = 0x2;
}

bitmap ThermostatFeature : BITMAP32 {
kHeating = 0x1;
kCooling = 0x2;
kOccupancy = 0x4;
kSchedule = 0x8;
kScheduleConfiguration = 0x8;
kSetback = 0x10;
kAutomode = 0x20;
kAutoMode = 0x20;
}

struct ThermostatScheduleTransition {
Expand Down
Loading

0 comments on commit 7299a2a

Please sign in to comment.