Reef Pi - Help

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
First post, hope this hits the right place. I'm getting this error on my reef-pi...

7/2/2019, 12:26:58 PM UI ERROR {"error":"Failed to create. Error: write /sys/class/pwm/pwmchip0/pwm0/period: invalid argument"} | HTTP 500

I haven't made it past the testing portion to check that my led dims... What am I missing here? I have a pretty limited understanding of this circuitry. Any help is appreciated!
 
Top Shelf Aquatics
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
If I check the HTTPS box, I can't seem to reconnect to reef-pi either, my browser just says there's no connection to that site but connects to others. I'm using hostname.local (with my actual "hostname" reef-bud) over wifi. If I disconnect from wifi I also can not access reef-pi UI while directly connected (not headless....?) Sorry, I'm trying to understand new lingo here.
 

crusso1993

Valuable Member
View Badges
Joined
Oct 21, 2018
Messages
4,362
Reaction score
24,676
Location
Chicago, IL, USA
First off, welcome to R2R!

Secondly, I presently cannot offer you any help other than to tag the creator of reef pi and some very experienced reef pi builders/users. Each one of these people should able to help but, more importantly, are really nice people. The list is in no particular order.
@Ranjib
@Bigtrout
@Tom Bishop
@Michael Lane
@DirtDiggler2823
@AquaRaider44

tenor.gif

#welcometor2r
#welcometoreef2reef
 
Last edited:

DirtDiggler2823

Valuable Member
View Badges
Joined
Jul 31, 2018
Messages
1,443
Reaction score
1,846
Location
Gambrills
Thank you crusso, for the welcome & turning on the "bat signal", much appreciated!
If you can get back into the machine, leave the https box unchecked. Also, what lights are you using? Some lights require an adaptor to work correctly.
 
Top Shelf Aquatics
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
I ended up resetting the database & starting over, leaving the https box unchecked this time. How can I back up the database for future issues? I've tried to copy it (in raspbian gui) & I get an error that it can't open it. After doing that I was able to keep rocking, but I'd like to secure this connection still.

I don't have this on my reef tank yet, just testing it out for the first time. I was following the guides on ada fruit and was unable to successfully complete the led test for the pwm/lighting control part of the guide. (I have 1 green led on a breadboard that came with a raspberry 3b+ starter kit) I wired up the blinking led to test out the equipment just fine, I am confident I have the circuit correct for the pwm test, yet I get this error...

ERROR {"error":"Failed to create. Error: write /sys/class/pwm/pwmchip0/pwm0/period: invalid argument"} | HTTP 500

...when I try to create a jack for pin 0.

I have limited experience, but I have walked thru the guides to get to this point & a little more to get a temp probe & vnc working. But, as I was typing this, I've lost connection to reef-pi again... I'm getting an "unable to connect" thru firefox esr...
 

Ranjib

Valuable Member
View Badges
Joined
Apr 16, 2016
Messages
7,049
Reaction score
12,559
Location
Palo Alto, Bay Area
First post, hope this hits the right place. I'm getting this error on my reef-pi...

7/2/2019, 12:26:58 PM UI ERROR {"error":"Failed to create. Error: write /sys/class/pwm/pwmchip0/pwm0/period: invalid argument"} | HTTP 500

I haven't made it past the testing portion to check that my led dims... What am I missing here? I have a pretty limited understanding of this circuitry. Any help is appreciated!
What version of reef-pi you are using? Theres known bug, which can cause this when you update the rpi pwm frequency. Reboot should resolve this, as long as the pwm freq is set to something invalid.
 

Ranjib

Valuable Member
View Badges
Joined
Apr 16, 2016
Messages
7,049
Reaction score
12,559
Location
Palo Alto, Bay Area
I ended up resetting the database & starting over, leaving the https box unchecked this time. How can I back up the database for future issues? I've tried to copy it (in raspbian gui) & I get an error that it can't open it. After doing that I was able to keep rocking, but I'd like to secure this connection still.

I don't have this on my reef tank yet, just testing it out for the first time. I was following the guides on ada fruit and was unable to successfully complete the led test for the pwm/lighting control part of the guide. (I have 1 green led on a breadboard that came with a raspberry 3b+ starter kit) I wired up the blinking led to test out the equipment just fine, I am confident I have the circuit correct for the pwm test, yet I get this error...

ERROR {"error":"Failed to create. Error: write /sys/class/pwm/pwmchip0/pwm0/period: invalid argument"} | HTTP 500

