update rflink automaticly

433Mhz opensource Receiver & Transmitter.

Moderator: Stuntteam

Post Reply
User avatar
remb0
Posts: 824
Joined: Thursday 11 July 2013 22:21
Target OS: Raspberry Pi
Domoticz version: Beta
Location: The Netherlands
Contact:

update rflink automaticly

Post by remb0 » Thursday 01 December 2016 16:16

I found some nice script to automaticly update the rflink firmware.
https://github.com/roondar/RFLink-update/

who creates an wiki page with a how to?
- install scripts, give execution rights
- create a virtual switch of cronjob that runs update.sh

working of this script:
Creates a directory in RFLink tMP
- download newest version FW stable in / tmp / RFLink /
- Controles if avrdude andJQ are installed, if not: installs it automaticly
- Check the following info" (idx, serial port, name, versions)
- Updates FW


git clone https://github.com/roondar/RFLink-update.git
cd RFLink-update
sh ./update_RFLink.sh


credits to deennoo

deennoo
Posts: 914
Joined: Wednesday 10 December 2014 14:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: update rflink automaticly

Post by deennoo » Thursday 01 December 2016 17:43

Hi there.

This is a part of working script

Please be patiente, stunteam is looking to add it to domoticz for all distro

Original topic was here : https://easydomoticz.com/forum/viewtopi ... =22&t=2832

Maybe you can ask to Roondar him self !

Have you try it ?

.sh files is mine ! thank for it !

.py is Roondar one's

Roondar says that is looking for a better way about this script.

Roondar Python's one is better again, it solve the fw check probleme who existe on the sh one.

You have to install python and some dep : like psutil

On the bash one fw check is flase, and version update is hardcoded

On Python 's one Script check if their really a new fw and then update if necessary

Next big step is to check Domoticz port : actually both script are using port 8080, but syno can use 8084 and some advanced user can use custom port

if you want to help your welcome !

One thing about python :

You have to change :

Code: Select all

l 19 : dry_run = True
to

Code: Select all

l 19 dry_run = False
Last edited by deennoo on Thursday 01 December 2016 17:47, edited 1 time in total.
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / ESP8266 / MQTT / BLE
http://domo-attitude.fr

User avatar
Stuntteam
Posts: 415
Joined: Wednesday 06 May 2015 16:39
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: update rflink automaticly

Post by Stuntteam » Thursday 01 December 2016 17:46

Yeah, wait until the developers of the script are done and everything is properly tested.
Btw, great work Deennoo, Roondar and all the others that are working on it..
-=# RFLink Gateway Development Team #=-
Introduction: http://www.nemcon.nl/blog2/
Generic RFLink Support forum: http://www.esp8266.nu/forum/viewforum.php?f=8

roondar
Posts: 3
Joined: Saturday 25 March 2017 19:05
Target OS: Linux
Domoticz version:
Contact:

Re: update rflink automaticly

Post by roondar » Saturday 25 March 2017 19:10

Hi all,

I just updated my code https://github.com/roondar/RFLink-update
I use it for about 2 months now without issues.

Enjoy. :D

User avatar
Derik
Posts: 1890
Joined: Friday 18 October 2013 23:33
Target OS: Raspberry Pi
Domoticz version: BETA
Location: Arnhem/Nijmegen Nederland
Contact:

Re: update rflink automaticly

Post by Derik » Saturday 25 March 2017 19:23

Can this implement in Domoticz like the Rfxcom?
Or do i need a different script install?
Xu4: Beta Extreme antenna RFXcomE,WU Fi Ping ip P1 Gen5 PVOutput Harmony HUE SolarmanPv OTG Winddelen Alive ESP Buienradar MySensors WOL Winddelen counting RPi: Beta SMAspot RFlinkTest Domoticz ...Different backups

roondar
Posts: 3
Joined: Saturday 25 March 2017 19:05
Target OS: Linux
Domoticz version:
Contact:

Re: update rflink automaticly

Post by roondar » Saturday 25 March 2017 19:45

Derik wrote:Can this implement in Domoticz like the Rfxcom?
Or do i need a different script install?
I don't have any Rfxcom.
The upgrade process of Rfxcom need a particular .exe
So, it won't be compatible with my script.

