| 254 | */ |
| 255 | |
| 256 | int wiringPiI2CSetup (const int devId) |
| 257 | { |
| 258 | int rev ; |
| 259 | const char *device ; |
| 260 | |
| 261 | rev = piGpioLayout () ; |
| 262 | |
| 263 | if (rev == 1) |
| 264 | device = "/dev/i2c-0" ; |
| 265 | else |
| 266 | device = "/dev/i2c-1" ; |
| 267 | |
| 268 | return wiringPiI2CSetupInterface (device, devId) ; |
| 269 | } |