Community
cancel
Showing results for 
Search instead for 
Did you mean: 
idata
Community Manager
2,619 Views

Intel Edison with BNO055 Adafruit Module via I²C

Hi I want to attach an BNO055 via I²C to the Intel Edison that Iam using with the MiniBreakout Board.

I found out, that the MiniBreakout of Intel is working with 1,8V and my Adafruit Module is working with 3V or 5V logic.

This is the sensor : https://learn.adafruit.com/adafruit-bno055-absolute-orientation-sensor/wiring-and-test https://learn.adafruit.com/adafruit-bno055-absolute-orientation-sensor/wiring-and-test

So i decided to use a levelshifter bi-directional that I connected between the Intel Edison and the BNO055 see link: https://www.sparkfun.com/products/12009 SparkFun Logic Level Converter - Bi-Directional - BOB-12009 - SparkFun Electronics

My question is the BNO055 hhas built in Pullups (10KOhm) for the I2C bus, but I read, that the miniBreakout of Intel has pullups too is it right? When yes should I remove some of them (from the sensor or Edison?). Second question is the Levelshifter has Resistors too 10KOhms, should I include the pullups for I²C from the Sensor to the Levelshifter or from the levelshifter to the Intel Edison?

Another question is which IDE you recommend to use to programm in C the Intel Edison?

16 Replies
idata
Community Manager
124 Views

Hello milito,

 

 

Thanks for reaching out!

 

 

