UNPKG

@name-industry/ni-ina219

Version:

Module for using the WaveShare UPS Raspberry Pi Hat that has an embedded Texas Instruments INA219 sensor.

15 lines (9 loc) 296 B
import I2CBus from "../../../Bus/I2C/index.js"; import { REGISTERS } from "../../../Constants/index.js"; class PowerService { constructor() {}; readRegister = async function () { return await I2CBus.readRegister(REGISTERS.POWER_R); } } export default new PowerService();