just select python code
Python Plugin : Broadlink
Moderator: leecollings
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Debug: Python Only
2020-07-04 11:57:24.998 (RM3m) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : True
2020-07-04 11:57:24.969 Status: User: Admin initiated a switch command (2/RM3m - IR Commands/Set Level)
2020-07-04 11:57:25.007 (RM3m) Update 1:'Learn IR command' (RM3m - RM2-Status)
2020-07-04 11:57:25.016 (RM3m) Update 1:'10' (RM3m - IR Commands)
2020-07-04 11:57:25.016 (RM3m) command to execute : "/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink//;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
2020-07-04 11:57:25.036 Error: (RM3m) 'onCommand' failed 'TimeoutExpired'.
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 445 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function onCommand
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 2294 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function start_shell
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 342 in '/usr/lib/python3.7/subprocess.py', function check_call
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 329 in '/usr/lib/python3.7/subprocess.py', function call
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 1006 in '/usr/lib/python3.7/subprocess.py', function wait
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 1616 in '/usr/lib/python3.7/subprocess.py', function _wait
2020-07-04 11:57:24.998 (RM3m) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : True
2020-07-04 11:57:24.969 Status: User: Admin initiated a switch command (2/RM3m - IR Commands/Set Level)
2020-07-04 11:57:25.007 (RM3m) Update 1:'Learn IR command' (RM3m - RM2-Status)
2020-07-04 11:57:25.016 (RM3m) Update 1:'10' (RM3m - IR Commands)
2020-07-04 11:57:25.016 (RM3m) command to execute : "/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink//;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
2020-07-04 11:57:25.036 Error: (RM3m) 'onCommand' failed 'TimeoutExpired'.
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 445 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function onCommand
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 2294 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function start_shell
2020-07-04 11:57:25.036 Error: (RM3m) ----> Line 342 in '/usr/lib/python3.7/subprocess.py', function check_call
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 329 in '/usr/lib/python3.7/subprocess.py', function call
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 1006 in '/usr/lib/python3.7/subprocess.py', function wait
2020-07-04 11:57:25.037 Error: (RM3m) ----> Line 1616 in '/usr/lib/python3.7/subprocess.py', function _wait
- Attachments
-
- Debug Python only.png (163.06 KiB) Viewed 2763 times
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
great!
this execute the right command.
verify that dombr.sh can be executed ( +x ) (ls -altr)
chmod +x if necessary...
you can run it by yourself if you open term session...
go to Broadlink folder:
"/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink//;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
this execute the right command.
verify that dombr.sh can be executed ( +x ) (ls -altr)
chmod +x if necessary...
you can run it by yourself if you open term session...
go to Broadlink folder:
"/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink//;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
-
- Posts: 66
- Joined: Tuesday 19 April 2016 23:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Hi zak45
Execute persmision was set, it was done with your install script, i did not do anything....
If i launch it manually works fine but domoticz gets time out when rise learn command
Best regards!
Execute persmision was set, it was done with your install script, i did not do anything....
If i launch it manually works fine but domoticz gets time out when rise learn command
Best regards!
Fronius plugin
https://github.com/ayasystems/froniusHttp
Solax plugin
https://github.com/ayasystems/SolaxHTTP
Openevse plugin
https://github.com/ayasystems/OpenEVSEPlugin
https://github.com/ayasystems/froniusHttp
Solax plugin
https://github.com/ayasystems/SolaxHTTP
Openevse plugin
https://github.com/ayasystems/OpenEVSEPlugin
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Hummm... maybe I'm wrong, but what I see, is that you have entered a control / break when you tried to run the command ( ^c )ayasystems wrote: ↑Saturday 04 July 2020 19:09 Hi zak45
Execute persmision was set, it was done with your install script, i did not do anything....
learn_device_responde.jpg
If i launch it manually works fine but domoticz gets time out when rise learn command
learn_device.jpg
Best regards!
could be nice to see the content of the nohup.out.
Maybe waiting for something ... and this is the reason of the Timeout error. ?? !!
-
- Posts: 66
- Joined: Tuesday 19 April 2016 23:37
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Hi
Timeout is raised without delay.
I did ctrl after a 10 seconds and it worked, the command was readed and ini created. But launched on console. Launched by domoticz raise timeout without delay.
Sorry for my English, it is not enough good to explain all
Regard
Timeout is raised without delay.
I did ctrl after a 10 seconds and it worked, the command was readed and ini created. But launched on console. Launched by domoticz raise timeout without delay.
Sorry for my English, it is not enough good to explain all
Regard
Fronius plugin
https://github.com/ayasystems/froniusHttp
Solax plugin
https://github.com/ayasystems/SolaxHTTP
Openevse plugin
https://github.com/ayasystems/OpenEVSEPlugin
https://github.com/ayasystems/froniusHttp
Solax plugin
https://github.com/ayasystems/SolaxHTTP
Openevse plugin
https://github.com/ayasystems/OpenEVSEPlugin
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Ok, no problem, thanks for the information.ayasystems wrote: ↑Sunday 05 July 2020 9:40 Hi
Timeout is raised without delay.
I did ctrl after a 10 seconds and it worked, the command was readed and ini created. But launched on console. Launched by domoticz raise timeout without delay.
Sorry for my English, it is not enough good to explain all
Regard
This show that the script is waiting something. The goal is that when you run the .sh, it launched a second py process and terminate in few ms...
What is the content of the nohup.out ???
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Have installed Debian on a VM, made some test and the Timeout not managed the same as on Windows.
Modification has been made.
Download setup.py and execute it again.
Modification has been made.
Download setup.py and execute it again.
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Previous errors have disappeared!
New error while pressing "Learn" in IR Command:
Error: (RM3m) ERR : learnir--Not able to enter learning mode--21
Log:
2020-07-06 17:02:20.886 (RM3m) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : True
2020-07-06 17:02:20.894 (RM3m) Update 1:'Learn IR command' (RM3m - RM2-Status)
2020-07-06 17:02:20.903 (RM3m) Update 1:'10' (RM3m - IR Commands)
2020-07-06 17:02:20.903 (RM3m) command to execute : "/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink/;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
2020-07-06 17:02:20.859 Status: User: Admin initiated a switch command (2/RM3m - IR Commands/Set Level)
2020-07-06 17:02:21.776 (RM3m) Connected successfully to 192.168.1.118:38418
2020-07-06 17:02:21.777 (RM3m) onMessage called for connection: 192.168.1.118:38418
2020-07-06 17:02:21.777 (RM3m) We bypass URL check
2020-07-06 17:02:21.777 (RM3m) data:b'{"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}'
2020-07-06 17:02:21.777 (RM3m) {"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}
2020-07-06 17:02:21.777 (RM3m) processing data : {"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}
2020-07-06 17:02:21.777 (RM3m) data process OK
2020-07-06 17:02:21.827 (RM3m) Connected successfully to 192.168.1.118:38420
2020-07-06 17:02:21.828 (RM3m) onDisconnect called for connection 192.168.1.118:38418
2020-07-06 17:02:21.828 (RM3m) Server Connections:
2020-07-06 17:02:21.828 (RM3m) --> 192.168.1.118:38418'.
2020-07-06 17:02:21.828 (RM3m) --> 192.168.1.118:38420'.
2020-07-06 17:02:21.828 (RM3m) onMessage called for connection: 192.168.1.118:38420
2020-07-06 17:02:21.828 (RM3m) We bypass URL check
2020-07-06 17:02:21.828 (RM3m) data:b'{"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}'
2020-07-06 17:02:21.828 (RM3m) {"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}
2020-07-06 17:02:21.828 (RM3m) processing data : {"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}
2020-07-06 17:02:21.832 (RM3m) Update 1:'Error to learn IR code' (RM3m - RM2-Status)
2020-07-06 17:02:21.836 (RM3m) Update 0:'Off' (RM3m - IR Commands)
2020-07-06 17:02:21.836 (RM3m) data process OK
2020-07-06 17:02:21.886 (RM3m) onDisconnect called for connection 192.168.1.118:38420
2020-07-06 17:02:21.886 (RM3m) Server Connections:
2020-07-06 17:02:21.886 (RM3m) --> 192.168.1.118:38420'.
2020-07-06 17:02:21.777 Error: (RM3m) ERR : learnir--Not able to enter learning mode--21
New error while pressing "Learn" in IR Command:
Error: (RM3m) ERR : learnir--Not able to enter learning mode--21
Log:
2020-07-06 17:02:20.886 (RM3m) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : True
2020-07-06 17:02:20.894 (RM3m) Update 1:'Learn IR command' (RM3m - RM2-Status)
2020-07-06 17:02:20.903 (RM3m) Update 1:'10' (RM3m - IR Commands)
2020-07-06 17:02:20.903 (RM3m) command to execute : "/home/pi/domoticz/plugins/Broadlink/scr/dombr.sh" "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py" "192.168.1.118;8080;24Dxxxxxxx;/home/pi/domoticz/scripts/broadlink/;RM2M;192.168.1.173;9000;2;2;/home/pi/domoticz/plugins/Broadlink/;9;en;learnir" no
2020-07-06 17:02:20.859 Status: User: Admin initiated a switch command (2/RM3m - IR Commands/Set Level)
2020-07-06 17:02:21.776 (RM3m) Connected successfully to 192.168.1.118:38418
2020-07-06 17:02:21.777 (RM3m) onMessage called for connection: 192.168.1.118:38418
2020-07-06 17:02:21.777 (RM3m) We bypass URL check
2020-07-06 17:02:21.777 (RM3m) data:b'{"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}'
2020-07-06 17:02:21.777 (RM3m) {"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}
2020-07-06 17:02:21.777 (RM3m) processing data : {"status":{"step":"ERR : learnir","msg":"Not able to enter learning mode","code":"21"}}
2020-07-06 17:02:21.777 (RM3m) data process OK
2020-07-06 17:02:21.827 (RM3m) Connected successfully to 192.168.1.118:38420
2020-07-06 17:02:21.828 (RM3m) onDisconnect called for connection 192.168.1.118:38418
2020-07-06 17:02:21.828 (RM3m) Server Connections:
2020-07-06 17:02:21.828 (RM3m) --> 192.168.1.118:38418'.
2020-07-06 17:02:21.828 (RM3m) --> 192.168.1.118:38420'.
2020-07-06 17:02:21.828 (RM3m) onMessage called for connection: 192.168.1.118:38420
2020-07-06 17:02:21.828 (RM3m) We bypass URL check
2020-07-06 17:02:21.828 (RM3m) data:b'{"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}'
2020-07-06 17:02:21.828 (RM3m) {"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}
2020-07-06 17:02:21.828 (RM3m) processing data : {"status":{"step":"learnir","msg":"Error to learn IR code","code":"1"}}
2020-07-06 17:02:21.832 (RM3m) Update 1:'Error to learn IR code' (RM3m - RM2-Status)
2020-07-06 17:02:21.836 (RM3m) Update 0:'Off' (RM3m - IR Commands)
2020-07-06 17:02:21.836 (RM3m) data process OK
2020-07-06 17:02:21.886 (RM3m) onDisconnect called for connection 192.168.1.118:38420
2020-07-06 17:02:21.886 (RM3m) Server Connections:
2020-07-06 17:02:21.886 (RM3m) --> 192.168.1.118:38420'.
2020-07-06 17:02:21.777 Error: (RM3m) ERR : learnir--Not able to enter learning mode--21
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
fine !!
now, this error show something wrong when try to put the device into learning mode, but connection looks OK.
Take a look into log folder, more information should be there.
Do a scan and provide the output.
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
2Mainoutput.txt:
--------------------------------------Start-------------------------------------
STEP ==: learnir --- 2020-07-06 17:07:45
Connected to Broadlink device: 192.168.1.173
Traceback (most recent call last):
File "/home/pi/domoticz/plugins/Broadlink/Dombroadlink.py", line 407, in learnir
device.enter_learning()
File "/usr/lib/python3.7/broadlink/__init__.py", line 615, in enter_learning
check_error(response[0x22:0x24])
File "/usr/lib/python3.7/broadlink/exceptions.py", line 97, in check_error
raise exception(error_code)
broadlink.exceptions.StorageError: The device storage is full
Not able to enter learning mode
Error : <class 'broadlink.exceptions.StorageError'> The device storage is full <traceback object at 0xb5770c
88>
---------------------------------------END--------------------------------------
2Mainoutput.err: Empty file
2RM2M.txt:
0x2712 192.168.1.173 24Dxxxxxxxxx
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Looks like problem with the broadlink library for your device ( suppose RM3 mini )
A link to read : https://github.com/home-assistant/core/issues/35875 and maybe provide some informations
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
zak45 wrote: ↑Monday 06 July 2020 19:12Looks like problem with the broadlink library for your device ( suppose RM3 mini )
A link to read : https://github.com/home-assistant/core/issues/35875 and maybe provide some informations
sudo python broadlink_cli.py --device "0x62be 192.168.1.172 xxxxxxxxxx" --learn
Learning...
2600700000012495111511151115111511151115111510391139103911381138123811381138121411151139111412141139111510161114123810161138113812141138123810381300050f0001264b11000c4f0001254b11000c4e0001254c11000c4e0001254c11000c4e0001264b10000d05000000000000
Base64: b'JgBwAAABJJURFREVERURFREVERURFRA5ETkQORE4ETgSOBE4ETgSFBEVETkRFBIUETkRFRAWERQSOBAWETgROBIUETgSOBA4EwAFDwABJksRAAxPAAElSxEADE4AASVMEQAMTgABJUwRAAxOAAEmSxAADQUAAAAAAAA='
Manual I can trigger to learn code, do you think the cause could be that device (rm4c_mini, 0x62be) is missing in Dombroadlink.py file?
(Possible solution mentioned in https://github.com/home-assistant/core/issues/35875 is the need to specify the correct type in the config. Use type: rm4c_mini...)
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Great. If you can learn code in command line, a solution exist.JUNA wrote: ↑Monday 06 July 2020 21:38 sudo python broadlink_cli.py --device "0x62be 192.168.1.172 xxxxxxxxxx" --learn
Learning...
2600700000012495111511151115111511151115111510391139103911381138123811381138121411151139111412141139111510161114123810161138113812141138123810381300050f0001264b11000c4f0001254b11000c4e0001254c11000c4e0001254c11000c4e0001264b10000d05000000000000
Base64: b'JgBwAAABJJURFREVERURFREVERURFRA5ETkQORE4ETgSOBE4ETgSFBEVETkRFBIUETkRFRAWERQSOBAWETgROBIUETgSOBA4EwAFDwABJksRAAxPAAElSxEADE4AASVMEQAMTgABJUwRAAxOAAEmSxAADQUAAAAAAAA='
Manual I can trigger to learn code, do you think the cause could be that device (rm4c_mini, 0x62be) is missing in Dombroadlink.py file?
(Possible solution mentioned in https://github.com/home-assistant/core/issues/35875 is the need to specify the correct type in the config. Use type: rm4c_mini...)
But first,
you said that your device is a rm4c_mini
but you have a RM2M fle in your log directory with this code on it: 0x2712
this is for the RM2 / RM3 device.
Can you change your plugin settings and select Remote control mini RM4 ?
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Sorry for the confusion. I have both, I own a rm4c_mini and a RM mini 3. I have been switching between the two models to see if there was a difference. (Strange, since reinstall I cannot see device 0x2712 any more in the log.)zak45 wrote: ↑Monday 06 July 2020 23:32Great. If you can learn code in command line, a solution exist.JUNA wrote: ↑Monday 06 July 2020 21:38 sudo python broadlink_cli.py --device "0x62be 192.168.1.172 xxxxxxxxxx" --learn
Learning...
2600700000012495111511151115111511151115111510391139103911381138123811381138121411151139111412141139111510161114123810161138113812141138123810381300050f0001264b11000c4f0001254b11000c4e0001254c11000c4e0001254c11000c4e0001264b10000d05000000000000
Base64: b'JgBwAAABJJURFREVERURFREVERURFRA5ETkQORE4ETgSOBE4ETgSFBEVETkRFBIUETkRFRAWERQSOBAWETgROBIUETgSOBA4EwAFDwABJksRAAxPAAElSxEADE4AASVMEQAMTgABJUwRAAxOAAEmSxAADQUAAAAAAAA='
Manual I can trigger to learn code, do you think the cause could be that device (rm4c_mini, 0x62be) is missing in Dombroadlink.py file?
(Possible solution mentioned in https://github.com/home-assistant/core/issues/35875 is the need to specify the correct type in the config. Use type: rm4c_mini...)
But first,
you said that your device is a rm4c_mini
but you have a RM2M fle in your log directory with this code on it: 0x2712
this is for the RM2 / RM3 device.
Can you change your plugin settings and select Remote control mini RM4 ?
sudo python broadlink_discovery.py
RM mini 3 discovered as:
###########################################
RM4
# broadlink_cli --type 0x5f36 --host 192.168.1.173 --mac xxxxe0a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x5f36 192.168.1.173 xxxxe0a7df24
Traceback (most recent call last):
File "broadlink_discovery.py", line 24, in <module>
print("temperature = {}".format(device.check_temperature()))
File "/usr/lib/python3.7/broadlink/__init__.py", line 673, in check_temperature
return self._read_sensor( 0x24, 4, 100.0 )
File "/usr/lib/python3.7/broadlink/__init__.py", line 653, in _read_sensor
check_error(response[0x22:0x24])
File "/usr/lib/python3.7/broadlink/exceptions.py", line 97, in check_error
raise exception(error_code)
broadlink.exceptions.StorageError: The device storage is full
RM4c mini:
###########################################
RM4
# broadlink_cli --type 0x62be --host 192.168.1.172 --mac xxxx31a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x62be 192.168.1.172 xxxx31a7df24
temperature = 0.0
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Ok. no problem.JUNA wrote: ↑Tuesday 07 July 2020 9:03
Sorry for the confusion. I have both, I own a rm4c_mini and a RM mini 3. I have been switching between the two models to see if there was a difference. (Strange, since reinstall I cannot see device 0x2712 any more in the log.)
sudo python broadlink_discovery.py
RM mini 3 discovered as:
###########################################
RM4
# broadlink_cli --type 0x5f36 --host 192.168.1.173 --mac xxxxe0a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x5f36 192.168.1.173 xxxxe0a7df24
Traceback (most recent call last):
File "broadlink_discovery.py", line 24, in <module>
print("temperature = {}".format(device.check_temperature()))
File "/usr/lib/python3.7/broadlink/__init__.py", line 673, in check_temperature
return self._read_sensor( 0x24, 4, 100.0 )
File "/usr/lib/python3.7/broadlink/__init__.py", line 653, in _read_sensor
check_error(response[0x22:0x24])
File "/usr/lib/python3.7/broadlink/exceptions.py", line 97, in check_error
raise exception(error_code)
broadlink.exceptions.StorageError: The device storage is full
RM4c mini:
###########################################
RM4
# broadlink_cli --type 0x62be --host 192.168.1.172 --mac xxxx31a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x62be 192.168.1.172 xxxx31a7df24
temperature = 0.0
For the RM3:
looks like your is part of the broadlink bug, maybe see if you can upgrade the firmware (do not know how to do that, I have a RM2 only)
For the RM4:
you have been able to learn manually, so this should work with the plugin.
Put the right settings (RM4) and IP (.172) /mac on the plugin, restart and test.
Let us know.
-
- Posts: 12
- Joined: Tuesday 30 June 2020 17:29
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
zak45, You are a genius! Thank you for your patience.zak45 wrote: ↑Tuesday 07 July 2020 12:32Ok. no problem.JUNA wrote: ↑Tuesday 07 July 2020 9:03
Sorry for the confusion. I have both, I own a rm4c_mini and a RM mini 3. I have been switching between the two models to see if there was a difference. (Strange, since reinstall I cannot see device 0x2712 any more in the log.)
sudo python broadlink_discovery.py
RM mini 3 discovered as:
###########################################
RM4
# broadlink_cli --type 0x5f36 --host 192.168.1.173 --mac xxxxe0a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x5f36 192.168.1.173 xxxxe0a7df24
Traceback (most recent call last):
File "broadlink_discovery.py", line 24, in <module>
print("temperature = {}".format(device.check_temperature()))
File "/usr/lib/python3.7/broadlink/__init__.py", line 673, in check_temperature
return self._read_sensor( 0x24, 4, 100.0 )
File "/usr/lib/python3.7/broadlink/__init__.py", line 653, in _read_sensor
check_error(response[0x22:0x24])
File "/usr/lib/python3.7/broadlink/exceptions.py", line 97, in check_error
raise exception(error_code)
broadlink.exceptions.StorageError: The device storage is full
RM4c mini:
###########################################
RM4
# broadlink_cli --type 0x62be --host 192.168.1.172 --mac xxxx31a7df24
Device file data (to be used with --device @filename in broadlink_cli) :
0x62be 192.168.1.172 xxxx31a7df24
temperature = 0.0
For the RM3:
looks like your is part of the broadlink bug, maybe see if you can upgrade the firmware (do not know how to do that, I have a RM2 only)
For the RM4:
you have been able to learn manually, so this should work with the plugin.
Put the right settings (RM4) and IP (.172) /mac on the plugin, restart and test.
Let us know.
After reinstall setup.py it worked.
- Spoiler: show
-
- Posts: 952
- Joined: Sunday 22 January 2017 11:37
- Target OS: Windows
- Domoticz version: V2024.4
- Contact:
Re: Python Plugin : Broadlink
Great that you have it working.
Do not forget to remove the debug mode !
Do not forget to remove the debug mode !
-
- Posts: 39
- Joined: Friday 19 February 2016 14:47
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
I wish I found this thread 2 days earlier. I got a broadlink mini 3 recently and of course the old plugin does not work with the new version. I had to figure this out the hard way.
I managed to get this plugin installed fairly quickly.
One note not sure if anybody picked up on this yet.
On Debian / Raspbian running python setup.py will run as python2 while python3 setup.py will run as python3. All additional commands inside the script set to run as sudo -H python will also run as python2 therefore I edited the setup.py and changed all lines from sudo -H python to sudo -H python3 and the script ran perfectly. I now have the web interface but I must figure out how to use it. It sure looks pretty..
Thanks for this.
I managed to get this plugin installed fairly quickly.
One note not sure if anybody picked up on this yet.
On Debian / Raspbian running python setup.py will run as python2 while python3 setup.py will run as python3. All additional commands inside the script set to run as sudo -H python will also run as python2 therefore I edited the setup.py and changed all lines from sudo -H python to sudo -H python3 and the script ran perfectly. I now have the web interface but I must figure out how to use it. It sure looks pretty..
Thanks for this.
-
- Posts: 39
- Joined: Friday 19 February 2016 14:47
- Target OS: Raspberry Pi / ODroid
- Domoticz version:
- Contact:
Re: Python Plugin : Broadlink
Though I am able to communicate with my device now I am unable to send commands to it. I imported some codes for my Samsung air conditioner but when I try and send commands I still seem to get device storage full error.
Any pointers?
2020-07-09 19:58:38.423 Error: (BroadLink) Traceback (most recent call last):
2020-07-09 19:58:38.423 File "/home/pi/domoticz/plugins/broadlink/plugin.py", line 1629, in send
2020-07-09 19:58:38.423 DEVICE.send_data(SENDCOMMAND)
2020-07-09 19:58:38.423 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 621, in send_data
2020-07-09 19:58:38.423 check_error(response[0x22:0x24])
2020-07-09 19:58:38.423 File "/usr/local/lib/python3.7/dist-packages/broadlink/exceptions.py", line 97, in check_error
2020-07-09 19:58:38.423 raise exception(error_code)
2020-07-09 19:58:38.423 broadlink.exceptions.StorageError: The device storage is full
2020-07-09 19:58:38.423 Error: (BroadLink) Warning : Code sent ....Probably timeout
Any pointers?
2020-07-09 19:58:38.423 Error: (BroadLink) Traceback (most recent call last):
2020-07-09 19:58:38.423 File "/home/pi/domoticz/plugins/broadlink/plugin.py", line 1629, in send
2020-07-09 19:58:38.423 DEVICE.send_data(SENDCOMMAND)
2020-07-09 19:58:38.423 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 621, in send_data
2020-07-09 19:58:38.423 check_error(response[0x22:0x24])
2020-07-09 19:58:38.423 File "/usr/local/lib/python3.7/dist-packages/broadlink/exceptions.py", line 97, in check_error
2020-07-09 19:58:38.423 raise exception(error_code)
2020-07-09 19:58:38.423 broadlink.exceptions.StorageError: The device storage is full
2020-07-09 19:58:38.423 Error: (BroadLink) Warning : Code sent ....Probably timeout
Who is online
Users browsing this forum: No registered users and 1 guest