mdegat01 / addon-amr2mqtt

HA Addon which runs rtlamr to read IDM power meter data and send to MQTT broker
MIT License
33 stars 18 forks source link

Allow setting device # when using multiple radios #99

Closed nukefrenzy closed 1 year ago

nukefrenzy commented 1 year ago

Is your feature request related to a problem? Please describe. I run rtl_433 using 2 radios and would like to run this add-on on a 3rd radio, but getting conflicts.

Describe the solution you'd like rtl_433 allows setting the device number to avoid conflicts, but this add-on defaults to device 0. Please add a setting so I can coordinate all of my addons/devices. It looks like rtlamr has this option when starting it: https://github.com/bemasher/rtlamr/issues/230

Describe alternatives you've considered I've tried setting devices on rtl_433 to 1 and 2 so that this addon can use default device 0, but still having issues and this addons exits

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
cont-init: info: running /etc/cont-init.d/00-banner.sh
-----------------------------------------------------------
 Add-on: AMR2MQTT
 AMR2MQTT for Home Assistant
-----------------------------------------------------------
 Add-on version: 2.1.2
 You are running the latest version of this add-on.
 System: Home Assistant OS 10.5  (amd64 / generic-x86-64)
 Home Assistant Core: 2023.8.4
 Home Assistant Supervisor: 2023.08.1
-----------------------------------------------------------
 Please, share the above information when looking for help
 or support in, e.g., GitHub, forums or the Discord chat.
-----------------------------------------------------------
cont-init: info: /etc/cont-init.d/00-banner.sh exited 0
cont-init: info: running /etc/cont-init.d/01-log-level.sh
cont-init: info: /etc/cont-init.d/01-log-level.sh exited 0
cont-init: info: running /etc/cont-init.d/02-set-timezone.sh
[11:11:52] INFO: Configuring timezone
cont-init: info: /etc/cont-init.d/02-set-timezone.sh exited 0
cont-init: info: running /etc/cont-init.d/30-config.sh
[11:11:53] INFO: Ensure MQTT broker is reachable at core-mosquitto:1883 (60s timeout)
cont-init: info: /etc/cont-init.d/30-config.sh exited 0
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun amr2mqtt (no readiness notification)
services-up: info: copying legacy longrun rtl_tcp (no readiness notification)
[11:11:53] INFO: Starting rtl_tcp daemon...
s6-rc: info: service legacy-services successfully started
Found 3 device(s):
  0:  Realtek, RTL2838UHIDIR, SN: 00000001
  1:  Realtek, RTL2838UHIDIR, SN: 00000001
  2:  Realtek, RTL2838UHIDIR, SN: 00000001
Using device 0: Generic RTL2832U OEM
usb_claim_interface error -6
Failed to open rtlsdr device #0.
[11:11:53] WARNING: Halt add-on with exit code 1
s6-rc: info: service legacy-services: stopping
[11:11:53] INFO: Service restart after closing
s6-rc: info: service legacy-services successfully stopped
s6-rc: info: service legacy-cont-init: stopping
s6-rc: info: service legacy-cont-init successfully stopped
s6-rc: info: service fix-attrs: stopping
s6-rc: info: service fix-attrs successfully stopped
s6-rc: info: service s6rc-oneshot-runner: stopping
s6-rc: info: service s6rc-oneshot-runner successfully stopped

Additional context https://github.com/bemasher/rtlamr/issues/230

github-actions[bot] commented 1 year ago

There hasn't been any activity on this issue recently, so we clean up some of the older and inactive issues. Please make sure to update to the latest version and check if that solves the issue. Let us know if that works for you by leaving a comment 👍 This issue has now been marked as stale and will be closed if no further activity occurs. Thanks!