mirror of
https://github.com/openhab/openhab-addons.git
synced 2025-01-10 15:11:59 +01:00
New PR candidate
Java doc and possible mdns discovery. Signed-off-by: Bob Eckhoff <katmandodo@yahoo.com>
This commit is contained in:
parent
2a73de9d06
commit
32c2665811
@ -23,28 +23,64 @@ import org.eclipse.jdt.annotation.NonNullByDefault;
|
|||||||
@NonNullByDefault
|
@NonNullByDefault
|
||||||
public class MideaACConfiguration {
|
public class MideaACConfiguration {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* IP Address
|
||||||
|
*/
|
||||||
public String ipAddress = "";
|
public String ipAddress = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* IP Port
|
||||||
|
*/
|
||||||
public int ipPort = 6444;
|
public int ipPort = 6444;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Device ID
|
||||||
|
*/
|
||||||
public String deviceId = "0";
|
public String deviceId = "0";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cloud Account email
|
||||||
|
*/
|
||||||
public String email = "";
|
public String email = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cloud Account Password
|
||||||
|
*/
|
||||||
public String password = "";
|
public String password = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Cloud Provider
|
||||||
|
*/
|
||||||
public String cloud = "";
|
public String cloud = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Token
|
||||||
|
*/
|
||||||
public String token = "";
|
public String token = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Key
|
||||||
|
*/
|
||||||
public String key = "";
|
public String key = "";
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Poll Frequency
|
||||||
|
*/
|
||||||
public int pollingTime = 60;
|
public int pollingTime = 60;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Socket Timeout
|
||||||
|
*/
|
||||||
public int timeout = 4;
|
public int timeout = 4;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Prompt tone from indoor unit with a Set Command
|
||||||
|
*/
|
||||||
public boolean promptTone = false;
|
public boolean promptTone = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* AC Version
|
||||||
|
*/
|
||||||
public int version = 0;
|
public int version = 0;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -140,6 +140,7 @@ public class ConnectionManager {
|
|||||||
}
|
}
|
||||||
retry = false;
|
retry = false;
|
||||||
try {
|
try {
|
||||||
|
socket.close();
|
||||||
socket = new Socket();
|
socket = new Socket();
|
||||||
socket.setSoTimeout(timeout * 1000);
|
socket.setSoTimeout(timeout * 1000);
|
||||||
socket.connect(new InetSocketAddress(ipAddress, ipPort), timeout * 1000);
|
socket.connect(new InetSocketAddress(ipAddress, ipPort), timeout * 1000);
|
||||||
|
@ -21,6 +21,10 @@ import org.eclipse.jdt.annotation.NonNullByDefault;
|
|||||||
*/
|
*/
|
||||||
@NonNullByDefault
|
@NonNullByDefault
|
||||||
public interface Callback {
|
public interface Callback {
|
||||||
|
/**
|
||||||
|
* Updates channels with the response
|
||||||
|
*
|
||||||
|
* @param response Byte response from the device used to update channels
|
||||||
|
*/
|
||||||
void updateChannels(Response response);
|
void updateChannels(Response response);
|
||||||
}
|
}
|
||||||
|
@ -7,5 +7,15 @@
|
|||||||
<name>MideaAC Binding</name>
|
<name>MideaAC Binding</name>
|
||||||
<description>This is the binding for MideaAC.</description>
|
<description>This is the binding for MideaAC.</description>
|
||||||
<connection>local</connection>
|
<connection>local</connection>
|
||||||
|
<discovery-methods>
|
||||||
|
<discovery-method>
|
||||||
|
<service-type>mdns</service-type>
|
||||||
|
<discovery-parameters>
|
||||||
|
<discovery-parameter>
|
||||||
|
<name>mdnsServiceType</name>
|
||||||
|
<value>_mideaair._tcp.local.</value>
|
||||||
|
</discovery-parameter>
|
||||||
|
</discovery-parameters>
|
||||||
|
</discovery-method>
|
||||||
|
</discovery-methods>
|
||||||
</addon:addon>
|
</addon:addon>
|
||||||
|
Loading…
Reference in New Issue
Block a user