Giter Site home page Giter Site logo

agan_brightness_x230_x330's Introduction

X330 X230 agan FHD/2K Linux brightness adjustment

X330 X230 FHD/2K 阿甘套件 亮度调节linux程序

GPL licensed

A work-in-progress.

Programme is written using native USB HID library available since probably since the inception of the Linux kernel so no driver is needed. All modern distros should be able to compile normally (macOS probably works as well, not sure how well it runs though).

Simple explanation: Programme interfaces with the onboard USB HID device. Commands are sent to the USB HID device to adjust brightness. Programme is fully commented.

一个非常简单的亮度调节程序,基于系统自带USB library。只在linux测试,黑苹果应该也可以,但本人没测试过不知道能不能用。以后还会加入systemd自动生成脚本,以及inotify来实现快捷键调节。 使用非常简单:

Compile it first先编译:

make

Run it运行:

sudo ./script //change brightness to 15 (max) 亮度调至最高
sudo ./script 0 //change brightness to 0 (lowest brightness level) 亮度调至0(最低亮度)
sudo ./script 15 //change brightness to 15 (highest brightness level) 亮度调至15(最高亮度)

To-do:

  • Implement this with ACPI calls so the script can be as portable as possible.

agan_brightness_x230_x330's People

Contributors

xy-tech avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 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.