Edison indeed has pull-up resistors as you can see in section 2.2 of the Intel® Edison Breakout Board Hardware Guide ( http://www.intel.com/content/www/us/en/support/boards-and-kits/000005574.html).

 

 

I believe there shouldn't be any issues if you leave both the Edison's and the sensor's pull-up resistors. I also doubt the level shifter's pull-ups will cause any trouble. Usually the issues with I2C+Level shifter are caused by the level shifter not being able to keep up with the I2C signals. So, my best suggestion is that you try it and let us know how it goes, if you have issues we'll be here to help you.

 

 

Regarding the IDE, you should try using the Intel® System Studio IoT Edition. You can find a guide on how to use it in https://software.intel.com/en-us/intel-system-studio-iot-edition-guide-for-c.

 

 

I hope this helps.

 

-Peter.
idata
Community Manager
124 Views

Hi thanks a lot for responding. I tried to detect if the sensor BNO055 is detected via i2cdetect -y -r6 but no sensor is shown. Do you know what could be the problem?

Regarding the pullups i saw that

in directory /sys/kernel/debug/gpio_debug/gpiox

file current_pullstrength contains one of the values 2k, 20k, 50k or 910ohms

file current_pullmode contains the value pullup

you can read out the status of the gpio pin and you can read out if pullup is active and the current_value is HIGH or LOW. In case , how I can enable or disable the pullups?

The other question is I read, that ecery gpio has a pullup of 2, 20 or 50kOhm and when you use these as I2c you have an additional 918KOhm, does it mean for example 2kOhm + 918kOhm?

Regarding the IDE, I prefer to programm in C or Python so the Intel System Studio Iot is the best? The problem is that I am using Windows 7 64Bit and Iam not able to install this IDE because I have got the message that Windows 7 is not supported.

Do you have maybe a Workaround to this?

Sorry for the question Iam quite new with the Intel Edison.

idata
Community Manager
124 Views

Hi milito,

 

 

I believe the reason why it is not detecting any device is because you might not be enabling the I2C interface. In order to enable the I2C interface in the mini breakout board, you can use the following script:

 

 

# !/bin/sh

 

echo 28 > /sys/class/gpio/export

 

echo 27 > /sys/class/gpio/export

 

echo mode1 > /sys/kernel/debug/gpio_debug/gpio28/current_pinmux

 

echo mode1 > /sys/kernel/debug/gpio_debug/gpio27/current_pinmux

 

 

Regarding the resistors question, what the documentation means is that in the I2C pins you have an extra option. So, in those pins you can have 2kΩ, 20kΩ, 50kΩ or 910Ω. The 910Ω do not add up to the other resistors.

 

 

With the issue on ISSIoT, as a workaround you can use a previous version of the IDE, you can get one in https://downloadmirror.intel.com/25871/eng/iss-iot-win_03-14-16.7z

 

 

This IDE works for C and Java, nevertheless, if you'd like to develop with Python, this IDE will not be of help. However, Edison is indeed compatible with this language (and with pretty much any other language compatible with Linux) but you'll have to run your tests directly on Edison's Linux console. If you need help with this just let me know and I'll gladly help you.

 

 

-Peter.
idata
Community Manager
124 Views

Thanks a lot i will this out.

A question I need to run this as a script? ---> Is this a python script? or I can to this via the CMD window?

idata
Community Manager
124 Views

What do you mean with i need to run the tests directly on Edisons Linux? Do you have any tutorial for this?

idata
Community Manager
124 Views

You can do it either way, above it is written as a shell script but if you remove the shebang (# !/bin/sh), you can run those lines as Linux commands.

What I mean by running Python scripts directly on Edison's Linux is that you have to execute them in the terminal. For example, if you have the simple example:

for x in range(1,6):

 

for y in range(1,6):

 

print "x is %d and y is %d" % (x,y)

And you'd like to run this on Edison, then you would have to first copy it into Edison's internal memory, using WinSCP (https://winscp.net/eng/download.php https://winscp.net/eng/download.php), vi (http://www.howtogeek.com/102468/a-beginners-guide-to-editing-text-files-with-vi/ http://www.howtogeek.com/102468/a-beginners-guide-to-editing-text-files-with-vi/), or any other method and then run them with the command python YOUR_SCRIPT.py. You can check the screenshot below to see how I did it:

-Peter.

idata
Community Manager
124 Views

Hi milito,

 

 

Do you have any updates about this?

 

 

-Peter.
idata
Community Manager
124 Views

Hi so i tried it to enable it via the CMD window it works, now I attached a second sensor (BNO055) and the board is running Iam not able to run yocto i dont know why?

Regarding to run the VDDIO pin for 1,8V i didnt try this but thanks for the hint i will give a look and write a feedback ok?

RH5
Novice
124 Views

That would be great, thank you.

idata
Community Manager
124 Views

No Problem, are you using the adafruit layout of the BNO055?

RH5
Novice
124 Views

Yes. I haven't looked at it closely since I looked over the Data sheet. Does it not include that pin? I'm a bit new to this, so I just assumed I missed the pin somehow.

RH5
Novice
124 Views

Hello all, I just received an Edison, with the breakout board today, and want to use the BNO055 IMU with it. Going over the datasheet for the BNO055 gave me the impression you could directly connect the BNO055 VDDIO pin to the Breakout 1.8V supply pin. Doing this would set the IMU IO to 1.8V, allowing you to forgo the level shifter. Am I mistaken, or does this compromise the functionality of the IMU in some way?

idata
Community Manager
124 Views

Hi regarding the enabling of I2C you gave me this:

echo 28 > /sys/class/gpio/export

echo 27 > /sys/class/gpio/export

echo mode1 > /sys/kernel/debug/gpio_debug/gpio28/current_pinmux

echo mode1 > /sys/kernel/debug/gpio_debug/gpio27/current_pinmux

My question is wht is the code doing exactly?- Normally Iam reading the actual status of pinmux?

idata
Community Manager
124 Views

Those lines simply change the state of a multiplexer in order to change the pin status from GPIO to I2C.

 

 

After doing this you can use I2C manually. However, if you use a library such as mraa, you don't need to do this as the library does it automatically for you when you define the pins either as GPIO or I2C.

 

 

This is not limited to I2C, but instead, every pin on Edison that is not a dedicated one has to do something similar in order to change from one interface to another.

 

 

-Peter.
idata
Community Manager
124 Views

Hi,so I gave a look regarding the VDDIO pin and in the adafruit layout they are saying, that the you can run this with 3V or 5V, maybe its because of the adafurit layout that is used with the BNO055. Here you can give a look:

https://learn.adafruit.com/adafruit-bno055-absolute-orientation-sensor/pinouts https://learn.adafruit.com/adafruit-bno055-absolute-orientation-sensor/pinouts

When you have other questions or you have updates write .

HLeeu
New Contributor I
124 Views

Anybody any more experience in getting this to work? Actually I was contemplating buying a different breakout board from Mouser where you can see both VDD and VDD_IO broken out, so I guess that means connecting the edisons 3.3V supply to VDD and the 1.8V to the VDD_IO.

http://nl.mouser.com/ProductDetail/Bosch-Sensortec/BNO055-Shuttle-Board/?qs=sGAEpiMZZMuWWq7rhECaKTV2... http://nl.mouser.com/ProductDetail/Bosch-Sensortec/BNO055-Shuttle-Board/?qs=sGAEpiMZZMuWWq7rhECaKTV2...%…

http://www.mouser.com/ds/2/783/150731_BNO055_Shuttleboard_Flyer_update-1091771.pdf http://www.mouser.com/ds/2/783/150731_BNO055_Shuttleboard_Flyer_update-1091771.pdf

For what its worth...

Best, Hans.

Reply