Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Interfacing digital pot to microcontroller....pull ups needed?

Status
Not open for further replies.
Hello!

Yes, I2C requires pull up resistors.
But depending on the microprocessor, there might be internal pull-ups.
I use MSP430 frequently, and you can setup each port (pin wise) with internal pull-ups
or pull downs. This feature probably exists on other MCUs.

Dora.
 
  • Like
Reactions: treez

    T

    Points: 2
    Helpful Answer Positive Rating
Most likely due to the fact, figure 7.1 on page 47 is in reference to Section 7.1 Power Supply Considerations and illustrates the proper use of bypass capacitors, not proper I2C implementation.

7.1 Power Supply Considerations

The typical application will require a bypass capacitor
in order to filter high-frequency noise, which can be
induced onto the power supply's traces. The bypass
capacitor helps to minimize the effect of these noise
sources on signal integrity. Figure 7-1 illustrates an
appropriate bypass strategy
.

In this example, the recommended bypass capacitor
value is 0.1 μF. This capacitor should be placed as
close to the device power pin (VDD) as possible (within
4 mm).

The power source supplying these devices should be
as clean as possible. If the application circuit has
separate digital and analog power supplies, VDD and
VSS should reside on the analog plane.

And yes, a correctly implemented I2C connection does require pull up resisters.


BigDog
 
  • Like
Reactions: treez

    T

    Points: 2
    Helpful Answer Positive Rating
thanks, but if i only want to write to the MCP4018, then i would think i do not need pull up resistors.?

so if i wish , i can just connect the microcontroller to the MCP4018's SDA and SCL pins with no resistors at all (i.e. no series resistors, no pullup or pull down)
 
Last edited by a moderator:

but if i only want to write to the MCP4018, then i would think i do not need pull up resistors.?

No, I don't believe so, you'll need to implement some method of pullup resistors at an appropriate value.

The SDA and SCL lines are frequently implemented with an open collector/drain configuration, therefore without proper pullup resistors to pull these lines high in idle, they will not function as required.


Reference: The I2C-bus and how to use it (including specifications), Section 4.0 GENERAL CHARACTERISTICS, Page 5
4.0 GENERAL CHARACTERISTICS

Both SDA and SCL are bidirectional lines, connected to a positive
supply voltage via a pull-up resistor (see Figure 4). When the bus is
free, both lines are HIGH. The output stages of devices connected
to the bus must have an open-drain or open-collector in order to
perform the wired-AND function.
Data on the I2C-bus can be
transferred at a rate up to 100 kbit/s in the standard-mode, or up to
400 kbit/s in the fast-mode. The number of interfaces connected to
the bus is solely dependent on the bus capacitance limit of 400pF.



Using the I2C Bus


BigDog
 
  • Like
Reactions: treez

    T

    Points: 2
    Helpful Answer Positive Rating
bigdogguru
you'll need to implement some method of pullup resistors

Thanks, but i cant see why i need pull up resistors, the uC pin can be driven high, and its connected to the MCP4018 SDA and SCL pins...so why do i need pullups?
 

What specific microcontroller are you utilizing in your design?

Are you implementing the I2C via software or I2Chardware peripheral module within the microcontroller?

Be aware driving the pins as digital I/O may behave significantly different when configured to an I2C hardware peripheral module connected to the same pins.

An open collector/drain configuration can only exist in two states without a pullup resistor, high impedance and low logic (GND).

While you can certainly implement a softI2C interface using general digital I/O pins of the microcontroller, the slave devices will certainly be open collector/drain.

Also keep in mind, the proper choice of a pullup resistor value for the I2C bus is largely dependent on the capacitive loading of the attached devices, therefore any usable builtin pullups may not provide the proper value in many cases.

I'll need the information requested in the previous questions to provide a more definitive answer.


BigDog
 

Are you implementing the I2C via software or I2Chardware peripheral module within the microcontroller?

Via I2C module

so even if i am only ever writing to the MCP4018, due to the I2C protocol, the MCP4018 has to be able to talk back to the micro?....eg to say, "ok send me another byte of data etc" ?

i dont know exactly which micro yet, as its an emergency led sign, and the choice of micro is a big choice due to lots of inputs/outputs etc.
 

If i wish to communicate with the MCP4018 from a PIC wihtout an I2C module, then will i have to do it using two external open collector transistors......which would be connected bases to the PIC pins?
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top