You can transfer a few dollars to a special account of the National Bank of Ukraine to help the Armed Forces of Ukraine
Bank: National Bank of Ukraine
MFO 300001
Account No. UA843000010000000047330992708
EDRPOU Code 00032106
Payee: National Bank of Ukraine
BENEFICIARY: National Bank of Ukraine
BENEFICIARY BIC: NBUA UA UX
BENEFICIARY ADDRESS: 9 Instytutska St, Kyiv, 01601, Ukraine
ACCOUNT NUMBER: 804790258
BENEFICIARY BANK NAME: JP MORGAN CHASE BANK, New York
BENEFICIARY BANK BIC: CHASUS33
ABA 0210 0002 1
BENEFICIARY BANK ADDRESS: 383 Madison Avenue, New York, NY 10017, USA
PURPOSE OF PAYMENT: for ac 47330992708
BENEFICIARY: National Bank of Ukraine
IBAN DE05504000005040040066
PURPOSE OF PAYMENT: for ac 47330992708
BENEFICIARY BANK NAME: DEUTSCHE BUNDESBANK, Frankfurt
BENEFICIARY BANK BIC: MARKDEFF
BENEFICIARY BANK ADDRESS: Wilhelm-Epstein-Strasse 14, 60431 Frankfurt Am Main, Germany
BENEFICIARY/RECIPIENT NAME: National Bank of Ukraine
ACCOUNT NUMBER: 80033041
IBAN GB52CHAS60924280033041
BENEFICIARY ADDRESS: 9 Instytutska St, Kyiv, 01601, Ukraine
BENEFICIARY BANK NAME: JP MORGAN CHASE BANK NA, London
BENEFICIARY BANK BIC: CHASGB2L
SORT CODE: 60-92-42
BENEFICIARY BANK ADDRESS: 125 London Wall, London EC2Y 5AJ, UK
PURPOSE OF PAYMENT: for ac 47330992708
Device works as solid state relay with 1 AC 220V input and 3 AC 220V outputs
Device can works in 2 mode
- Standalone mode
- Slave mode
Device can be configured from:
- web user interface (through API)
- android app
After startup device start SoftAP with special name witch contain important information for Android AP
KVR_[AP KEY]
KVR_AABBCCDDEEFF
Device look for wifi settings in /cfg/wifi.json after startup. Every time you setup network connection device store given ssid & key in wifi.json file. History length of stored wifi ssid & key pair is 3. When device loose connection to current wifi station it start to loock for next available ssid. if one available - device connects using ssid & key.
{
"mode": "server",//start soft AP (can be disable after first setup) (can be: server or client)
"ssid": "KVR_",//wifi softAP name prefix
"key": "",//key for wifi soft AP. If empty - MAC address is used to acess to AP
"ip": "192.168.4.1",//ip address of soft AP
"mask": "255.255.255.0",//network mask
"wifi": [//saved wifi credentionals of known networks
{
"ssid": "network1",
"key": "12345678"
},
{
"ssid": "network2",
"key": "123456789"
},
{
"ssid": "network3",
"key": "987654321"
}
]
}
Device have no RTC battary, so NTP time synchronization is used. Connection parameters of NTP server and time zone configuration stored in ntp.json file
{
"port": "2390",//NTP port
"server": "europe.pool.ntp.org",//NTP server name/ip
"standart-time": "Last, Sun, Oct, 4, +2",//Time offset from greenwich winter
"summer-time": "Last, Sun, Mar, 3, +3"//Time offset from greenwich summer
}
MQTT server connection setting stored in /cfg/mqtt.json
{
"server": "192.168.5.100",//ip address of mqtt broker
"port": "1883",//mqtt broker port
"user": "",//mqtt user
"password": ""//mqtt password
}
The device have 3 high current outputs (out1, out2, out3) and 1 buldin led output. Buildin led is used only for testing device functionaluty at first setup. It have no effect except blinkin. Each output linked to 3 mqtt topic. Name of then topiks contains from MAC address of device and output name.
- state topic "/switches/AABBCCDDEEFF/name" Evry time the state of output is changed - device publish new state ("ON"/"OFF") to payload of this topic
- set topic "/switches/AABBCCDDEEFF/name/set" Device subscribe for this topic and set the state of output to on when recive "ON" payload else set state to off
- available topic "/switches/AABBCCDDEEFF/name/available" Available topic is used to signalize to automation system that output gose online. Evry time device is connected to mqtt broker - it publish "online" payload data
AABBCCDDEEFF - mac address of device (upper case, no separator character) name - name of output
API authorization
/api/auth?user=user&password=password&json=true
user- user name
password - password
json - define responce format by setting this parameter. If parameter is present (don't metter what value is) device return code 200 and session id in json format. If json paramater don't present - then device returns 302 responce code is authorisation is success.
Before call any API function you must be authorized on device. If authorization success - device generate unique session ID and write user name and id to Cookie header (Cookie "user=;session=" Note - only device should write session and user to Cookies.
Success if session and user cookies present in responce header
{"user":"user", "session":"123456"}
After call of any API function - device will check Cookies session ID and user name with stored in EEPROM memory user and session data. If Session and user match with stored session and user then authorization successed and API function return result code OK. else it will return 404 error code.
Return list of awailable wifi ap
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
"mac":"AA:BB:CC:DD:EE:FF",// wifi adapter mac address
"localip":"192.168.0.2",//ip address of device
"getway":"192.168.0.1",//ip address of router
"dnsip":"192.168.0.1",//ip address of primary DNS server
"ssid"://list of awailable wifi netwoks
[
{"name":"name1", "encryption":"type of ecryption", "rssi":"siglal level"},
{"name":"name2", "encryption":"type of ecryption", "rssi":"siglal level"},
..
{"name":"nameX", "encryption":"type of ecryption", "rssi":"siglal level"},
]
}
Add SSID and key to known networks of device (3 networks allowed by default)
/api/wifisave?n=SSID&p=SSKEY&mode=server
SSID - name of wifi network to connect
SSKEY - key for wifi network
mode - optional. Possible value server or client. In server mode - device start soft AP. This allows user to connect to device from android App. In client mode soft AP disabled and device connect to available wifi network.
Use this parameter only if you want to switch device mode. If you dont want to change mode after setting wifi credentionals - dont pass this parameter
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt"//long
}
Return current MQTT server connection parameters
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
"broker", "broker IP/url",
"port", "port number",
"user", "user name(empty if broker is public)",
"key", "authorization key"
}
Save MQTT server connection parameters
/api/mqttsave?broker=broker_name&port=port_name&user=user_name&key=authorization_key
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
}
SET startup states of outputs by name.
/api/startup?out1=on&out2=on&out3=on&led=off
Where out1, out2, out3, led - outputs name of device
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
}
Return HTML code fragment of webUI
/api/template?name=html_template_name
Data for template stored in minimized html file /html/v/_html_template_name.min.html
template file exists
html content
template file not exists
Allow to setup automation of device outputs. Each output can be configured to run triggers task
- on/off trigger set output to ON/OFF state in some time of day
- PWM trigger can set output state to ON for some perion and after set output state to OFF for some period
- Termostat trigger set output state to ON when some sensor value is smaller then min, and set output state to off when sensor value is larger then max
- Venting trigger set output state to ON when some sensor value is bigger then max, and set output state to off when sensor value is less then min
- Timeout trigger After output state becomes ON - trigger start timeout timer. After timer ellapsed - trigger set output to OFF
/api/setup?index=output_index
return list of all automation assigned for output
output_index - index ot uouput
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
"items":
[
{
"name":"trigger name",//title of items
"uid":"number",//trigger uid
"days":"number", //days of wee when this trigger is active
"type":"trigger type", // type name of then trigger
"template":"template_name" //HTML template for display in web UI
"editingtemplate":"editingtemplate_name" //HTML template to display trigger in edit mode
..//different trigger have some other aditional proprties
},
{
"name":"trigger name",//title of items
"uid":"number",//trigger uid
"days":"number", //days of wee when this trigger is active
"type":"trigger type", // type name of then trigger
"template":"template_name" //HTML template for display in web UI
"editingtemplate":"editingtemplate_name" //HTML template to display trigger in edit mode
..//different trigger have some other aditional proprties
}
..
{
"name":"trigger name",//title of items
"uid":"number",//trigger uid
"days":"number", //days of wee when this trigger is active
"type":"trigger type", // type name of then trigger
"template":"template_name" //HTML template for display in web UI
"editingtemplate":"editingtemplate_name" //HTML template to display trigger in edit mode
..//different trigger have some other aditional proprties
}
]
}
index of output out of bounds
/api/setup?delete=trigger_uid&switch=output_index
delete froigger from device
trigger deleted from flash
trigger not found or output with index not exists
Return list of all outputs and their states
/api/switches
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
"items":
[
{
"name":"out1",//title of items
"type":"switch",//type of item
"state":"ON", //current state "ON" or "OFF"
"index":"1", // index of item in array
"visual":"switch" //HTML template for display in web UI
},
{
"name":"out2",//title of items
"type":"switch",//type of item
"state":"ON", //current state "ON" or "OFF"
"index":"1", // index of item in array
"visual":"switch" //HTML template for display in web UI
},
..
{
"name":"outX",//title of items
"type":"switch",//type of item
"state":"ON", //current state "ON" or "OFF"
"index":"1", // index of item in array
"visual":"switch" //HTML template for display in web UI
},
]
}
Set state of output to ON/OFF
/api/switches?index=item_index&state=items_state
item_index - index of output in outputs list
items_state - new state of output. When On - output turns on else output turns off
items_state
item not fpund
return list of webUI menu items in json format
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt",//long
"items":
[
{"name":"menu item 1 title", "href":"menu item 1 url", "target":"menu item 1 tager"},
{"name":"menu item 2 title", "href":"menu item 2 url", "target":"menu item 2 tager"},
..
{"name":"menu item X title", "href":"menu item X url", "target":"menu item X tager"}
]
}
reboot the device
{
"systime":"HH:mm:ss",//string
"uptime":"millis from device strt"//long
}