ikarus / sps-i2c-gpio-extender
v0.8.12
2024-07-03 12:24 UTC
Requires
- php: >7.2
- tasoft/php-i2c-extension: ^0.9|^8
README
This package contains php classes to extend your gpio pins.
Installation
$ composer require ikarus/sps-i2c-gpio-extender
Usage
<?php use Ikarus\SPS\I2C\Extender_8GPIO_PCF_8574; use TASoft\Bus\I2C; $extender = new Extender_8GPIO_PCF_8574( new I2C(0x3F) ); $extender->digitalWrite( $extender::PIN_3, $extender::VAL_HIGH ); sleep(1); $extender->digitalWrite( $extender::PIN_3, $extender::VAL_LOW ); $extender->cleanup();