reef-pi :: An opensource reef tank controller based on Raspberry Pi.

OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Yes, after every change to the config, the reef-pi service was restarted.

Code:
pi@raspberrypi:/etc/reef-pi $ journalctl -u reef-pi.service
-- Logs begin at Wed 2017-08-23 19:26:19 UTC, end at Wed 2017-08-23 23:39:44 UTC. --
Aug 23 23:36:55 raspberrypi systemd[1]: Started raspberry pi based reef tank controller.
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 DB: reef-pi.db
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for temperature bucket
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: temperature
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting temperature controller
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: lightings
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for timers bucket
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting lighting cycle
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: timers
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: camera
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for system bucket
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: system
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Equipment sub-system: Running in dev mode, skipping gpio initializatio
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: equipments
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Image directory:
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting http server at: localhost:8080
Aug 23 23:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 reef-pi is up and running
reef-pi is still listening to localhost. It can be either a configuration file formatting issue or the parameter is not present in the right place,, what version of reef-pi you are using? `reef-pi -version`
 

Mr_Robot

Community Member
View Badges
Joined
Aug 16, 2017
Messages
26
Reaction score
30
Rating - 0%
0   0   0
reef-pi is still listening to localhost. It can be either a configuration file formatting issue or the parameter is not present in the right place,, what version of reef-pi you are using? `reef-pi -version`

0.0.7-23-g3cce498
Should be the latest version available on git, unless you keep git REALLLY up to date.

I've tried encapsulating the IP : port in quotes, and without (I saw an example without quotes in the guide, so I gave it a shot.)
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Whoa :-) ... i know what it is.. I am changing lot of code, so master config parsing is changed than the older releases
Can you specify address under `api` key. and restart reef-pi? something like this:
```
---
api:
address: 0.0.0.0:8088
```
 

Mr_Robot

Community Member
View Badges
Joined
Aug 16, 2017
Messages
26
Reaction score
30
Rating - 0%
0   0   0
Whoa :) ... i know what it is.. I am changing lot of code, so master config parsing is changed than the older releases
Can you specify address under `api` key. and restart reef-pi? something like this:
```
---
api:
address: 0.0.0.0:8088
```
Same results.
I noticed that there were two instances of 'db:' as well, so I deleted the occurance at the top of the file, and left the occurance above 'api:'

Code:
pi@raspberrypi:/etc/reef-pi $ journalctl -u reef-pi.service
-- Logs begin at Wed 2017-08-23 14:26:19 CDT, end at Wed 2017-08-23 19:12:40 CDT. --
Aug 23 18:36:55 raspberrypi systemd[1]: Started raspberry pi based reef tank controller.
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 DB: reef-pi.db
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for temperature bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: temperature
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting temperature controller
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: lightings
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for timers bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting lighting cycle
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: timers
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: camera
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for system bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: system
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Equipment sub-system: Running in dev mode, skipping gpio initialization
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: equipments
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Image directory:
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting http server at: localhost:8080
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 reef-pi is up and running
Aug 23 19:10:27 raspberrypi systemd[1]: Stopping raspberry pi based reef tank controller...
Aug 23 19:10:27 raspberrypi systemd[1]: Stopped raspberry pi based reef tank controller.
Aug 23 19:12:27 raspberrypi systemd[1]: Started raspberry pi based reef tank controller.
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 DB: reef-pi.db
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: lightings
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: timers
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: camera
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: system
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Equipment sub-system: Running in dev mode, skipping gpio initialization
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: equipments
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: temperature
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Image directory:
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Starting http server at: localhost:8080
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 Starting lighting cycle
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 Starting temperature controller
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 reef-pi is up and running

Code:
pi@raspberrypi:/etc/reef-pi $ cat config.yml
---
system:
  enable: true
  interface: en0
  display: false
  dev_mode: true
  name: controller
equipments:
  enable: true
  dev_mode: true
  outlets:
    AC1:
      pin: 12
    AC2:
      pin: 13
lighting:
  enable: true
  dev_mode: true
  jacks:
    SingleChannel:
      pins:
        - 24
    DoubleChannel:
      pins:
        - 21
        - 23
camera:
  enable: true
timers:
  enable: true
ato:
  enable: false
  dev_mode: true
  sensor: 12
  check_interval: 5
  control: true
  pump: 16
temperature:
  enable: true
  min: 77
  max: 79
  check_interval: 60
  heater: 14
  cooler: 17
