diff --git a/.markdownlint.yaml b/.markdownlint.yaml new file mode 100644 index 0000000..256dc9f --- /dev/null +++ b/.markdownlint.yaml @@ -0,0 +1,4 @@ +--- +headers: + allow_different_nesting: true +line_length: false diff --git a/CHANGELOG.md b/CHANGELOG.md index 228d02f..bc3fbdc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,9 +1,22 @@ # Changelog -All notable changes to this project will be documented in this file. + +All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) This project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html) +## 2020-04-25 Release 1.0.1 + +### Added + +- Hubitat Package Manager manifest + +### Changed + +- Move logging of mode change request prior to sending to make Abode websocket delays visible +- Reformat log messages for easier understanding when debug is disabled. + _Author had never run it with debug logging disabled_. :stuck_out_tongue_winking_eye: + ## 2020-04-25 Release 1.0 No changes diff --git a/drivers/AbodeAlarm.groovy b/drivers/AbodeAlarm.groovy index c5958b3..f321b8a 100644 --- a/drivers/AbodeAlarm.groovy +++ b/drivers/AbodeAlarm.groovy @@ -205,9 +205,9 @@ private clearLoginState() { private changeMode(String new_mode) { if(new_mode != device.currentValue('gatewayMode')) { // Only update area 1 since area is not returned in event messages + log.info "Sending request to change Abode gateway mode to ${new_mode}" reply = doHttpRequest('PUT','/api/v1/panel/mode/1/' + new_mode) if (reply['area'] == '1') { - log.info "Sent request to change Abode gateway mode to ${new_mode}" state.localModeChange = new_mode } } else { @@ -533,7 +533,7 @@ def parseEvent(String event_text) { break default: - log.warn "Event ${event_class} has unknown data format: ${event_data}" + log.warn "Abode event ${event_class} has unknown data format: ${event_data}" message = event_data break } @@ -582,11 +582,11 @@ def parseEvent(String event_text) { break default: - if (logDebug) log.debug "Ignoring Event ${event_class} ${message}" + if (logDebug) log.debug "Ignoring event ${event_class} ${message}" break } } else { - log.warn "Unparseable Event message: ${event_text}" + log.warn "Unparseable Abode event message: ${event_text}" } } @@ -630,12 +630,12 @@ def parse(String message) { message_data = packet_data.substring(1) switch(message_type) { case '0': - log.info 'webSocket message = Event socket connected' + log.info 'Abode event socket connected' runInMillis(state.webSocketPingInterval, sendPing) break case '1': - log.info 'webSocket message = Event socket disconnected' + log.info 'webSocket message = event socket disconnected' break case '2': @@ -686,13 +686,13 @@ def webSocketStatus(String message) { break case ~/^failure:(.*)$/: - log.warn 'Event socket connection: ' + message + log.warn 'Abode event socket connection: ' + message state.webSocketConnected = false state.webSocketConnectAttempt += 1 break default: - log.warn 'Event socket sent unexpected message: ' + message + log.warn 'Abode event socket sent unexpected message: ' + message state.webSocketConnected = false state.webSocketConnectAttempt += 1 } diff --git a/packageManifest.json b/packageManifest.json new file mode 100644 index 0000000..f8c1114 --- /dev/null +++ b/packageManifest.json @@ -0,0 +1,19 @@ +{ + "packageName": "Abode Alarm", + "minimumHEVersion": "2.1.0", + "author": "Jo Rhett", + "version": "1.0.1", + "dateReleased": "2020-07-18", + "licenseFile": "https://github.com/jorhett/hubitat-abode/blob/master/LICENSE", + "releaseNotes": "https://github.com/jorhett/hubitat-abode/blob/master/CHANGELOG.md", + "apps" : [], + "drivers" : [ + { + "id" : "a3f88dd8-474c-4fe7-a226-521f44638d87", + "name": "Abode Alarm", + "namespace": "jorhett", + "location": "https://raw.githubusercontent.com/jorhett/hubitat-abode/v1.0.1/drivers/AbodeAlarm.groovy", + "required": true + } + ] +}