Difference between revisions of "X750 Sofrware"
(Created page with "{{GD Template Impl}} '''1. Enabled I2C support on the Raspbia.''' <pre> sudo raspi-config </pre> Select 5 Interfacing Options and then P5 I2C - Enable/Disable automatic load...") |
|||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
{{GD Template Impl}} | {{GD Template Impl}} | ||
+ | NOTE: The following operation is tested base on 2020-05-27-raspios-buster-full-armhf.img. | ||
+ | |||
'''1. Enabled I2C support on the Raspbia.''' | '''1. Enabled I2C support on the Raspbia.''' | ||
Line 22: | Line 24: | ||
sudo bash <nowiki>x750.sh</nowiki> | sudo bash <nowiki>x750.sh</nowiki> | ||
+ | |||
+ | This command will gernerate a new x750ups.py in the current path, in generay, the current path is /pi/home, please remember this path, you will use this file soon. | ||
'''5. Setting up the command to turn off X750 from software''' | '''5. Setting up the command to turn off X750 from software''' | ||
Line 30: | Line 34: | ||
'''6. Test the safe shutdown command''' | '''6. Test the safe shutdown command''' | ||
− | + | x750off | |
'''7. How to read the battery voltage and percentage?''' | '''7. How to read the battery voltage and percentage?''' | ||
− | sudo | + | sudo python <nowiki>x750ups.py</nowiki> |
+ | |||
+ | NOTE: you can use the following command to search x750ups.py file if you don't know where this file is; | ||
+ | |||
+ | sudo find / -name x750ups.py | ||
<!--Add review function! --> | <!--Add review function! --> |
Latest revision as of 17:38, 20 June 2020
NOTE: The following operation is tested base on 2020-05-27-raspios-buster-full-armhf.img.
1. Enabled I2C support on the Raspbia.
sudo raspi-config
Select 5 Interfacing Options and then P5 I2C - Enable/Disable automatic loading. A prompt will appear asking Would you like the ARM I2C interface to be enabled?, select "Yes"
2. Install I2C-tools software package.
sudo apt-get install python-smbus sudo apt-get install i2c-tools
3. Download the required script
git clone https://github.com/geekworm-com/x750.git cd x750 chmod +x x750.sh
4. Install&run the script
sudo bash x750.sh
This command will gernerate a new x750ups.py in the current path, in generay, the current path is /pi/home, please remember this path, you will use this file soon.
5. Setting up the command to turn off X750 from software
printf "%s\n" "alias x750off='sudo x750shutdown.sh'" >> ~/.bashrc sudo reboot
6. Test the safe shutdown command
x750off
7. How to read the battery voltage and percentage?
sudo python x750ups.py
NOTE: you can use the following command to search x750ups.py file if you don't know where this file is;
sudo find / -name x750ups.py
Enable comment auto-refresher
Anonymous user #2
Permalink |
Anonymous user #1
Permalink |
Anonymous user #3
Anonymous user #1
Permalink |
Anonymous user #1
Permalink |
Anonymous user #1