adafruitio:
  enable: false
  token: xxx
  user: xxx
  feed: temperature
enable_gpio: true
enable_pwm: true
database: "reef-pi.db"
api:
address: 0.0.0.0:8080
enable_auth: false
auth:
  id: 35adsjfaksjfdhks5eun435b.apps.googleusercontent.com
  secret: adqwieuqiwue
  callback_url: http://localhost:8088/auth/callback/google
  domain: example.com
  users:
    - foobar
  gomni_auth_secret: sadfhsadfkh238asdf
image_directory: /var/lib/reef-pi/images
interface: enxb827ebf47fe0
display: false
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Same results.
I noticed that there were two instances of 'db:' as well, so I deleted the occurance at the top of the file, and left the occurance above 'api:'

Code:
pi@raspberrypi:/etc/reef-pi $ journalctl -u reef-pi.service
-- Logs begin at Wed 2017-08-23 14:26:19 CDT, end at Wed 2017-08-23 19:12:40 CDT. --
Aug 23 18:36:55 raspberrypi systemd[1]: Started raspberry pi based reef tank controller.
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 DB: reef-pi.db
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for temperature bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: temperature
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting temperature controller
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: lightings
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for timers bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting lighting cycle
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: timers
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: camera
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Initializing DB for system bucket
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: system
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Equipment sub-system: Running in dev mode, skipping gpio initialization
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Successfully started subsystem: equipments
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Image directory:
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 Starting http server at: localhost:8080
Aug 23 18:36:56 raspberrypi reef-pi[15865]: 2017/08/23 23:36:56 reef-pi is up and running
Aug 23 19:10:27 raspberrypi systemd[1]: Stopping raspberry pi based reef tank controller...
Aug 23 19:10:27 raspberrypi systemd[1]: Stopped raspberry pi based reef tank controller.
Aug 23 19:12:27 raspberrypi systemd[1]: Started raspberry pi based reef tank controller.
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 DB: reef-pi.db
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: lightings
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: timers
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: camera
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: system
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Equipment sub-system: Running in dev mode, skipping gpio initialization
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: equipments
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Successfully started subsystem: temperature
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Image directory:
Aug 23 19:12:27 raspberrypi reef-pi[17316]: 2017/08/23 19:12:27 Starting http server at: localhost:8080
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 Starting lighting cycle
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 Starting temperature controller
Aug 23 19:12:28 raspberrypi reef-pi[17316]: 2017/08/23 19:12:28 reef-pi is up and running

Code:
pi@raspberrypi:/etc/reef-pi $ cat config.yml
---
system:
  enable: true
  interface: en0
  display: false
  dev_mode: true
  name: controller
equipments:
  enable: true
  dev_mode: true
  outlets:
    AC1:
      pin: 12
    AC2:
      pin: 13
lighting:
  enable: true
  dev_mode: true
  jacks:
    SingleChannel:
      pins:
        - 24
    DoubleChannel:
      pins:
        - 21
        - 23
camera:
  enable: true
timers:
  enable: true
ato:
  enable: false
  dev_mode: true
  sensor: 12
  check_interval: 5
  control: true
  pump: 16
temperature:
  enable: true
  min: 77
  max: 79
  check_interval: 60
  heater: 14
  cooler: 17
adafruitio:
  enable: false
  token: xxx
  user: xxx
  feed: temperature
enable_gpio: true
enable_pwm: true
database: "reef-pi.db"
api:
address: 0.0.0.0:8080
enable_auth: false
auth:
  id: 35adsjfaksjfdhks5eun435b.apps.googleusercontent.com
  secret: adqwieuqiwue
  callback_url: http://localhost:8088/auth/callback/google
  domain: example.com
  users:
    - foobar
  gomni_auth_secret: sadfhsadfkh238asdf
image_directory: /var/lib/reef-pi/images
interface: enxb827ebf47fe0
display: false
You have indentation error, address is a key under api, let me use the fancy formatting here

Code:
api:
   address: "0.0.0.0:8080"
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Im using the pi3. Im getting ready to work on my led controller maybe tonight. I got all my stuff in today.
reef-pi master just went through whole lotta changes.. it might have some bug, do let me know if you encounter any issues. If I am not responding, please checkout the 0.0.7 tag and build from there. thats more tested release
 

Mr_Robot

Community Member
View Badges
Joined
Aug 16, 2017
Messages
26
Reaction score
30
Rating - 0%
0   0   0
You have indentation error, address is a key under api, let me use the fancy formatting here

Code:
api:
   address: "0.0.0.0:8080"

It worked, Thanks for the advice!
Here's where I keep my mouth shut :)
Agreed, YAML's indentation is important. However, is address: related to api: ? By my logic, shouldnt it be located under the "system -" header?
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
It worked, Thanks for the advice!
Here's where I keep my mouth shut :)
Agreed, YAML's indentation is important. However, is address: related to api: ? By my logic, shouldnt it be located under the "system -" header?
PR welcome :-)
 

HM3105

Well-Known Member
View Badges
Joined
Nov 30, 2014
Messages
665
Reaction score
403
Location
United States
Rating - 0%
0   0   0
Right there with you. Really important to get the build guides fleshed out. When i start loading my pi, I will take step by step notes and then submit them on github. Do you remember the steps you went through

I have my pi but don't have my ttl to usb cable...stuck like chuck until I get that... I may be wrong but my feeling is that we can make the install guides good enough that Ranjib won't have answer too many questions...so far Mr robot used a pi b and I think someone used a pi zero...maybe brad... if we can get all that info in the install guides it will help others and free up Ranjib to code....just my opinion though

I'm relatively recent to the install and process. Mine's been running a few weeks and I'm building an electrical bar. I remember most of everything I did to get it going. It was actually pretty straight forward, if there is anything I can contribute I'll be glad to help.
 

Cary

Well-Known Member
View Badges
Joined
Feb 19, 2016
Messages
638
Reaction score
766
Location
Allen, Tx
Rating - 0%
0   0   0
I'm relatively recent to the install and process. Mine's been running a few weeks and I'm building an electrical bar. I remember most of everything I did to get it going. It was actually pretty straight forward, if there is anything I can contribute I'll be glad to help.

It might be helpful if you offered suggestions or hints based on your experiences for everyone in the thread to see.
 

Cary

Well-Known Member
View Badges
Joined
Feb 19, 2016
Messages
638
Reaction score
766
Location
Allen, Tx
Rating - 0%
0   0   0
Not too much. I would appreciate any help around documentation :)
Let me know what you need from me? I can add a place holder page that you can use as example, I have a few words in mind for the gloassary .. reef-pi's website is README tells about how to add anything in the website: https://github.com/reef-pi/website

right now this information is scattered across guides. Like the cron/timer details can be found here: https://reef-pi.github.io/general-guides/timer/
similarly, various electronics parts is somewhat mentioned here: https://reef-pi.github.io/general-guides/electronics/

I would love to get all of your feedback on how to best organize the documents.. as you know first hand the challenges in assembly.

Ranjib, If you could start a page for glossary it would be great. That way I can to a pull. I have started a text document without any formatting except carriage returns, will that work? What terms would you like to add to the list?..

As to feedback on the general guides, I think they are fine. Though the Electronic components link might be separated under a different heading called "Possible Reef-Pi Components", or something like that, but still in General Guides; maybe at the top. What do you think about that?
 
OP
OP
Ranjib

Ranjib

7500 Club Member
View Badges
Joined
Apr 16, 2016
Messages
9,876
Reaction score
16,682
Location
Pleasant Hill, Concord
Rating - 0%
0   0   0
Ranjib, If you could start a page for glossary it would be great. That way I can to a pull. I have started a text document without any formatting except carriage returns, will that work? What terms would you like to add to the list?..

As to feedback on the general guides, I think they are fine. Though the Electronic components link might be separated under a different heading called "Possible Reef-Pi Components", or something like that, but still in General Guides; maybe at the top. What do you think about that?
Done. glossary web page: https://reef-pi.github.io/general-guides/glossary/
Corresponding markdown file: https://raw.githubusercontent.com/reef-pi/website/master/content/general-guides/glossary.md . Send changes against this file/repo
 

TOP 10 Trending Threads

DO YOU THINK TECHNOLOGICAL ADVANCEMENTS ARE MORE HELPFUL OR HURTFUL TO REEFING?

  • More helpful.

    Votes: 51 41.8%
  • More hurtful.

    Votes: 5 4.1%
  • I think it depends mostly on the technology.

    Votes: 48 39.3%
  • I think it dependsmostly on the reefer behind the technology.

    Votes: 36 29.5%
Back
Top
Home
Post thread…
Market
What's new