robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Slice of Pi/o Address Problem

Sun May 25, 2014 8:12 am

Hi all,

I have been successfully using a Slice of Pi/o for a while now, in fact I have made quite a useful device with it: http://www.thehomebrewforum.co.uk/showt ... hp?t=42374. However, I am having problems with a difference Slice of Pi/o and Pi, which I was hoping someone might be able to help me fault find.

I am trying to get another Slice of Pi/o to work for a friend's kid, who I am teaching some simple programming. However, I don't seem to be able to get the damn thing to work.

Basically, I am using a fairly early Model B Pi, which a recently bought Slice of Pi/o V1.2.

When I power up, I can use "i2cdetect -y 0", and the Slice of Pi/o is detected on port 20 (as below).

Code: Select all

[email protected] ~ $ i2cdetect -y 0
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: 20 -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --
Note: My other Pi from the project linked to above is on bus 1, rather than bus 0, and the RPis were bought at pretty much the same time, so I am not sure if this is indicating a problem at all.

Then, when I run any code to use the Slice of Pi/o, and then retype "i2cdetect -y 0" it seems to detect on all the ports like this (note: this occurs even if the Slice of Pi/o is connected with nothing connected to the i/o header on the Slice of Pi/o):

Code: Select all

[email protected] ~ $ i2cdetect -y 0
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f
10: 10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f
20: 20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f
30: 30 31 32 33 34 35 36 37 38 39 3a 3b 3c 3d 3e 3f
40: 40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d 4e 4f
50: 50 51 52 53 54 55 56 57 58 59 5a 5b 5c 5d 5e 5f
60: 60 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f
70: 70 71 72 73 74 75 76 77
I wondered if this might be linked to a broken Pi, so I tried this Slice of Pi/o in two other Pis, and the problem occurs on all three (one of which is also the Pi I am using with my boiler controller so definitely works, but not with this new Slice of Pi/o).

Also, when I tried the new Slice of Pi/o on my old Pi which is in the boiler controller, it showed up on bus 0 rather than on bus 1, so it seems that the Slice of Pi/o is changing the bus some how, which seems impossible to me.

I even tried swapping the chip from one Slice of Pi/o to the other, and there was still no change.

Do you have any idea what the problem might be? Could it be that the Slice of Pi/o is broken in some way, or might I be unlucky enough to have a combination of broken Pi-s and broken Slice of Pi/o-s which are causing me all this confusion.

Is there an easy way that I can check the health of my GPIOs on the Pi for any errors so that I can rule out the Pi as being part of the problem?

Thanks

Robbo100

User avatar
DougieLawson
Posts: 36578
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Slice of Pi/o Address Problem

Sun May 25, 2014 8:25 am

I'd start by visually inspecting every solder joint to see if any are dry or any bridge two tracks.the I2C detect error points towards the SDA and SCL having the wrong logic level.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Re: Slice of Pi/o Address Problem

Sun May 25, 2014 8:34 am

Thanks Dougie,

I will have a check. I did do an initial look and all seemed fine, but I will give it a closer inspection later (the slice of Pi/o is at the kids house at the moment, so I won't get it back until tuesday, so will look then).

When you say "points towards the SDA and SCL having the wrong logic level." - what exactly does this mean in simpleton speak. I presume you mean that the SDA and SCL lines are getting the wrong voltage from somewhere?

Thanks

User avatar
DougieLawson
Posts: 36578
Joined: Sun Jun 16, 2013 11:19 pm
Location: Basingstoke, UK
Contact: Website Twitter

Re: Slice of Pi/o Address Problem

Sun May 25, 2014 8:38 am

When you hold the I2C line at 3v3 they won't work. When you hold the I2C lines low (gnd) they give the results you see.
Note: Having anything humorous in your signature is completely banned on this forum. Wear a tin-foil hat and you'll get a ban.

Any DMs sent on Twitter will be answered next month.

This is a doctor free zone.

robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Re: Slice of Pi/o Address Problem

Thu May 29, 2014 9:08 pm

Hi Dougie,

I have checked the Slice of Pi/o board both visually, and also with a multimeter. I have checked that there is no ground or 5v leakage to the SCL or SCA lines, but found no problems.

I have tried to start with a new SD Card image, but this has not resolved the problem.

Is there any way that I can test the SCL and SCA of the Pi (I don't have an oscilloscope or anything like that).

I was thinking of taking the chip off the Slice of Pi/o and putting it on a prototyping board and wiring it directly to the pi (i.e. not using the supplied PCB) using this guide: http://www.raspberrypi-spy.co.uk/2013/0 ... pi-part-1/

Do you think this is worth a try, and do you have any other ideas to test?

Thanks

Robbo100

robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Re: Slice of Pi/o Address Problem

Fri May 30, 2014 9:00 am

Also,

Since I have a slice of Radio (which I am yet to play with), I presume that if I can get this to work (which also uses the SDA/SDL pins on the GPIO header), then this will prove that the Pi is working fine, thus pin the problem down to the Slice of Pi/o.

Does this make sense?

asandford
Posts: 1997
Joined: Mon Dec 31, 2012 12:54 pm
Location: Waterlooville

Re: Slice of Pi/o Address Problem

Fri May 30, 2014 2:46 pm

robbo100 wrote:Also,

Since I have a slice of Radio ...(which also uses the SDA/SDL pins on the GPIO header)

Does this make sense?
Slice of Radio uses Tx, Rx and GPIO22 (sometimes), more info here

robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Re: Slice of Pi/o Address Problem

Sat May 31, 2014 8:00 am

Well, I am not clever enough to get the Slice of Radio working yet anyway (which could be me, or it could be a broken Pi, who knows) :lol:

I have tried wiring up the chip from the Slice of Pi/o using this guide: http://www.raspberrypi-spy.co.uk/2013/0 ... pi-part-1/ and I have exactly the same problem. I have tried it with two different MCP23017 chips with the same result!

I suspect I have a broken Pi, in fact, since this is a problem with two Pis, I think I have two broken Pis, which is a complete shame since they are both just out of the box, having bought them a couple of years ago.

Oh well, I will have to go shopping now! :P (unless anyone else can think of something I can try?)

transfinite
Posts: 5
Joined: Thu Apr 11, 2013 7:33 pm

Re: Slice of Pi/o Address Problem

Thu Jun 05, 2014 3:26 am

The i2cdetect problem is a known (kernel) bug. There's a work around discussed here:

https://github.com/raspberrypi/linux/issues/435

I had this problem, and it was maddening until I applied the work around, which involves changing the order the device modules are loaded.

-transfinite

robbo100
Posts: 60
Joined: Thu May 17, 2012 11:39 am

Re: Slice of Pi/o Address Problem

Fri Jun 06, 2014 11:57 am

transfinite

You are a star! (although I wish you had replied before I bought a new Pi :lol: )

I will try this tonight.

Thanks

Robbo100

Return to “Interfacing (DSI, CSI, I2C, etc.)”