ANT+ via ESPHome: mcu-nrf-ant (RadiANT) sends heart rate to mcu-nrf-dk over packet_transport

Replaces the E73 running the archived nrf-ant-bridge firmware and drops
mcu-ant-host, which read that bridge's line protocol.
This commit is contained in:
randy committed 2026-09-30 21:17:20 +02:00
1 parent 6fd5ee1fa7
commit 3a397cfb4b
4 files changed
+60 -43

No files matched your search

-34
View File
@@ -1,34 +0,0 @@
# Hardware: Linux host (ESPHome host platform)
# Pinout:
# /dev/ttyACM3 nRF52840 DK running ant_bridge (J-Link VCOM, usb-SEGGER_J-Link_000683492497)
substitutions:
device: ant-host
name: ANT+ Host
comment: ANT+ heart rate monitor via nRF52840 DK bridge
esphome:
name: mcu-${device}
friendly_name: ${name}
comment: ${comment}
host:
packages:
api: !include common/api.yaml
logger: !include common/logger.yaml
external_components:
- source: github://randybb/esphome-components
components: [ant_plus]
uart:
# the host uart only takes /dev/<name>, not /dev/serial/by-id/...
port: /dev/ttyACM3
baud_rate: 115200
ant_plus:
device_number: 655730
heart_rate:
name: Heart Rate
filters:
- throttle: 1s
+43
View File
@@ -0,0 +1,43 @@
---
# Hardware: Nordic nRF52840 DK
# Pinout:
# P0.06 UART0 TX -> logger (J-Link VCOM)
# P1.01 UART1 TX -> mcu-nrf-dk UART1 RX (P1.01), packet_transport; plus GND
# Radio: ANT+ receiver (RadiANT), no network of its own; values go to mcu-nrf-dk
esphome:
name: mcu-nrf-ant
friendly_name: nRF ANT+
# needs the esphomeplatformzephyr fork (esphome-zephyr); RadiANT needs NCS
zephyr:
variant: NRF52
board: nrf52840dk/nrf52840
framework:
type: ncs
logger:
hardware_uart: UART0
external_components:
- source: github://randybb/esphome-components
components: [ant_plus]
ant_plus:
network_key: !secret ant_plus_network_key
device_number: 655730
heart_rate:
id: heart_rate
name: Heart Rate
uart:
id: link
port: UART1
tx_pin: P1.01
baud_rate: 115200
packet_transport:
- platform: uart
uart_id: link
update_interval: 1s
sensors:
- heart_rate
+14 -9
View File
@@ -9,7 +9,7 @@
# P0.16 LED 4 (active low) -> LED 4 (light binary) # P0.16 LED 4 (active low) -> LED 4 (light binary)
# P0.24 Button 3 (active low) -> Button 3 (binary_sensor gpio) # P0.24 Button 3 (active low) -> Button 3 (binary_sensor gpio)
# P0.25 Button 4 (active low) -> Button 4 (binary_sensor gpio) # P0.25 Button 4 (active low) -> Button 4 (binary_sensor gpio)
# P1.01 UART1 RX <- Ebyte E73-TBM-01 (E73-2G4M04S1B, nRF52832) ant_bridge TX (P0.24) # P1.01 UART1 RX <- mcu-nrf-ant UART1 TX (P1.01), packet_transport; plus GND
esphome: esphome:
name: mcu-nrf-dk name: mcu-nrf-dk
friendly_name: nRF DK friendly_name: nRF DK
@@ -34,20 +34,25 @@ api:
encryption: encryption:
key: !secret api_key key: !secret api_key
external_components: # ANT+ values from mcu-nrf-ant (second nRF52840 DK) over UART
- source: github://randybb/esphome-components
components: [ant_plus]
# ANT+ from the E73 test board running ant_bridge (the ANT stack doesn't work on NCS 3.4)
uart: uart:
id: ant_link
port: UART1 port: UART1
rx_pin: P1.01 rx_pin: P1.01
baud_rate: 115200 baud_rate: 115200
ant_plus: packet_transport:
device_number: 655730 - platform: uart
heart_rate: uart_id: ant_link
providers:
- name: mcu-nrf-ant
sensor:
- platform: packet_transport
provider: mcu-nrf-ant
remote_id: heart_rate
name: Heart Rate name: Heart Rate
internal: false
filters: filters:
- throttle: 1s - throttle: 1s
+3
View File
@@ -32,3 +32,6 @@ ble_beacon_toyota_yaris_honda_minor: 61958
# Thread active dataset (hex TLV) from Home Assistant # Thread active dataset (hex TLV) from Home Assistant
thread_tlv: "0E080000000000010000" thread_tlv: "0E080000000000010000"
# ANT+ network key (8 bytes hex), from thisisant.com
ant_plus_network_key: "0000000000000000"