Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
fe43bda
Update lint.yaml
WillCodeForCats Aug 17, 2025
5b33458
Create linter.yml
WillCodeForCats Aug 17, 2025
bcdadde
Merge branch 'main' into super-linter
WillCodeForCats Aug 17, 2025
c7cef3a
Run prettier on markdown files
WillCodeForCats Aug 17, 2025
4336e88
Run prettier on yaml files
WillCodeForCats Aug 17, 2025
ad7f8b5
Update bug_report.md
WillCodeForCats Aug 17, 2025
715c0ba
Format with black
WillCodeForCats Aug 17, 2025
98cda00
Update Dockerfile
WillCodeForCats Aug 17, 2025
be30ed7
Update Dockerfile
WillCodeForCats Aug 17, 2025
9b00448
Update Dockerfile
WillCodeForCats Aug 17, 2025
db6c91d
Update README.md
WillCodeForCats Aug 17, 2025
0b95d47
Update README.md
WillCodeForCats Aug 17, 2025
93ae544
Update DOCS.md
WillCodeForCats Aug 17, 2025
1f7ae02
Merge branch 'main' into super-linter
WillCodeForCats Nov 26, 2025
b291c37
Merge branch 'main' into super-linter
WillCodeForCats Dec 1, 2025
f59d3b4
Merge branch 'main' into super-linter
WillCodeForCats Apr 18, 2026
2a55398
Run prettier on files
WillCodeForCats Apr 18, 2026
112e3bf
Disable pyink
WillCodeForCats Apr 18, 2026
d9ec03e
Merge branch 'addon-now-apps' into super-linter
WillCodeForCats Apr 18, 2026
bb89dc7
Update lint.yaml
WillCodeForCats Apr 18, 2026
d62939e
Update CHANGELOG.md
WillCodeForCats Apr 18, 2026
6512230
Fix bare URLs
WillCodeForCats Apr 18, 2026
a778e83
Merge branch 'main' into super-linter
WillCodeForCats Apr 18, 2026
3b7b024
Merge branch 'main' into super-linter
WillCodeForCats Apr 18, 2026
a16c045
Update CHANGELOG.md
WillCodeForCats Apr 19, 2026
b1223b1
Create .hadolint.yaml
WillCodeForCats Apr 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''

title: ""
labels: ""
assignees: ""
---

Before reporting a bug, make sure you are running the latest version of `tekmar-packetserv` add-on and the `tekmar-482` integration.
Expand All @@ -22,9 +21,10 @@ If applicable, add screenshots of the problem and/or configuration.
Copy any log messages/errors from the Home Assistant add-on logs.

**Home Assistant (please complete the following information):**
- Home Assistant Core Version:
- Gateway 482 Firmware Version:
- Gateway 482 Protocol Version:

- Home Assistant Core Version:
- Gateway 482 Firmware Version:
- Gateway 482 Protocol Version:

**Additional context**
Add any other context about the problem here.
61 changes: 30 additions & 31 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@ name: "CodeQL"

on:
push:
branches: [ main ]
branches: [main]
pull_request:
# The branches below must be a subset of the branches above
branches: [ main ]
branches: [main]
schedule:
- cron: '17 20 * * 6'
- cron: "17 20 * * 6"

jobs:
analyze:
Expand All @@ -32,41 +32,40 @@ jobs:
strategy:
fail-fast: false
matrix:
language: [ 'python' ]
language: ["python"]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v6.0.2
- name: Checkout repository
uses: actions/checkout@v6.0.2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.


# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v4
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v4

# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh
# If the Autobuild fails above, remove it and uncomment the following three lines.
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
# - run: |
# echo "Run, Build Application using script"
# ./location_of_script_within_repo/buildscript.sh

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
31 changes: 31 additions & 0 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
---
name: Lint Code Base
on:
push:
pull_request:
branches:
- main
permissions: read-all
jobs:
build:
name: Lint Code Base
runs-on: ubuntu-latest
permissions:
contents: read
packages: read
statuses: write
steps:
- name: Checkout Code
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Lint Code Base
uses: github/super-linter@v7
env:
VALIDATE_ALL_CODEBASE: true
VALIDATE_JSCPD: false
VALIDATE_PYTHON_MYPY: false
VALIDATE_PYTHON_PYLINT: false
VALIDATE_PYTHON_PYINK: false
DEFAULT_BRANCH: main
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
12 changes: 12 additions & 0 deletions .hadolint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
ignored:
- DL3003
- DL3006
- DL3007
- DL3008
- DL3013
- DL3018
- DL3042
- DL4006
- SC2046
- SC2086
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Tekmar Packet Server (tekmar-packetserv)

![Supports aarch64 Architecture][aarch64-shield]
![Supports amd64 Architecture][amd64-shield]

Expand Down Expand Up @@ -31,9 +32,9 @@ This App is part of the Tekmar 482 Integration. Install this integration togethe
## Credits

Implemented using "tN4 Gateway 482 - Custom Integration Tools" and "Tekmar Home Automation
(tHA) Protocol" from: https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482
(tHA) Protocol" from: [https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482](https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482)

Tekmar, tekmarNet, tN4, tN2, and related logos and trademarks are copyright 2021 Watts.

[aarch64-shield]: https://img.shields.io/badge/aarch64-yes-green.svg
[amd64-shield]: https://img.shields.io/badge/amd64-yes-green.svg
[amd64-shield]: https://img.shields.io/badge/amd64-yes-green.svg
13 changes: 13 additions & 0 deletions tekmar_packetserv/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,51 +1,64 @@
# Changelog