...when I try to create a jack for pin 0.

I have limited experience, but I have walked thru the guides to get to this point & a little more to get a temp probe & vnc working. But, as I was typing this, I've lost connection to reef-pi again... I'm getting an "unable to connect" thru firefox esr...
stop reef-pi before you copy/move the database,
Code:
sudo systemctl stop reef-pi.service
sudo cp /var/lib/reef-pi/reef-pi.db /home/pi
sudo systemctl start reef-pi.service
And a warm welcome to reef2reef :)
 

Ranjib

Valuable Member
View Badges
Joined
Apr 16, 2016
Messages
7,049
Reaction score
12,559
Location
Palo Alto, Bay Area
regarding the http thing, when you enable https and dont update the address (ip:port), that leaves reef-pi running in https mode while using the normal http port (80), As a result you have to access it like this: https://<your reef-pi ip>:80 . If you change the address to "0.0.0.0:443" , than this should be fixed and you can access reef-pi with just "https://reef-pi-ip" .
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
What version of reef-pi you are using? Theres known bug, which can cause this when you update the rpi pwm frequency. Reboot should resolve this, as long as the pwm freq is set to something invalid.
I'm using 2.4 on a pi 3B+. Is there a safe freq to set it at while testing?
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
What version of reef-pi you are using? Theres known bug, which can cause this when you update the rpi pwm frequency. Reboot should resolve this, as long as the pwm freq is set to something invalid.
I'm using 2.4 on a pi 3B+. Is there a safe freq to set it at while testing?
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
regarding the http thing, when you enable https and dont update the address (ip:port), that leaves reef-pi running in https mode while using the normal http port (80), As a result you have to access it like this: https://<your reef-pi ip>:80 . If you change the address to "0.0.0.0:443" , than this should be fixed and you can access reef-pi with just "https://reef-pi-ip" .
Ok, thank you for the clarification!
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
stop reef-pi before you copy/move the database,
Code:
sudo systemctl stop reef-pi.service
sudo cp /var/lib/reef-pi/reef-pi.db /home/pi
sudo systemctl start reef-pi.service
And a warm welcome to reef2reef :)
Thanks again Ranjib, your expertise is a welcome sight for someone new to all of this!
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
So I reset the database and put in the proper address for https, all good there. I have access to reef-pi again. While I was rebuilding, I got the same error for the PWM after creating a new jack for it. Is this due to using 2.4, and should I upgrade to 3.0?

If so, do I save the work I've done to rebuild it by copying the database file like above?
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
Hey thanks for asking, it's coming along. I have gathered more parts for the build & wanted to go with a pi zero wh. After downloading the latest release onto the 3b+ I was back on track, thanks again for that. I am having a hard time updating the pi zero using the command line. Could you post what I should type there exactly, for the zero? Sorry, I'm out of my element here & your help is appreciated here. What you guys are doing here is quite admirable.
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
Alright I've figured my way thru by using the browser on the Rpi zero itself to download the latest release & install it. I actually didn't expect it to be that easy. I'm still curious about using the command line instead & what I would have to punch in there. So, I'm back to square one on filling in connectors, equipment etc but I'm getting that part down if nothing else lol. This has been a fun challenge to learn!
 

Ryan115

Well-Known Member
View Badges
Joined
Dec 28, 2010
Messages
582
Reaction score
1,076
Location
Mississippi
Alright I've figured my way thru by using the browser on the Rpi zero itself to download the latest release & install it. I actually didn't expect it to be that easy. I'm still curious about using the command line instead & what I would have to punch in there. So, I'm back to square one on filling in connectors, equipment etc but I'm getting that part down if nothing else lol. This has been a fun challenge to learn!
You said that you used the browser on the pi zero? Are you running the fill install with the Raspbian GUI? If so, it is recommended to run on the lite version of Raspbian when running on the zero, as it can be too much for that system to do both the GUI and reef-pi.
 
OP
ReefLuck1123

ReefLuck1123

Member
View Badges
Joined
Jul 1, 2019
Messages
15
Reaction score
26
I'm going to say yes... It's raspbian buster with desktop, but not including recommended software.
 

Do you have a local "hobby" friend you can call on when you need them?

  • YES

    Votes: 161 34.9%
  • No

    Votes: 90 19.5%
  • I wish!

    Votes: 210 45.6%

Online statistics

Members online
1,379
Guests online
3,014
Total visitors
4,393
Top