[enocean] fix typos

Rename constants name from *RESPONE to *RESPONSE

Signed-off-by: Zhivka Dimova <zhivka.dimova@myforest.net>
This commit is contained in:
Zhivka Dimova 2024-09-19 15:07:15 +02:00
parent 5c6b74b960
commit 08099f8de4
No known key found for this signature in database
GPG Key ID: C773EB39CFE5BB30
2 changed files with 10 additions and 9 deletions

View File

@ -48,9 +48,9 @@ public abstract class D2_01 extends _VLDMessage {
protected static final byte CMD_ACTUATOR_SET_STATUS = 0x01;
protected static final byte CMD_ACTUATOR_STATUS_QUERY = 0x03;
protected static final byte CMD_ACTUATOR_STATUS_RESPONE = 0x04;
protected static final byte CMD_ACTUATOR_STATUS_RESPONSE = 0x04;
protected static final byte CMD_ACTUATOR_MEASUREMENT_QUERY = 0x06;
protected static final byte CMD_ACTUATOR_MEASUREMENT_RESPONE = 0x07;
protected static final byte CMD_ACTUATOR_MEASUREMENT_RESPONSE = 0x07;
protected static final byte ALL_CHANNELS_MASK = 0x1e;
protected static final byte CHANNEL_A_MASK = 0x00;
@ -85,7 +85,7 @@ public abstract class D2_01 extends _VLDMessage {
}
protected State getSwitchingData() {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONE) {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONSE) {
return OnOffType.from((bytes[bytes.length - 1] & OUTPUT_VALUE_MASK) != STATUS_SWITCHING_OFF);
}
@ -97,7 +97,8 @@ public abstract class D2_01 extends _VLDMessage {
}
protected State getSwitchingData(byte channel) {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONE && (getChannel() == channel || getChannel() == ALL_CHANNELS_MASK)) {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONSE
&& (getChannel() == channel || getChannel() == ALL_CHANNELS_MASK)) {
return OnOffType.from((bytes[bytes.length - 1] & OUTPUT_VALUE_MASK) != STATUS_SWITCHING_OFF);
}
@ -126,7 +127,7 @@ public abstract class D2_01 extends _VLDMessage {
}
protected State getDimmingData() {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONE) {
if (getCMD() == CMD_ACTUATOR_STATUS_RESPONSE) {
return new PercentType((bytes[bytes.length - 1] & OUTPUT_VALUE_MASK));
}
@ -142,7 +143,7 @@ public abstract class D2_01 extends _VLDMessage {
}
protected State getEnergyMeasurementData() {
if (getCMD() == CMD_ACTUATOR_MEASUREMENT_RESPONE) {
if (getCMD() == CMD_ACTUATOR_MEASUREMENT_RESPONSE) {
float factor = 1;
switch (bytes[1] >>> 5) {
@ -169,7 +170,7 @@ public abstract class D2_01 extends _VLDMessage {
}
protected State getPowerMeasurementData() {
if (getCMD() == CMD_ACTUATOR_MEASUREMENT_RESPONE) {
if (getCMD() == CMD_ACTUATOR_MEASUREMENT_RESPONSE) {
float factor = 1;
switch (bytes[1] >>> 5) {

View File

@ -44,7 +44,7 @@ public class D2_05_00 extends _VLDMessage {
protected static final byte CMD_ACTUATOR_SET_POSITION = 0x01;
protected static final byte CMD_ACTUATOR_STOP = 0x02;
protected static final byte CMD_ACTUATOR_POSITION_QUERY = 0x03;
protected static final byte CMD_ACTUATOR_POSITION_RESPONE = 0x04;
protected static final byte CMD_ACTUATOR_POSITION_RESPONSE = 0x04;
protected static final byte ALL_CHANNELS_MASK = 0x1e;
protected static final byte CHANNEL_A_MASK = 0x00;
@ -86,7 +86,7 @@ public class D2_05_00 extends _VLDMessage {
}
protected State getPositionData() {
if (getCMD() == CMD_ACTUATOR_POSITION_RESPONE) {
if (getCMD() == CMD_ACTUATOR_POSITION_RESPONSE) {
int position = bytes[0] & 0x7f;
if (position != 127) {
return new PercentType(position);