Skip to content

Use single LED to indicate download/upload#1

Open
ayufan wants to merge 1 commit into
ddrown:masterfrom
ayufan-research:master
Open

Use single LED to indicate download/upload#1
ayufan wants to merge 1 commit into
ddrown:masterfrom
ayufan-research:master

Conversation

@ayufan
Copy link
Copy Markdown

@ayufan ayufan commented Nov 20, 2016

This uses single LED for presenting download and upload:

  1. red: download saturated,
  2. green: download/upload OK,
  3. blue: upload saturated,
  4. magenta: download/upload saturated.

@BuloZB
Copy link
Copy Markdown

BuloZB commented Nov 20, 2016

thanks for this

@Jan357
Copy link
Copy Markdown

Jan357 commented Nov 20, 2016

I like this! Thanks. 👍

@ddrown
Copy link
Copy Markdown
Owner

ddrown commented Nov 20, 2016

I want to split out setting the LEDs from gathering the data. This way, people can customize what leds mean what.

@ddrown
Copy link
Copy Markdown
Owner

ddrown commented Nov 21, 2016

I've changed how this works in e88f248

This project now has an external config file, /etc/config/omnia-led-colors

The example config file still uses the lan0/wan LEDs:

config led wan
        option colorfunction 'bandwidth'
        option interface 'eth1'
        option direction 'in'
        option limit 300000000

config led lan0
        option colorfunction 'bandwidth'
        option interface 'eth1'
        option direction 'out'
        option limit 20000000

But I've created a new colorfunction "dualbandwidth" along your lines. Upload above 50% sets the color to blue, below 50% the color is set by the download speed. This example sets the wan LED.

config led wan
       option colorfunction 'dualbandwidth'
       option interface 'eth1'
       option limit_in 300000000
       option limit_out 20000000

This way you can customize what colors are set and when. Using a uci config file means a LuCI module could be created to manage these settings.

ddrown pushed a commit that referenced this pull request Sep 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants