GithubHelp home page GithubHelp logo

the-gift / pwnagotchi-plugin-pisugar3 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from taiyonemo/pwnagotchi-plugin-pisugar3

1.0 0.0 0.0 5 KB

pwnagotchi plugin for pisugar 3 UPS

Python 100.00%

pwnagotchi-plugin-pisugar3's Introduction

pwnagotchi-plugin-pisugar3

pwnagotchi plugin for pisugar 3 UPS.

Installation

  1. Enable i2c by running sudo raspi-config select option 3 and enable i2c. You can skip this if you have already enabled I2c to setup a RTC.

  2. use scp to copy the plugin to /usr/local/lib/python3.7/dist-packages/pwnagotchi/plugins/default .

scp pisugar3.py [email protected]:/usr/local/lib/python3.7/dist-packages/pwnagotchi/plugins/default/pisugar3.py
  1. Enable the plugin in /etc/pwnagotchi/config.toml by adding the following line.
main.plugins.pisugar3.enabled = true
  1. Set the percentage that should trigger a power off.
main.plugins.pisugar3.shutdown = 5

TODO

  • Display battery percentage as read from register 0x2a
  • Add provisions for callibrating the value from 0x2a
  • Display battery voltage from 0x22 and 0x23
  • Display charging status. 6th bit from 0x02
  • Safe shutdown using soft switch or powerswitch.
  • Pisugar RTC??

Referaces

https://github.com/evilsocket/pwnagotchi/blob/master/pwnagotchi/plugins/default/ups_lite.py https://github.com/kellertk/pwnagotchi-plugin-pisugar2/blob/main/pisugar2.py https://github.com/PiSugar/PiSugar/wiki/PiSugar-3-Series#%EF%B8%8F-full-functions-ups https://www.tindie.com/stores/pisugar/

pwnagotchi-plugin-pisugar3's People

Contributors

taiyonemo avatar sniffleupagus avatar

Stargazers

 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.