Author Topic: LTspice simulation of MC34063 regulator.  (Read 13982 times)

0 Members and 1 Guest are viewing this topic.

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
LTspice simulation of MC34063 regulator.
« on: August 07, 2013, 11:35:55 am »
I fail to run the simulation.
Diode data is not involved in lib and how can i solve this problem?
Please do guide me. Thank you!
 

Offline Psi

  • Super Contributor
  • ***
  • Posts: 9889
  • Country: nz
Re: LTspice simulation of MC34063 regulator.
« Reply #1 on: August 07, 2013, 12:01:52 pm »
Is your voltage source even grounded?

I did have problems opening the file due to missing pot and IC components, so it may actually be correct.
But for me the voltage source has no ground in your circuit.

I'm also not sure about your switch/relay, can you use it like that without any of the control wires connected?
Greek letter 'Psi' (not Pounds per Square Inch)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #2 on: August 07, 2013, 12:36:32 pm »
I did the mistakes. My voltage is not grounded but now i have corrected it.
This is really my circuit.  I am very sorry for the inconvenience.
I get the MC34063 circuit from LTspice yahoo group. But k cant run the simulation though.
Please guide me and i really need your advice
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #3 on: August 07, 2013, 12:37:13 pm »
Please attach the MC34063 model file you have, I think it might have pins swapped (4 and 5).

Here's how I got your file to work, with what you've given me:

- Put in my own MC34063 model because yours is missing; swap pins 4 and 5.
- Replace the potentiometer with two resistors (I don't have that model either)
- Replace D2 with one I have a model for (1N4007)
- Remove the TVS diode that you've named "K" for some reason... ???
- Remove and bypass S1 which has not been connected or given a model.
- Remove D3.
- Remove V2.

Now it works.

Remember that the "value" field actually means something to SPICE. You can't just go sticking in things like "zener diode" and "A". Also, V2, a zero-volt voltage source, is a dead short on the output.

It might make your schematic a bit cleaner, too, if you leave out things that don't affect the simulation. That TVS diode, D2, C1 and C2, D4...
« Last Edit: August 07, 2013, 12:48:21 pm by c4757p »
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #4 on: August 07, 2013, 02:02:10 pm »
Hello. Thanks for your advices. May you do a favor for me?
I think i need your MC34063 model. Can you attach it to me? Thanks a lot.
By the way, this is the link of the project. http://electronics-diy.com/schematics/ipod_charger.htm
Those C1 or diodes have their own role in this project. And the voltage output should be 5V.
Anyway,thanks a lot :-+
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #5 on: August 07, 2013, 02:09:13 pm »
This is MC34063 model.
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #6 on: August 07, 2013, 02:17:25 pm »
That's just the symbol... You need the model file as well!! Here, I attached mine. Just take the .txt extension off.

OK, the pins are fine, they just moved them graphically in the symbol.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #7 on: August 07, 2013, 02:29:43 pm »
I am very sorry that i have no idea to off the txt extension. |O
Please attach the model with zip file. Really need your help. Thanks a lot.
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #8 on: August 07, 2013, 02:35:05 pm »
Yahoo! I have removed the txt extension. Should i put the file into 'sub'?
But when i pick out MC34063, it is not considered as SPICE???????
????????????????????????????????????????? :palm:
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #9 on: August 07, 2013, 02:46:14 pm »
Yahoo! I have removed the txt extension. Should i put the file into 'sub'?

Yes.

Quote
But when i pick out MC34063, it is not considered as SPICE?

I don't really know what that means. ???
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #10 on: August 07, 2013, 03:06:01 pm »
????????????????????????????????????????????????
?????????????????????????????????????????????
????????????????????????
???????????
« Last Edit: August 07, 2013, 03:07:45 pm by humvivz »
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #11 on: August 07, 2013, 03:09:32 pm »
I can't help you unless you can explain yourself more clearly. Shitting out a pile of question marks doesn't help me. What do you mean by "not considered as SPICE"? I assure you it is...
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #12 on: August 07, 2013, 03:13:26 pm »
I am sorry for the inconvenience. :-[
I think i need a sub file of MC34063.
Do you mind to upload the sub file again by using zip?
Thanks again and sorry again.
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #13 on: August 07, 2013, 03:20:32 pm »
I just re-downloaded the file and did a byte-for-byte compare with the original file on my hard disk that I use all the time and it matches. It is the sub file. Just needs to be renamed!

Here it is, though....
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #14 on: August 07, 2013, 03:35:00 pm »
Make sure all the files are where LTspice can see them. Easiest place is where it keeps its own files. Then you should be able to just plunk down the schematic symbol and use it directly. Looks like there aren't any naming differences or anything between your symbol and my model, so it should work without modification :-+

And you really need to brush up on computer skills like that...... Changing an extension is just basic renaming. If your system is set to hide extensions, fix that shit now, it's a recipe for virus problems anyway.

Once you've done that, just grab the file, hit F2 (or right-click, Rename) and lop off the .txt!
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #15 on: August 07, 2013, 03:48:47 pm »
:D Thanks you very much.  :-+ yes. You are right. I really need to sharpen my computer skill ^^
I am not purposely putting the question marks and emoticons. There are some mistakes and i feel shocked about it too. Sorry.

By the way, I have uploaded screenshot. The problems that make me fail to run simulation.Please do guide me. Thank you and sorry  :)
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #16 on: August 07, 2013, 03:58:44 pm »
Hehe... sorry for being a bit grouchy there.... but maybe you should stop letting your cat walk on your keyboard! ;)

