Canada
Asked — Edited
Resolved Resolved by DJ Sures!

Ez-B Fails With I2c Script

This is the first time I have tried using the I2C command and port. The EZ-B browns out (blue tooth is still blinking) when I run the command with nothing attatched at the port. Sometimes it fails right away running the script once and sometimes it takes 3 to 4 times for it to fail. No brownouts occur when not running the script!

I2CWrite(0,0x09,"n",0x00,0x00,0x11) ran Script 2

2/14/2014 3:46 PM - Comm Err: The operation has timed out. 2/14/2014 3:46 PM - BbytesToExpect: 1 2/14/2014 3:46 PM - Received: 2/14/2014 3:46 PM - Disconnected 2/14/2014 3:46 PM - Disconnected 2/14/2014 3:46 PM - Disconnected

second attempt, ran script 4 times and EZ-Board crashed.. following dbug info 2/14/2014 3:47 PM - Attempting connection on COM3 2/14/2014 3:47 PM - Connected to COM3 at 9600 2/14/2014 3:47 PM - EZ-B reports EZ-Robot OS v16 2/14/2014 3:47 PM - Welcome to EZ-B v3! 2/14/2014 3:47 PM - Connected 2/14/2014 3:47 PM - Setting battery monitor voltage: 6 2/14/2014 3:47 PM - Setting battery protection: True 2/14/2014 3:47 PM - Disgard incoming buffer (This usually means your EZ-B requires more power or the communication is unstable) 2/14/2014 3:48 PM - Comm Err: The operation has timed out. 2/14/2014 3:48 PM - BbytesToExpect: 1 2/14/2014 3:48 PM - Received: 2/14/2014 3:48 PM - Disconnected 2/14/2014 3:48 PM - Disconnected 2/14/2014 3:48 PM - Disconnected

I checked the underside of the board for any "shorting issues" at the I2C area with a magnifying glass and found none. I did take a plastic spudder probe and gently rubbed in between all 4 pins. Topside at the prcessor looked clean and free of any possible contaminates. I also, while the EZ was powered up checked voltages at the +5 volts and ground at the I2C pinouts. There was 5 volts at the SCL and SDA pinouts to ground. I dont know if that is normal?! When the EZ-Board was powered downd I measured 70K between SDA and SCL pinouts. The BlinkM type works fine on my "other" board . This is the first time I have tried using the I2C command and port. I hope someone can verify my voltage readings at the SDA and SCL points to compare my findings. I am not sure what else I can do to further trouble shoot, any ideas would be greatly appreciated:) Thanks for any assistance, Glen


ARC Pro

Upgrade to ARC Pro

ARC Pro is your passport to a world of endless possibilities in robot programming, waiting for you to explore.

#33  

Really thanks so much @Rich! My primitive understanding is obvious but since you have been giving your knowledge and experience generously on this forum my own understanding has grown immensely and along with many others. This I2CRead "statement" was not well described in great detail as it is here!
Have a great day!

United Kingdom
#34  

I haven't forgotten about this I've just been real busy. I'll grab my test board in a bit and do some checking. I don't have my BlinkM easy to get to since it's in Melvin's head at the moment and Melvin is a little worse for wear at the moment (don't ask!) but I'll check out the resistances and voltages for you as a benchmark. Give me an hour or so and it'll be done:)

United Kingdom
#35  

Gnd to Vcc = 4.99v Gnd to SDA = 4.96v Gnd to SCL = 4.96v VCC to SDA = Open/0V VCC to SCL = Open/0V SDA to SCL = Open/0V

Gnd to Vcc = Open Circuit Gnd to SDA = Open Circuit Gnd to SCL = Open Circuit Vcc to SDA = 4.63k VCC to SCL = 4.59k SDA to SCL = 9.25k

Also, run the script

I2CWrite(0,0x03,0x02,0x05,0x06)
sleep(2000)
I2CWrite(0,0x03,0x02,0x05,0x06)
sleep(2000)
I2CWrite(0,0x03,0x02,0x05,0x06)
sleep(2000)
I2CWrite(0,0x03,0x02,0x05,0x06)
sleep(2000)
I2CWrite(0,0x03,0x02,0x05,0x06)
sleep(2000)
I2CWrite(0,0x03,0x02,0x05,0x06)

It made the EZ-B blue light turn off, a few moments later bt disconnected. I'll do some more digging. This was without anything attached.

I just tried Melvin again, and on init he was disconnecting. My init script starts up both the BlinkM and LCD which are both on I2C. I changed the init script so it didn't run, connected, was working fine, tried to init the LCD and blue light went out and disconnected the EZ-B.

I can't be 100% sure it isn't my robot that is to blame but it does seem coincidental that any I2C commands are being problematic on both of the EZ-Bs I have running. Both doing the same thing. Even using the built in BlinkM control was causing problems.

I will do more playing around when I have more time but as it stands it does seem like the issue is not with your EZ-B but may be with ARC...

Hopefully someone else using I2C can comment on if they are having problems with the latest version so we can get as much info as possible together to help diagnose/solve the issue.

Update:

Is this what happens to yours?

#36  

@Rich ..Yes that's exactly whats happening! and your quote " Hopefully someone else using I2C can comment on if they are having problems with the latest version so we can get as much info as possible together to help diagnose/solve the issue." My I2C was failing on Release 2014.01.07 and then upgraded to the current release, same issue. Curiouser and curiouser! Three different boards same software? Thanks once again Rich!:)

United Kingdom
#37  

If nobody chips in within a few days I'll drop @toymaker an email since I know he uses I2C a lot but may have missed this topic.

I will admit, I haven't used I2C for a while (I haven't used ARC for a while - I've seriously been neglecting my robots lately) so I don't know when it may have started to play up. If it's still installed I'll try it on my office PC which I know was working, this will rule out the slim chance of it being pure coincidence.

#38  

I know there was a I2C Write Read fix on Release 2013.07.24.00......I know @DJ could spread a bit more light on those updates! We all "neglect" our robots building from time to time but that just allows more focus the next time:) All my servo scripts are working just fine. whew

#39  

Hey all

Strange things here trying to reproduce my problem I had before. It was the same trouble that Rich shows in his video, exactly the same thing! Thought it was my BlinkM that was bad and causing the EZB to brownout. Tried another BlinkM and all was/is ok. Wanted to try and help out here so I decided to try the original BlinkM and see if some way some how to figure this out. Well your not going to believe this but now the original BlnkM works and does not brownout the EZB? Can't figure out what or if I did anything different.

Thought I'd let you guys know and will continue to look further. Using and older version 10-28-2013.

#40  

Thanks for chiming in Herr Ball! What script are your running on the BlinkM that is not " browning " out your board. So the version your using is "Post" fix of the I2C... Our boards are "browning" out "bare" board with nothing plugged in and running an I2C Write script! Can you run your script repeatedly ? Also take some voltage and ohmage readings on your I2C port to compare with Richs if its convenient. Thanks so much Herr Ball!