MCP23017 Arduino Class Development

Job ID: 38569740

Budget: $10 – $30 USD

I'm looking for a skilled Arduino programmer to create a class that can use 3 instances of the MCP23017 I/O expander.

I want a class for a relay. The relay is connected to eGPB6 = relay1 (eGPB7 for relay 2) .
I want use the class like create a relay object:
Relay relayOne(/* instance of mcp23017 */mcp1, /* this is relay one*/ 1);

Then I just want to use relayOne.On(); to turn on the relay

So the problem is how to pass mcp23017 objects to the class

Attached is a working Arduino code built without Relay class and tab so separate "main" from functions.
(The 2 INO files)
Also my attempt to create a Relay class.
( the .h and cpp file)

The class shoud do Pinmode in the constructor and set the mcp23017 pin to OUTPUT.
Simple on/off functions.