No description
  • Python 94.7%
  • JavaScript 3%
  • CSS 1%
  • HTML 0.7%
  • Shell 0.6%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Robert Marshall e3c138a255
Some checks failed
Lint, type check and test / hassfest (push) Successful in 8s
Lint, type check and test / quality (push) Successful in 1m56s
Lint, type check and test / release (push) Failing after 3s
Merge pull request 'Follow the origin removal and colour light wire changes' (#127) from refactor/colour-light-no-origin into main
Reviewed-on: #127
2026-10-13 20:33:30 +00:00
.forgejo/workflows Rename the integration from Campervan to CamperCan 2026-10-10 20:21:26 +01:00
custom_components/campercan Keep a dim colour light request above zero and fix stale citations 2026-10-13 20:56:48 +01:00
docs Drive the colour light through CMD_COLOUR and expose HS colour 2026-10-13 20:53:40 +01:00
ha-config Rename the integration from Campervan to CamperCan 2026-10-10 20:21:26 +01:00
ha-data/config/custom_components Move explination of .gitkeep existence in to .gitkeep file so it's easier to find out why it's there 2026-09-06 18:10:49 +01:00
mqtt-data/config Remove unecessary persistence and auto save to prevent wear on SD card 2026-09-21 08:03:19 +00:00
tests Take the vectors from firmware main now that #107 has landed 2026-10-13 21:28:23 +01:00
theme Colour history graph lines from the theme palette 2026-10-05 11:03:05 +01:00
tools Keep a dim colour light request above zero and fix stale citations 2026-10-13 20:56:48 +01:00
updater Rename the updater container, paths and hotspot to campercan 2026-10-10 20:47:06 +01:00
.editorconfig Cut comments back to the ones that earn their place 2026-09-06 21:52:13 +01:00
.gitignore Rename the integration from Campervan to CamperCan 2026-10-10 20:21:26 +01:00
CLAUDE.md Drive the colour light through CMD_COLOUR and expose HS colour 2026-10-13 20:53:40 +01:00
compose.yaml Rename the updater container, paths and hotspot to campercan 2026-10-10 20:47:06 +01:00
pyproject.toml Rename the integration from Campervan to CamperCan 2026-10-10 20:21:26 +01:00
README.md Ship the brand images inside the integration 2026-10-10 20:51:03 +01:00
requirements-dev.txt Take the review: pin the CI variable to the step that uses it 2026-09-19 21:29:08 +01:00

CamperCan

A Home Assistant custom integration for CampervanControlSystems.

Home Assistant sits on the bus as node 0x01. It finds the van's controllers, shows them as devices and entities, and sends them commands.

Home Assistant 2026.3 and later shows the CamperCan icon from custom_components/campercan/brand/.

Also manages distribution of firmware updates, see: docs/updater.md

See docs/entities.md for how the entities behave.

Requirements

  • A CAN interface up at 250 kbps, CAN 2.0B with 29-bit extended identifiers.

Running

compose.yaml runs Home Assistant Container with this integration bind-mounted in.

tools/stamp-build               # stamp the commit this checkout is on
docker compose up -d
docker compose logs -f          # the first start takes a minute

Then http://localhost:8123, complete onboarding, and add the integration from Settings -> Devices & services.

To log frames, turn on the Frame log switch in the Bridge device settings. The logger level it needs is already set in ha-config/configuration.yaml.

A few things worth knowing:

  • Any changes to the integration require a container restart.
  • network_mode: host is required so the container can see the CAN network.
  • ha-data/ is Home Assistant's data directory and is not tracked. configuration.yaml lives in ha-config/ and is mounted over it read-only, so edit it there and restart.
  • The container tracks stable, by default. Set HA_VERSION to pin it.

See docs/updater.md for how the updater service works.

Development

uv venv --python 3.14 .venv
uv pip install --python .venv/bin/python -r requirements-dev.txt

tools/check

tools/check runs what CI runs: ruff check, a formatting check, mypy, then the tests. .venv/bin/ruff format . fixes formatting.

See docs/development.md for the protocol package, the shared test vectors, the test suite, and release details.

Testing

tools/frame-bench builds any frame in the message catalogue and puts it on a virtual CAN bus. It needs no van and no firmware.

tools/frame-bench             # asks for sudo

Then http://127.0.0.1:8099, and candump vcan0 in another terminal to watch what arrives.

See docs/frame-bench.md for the bench, its sequence player, and the tests that cover it.

Raspberry Pi

There are some brief Raspberry Pi setup instructions at docs/rpi-setup.md.