https://github.com/chewett/raspberrypivcgencmd
A small python library to programmatically access some of the internal sensors of the Raspberry Pi
https://github.com/chewett/raspberrypivcgencmd
codec internal-components measure python raspberry-pi vcgencmd video
Last synced: 3 months ago
JSON representation
A small python library to programmatically access some of the internal sensors of the Raspberry Pi
- Host: GitHub
- URL: https://github.com/chewett/raspberrypivcgencmd
- Owner: chewett
- License: mit
- Created: 2016-10-26T18:06:00.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2021-01-09T01:04:41.000Z (over 4 years ago)
- Last Synced: 2025-01-17T02:15:44.545Z (4 months ago)
- Topics: codec, internal-components, measure, python, raspberry-pi, vcgencmd, video
- Language: Python
- Homepage:
- Size: 19.5 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Raspberry Pi Vcgencmd
=============================A small python library to programmatically access the internal
sensors of the Raspberry Pi.## Usage
Install this via pip:
`python3 -m pip install RaspberryPiVcgencmd`
Include the module in your python file
`from RaspberryPiVcgencmd import Vcgencmd`
Once you have included it you can use it in your program as below
```
vcgencmd = Vcgencmd()
print(vcgencmd.get_version())
```## Exposed Functions
The majority of the useful output from vcgencmd is exposed in the class with the below functions
* get_cpu_temp - Gets the system temperature of the soc in Celsius or Fahrenheit
* get_ram_split - Gets the memory split between the gpu and cpu
* measure_volts - Measures the voltage of various internal components
* measure_clock - Mesures the clock frequency of various internal components
* is_codec_available - Returns whether the codec specificed video/audio codec is available on the Raspberry Pi
* get_version - Gets the version of the firmware installed on the Raspberry Pi
* set_display_power - Allows turning off/on the video output of the Raspberry Pi## Todo
* The first time vcgencmd is requested to run it should run
and then check what commands are available on that Raspberry Pi.
This should then confirm that the command is available and also
stop any commands which are not available on the Pi.
* Combine some of the output functions so that it doesnt use several
different formatting methods## Want to help?
Suggestions and improvements are welcome, if you have anything to add
feel free to make a pull request on [github](https://github.com/chewett/RaspberryPiVcgencmd).