deennoo
Posts: 914
Joined: Wednesday 10 December 2014 14:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: RE: Re: update rflink automaticly

Post by deennoo » Saturday 25 March 2017 23:07

roondar wrote:
Derik wrote:Can this implement in Domoticz like the Rfxcom?
Or do i need a different script install?
I don't have any Rfxcom.
The upgrade process of Rfxcom need a particular .exe
So, it won't be compatible with my script.
On domoticz running on a pi you can apply update direct from domoticz.


@Derick

Installation script be sure it can be run, then set a virtual pushon and put script://waytoyourscript/updaterflink.py on action ON.

Then set a planning for on every monday at 8:00 and forget it.

Update will be check and apply full auto.
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / ESP8266 / MQTT / BLE
http://domo-attitude.fr

blauwebuis
Posts: 158
Joined: Wednesday 21 December 2016 10:11
Target OS: Raspberry Pi
Domoticz version: current
Contact:

Re: update rflink automaticly

Post by blauwebuis » Sunday 26 March 2017 0:12

Couldn't Domoticz be pre-packaged with lots of scripts (like the presence detection script too), and then manage the running of those scripts by itself, without Crontab? Then Domoticz could offer simple settings-pages for those scripts that set the parameters. Perhaps it could read a list of required parameters from the top of the script.

roondar
Posts: 3
Joined: Saturday 25 March 2017 19:05
Target OS: Linux
Domoticz version:
Contact:

Re: update rflink automaticly

Post by roondar » Sunday 26 March 2017 0:52

blauwebuis wrote:Couldn't Domoticz be pre-packaged with lots of scripts (like the presence detection script too), and then manage the running of those scripts by itself, without Crontab? Then Domoticz could offer simple settings-pages for those scripts that set the parameters. Perhaps it could read a list of required parameters from the top of the script.
Well, it's already implemented in Domoticz with plugins but I think Domoticz dev team couldn't maintain them all.
So, as Deenoo said you can create a dummy button and trigger a script when you want.

@Deenoo
I see the upgrade firmware function in https://github.com/domoticz/domoticz/bl ... Serial.cpp.
My knowledge in C is very limited but, you need to provide a firmware file before upgrade ?

If someone have some link with how to upgrade rfxcom firmware's on Linux, I could be update my script.

deennoo
Posts: 914
Joined: Wednesday 10 December 2014 14:06
Target OS: Linux
Domoticz version: beta
Location: Bordeaux France
Contact:

Re: update rflink automaticly

Post by deennoo » Sunday 26 March 2017 12:57

Yes you have to choose your new Fw to update on rfx config page.

Really not do easy than your script.

Python plugin are still new and some changé have still to be made.

Be patient with this, and as this an open source, you can help if you want, be translate présence détection on domoticz plugin.

Just before think to all aviable possibility :
Hci dongle choice
Update refresh
Ble device auto discover
Lib needed for plugin with auto installation
Etc etc
Domoticz stable 3.5877 for real & Domoticz beta for test
Rfxtrxe / RFLink / Milight / Yeelight / ESP8266 / MQTT / BLE
http://domo-attitude.fr

blauwebuis
Posts: 158
Joined: Wednesday 21 December 2016 10:11
Target OS: Raspberry Pi
Domoticz version: current
Contact:

Re: update rflink automaticly

Post by blauwebuis » Sunday 26 March 2017 14:59

Sorry, I meant shell scripts specifically.

basmaaks
Posts: 4
Joined: Tuesday 17 October 2017 18:55
Target OS: Raspberry Pi
Domoticz version:
Contact:

Re: update rflink automaticly

Post by basmaaks » Tuesday 21 November 2017 14:29

roondar wrote:
Saturday 25 March 2017 19:10
Hi all,

I just updated my code https://github.com/roondar/RFLink-update
I use it for about 2 months now without issues.

Enjoy. :D
Great script, running every night so always up to date, THANKS.

One question, how to modify it so I get an email when your scripts has update the rflink ?

Post Reply

Who is online

Users browsing this forum: Denny64 and 3 guests