Welcome, Guest

Author Topic: how to acccess TWI I2C with python  (Read 3398 times)

yoann_q

  • Newbie
  • *
  • Posts: 48
  • Karma: +0/-0
    • my blog
how to acccess TWI I2C with python
« on: June 24, 2014, 10:07:19 AM »
hi,
i want to communicate with ADXL accelerometer using I2C interface using python , i haven't try anything for the momment but is there any example to start ?
best regards

martinayotte

  • Full Member
  • ***
  • Posts: 125
  • Karma: +2/-0
Re: how to acccess TWI I2C with python
« Reply #1 on: June 24, 2014, 04:58:40 PM »
The I2C library in Python is called "smbus". You can install it using "apt-get install python-smbus".

yoann_q

  • Newbie
  • *
  • Posts: 48
  • Karma: +0/-0
    • my blog
Re: how to acccess TWI I2C with python
« Reply #2 on: June 26, 2014, 12:05:13 AM »
It works perfectly thanks Martin