RPiLight

1.1.1

24-Hour LED Controller for Raspberry Pi. Aimed at Aquarium Use.
Kaiede/RPiLight

What's New

Binary Packages

2020-03-25T20:37:15Z
  • Binary Packages
  • Swift 5.1.5 Update

Binary packages are back. The binaries built include the Swift runtime libraries needed making it possible to install this as a single debian package. Going forward, users should install the debian package instead of building from source unless they intend to make changes.

Thanks to this, RPiLight will now focus on a single Swift version at a time, since it is now included with the binary release. With this version, Swift 5.1.5 is now the official version.

RPiLight

Actions Status MIT license Swift

An Aquarium Light Controller for the Raspberry Pi

Hardware / OS

Supported

Raspbian Buster on any supported Raspberry Pi (Zero, 1, 2, 3, or 4) is the recommended configuration.

While RPiLight depends on Swift, the binary packages include the needed pre-compiled libraries, and can be installed on a clean Raspberry Pi image.

Experimental

Running on ARM64 Ubuntu 16.04 or 18.04, or Debian Buster is possible, but may have some issues. Generally, this means that hardware LED controllers may be more limited, and access to the PWM hardware on a Raspberry Pi is more locked down. Stick to I2C-based controllers like the PCA9685 or MCP4725 if you can.

Getting Started

These instructions will get you a copy of the project up and running on your local Raspberry Pi. It can be installed from binary, or you can grab source for development purposes.

See the page on Setting up the Raspberry Pi for details.

Installing RPiLight

Grab the latest .deb package from here. You can grab it from the Pi using curl, usually.

Once downloaded you can install it using a command like this, where the final argument is the path to the package:

sudo apt install ./rpilight_1.1.1_armhf.deb

Once installed, you will then need to configure it. Under /opt/rpilight/config it is expected to find a config.yml and schedule.yml file. The first tells RPiLight how you're hardware is setup, while the second contains the light schedule.

Configuration

Examples are in the examples folder.

See Configuring the Light Schedule for full details.

Starting the Daemon

The installer will do most of the work, so you should only need to start it using systemctl, which will control the service:

sudo systemctl start rpilight
sudo systemctl restart rpilight
sudo systemctl stop rpilight

Building From Source

  • Clone the repository on a Raspberry Pi, and then navigate to the directory
  • (One Time Only) bash bootstrap.sh - This will install dependencies needed for development. Specifically, it will download and install the version of Swift currently used for development, and anything else it may need.
  • ./build.sh - This is a wrapper around the Swift build system. It mostly provides a couple functions:
    • It can install a release build on the device using ./build.sh install
    • It can package a release build using ./build.sh package
    • You can add the stable or latest argument to have it fetch the latest tag (stable) or the latest master commit (latest) before building.

Built With

  • Ephemeris - Calculate Moon and Sun positions in Swift.
  • Moderator - A simple, modular command line argument parser in Swift.
  • PCA9685 - PCA9685 I2C Driver for Swift.
  • MCP4725 - MCP4725 I2C Driver for Swift.
  • SingleBoard - Type-safe GPIO Library for single board computers.

Contributing

Please read CONTRIBUTING.md for details on our code of conduct, and the process for submitting pull requests to us.

Authors

  • Adam Thayer - Initial work - Kaiede

See also the list of contributors who participated in this project.

License

This project is licensed under the MIT License - see the LICENSE file for details

Description

  • Swift Tools 5.0.0
View More Packages from this Author

Dependencies

Last updated: Thu Oct 17 2024 21:37:36 GMT-0900 (Hawaii-Aleutian Daylight Time)