Weird signals on SDA/SCL pins for I2C

Go To Last Post
12 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello I am trying to communicate with a device via SMBus.  So when I try to send a data which was 0x0D and address of the device was 0x16. I see something like that on the data line:

 

 

 

 

And this is how my clock (SCL) pin looks like:

 

 

 

So my questions are :

  1. Is this data and clock signals look normal? I know data is not normal because I cannot transmit the message but what about clock signal?
  2. So Data looks like 1 1 1 1 1 1 .... 1 1, is it because I cannot ack ACK/NACK from slave, it keep sending the data over and over again? Or maybe something else behind this strange data signal.
  3. I used 20 K pull up resistors for SDA and SCL for 5 V Vdd. (For SMBus I think I should have used 15 k ohm.) Can it be the reason? Or any other ideas that causes this? Thanks beforehand
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

20k is way too high.  4.7k or 10k is the norm.

 

Jim

 

EDIT:  The resistors must also be at the last device on your bus.  Not at the microcontroller.

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

Last Edited: Thu. Apr 4, 2019 - 12:49 PM
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

 

Actually in the datasheet of the device that I try to communicate it says this: (but I couldn't get what does it mean so I just used 20 k ohm )

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

You asked about I2C, not SMBus. For I2C we generally use pull up,resistors in the range of 2.2k to 10k.

What are you trying to interface to?

Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

My bad, I am trying to communicate with a smart battery by using PIC, I want to get the state of charge information from it. SMBus v1.1 the battery uses

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

GunkutA wrote:
by using PIC,

Wrong web site, suggest you ask in the PIC Microchip forums!

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274
get $5 free gold/silver https://www.onegold.com/join/713...

 

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

GunkutA wrote:
by using PIC,
On an AVR website? Surely the PIC website knows more about the PIC I2C interface??

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Yes, I just wanted to ask about the pull up resistors tho

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The DS says 15k, so use 15k's, what does it say about bus speed?

With 15k pullups your bus speed will be sloooowwww,  so don't try to go fast, ie. 400kHz, start with 10kHz to 50kHz.

 

Jim

 

Click Link: Get Free Stock: Retire early! PM for strategy

share.robinhood.com/jamesc3274
get $5 free gold/silver https://www.onegold.com/join/713...

 

 

 

 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Worth reading this...

 

https://www.totalphase.com/suppo...

#1 This forum helps those that help themselves

#2 All grounds are not created equal

#3 How have you proved that your chip is running at xxMHz?

#4 "If you think you need floating point to solve the problem then you don't understand the problem. If you really do need floating point then you have a problem you do not understand." - Heater's ex-boss

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Observation -

 

The OP has not been here since #8. Perhaps he or she has gone to the PIC site, where the question really belonged. There have been several direct questions about  schematic and such with no response.

 

Jim

Jim Wagner Oregon Research Electronics, Consulting Div. Tangent, OR, USA http://www.orelectronics.net

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

ka7ehk wrote:

Observation -

 

The OP has not been here since #8. Perhaps he or she has gone to the PIC site, where the question really belonged. There have been several direct questions about  schematic and such with no response.

 

Jim

 

ANd here I was getting ready to split the thread as we have taken it over somewhat as well.

 

Other Jim

I would rather attempt something great and fail, than attempt nothing and succeed - Fortune Cookie

 

"The critical shortage here is not stuff, but time." - Johan Ekdahl

 

"Step N is required before you can do step N+1!" - ka7ehk

 

"If you want a career with a known path - become an undertaker. Dead people don't sue!" - Kartman

"Why is there a "Highway to Hell" and only a "Stairway to Heaven"? A prediction of the expected traffic load?"  - Lee "theusch"

 

Speak sweetly. It makes your words easier to digest when at a later date you have to eat them ;-)  - Source Unknown

Please Read: Code-of-Conduct

Atmel Studio6.2/AS7, DipTrace, Quartus, MPLAB, RSLogix user