This module provides an interface to the PCA9544 I2C multiplexer. This IC allows you to have up to four devices using the same address on your I2C bus.
The PCA9544A documentation states a maximum I2C bus speed of 400 kbit/s. This means it will be fine if you are using the Raspberry Pi default setting of 100 kbit/s
It uses HiPi::Device::I2C as a backend.
Create a new instance of the module class.
use HiPi::Interface::PCA9544; my $mux = HiPi::Interface::PCA9544->new( address => 0x70, );
Set the channel to open. $channel can be 0, 1, 2 or 3
. . . $mux->set_channel( 1 );
Get current open channel and interrupt status for all four channels.
. . . my ( $channel, @interupts ) = $mux->get_status();