I2c Connection to Relais Board

Hey,

I am trying to get a Raspberry Pi 3 Relais Board up and running. The board connects via i2c and i really searched the whole forum and tried everything from Fleet Configuration (dtoverlay=i2c1=on, etc.) to reload the kernel modules in the Dockerfile (modprobe i2c-dev).

Nothing works :frowning:

We use a RPi3 with the resin/raspberrypi3:latest image.

Hope you can help me :slight_smile:

You need to set

dtparam=i2c_arm=on

in the config.txt file on the SD card.

As a sidenote, you can also use the remote configuration settings to set such variables, that is setting RESIN_HOST_CONFIG_variable to value to have a variable=value set in your config.txt. Here it would be:

RESIN_HOST_CONFIG_dtparam

set to

i2c_arm=on

and have to add these on Device Configuration or Fleet Configuration tab. (though a current limitation that only one variable of the same name can be added through the remote configuration, ie. not multiple dtparam, even though the config.txt can have multiple lines like that. We are working on improving this. But might be still useful for you as it is now.)

See more in the docs: https://docs.resin.io/hardware/i2c-and-spi/#customising-config-txt

It is working now.

There was a problem caused by a node lib we used (node-rpio). The library is blocking the i2c port cause it is compiling own kernel modules.

thanks to @imrehg and @marssystems for your support :slight_smile:

1 Like

Glad to hear its workin now.:thumbsup: :grin: