Coder Social home page Coder Social logo

alfrodull's Introduction

Alfrodull

Alfrodull is a utility that controls lights based on the a computers events.

The lights can be turned off when the computer sleepd, and turn on when the computer wakes up. The original use case was to attach an led strip behind the monitor that turn on and off as the display does. But much more can be doen as additional events can easily be added. For example blinking the lights when notifications are received or tracking CPU usage and warning when it passes a threshold.

Right now the only supported devices are those from blinksticks. More can be added if requested and I can get ahold of them.

Alfrodull only works on Linux right now as all of the events uses DBUS notifications to react to events. Support for Windows could be added in the future but would require some other notification service.

Install

pip install alfrodull

Usage

Simply start alfrodull and pass a configuration file path as input.

alfrodull config.yml

Alfrodull could for example be started in xinit or i3wm config.

Configuration

Alfrodull is configured with a file, this is where the event, animation and, color are specified. Colors are defined as hex values ex. #ff00ff, the values will be checked when the program is started and throw an exception if they can't be parsed. Passing a null value to the color is parsed as turning off the lights. Below are the currently supported events and animations that can be used.

Event Description
Init After the applicationn is first run
Shutdown Before the computer turns off
Sleep Before the computer goes to sleep
Wakeup After the computer wakes up
Effect Description
Fade Fades from the current color or if the color is null turn off.
Outside In Starts from the outside and changes light one by one to the inside.
Inside Out Opposite of Outside In.
device: blinkstick
events:
  - type: "Init"
    animation:
      type: "Fade"
      color: "#ffffff"
  - type: "Sleep"
    animation:
      type: "Inside Out"
      color: "#000000"
  - type: "Wakeup"
    animation:
      type: "Outside In"
      color: "#ffffff"

License

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

alfrodull's People

Contributors

phillebaba avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.