## 1.3.3

- Update to base 3.23
- Addons are now Apps
- Bind socket to docker container IP
- Migrate from deprecated home-assistant/builder action

## 1.3.2

- Detect IPv4 mapped IPv6
- Additional logging

## 1.3.1

- Update to base 3.19
- Remove tempio
- Use alpine pyserial package

## 1.3.0

- Drop support for armhf, armv7, and i386 architectures.

## 1.2.2

- Update documentation.

## 1.2.1

- Update S6-Overlay structure
- Fixes reloading on serial port errors

## 1.2.0

- Add Socket and RFC2217 serial options.

## 1.1.0

- Add custom apparmor file.
- S6-Overlay 3.x

## 1.0.2

- Add EN translation.

## 1.0.1

- Add allowed IP address (CIDR format) setting for security.

## 1.0.0

- First stable release.

## 0.9.1 through 0.9.9

- Fine tuning on errors.
- Internal cleanup for use as add-on.
- Test with bad input sent to packet server
- Test for USB serial unplugged while running

## 0.9.0

- First test version.
4 changes: 2 additions & 2 deletions tekmar_packetserv/DOCS.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Or an IP to Serial connection:

This App is part of the Tekmar 482 Integration. Install this integration together with the App:

https://github.com/WillCodeForCats/tekmar-482
[https://github.com/WillCodeForCats/tekmar-482](https://github.com/WillCodeForCats/tekmar-482)

## Configuration

Expand Down Expand Up @@ -68,6 +68,6 @@ On IP-to-Serial servers use "9600,8,N,1" for the serial port:
## Credits

Implemented using "tN4 Gateway 482 - Custom Integration Tools" and "Tekmar Home Automation
(tHA) Protocol" from: https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482
(tHA) Protocol" from: [https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482](https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482)

Tekmar, tekmarNet, tN4, tN2, and related logos and trademarks are copyright 2021 Watts.
6 changes: 3 additions & 3 deletions tekmar_packetserv/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ This is a Home Assistant App used by the [Tekmar Gateway 482 Integration](https:

Install this integration together with the App:

https://github.com/WillCodeForCats/tekmar-482
<https://github.com/WillCodeForCats/tekmar-482>

Important: This App can only be used with the Gateway 482. The touchscreen Gateway 486 IS NOT compatible because it doesn't have a local API.

### Credits
## Credits

Implemented using "tN4 Gateway 482 - Custom Integration Tools" and "Tekmar Home Automation
(tHA) Protocol" from: https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482
(tHA) Protocol" from: <https://www.watts.com/products/hvac-hot-water-solutions/controls/control-accessories/482/482>

Tekmar, tekmarNet, tN4, tN2, and related logos and trademarks are copyright 2021 Watts.
27 changes: 13 additions & 14 deletions tekmar_packetserv/rootfs/usr/local/packetserv/fields.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,21 @@
""" Field identifying and parsing.
"""Field identifying and parsing.

The contents of this module allow the specifcation of formats of arrays
of bytes (similar to the python's struct module), but with more
granularity.
The contents of this module allow the specifcation of formats of arrays
of bytes (similar to the python's struct module), but with more
granularity.

Each field basically has two properties: a name and a size (in bytes).
Each field basically has two properties: a name and a size (in bytes).

Each field has basically two methods: pack and unpack.
Each field has basically two methods: pack and unpack.

The unpack method takes a sequence of bytes and unpacks the data into
a list of values. The method returns the unpacked list and any trailing
(packed) data as a tuple.

The pack method takes a sequence of values and packs them into a list of
bytes. The method returns the packed list and any extra values as a
tuple.
"""
The unpack method takes a sequence of bytes and unpacks the data into
a list of values. The method returns the unpacked list and any trailing
(packed) data as a tuple.

The pack method takes a sequence of values and packs them into a list of
bytes. The method returns the packed list and any extra values as a
tuple.
"""

# ******************************************************************************
LITTLE_ENDIAN = False
Expand Down
16 changes: 8 additions & 8 deletions tekmar_packetserv/rootfs/usr/local/packetserv/packet.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
""" Packet object.
"""Packet object.

Basically a packet has a type and some data and is represented in two
forms: its raw (object) form and in string form.
Basically a packet has a type and some data and is represented in two
forms: its raw (object) form and in string form.

In string form, it looks like a sequence of hex bytes, e.g.
0102030F\n
In string form, it looks like a sequence of hex bytes, e.g.
0102030F\n

The 01 is the packet type and 02, 03, and 0F is the packet data. A
packet is always delimited by a newline character (in string form).
"""
The 01 is the packet type and 02, 03, and 0F is the packet data. A
packet is always delimited by a newline character (in string form).
"""

# ******************************************************************************
from fields import FieldList, Int8
Expand Down
11 changes: 5 additions & 6 deletions tekmar_packetserv/rootfs/usr/local/packetserv/tpck.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
""" Allow reading and writing of packets using the tpck protocol.

The tpck protocol provides data delimiting and validation for
communication links that can not support the simplicity of the
string-based packet transfer.
"""
"""Allow reading and writing of packets using the tpck protocol.

The tpck protocol provides data delimiting and validation for
communication links that can not support the simplicity of the
string-based packet transfer.
"""

# ******************************************************************************
import packet
Expand Down
Loading