OK. Well, you're going to have to address all the problems I listed above. Right now it's bitching about the potentiometer, because you don't have the model for it installed (or loaded). Just replace it with a pair of resistors.

After that, it'll pitch a fit about D2 (because it doesn't have a model for 1N5404), the TVS diode that you've labeled "K", S1 (because first, there's nothing connected to the control terminals, and second, it doesn't have a model specified), and D3 (because "zener diode" isn't a proper value). Just take those out and get the circuit working, you can add them back in later.

Then, once it starts simulating, it won't work well, because V2 is a short circuit across the output. (It's a 0V voltage source.) Remove it.

When it first starts running, it might get stuck (giving the messages "Stepping Source" and "Damped Pseudo-Transient Analysis" in the status bar). You don't have to wait for those to complete, just bang on Esc a few times. (Three times IIRC)
« Last Edit: August 07, 2013, 04:06:09 pm by c4757p »
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #17 on: August 07, 2013, 04:03:42 pm »
Actually that's a dog. haha. Just kidding. The truth is i set chinese language as priority language  and that's why it turns out like this. When i preview it, it looks normal but errr....it turns out in other way haha.. |O
By the way, really thanks for your patience. :-+ Wish you have a nice day !
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #18 on: August 07, 2013, 04:07:37 pm »
Ah. I understand now. This forum has a problem with international characters. Worse, it shows them correctly in the preview |O

Hint: You might get more sympathy for language issues if you set your home country in your profile so we can see it.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #19 on: August 07, 2013, 04:14:31 pm »
I follow your advice and make some changes. But there are still some mistakes here.

Regarding to the language issue, err...that's my mistake haha..I should be more careful. Anyway, thanks for advice. :)
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #20 on: August 07, 2013, 04:17:57 pm »
Either MC34063.sub is installed into the wrong place, or you forgot to close and reopen LTspice after installing it.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #21 on: August 07, 2013, 04:25:28 pm »
I reopen LT-spice more than one time.
And i have checked both files names either in sub or asy. They are the same. 
As i right click the MC34063, it turns out like this.(file 66)
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #22 on: August 07, 2013, 04:38:33 pm »
Ah.... that asy file is missing its model file declaration.

Here, I fixed it, install this.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #23 on: August 07, 2013, 04:59:22 pm »
Yahoo..finally the simulation can be run now! :-DMM
Unfortunately, the output voltage is only 2.1V  :-BROKE
These are my sub and asy file of potentiometer. Can you help me to check? Thank you!
The output voltage must be 5V. because generally mp3 charger only requires 5V.
Then i think maybe potentiometer can help me to get 5V.
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #24 on: August 07, 2013, 05:04:04 pm »
Tear out R8. Change R4 to 3k and R6 to 1k. If you don't have a 3k resistor, use 10k and 3.3k instead of 3k and 1k. Then do some reading. MC34063 expects to see 1.25V on the feedback pin when the output voltage is correct.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #25 on: August 07, 2013, 05:13:46 pm »
Yeah!!!!! finally!
Thank you so much  :-+ :-DMM
By the way, what does it mean that MC34063 will give me feedback? Is it i have to put the probe on pin(gnd)?
Really thank you! :clap:
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #26 on: August 07, 2013, 05:18:35 pm »
The MC34063 will back off the output when the voltage at the Cinv pin hits 1.25V. You set the output voltage by using a voltage divider chosen so that when the output is what you want, the Cinv pin sees 1.25V and the MC34063 stops increasing the voltage.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #27 on: August 07, 2013, 05:32:14 pm »
 ;D i got it!
it means Cinv pin acts as sensor,which instructs the MC34063 to continue increase the voltage or stop increase it until i gain the desired output voltage.

Can i ask one more question?
I have to design a 220uH inductor. I know i need datasheet of the iron core to determine how many turns of the coil? Anything else i should consider?

By the way, thank you  :-+
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: LTspice simulation of MC34063 regulator.
« Reply #28 on: August 07, 2013, 05:36:43 pm »
I'm sure there is, but magnetics really isn't my thing, hopefully someone else can answer that! I usually just throw some wire on a core until the LCR meter reads 220uH... ;D
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline humvivzTopic starter

  • Contributor
  • Posts: 25
Re: LTspice simulation of MC34063 regulator.
« Reply #29 on: August 07, 2013, 05:39:35 pm »
Good idea!! ;D
Anyways, Thank you c4757p  ^^
I need to sleep now. :=\
Good bye. And wish you have a great day! Thanks again ??? |O
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf