Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Getting updated reef-pi code from JFReyes
#1
Rob has generously offered to host my updated reef-pi distribution. While I strive to do my best, there are no guarantees. The current version is listed at the bottom of this post.

These are the instructions for Raspberry Pi:

1. Open a terminal session to your Raspberry Pi (I use PuTTY).

2. Make a backup copy of reef-pi-*.deb (usually in your /home/ directory. Also make a backup copy of the database, usually located at /var/lib/reef-pi/reef-pi.db. I believe @ranjib recently added a utility to do such backups but am unsure if they're in the latest official release, please check here.

3. Download the JFReyes release:
Code:
$ sudo wget https://robo-tank.ca/reef-pi/<name of the release version>.deb

4. Make sure your tank can withstand a few minutes without the controller, then remove the currently installed version:

$ sudo apt-get remove -y --purge reef-pi

5. The uninstall process should not have removed the current database. Next, proceed to install the new version:

Code:
$ sudo dpkg -i <name of the release version>.deb


6. That's it. In a few seconds, reload the webpage and the new version should be available.

7. As of 12-Nov-2020, the <name of the release version> is: reef-pi-3.5-3-gcb3d634-MODIFIED.

Hope y'all like it.
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 1 user Likes JFReyes's post:
  • Rob F
Reply to top
#2
Thanks for sharing, works good.
Reply to top
#3
For the absolute Luddites like myself, please can you share the correct commands for making the backup of the database.

Just so I am certain I have that correct.
Reply to top
#4
(11-15-2020, 01:43 AM)Dewd Wrote: For the absolute Luddites like myself, please can you share the correct commands for making the backup of the database.

Just so I am certain I have that correct.

Hi Dewd:

As things stand currently with reef-pi, a backup is a simple file copy. Hopefully the reef-pi core team will release a true backup utility. Until then, you can back up the database as follows.

From your home directory, type:

$ sudo cp /var/lib/reef-pi/reef-pi.db reef-pi.db.bak

(or whatever extra extension you want to use after .db)
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
Reply to top
#5
(11-15-2020, 06:12 PM)JFReyes Wrote: Hi Dewd:

As things stand currently with reef-pi, a backup is a simple file copy. Hopefully the reef-pi core team will release a true backup utility. Until then, you can back up the database as follows.

From your home directory, type:

$ sudo cp /var/lib/reef-pi/reef-pi.db reef-pi.db.bak

(or whatever extra extension you want to use after .db)

I've seen talk that a backup utility could be added soon.
Reply to top
#6
(11-15-2020, 08:13 PM)Rob F Wrote:
(11-15-2020, 06:12 PM)JFReyes Wrote: Hi Dewd:

As things stand currently with reef-pi, a backup is a simple file copy. Hopefully the reef-pi core team will release a true backup utility. Until then, you can back up the database as follows.

From your home directory, type:

$ sudo cp /var/lib/reef-pi/reef-pi.db reef-pi.db.bak

(or whatever extra extension you want to use after .db)

I've seen talk that a backup utility could be added soon.

I asked a long time ago for the ability to send a backup file to yourself via email.  Should be easy to do. File should be small.  Even the ability to schedule backups via timers.
Reply to top
#7
That's a good idea Dewd. I don't know about easy, though. I'll look into it, thanks.
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
Reply to top
#8
Found 1 issue with this update   I am adding ORP, Conductivity and such to the PH probe as a input file
when I try to set the limit LOW and HIGH for the graphing it wont allow me to add greater than 14 in the high but lets any # in the low .

what build code did you use from github   I can update it on my side since I now have the Dev environment up and running and want to start with your repo to continue building out my functionality
Reply to top
#9
(11-17-2020, 02:55 PM)kfialkowski Wrote: Found 1 issue with this update   I am adding ORP, Conductivity and such to the PH probe as a input file
when I try to set the limit LOW and HIGH for the graphing it wont allow me to add greater than 14 in the high but lets any # in the low .

what build code did you use from github   I can update it on my side since I now have the Dev environment up and running and want to start with your repo to continue building out my functionality

Hi:

I haven't considered parameters other than pH so I put 14 as the high limit for that reason. Thanks for letting me know about these issues.

I cloned the original master branch from the official reef-pi repository and then in my local environment created a branch called uichanges, which I'm pushing to my repository. It's been a couple of weeks since then so the upstream master branch has changed a little bit but from what I've seen it doesn't affect the UI changes I'm doing. I reckon that if you clone my uichanges branch you'll get my changes as well as the master branch as it existed until a few weeks ago. It remains to be seen how will I incorporate future changes to the source master branch into my repo.
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
Reply to top
#10
I just sent the latest version of reef-pi-3.5-3-gcb3d634-MODIFIED.deb for Rob to host. The only changes are sorted lists by name for the Equipment/Timers/Lights/Temperature/etc. tabs. The sorting order is ASCII alphanumeric: (space)[0-9][A-Z..a-z]. Devise a sensible naming convention and if you need further ordering then use numbers, e.g.

1. KH Daily Dosing (Morning)
2. KH Daily Dosing (Noon)
3. KH Daily Dosing (Evening)
4. KH Daily Dosing (Night)

Beware of spaces as they're invisible but do count as a character to sort so they can screw up the ordering.

Hope it's useful.

Regards,
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 2 users Like JFReyes's post:
  • Dewd, Rob F
Reply to top
#11
(11-17-2020, 10:55 AM)JFReyes Wrote: That's a good idea Dewd. I don't know about easy, though. I'll look into it, thanks.

In my case I get reef-pi alerts sent via e-mail.  So I (probably foolishly) thought it should be quite easy to send a copy of the database in the same was as reef-pi send a preconfigured message to the pre-defined email address.  Then schedule it with a timer.


These things are never as easy in real life as they seem in my mind.
Reply to top
#12
Hi all:

I just sent Rob the latest version and it's called reef-pi-4.0-6-gbdd8708-MODIFIED.deb.

This release is a minor but important update. Except for an updated About page it doesn't contain any new features nor bug fixes on my part. However, I merged the upstream 4.0 version into it to maintain compatibility with the official release. Therefore it does include the (IMHO) minor changes in the latest 4.0 version.

Thanks,
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 2 users Like JFReyes's post:
  • Dewd, Rob F
Reply to top
#13
I've just got round to updating to @JFReyes Modified Reef-pi, So I'm on 4.0 with the ability to specify chart ranges. It is fantastic! Very happy.

If I may suggest one or two mods to consider for the future........

1) The ability to specify the chart ranges in fractions. For example my pH - Only really needs to display 7.5 to 8.5, but I get the message that the range must me integer values, so I have set it to display 7 to 9. Not a big deal actually, but something to consider.

2) In 4.0, Ranjib did something to fix Adafruit IO integration. I used to constantly sit with 40+ errors in reef-pi, mostly relating to AIO. Updating to 4.0 fixed that. Updating to 4.0 MODIFIED sees those errors are back.

3) The 4.0 features of the Database export and updating through the UI are gone in 4.0 MODIFIED. Reef-pi reports that my version is 4.0-6-gbdd8708-MODIFIED, but a few of the 4.0 features aren't there, so is it technically still 3.XX where those features are concerned? I see other 4.0 features like the "Journal" tab (which doesn't work yet) are present.

4) Updating - In version 4.0, Ranjib added the feature to update reef-pi within the UI on the same page you can expo, and I see you have to put in the version you want to upgrade to (3.5, 4.0 etc etc) It would be really nice if you could drop the link to the update file in that box and have it update to whatever file you point it to.

Anyway, I'm really happy with the graphs, just throwing out where my head went with ideas and what I have seen.

Thanks for the great work.
[-] The following 1 user Likes Dewd's post:
  • JFReyes
Reply to top
#14
Hello:

Thank you @Dewd for discovering my mistake with the last release as it lacked the 4.0 features. I just fixed that.

The new release is reef-pi-4.0-10-gd159b10-MODIFIED.deb.


As for @Dewd's suggestions:

1) I'll look into using fractional values for the chart limits but it could be tricky due to using floating point numbers; they're always a pain to handle without a lot of error checking logic.

4) I don't want to hard code the update file's location but I could probably add a user changeable setting whose default value would be Rob's server (with his permission, of course) and that setting would display as a link in the About page. I'll need some time to study @Ranjib's logic to figure out a compatible solution.

Thanks,
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 1 user Likes JFReyes's post:
  • Dewd
Reply to top
#15
Thanks Jose'

About the above.... 1) isn't really a thing that is necessary - particularly if it is tricky - Maybe a note at the window saying "whole values only"

4) My thinking was Rob would still host his file wherever, and reef-pi could host their's wherever too. So a blank box where you drop in the url of the file you want to update to. So if they want to update to your version, they would copy and paste https://robo-tank.ca/reef-pi/reef-pi-4.0...DIFIED.deb in and https://github.com/reef-pi/reef-pi/relea....0-pi3.deb if you want "Normal" reef-pi. Just strikes me as a better way than than the version no - but I understand it all depends on how the code is written, and I also understand why Ranjib did it that way - to try keep "alliegence" to the original fork.

