Skip to content

petrleocompel/py-jablotron6x

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

py-jablotron6x

Library for interfacing with Jablotron 6x alarms by using the JA-80T serial cable.

Example usage:

python

>>> from jablotron import Jablotron6x
>>> with Jablotron6x("/dev/ttyUSB0") as j:
>>>   j.on_mode_change = lambda mode: print(str(mode))
>>>   j.send_keys('F06060')
>>>   j.send_keys('N')

More details about the ja-6x protocol is in the wiki.

Docker

Right now you have to build docker image for yourself.

  1. Clone repo
  2. build docker image
  3. run image

Running docker image

Variable Description Default value
SERIAL_DEVICE Path to device /dev/ttyUSB0
MQTT_HOST Host for MQTT localhost
MQTT_PORT Port for MQTT 1883
TOPIC Topic for MQTT alarm

Docker run

docker run -d -e SERIAL_DEVICE=/dev/ttyUSB0 -e MQTT_HOST=localhost -e MQTT_PORT=1883 -e TOPIC=alarm --device=/dev/ttyUSB0 py-jablotron

Docker-compose

version: '2'

services:
  jablotron:
    build: .
    restart: on-failure
    container_name: jablotron
    environment:
      - SERIAL_DEVICE=/dev/ttyUSB0
      - MQTT_HOST=localhost
      - MQTT_PORT=1883
      - TOPIC=alarm
    devices:
      - "/dev/ttyUSB0:/dev/ttyUSB0"

Home Assistant

Replace 0000 with your code

alarm_control_panel:
  - platform: mqtt
    unique_id: jablotron_my_name
    state_topic: "alarm/mode"
    command_topic: "alarm/key/press"
    code: 0000
    code_arm_required: false
    code_disarm_required: true
    code_trigger_required: false
    name: JablotronMyName
    payload_arm_away: NNF1
    payload_arm_home: NNF1
    payload_arm_night: NNF1
    payload_arm_custom_bypass: NNF1
    payload_arm_vacation: NNF1
    payload_disarm: NNF0000

About

Library for interfacing with Jablotron 6x alarms + Home Assistant

Topics

Resources

Stars

Watchers

Forks

Languages

  • Python 97.8%
  • Dockerfile 2.2%