]> git.basschouten.com Git - openhab-addons.git/blob
5248a1ae9609419fd3f9ab3db3afe3d98500f4c9
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2023 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
7  * This program and the accompanying materials are made available under the
8  * terms of the Eclipse Public License 2.0 which is available at
9  * http://www.eclipse.org/legal/epl-2.0
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.mystrom.internal;
14
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.core.thing.ThingTypeUID;
17
18 /**
19  * The {@link MyStromBindingConstants} class defines common constants, which are
20  * used across the whole binding.
21  *
22  * @author Paul Frank - Initial contribution
23  * @author Frederic Chastagnol - Add constants for myStrom bulb support
24  */
25 @NonNullByDefault
26 public class MyStromBindingConstants {
27
28     public static final int DEFAULT_REFRESH_RATE_SECONDS = 10;
29     public static final int DEFAULT_BACKOFF_TIME_SECONDS = 10;
30
31     private static final String BINDING_ID = "mystrom";
32
33     // List of all Thing Type UIDs
34     public static final ThingTypeUID THING_TYPE_PLUG = new ThingTypeUID(BINDING_ID, "mystromplug");
35     public static final ThingTypeUID THING_TYPE_BULB = new ThingTypeUID(BINDING_ID, "mystrombulb");
36     public static final ThingTypeUID THING_TYPE_PIR = new ThingTypeUID(BINDING_ID, "mystrompir");
37
38     // List of all Channel ids
39     public static final String CHANNEL_SWITCH = "switch";
40     public static final String CHANNEL_POWER = "power";
41     public static final String CHANNEL_ENERGY_CONSUMED_SINCE_LAST_CALL = "energy-consumed-since-last-call";
42     public static final String CHANNEL_TEMPERATURE = "temperature";
43     public static final String CHANNEL_COLOR = "color";
44     public static final String CHANNEL_RAMP = "ramp";
45     public static final String CHANNEL_MODE = "mode";
46     public static final String CHANNEL_COLOR_TEMPERATURE = "colorTemperature";
47     public static final String CHANNEL_BRIGHTNESS = "brightness";
48     public static final String CHANNEL_MOTION = "motion";
49     public static final String CHANNEL_LIGHT = "light";
50
51     // Config
52     public static final String CONFIG_MAC = "mac";
53
54     // List of all Properties
55     public static final String PROPERTY_MAC = "mac";
56     public static final String PROPERTY_VERSION = "version";
57     public static final String PROPERTY_TYPE = "type";
58     public static final String PROPERTY_SSID = "ssid";
59     public static final String PROPERTY_IP = "ip";
60     public static final String PROPERTY_MASK = "mask";
61     public static final String PROPERTY_GW = "gw";
62     public static final String PROPERTY_DNS = "dns";
63     public static final String PROPERTY_STATIC = "static";
64     public static final String PROPERTY_CONNECTED = "connected";
65     public static final String PROPERTY_LAST_REFRESH = "lastRefresh";
66
67     // myStrom Bulb modes
68     public static final String RGB = "rgb";
69     public static final String HSV = "hsv";
70     public static final String MONO = "mono";
71 }