Useful tool to execute commands via SSH on a RPI or grab system info from said RPI
Project description
raspycheck
raspycheck is a small tool to grab infos from and execute commands on a Raspberry Pi via SSH.
raspycheck is in an early alpha stage!
Usage:
from raspycheck import RasPyCheck
rpc = RasPyCheck(ip='ip', user='username', password='password', persist=False) # Setting persist to True keeps the connection open
# Commands to grab data from the RPI
ip = rpc.get_rpi_ip()
hostname = rpc.get_rpi_hostname()
cpu_temp = rpc.get_rpi_cpu_temp()
usb_devices = rpc.get_rpi_usb_devices()
rpi_version = rpc.get_rpi_version()
free_mem = rpc.get_rpi_free_memory()
total_mem = rpc.get_rpi_total_memory()
essids = rpc.get_rpi_available_essids()
date = rpc.get_rpi_date()
installed_packages = rpc.get_rpi_list_installed_packages()
all_infos = rpc.get_all_rpi_info()
# Commanding the Pi
rpc.cmd_reboot_pi()
# Generic stuff
output = rpc.run_command_get_output('pwd') # executes pwd on the RPI and returns the output
return_code = rpc.run_command_get_return_code('pwd') # executes pwd on the RPI and returns the return code
# Only when persist=True:
rpc.close_instance_client() # closes SSH client
Supported Versions
raspycheck is currently only tested with Python3.9
TODO:
- Extend errorhandling
- Extend functionality
- Add tests
- Relax/Check dependencies
- ...
Release History
0.0.2 (2021-05-24)
Improvements
- Added README
- Added HISTORY
Bugfixes
- Fixed package structure
0.0.1 (2021-05-24)
- Initial Creation
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
raspycheck-0.0.2.tar.gz
(6.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file raspycheck-0.0.2.tar.gz.
File metadata
- Download URL: raspycheck-0.0.2.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
217ccb3899a37bdb76ced7080630db476f7171d7bc52bebfafd812d97e5360c5
|
|
| MD5 |
22afb1d8ce469e31af085659006b707c
|
|
| BLAKE2b-256 |
3a086cb003142abe057395eb3e29ff26111470b4615dfdf5f0f110cd076a13d7
|
File details
Details for the file raspycheck-0.0.2-py3-none-any.whl.
File metadata
- Download URL: raspycheck-0.0.2-py3-none-any.whl
- Upload date:
- Size: 8.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.9.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bf1ab8c59d3023ef3d9a4338ea9f05348337c8512eb1e2a78679feb93b0ccaa4
|
|
| MD5 |
2f8c816106880bdaa1291b13c8efd5c0
|
|
| BLAKE2b-256 |
cefcfaa759866ec60f6b97563dd6202d36fd179ef38a53137ee09166f34fabe0
|