Questions about powering the CP2104

Hey guys,
I have questions regarding the CP2104 module in self-powered mode. As noted in the manual, the REGIN input is connected to the Vdd to bypass the voltage regulator.

  • In contrast to the Bus-powered configuration in which the Vdd output 3.45V with the voltage regulator, I guess the REGIN / Vdd pins are now inputs? Does the REGIN / Vdd really has to be powered with 3.3V even though VBUS already receives 3.3V? I guess yes but just wonder why.

  • After adding the voltage divider (note 5), the VBUS is receiving 3.3V from the USB plug. Just curious, why not also connecting the REGIN after this voltage connector?

Probably stupid questions. But you now know both electronics and English are not my first languages :slight_smile:

Thanks
Laurent

Because of the 24k upper resistor in the voltage divider. This would create a voltage drop depending on the current draw of the CP210x, which will be variable.

@ponpon777

Does the REGIN / Vdd really has to be powered with 3.3V even though VBUS already receives 3.3V?

VBUS does not supply power to the IC, REGIN supplies the power. VBUS does not receive 3.3V in BUS powered mode, it receives 5V. The USB bus voltage is always 5V never 3.3V. REGIN is connected to 5V and Vdd OUTPUTS 3.3V in BUS powered mode

After adding the voltage divider (note 5), the VBUS is receiving 3.3V from the USB plug. Just curious, why not also connecting the REGIN after this voltage connector?

That would defeat the whole purpose of SELF power mode. Besides REGIN is the power supply pin for the IC. It need to be connected to a 3.3V supply and not through a voltage divider in SELF powered mode

There's a problem with the "VBUS" label in that it can either refer to the VBUS pin on the USB side or the VBUS pin on the CP210x side. It's ambiguous. I assumed OP meant the latter - i.e. the VBUS pin on the CP210x.

A similar problem exists in the name 'self powered', which is IMO poorly chosen since it doesn't specify who 'self' is.

What don't you understand about the operation of the IC?

This is not about my understanding of this IC. I'm pointing out ambiguity in definitions which may be a problem in interpreting your response.
image

Well let's see if @ponpon777 is also confused.

Thanks to all of you. It took me a long time actually to understand both concept.
Here, I just wanted to know if it was possible to do this...
image
It was tempting since I have 3.3V after the voltage divider.

For the confusion, well... D+ goes to D+, GND to GND... and VBUS to VBUS. My confusion is more on which one should I choose: SELF or BUS powered. I guess it depends what my project is. Actually, I just want to use this USB to load the program on the ESP32 and charge the battery if it is connected (using another module). Which one usually people choose?

There you go. Depends on what you want to achieve.

Do you want the device to connect to USB but not draw power from it, then provide power from an additional source to your CP210x. If you want the device to be powered from the bus, then do that. If you want both, depending on what's connected, there are also ways to do that. Depends on the context.

No it is NOT

Bus powered

Understood

Like I said, I just want to use the USB to load my program on my ESP32 (and eventually to charge my battery). Nothing else. Actually, the reason why I asked that is because when I plug my battery after loading the program, I connected the 3.3V from the battery (after the voltage converter MIC5219-3.3YM5 of course) to Vdd and I had huge increase of current consumption (0.02 to 6.8mA). It went back to normal after cutting the trace going to Vdd. I thought it was because of the configuration of the CP2104. I thought to turn off this part of the circuit with a simple slide switch after program is loaded. Probably not the best solution...

Then use the BUS powered configuration. No point in powering the CP2104 if it's not connected to USB, you would be wasting battery power for nothing

Ok, then where should I connect the 3.45V output Vdd? and do I have to? The BUS powered configuration is what I did the first time but maybe my mistake was to connect Vdd output to the 3.3V of the battery. Was it bad?

No, do not connect it to anything other than Vio and the filter capacitors as shown in figure 8 of the data sheet.

When cinfigured as BUS powered, Vdd outputs 3.45V but when the USB connector is removed that voltage is no longer present. If you already have a 3.3V supply I see no real use for the Vdd 3.45V output unless you want to have some circuit powered only when the USB is plugged in.

1 Like

Well, does the ESP32 need to be powered while I'm loading the program?

Of course but I don't recommend using Vdd, it's limited to 100mA and I wouldn't draw any more than 60mA from it.

Ok, then, I can just connect my battery during the load. And leave the Vdd connected to Vio as you've suggested.
Thank you so much @jim-p, I can see how to fix my project now.

You can do that or you can have some extra circuitry to switch between battery power and USB power or simply put a toggle switch.

Hold on I have one more suggestion you should implement.

When you have a powered device (ESP) connected to a non powered device (CP2104) you should have buffers between the two in order to provide isolation.

Here is where Vdd comes into use. Connect 74LVC125 buffers on any data connection between the CP2104 and the ESP ( RX, TX, DTR, etc) and power it from Vdd. When the USB is not plugged in the CP2104 is not powered and Vdd will be zero. That will cut power the the 74LVC125s and isolate the two devices.

2 Likes