dcpartners
dcpartners

Reputation: 5446

How to code for accessing I2C in UWP C#

We are trying to simulate the real IoT device for sensoring Temperature and Humidity using Raspberry Pi 2 and SparkFun HIH6130 sensor.

What we have done so far:

  1. Install Windows 10 Core into Raspberry Pi 2
  2. Download and deployed from GitHub for creating sensor simulation (dummy) using UWP in C# into RaspberryPi device
  3. Linking these 2 devices already using jumper wire (https://www.youtube.com/watch?v=1tEMRCtXALM)

What we need to next is trying to replace code (point #2) by reading the real data from the actual sensor. After digging more info that this connection can utilise the I2C protocol.

My question is how do we achieve this to read this data from I2C protocol? Is there any library/sample specific for UWP that we can utilise this? I know there is GitHub for this - https://github.com/baget/BMP085Dotnet but looks like for specific sensor ?!?!

We are appreciated your help.

Thanks

Upvotes: 0

Views: 1812

Answers (1)

Tamás Deme
Tamás Deme

Reputation: 2228

Here's a good sample project that answers your question: https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/IoT-I2C

Upvotes: 1

Related Questions