Going to update my reef-pi again now.

(11-18-2020, 04:02 PM)JFReyes Wrote: I just sent the latest version of reef-pi-3.5-3-gcb3d634-MODIFIED.deb for Rob to host. The only changes are sorted lists by name for the Equipment/Timers/Lights/Temperature/etc. tabs. The sorting order is ASCII alphanumeric: (space)[0-9][A-Z..a-z]. Devise a sensible naming convention and if you need further ordering then use numbers, e.g.

1. KH Daily Dosing (Morning)
2. KH Daily Dosing (Noon)
3. KH Daily Dosing (Evening)
4. KH Daily Dosing (Night)

Beware of spaces as they're invisible but do count as a character to sort so they can screw up the ordering.

Hope it's useful.

Regards,

Jose'

So am I correct in assuming that it only sorts on the numbers 0-9 and not, say 10?  I've just numbered equipment 1-15 and it puts 10 immediately after 1, so 1, 10, 2, 3.......

OK  Solved it.  Renumbered 01, 02, 03, etc and it sorted 10 to the correct position.

Very happy to be able to order items like this.
Reply to top
#16
(12-01-2020, 12:03 AM)Dewd Wrote: Jose'

So am I correct in assuming that it only sorts on the numbers 0-9 and not, say 10?  I've just numbered equipment 1-15 and it puts 10 immediately after 1, so 1, 10, 2, 3.......

OK  Solved it.  Renumbered 01, 02, 03, etc and it sorted 10 to the correct position.

Very happy to be able to order items like this.

Hmm, the function I chose for sorting *should* have handled the "natural sort" correctly, with 10 after 9 and not after 1; leading zeroes will always work. Will look into it. Thanks again Dewd!
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
Reply to top
#17
(12-01-2020, 03:41 AM)JFReyes Wrote: Hmm, the function I chose for sorting *should* have handled the "natural sort" correctly, with 10 after 9 and not after 1; leading zeroes will always work. Will look into it. Thanks again Dewd!

I think 1, 10, 2 is "natural sort" order.
Reply to top
#18
(12-01-2020, 03:41 PM)Rob F Wrote:
(12-01-2020, 03:41 AM)JFReyes Wrote: Hmm, the function I chose for sorting *should* have handled the "natural sort" correctly, with 10 after 9 and not after 1; leading zeroes will always work. Will look into it. Thanks again Dewd!

I think 1, 10, 2 is "natural sort" order.

Sorry, I beg to differ but no, it isn't... People don't count that way, computers do. No worries, I just found out the exact options I have to pass to the function and a fix is coming in the next release.

It will also include a "hook" to an experimental feature where the Equipment bar chart on the Dashboard can be replaced with an actual control panel where you can click or tap on the equipment's button to turn it on or off. You can also choose the regular bar chart instead. It will not be ready for prime time soon because it's new stuff for me so it'll take some time.

Regards,
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 1 user Likes JFReyes's post:
  • Dewd
Reply to top
#19
Sorry, I was wrong, it's sorting alphanumeric.
Reply to top
#20
Greetings:

The latest version is reef-pi-4.0-12-g1138073-MODIFIED.deb.

It fixes the name sorting so now it applies a "natural sort". It also includes a new, experimental feature called "Equipment Control Panel"; what it does is present the equipment switches in a panel on the dashboard so one doesn't have to click/tap the Equipment tab to turn things on/off. Activate it the same way as the regular bar chart, which is still available.

As always, there are no guarantees but your feedback is always appreciated.

Regards,


Attached Files Image(s)
   
José

Please post questions in the forum (not via PM) so that everyone can benefit from and contribute to finding solutions. Thank you.
[-] The following 2 users Like JFReyes's post:
  • Dewd, Rob F
Reply to top


Possibly Related Threads…
Thread Author Replies Views Last Post
  Two issues: Failed to init I2C & Reef-pi.service not Binding BlakeD 6 2,195 05-12-2023, 10:36 PM
Last Post: Rob F
  Code changes / repo mginster 1 1,262 10-21-2022, 07:20 PM
Last Post: Rob F
  Reef-Pi or Robo-Tank 6.x Wolfw28 6 2,772 09-01-2022, 01:11 AM
Last Post: Rob F
  reef-pi with v2 controller gandalf 1 1,436 04-06-2022, 12:48 PM
Last Post: Rob F

Forum Jump:

Current time: 03-28-2024, 06:06 AM