# Battery Charging System (Adjustable Current Regulator)

#### hannahhamzah

Joined Jun 8, 2023
5
Hello everyone! I need a little help here. I'm trying to simulate this cct using PSpice from LM338 datasheet of Texas Instrument and I'm not sure if this is the right value and graph that I should be getting? Thank you in advance for your help!

#### Attachments

• 161.8 KB Views: 24
• 98.6 KB Views: 15

#### Ya’akov

Joined Jan 27, 2019
8,515
Welcome to AAC.

Your post was moved to Homework Help to comply with AAC rules concerning coursework related questions. AAC members are only allowed to provide guidance with your own attempts to solve the problem and having the question posted in Homework Help signals the sort of question that it is.

[Moderation]

#### crutschow

Joined Mar 14, 2008
33,355
I'm not sure if this is the right value and graph that I should be getting?
What value and graph?

#### hannahhamzah

Joined Jun 8, 2023
5
What value and graph?
This is a CC-CV circuit, so I want to observe the value of output current and voltage. My apology, I attached the wrong file.

#### Attachments

• 61.1 KB Views: 17

#### Alec_t

Joined Sep 17, 2013
14,007
This is a CC-CV circuit
The only way you can have a constant current through a load and a constant voltage across that load is if the load has one specific resistance determined by Ohm's Law. Regulator circuits would normally provide CC or CV: not both at the same time.
Just what is your circuit intended to do?

#### crutschow

Joined Mar 14, 2008
33,355
You circuit rather looks like two constant-current circuits in series.
Try a constant-current circuit driving a constant-voltage circuit connected to your load.
Then, as the load resistance is increased, it will start with a constant-current until the constant-voltage voltage is reached across the load, where it will remain.

What current and voltage do you want?

#### Audioguru again

Joined Oct 21, 2019
6,441
You do not say or show what kind of battery.
The LM338 is a 5A version of an LM317 1.5A regulator but the 150 ohms resistor limits its output current to only 8.3mA.
Your LM317 has an output voltage of only 1.25V that is too low to charge any kind of battery.

Your schematic has too many wire bends:

#### Attachments

• 32.4 KB Views: 8
Last edited:

#### Audioguru again

Joined Oct 21, 2019
6,441
You circuit rather looks like two constant-current circuits in series.
The LM317 is wired as a 1.25V voltage regulator with a max output current of 1.5A but it is fed only 8.3mA.

#### MrAl

Joined Jun 17, 2014
10,906
Hello everyone! I need a little help here. I'm trying to simulate this cct using PSpice from LM338 datasheet of Texas Instrument and I'm not sure if this is the right value and graph that I should be getting? Thank you in advance for your help!
Hi,

Do you see what is wrong with the input to U2? Look it over and think about how the 338 IC works and what the 0.2 Ohm resistor is there for.

Also, you do not show any load resistor, unless of course you are happy with a 1.25v output that can go no higher and that would make the 120 Ohm resistor the load.

Another question, which of the two IC's do you intend to make the current limit IC, the 338 or the 317?

#### hannahhamzah

Joined Jun 8, 2023
5
You do not say or show what kind of battery.
The LM338 is a 5A version of an LM317 1.5A regulator but the 150 ohms resistor limits its output current to only 8.3mA.
Your LM317 has an output voltage of only 1.25V that is too low to charge any kind of battery.

Your schematic has too many wire bends:
i want to charge a lithium ion battery of 12v

#### hannahhamzah

Joined Jun 8, 2023
5
You circuit rather looks like two constant-current circuits in series.
Try a constant-current circuit driving a constant-voltage circuit connected to your load.
Then, as the load resistance is increased, it will start with a constant-current until the constant-voltage voltage is reached across the load, where it will remain.

What current and voltage do you want?
i would like to observe the output current and voltage to see if this circuit follows the CC-CV theory

#### Audioguru again

Joined Oct 21, 2019
6,441
A single Lithium-Ion battery cell is 4.2V when fully charged. Then three cells make 12.6V and they are stored at a half-charge of 11.1V. When they discharge to 9V then the load should be disconnected.
The battery is still charging when its voltage reaches 12.6V and the charger MUST be disconnected when the charging current drops low. The load must not be connected to the charger when the battery is charging because a Lithium-Ion battery MUST NEVER be trickle charged.
Use a Lithium-Ion battery charger IC.

Here is a graph from www.batteryuniversity.com :

#### Attachments

• 180.8 KB Views: 5
Last edited:

#### MrAl

Joined Jun 17, 2014
10,906
i would like to observe the output current and voltage to see if this circuit follows the CC-CV theory
What circuit?
You did not yet show a working circuit, did you.

#### hannahhamzah

Joined Jun 8, 2023
5
What circuit?
You did not yet show a working circuit, did you.
yes, the circuit is currently still not working as the current is still not constant at 1A. i wasnt sure what is wrong with the circuit

#### Attachments

• 79.2 KB Views: 8
• 81.6 KB Views: 7

#### MrAl

Joined Jun 17, 2014
10,906
yes, the circuit is currently still not working as the current is still not constant at 1A. i wasnt sure what is wrong with the circuit
Yes circuit still is not right.
Look at the data sheet for the U1 circuit try to match yours to that.

#### Audioguru again

Joined Oct 21, 2019
6,441
Maybe you did not look at the datasheets for the LM338 and LM317?

#### Attachments

• 104.1 KB Views: 7

#### Alec_t

Joined Sep 17, 2013
14,007
In post #14, why is V1 shown as an AC voltage source? I see AG has corrected this in post #16.