#data #access #allowing #ups #key #folder #apcupsd

apcaccess

A Rust implementation of apcaccess to get data from apcupsd

5 releases

0.2.0 Oct 16, 2024
0.1.3 Aug 30, 2023
0.1.2 Aug 30, 2023
0.1.1 Aug 30, 2023
0.1.0 Aug 27, 2023

#4 in #ups

Download history 4/week @ 2024-10-09 154/week @ 2024-10-16 3/week @ 2024-10-23 7/week @ 2024-10-30 8/week @ 2024-11-06 1/week @ 2024-11-13 2/week @ 2024-11-20 2/week @ 2024-12-04 7/week @ 2024-12-11 5/week @ 2024-12-25

312 downloads per month

MIT license

6KB
99 lines

apcaccess-rs

A Rust library allowing access to the data provided by apcupsd.

Usage

use apcaccess_rs::{APCAccess, APCAccessConfig};

let apc = APCAccess::new(Some(APCAccessConfig { ..Default::default() }));
let data = apc.fetch().unwrap(); // returns a hashmap of the data

You can see possible keys in the resources folder based on your UPS.

fetch() will panic if your IP address is not valid.

No runtime deps