Sennevds / RFXcomIdGenerator

Generate RFXcom ID for Home Assistant

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MDREMOTE V106 / V107 not working

sunflowerABB opened this issue · comments

HASS IDs generated for MDREMOTE V106 / V107 (Lightning 5 tab in RFXMngr) result in an error and cannot be added to the configuration:

$ generateId.py -t Lighting5 -s MDREMOTE -p 37191,1

Result: 0a14030001457110000

I tried entereind the ID both in HEX and DEC format.

Log output:
ERROR (MainThread) [homeassistant.config] Invalid config for [switch.rfxtrx]: Rfxtrx device 00a14030001457110000 is invalid: Invalid device id for OrderedDict([('0a14030001457110000', OrderedDict([('name', 'LED_1')]))]) for dictionary value @ data['devices']. Got OrderedDict([('0a14030001457110000', OrderedDict([('name', 'LED_1')]))]). (See ?, line ?). Please check the docs at https://home-assistant.io/components/switch.rfxtrx/

commented

mdremote107_1er

Sending this command manually from RFXMgnr works, but impossible from HASS

MDremote V107 works the same, however MDremote V108 seems to be different and doesn't work...

Alternatively, howto send an ID (i.e. 9147 as shown above) via ssh manually as a RF command using echo as shown below? What is the code pattern needed, i.e.:

echo -ne '\x00\x91\x47\x00\x00' > /dev/ttyUSB-RFX433

?

I received the following info from RFXCOM which I wanted to post in case someone else finds it useful:

In order to activate "Undec Mode" on the RFXCOM it is necessary to send an init command after the connection like this:
0D 00 00 04 03 53 1C 88 00 00 00 00 00 00

The 88 undec on + Lighting4 enabled

I assume this can be done from the terminal using the following command:

echo -ne '\x0D\x00\x00\x04\x03\x53\x1C\x88\x00\x00\x00\x00\x00\x00' > /dev/ttyUSB-RFX433

Unfortunately I am unable to activate the undec mode using the command stated above - in any case not all signals are received by my rfxtrx once the echo command is sent. Any clues?

FYI everyone, here the answer from RFXCOM on how the code is put together:

MD106 command = 14 03:
Lighting5 command: 0A 14 03 03 00 91 47 01 00 00 00

Packettype = Lighting5
subtype = MD Remote version 106
Sequence nbr = 3
ID = 9147 decimal:37191
Command = Power (00)
Other commands can be found in RFXmngr, for example light=01 and so on.

MD107 command = 14 0C:
Lighting5 command: 0A 14 0C 09 00 91 47 01 00 00 00

Packettype = Lighting5
subtype = MD Remote version 107
Sequence nbr = 9
ID = 9147 decimal:37191
Command = Power

screen shot 2017-08-28 at 19 04 14

With this resulting code I was finally able to get my cheap chinese LED controller to cooperate with rfxtrx (example shows power toggle):

echo -ne '\x0A\x14\x0C\x03\x00\x91\x47\x01\x00\x00\x00' > /dev/ttyUSB-RFX433

I am thus using a workaround home assistant / HASS script to control my LEDs:

#!/bin/bash
set -e

This script is used to send commands via the terminal to an MDRemote V106 / V107 LED controller

Path to your RFXCOM device

RFXCOM_DEV=/dev/ttyUSB-RFX433

Number of times to send the command

REPEAT=1

Pause between each command being sent

#REPEAT_DELAY=0.2

echo -ne '\x0A\x14\x0C\x03\x00\x8C\x16\x01\x00\x00\x00' > "$RFXCOM_DEV"

screen shot 2017-08-28 at 19 23 09