public static final String GENERIC_NO = "No";
public static final int CHARGER_OP_STATE_WAITING = 2;
public static final int CHARGER_OP_STATE_CHARGING = 3;
- public static final int CHARGER_DYNAMIC_CURRENT_PAUSE = 0;
+ public static final double CHARGER_DYNAMIC_CURRENT_PAUSE = 0;
public static final int CHARGER_REASON_FOR_NO_CURRENT_PAUSED = 52;
public static final String THING_CONFIG_ID = "id";
private void updateChargerStartStop(Map<Channel, State> result, String value, JsonObject rawData) {
Channel channel = channelProvider.getChannel(CHANNEL_GROUP_CHARGER_COMMANDS, CHANNEL_CHARGER_START_STOP);
if (channel != null) {
- int val = Integer.valueOf(value);
+ int val = Integer.parseInt(value);
// state >= 3 will mean charging, ready to charge or charging finished
boolean charging = val >= CHARGER_OP_STATE_CHARGING;
private void updateChargerPauseResume(Map<Channel, State> result, String value) {
Channel channel = channelProvider.getChannel(CHANNEL_GROUP_CHARGER_COMMANDS, CHANNEL_CHARGER_PAUSE_RESUME);
if (channel != null) {
- int val = Integer.valueOf(value);
+ double val = Double.parseDouble(value);
// value == 0 will mean paused
boolean paused = val == CHARGER_DYNAMIC_CURRENT_PAUSE;