Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Netduino + BL-CTRL 2.0 + I2C = Not working?


  • Please log in to reply
1 reply to this topic

#1 voodoo44

voodoo44

    New Member

  • Members
  • Pip
  • 5 posts

Posted 10 February 2011 - 11:41 AM

Hello People,

I got a question to you: We want to control 2 BL-CTRL2.0 via I2C and our Netduino.
One BL-CTRL has adress 2, the other one 3.
For trying out i just wanted to run on controller, but it doesnt work.


Our code:
 I2CDevice i2c = new I2CDevice(new I2CDevice.Configuration(0x29, 100));
 I2CDevice.I2CTransaction[] Actions = new I2CDevice.I2CTransaction[1];
 Actions[0] = I2CDevice.CreateWriteTransaction(new byte[] { 0x66 });

 int j = 0;
 while (j < 5000)
 {
 int result = i2c.Execute(Actions, 100);
 j++;
 }
Do we need to ground the "ground"-pins on the bl-ctrl 2.0 so that they are working?
Something wrong with the code?

THX in advice!

#2 Luke Cummings

Luke Cummings

    Advanced Member

  • Members
  • PipPipPip
  • 38 posts
  • LocationCalgary, AB

Posted 10 February 2011 - 09:11 PM

The fist thing that jumps out is you specified address 2 and 3 in you post, but 0x29 in your code. If the address is supposed to be 2 then cahnge the first line to : I2CDevice i2c = new I2CDevice(new I2CDevice.Configuration(0x02, 100));
Cheap, Fast, Good... Pick two




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.