Switching a PIC circuit from 5 to 12 volts

  • Thread starter Thread starter mishobg12
  • Start date Start date
  • Tags Tags
    Circuit Volts
Click For Summary

Discussion Overview

The discussion revolves around the challenges of switching a PIC circuit from 5V to 12V power supply while ensuring compatibility with CMOS logical levels. Participants explore the implications of using a voltage regulator and the necessary protective measures for the circuit.

Discussion Character

  • Technical explanation
  • Conceptual clarification
  • Debate/contested
  • Mathematical reasoning

Main Points Raised

  • One participant inquires about the compatibility of the PIC with CMOS logic levels, suggesting that since the PIC is a CMOS device, it should work with the expected input levels.
  • Another participant mentions the need for a voltage regulator to power the PIC from 12V, recommending the LM7805 as a suitable option for converting 12V to 5V.
  • There is a discussion about the placement of capacitors, with one participant suggesting that electrolytic capacitors should be used for filtering, while ceramic capacitors are recommended for bypassing near the ICs.
  • One participant asks for clarification on the use of electrolytic capacitors, leading to a discussion about their cost-effectiveness and functionality in smoothing voltage ripple.
  • Participants express varying levels of understanding regarding circuit design and component selection, indicating a need for further clarification on specific practices.

Areas of Agreement / Disagreement

Participants generally agree on the need for a voltage regulator and the use of capacitors, but there are nuances in their understanding of component placement and specifications, indicating that the discussion remains somewhat unresolved.

Contextual Notes

There are limitations in the discussion regarding the specific electrical specifications of the PIC and the exact requirements for the circuit design, which may depend on additional factors not fully explored in the thread.

Who May Find This Useful

Electronics enthusiasts, hobbyists working on microcontroller projects, and individuals interested in power supply design and component selection for CMOS circuits may find this discussion relevant.

mishobg12
Messages
25
Reaction score
0
Hi all,
I have almost completed a project that I power on the breadboard from USB and it works with TTL levels.

But the situation is that I must make it powered by 12V and working with CMOS logical levels (because of the external input to the device).

All my chips are CMOS already (HC to be more exact), but at the moment working with TTL logical levels. So, I guess, there will be no problem with them, and for powering the PIC probably I could use a stabilizer. But I don't know what to do about making compatible the CMOS logical levels that are going to be sent by the ICs with the PIC.

And another question, can you give me some good advices about putting protection on the device input from high voltages and big currents so that the chips won't burn out.

Thank you
 
Engineering news on Phys.org
mishobg12 said:
Hi all,
I have almost completed a project that I power on the breadboard from USB and it works with TTL levels.

But the situation is that I must make it powered by 12V and working with CMOS logical levels (because of the external input to the device).

All my chips are CMOS already (HC to be more exact), but at the moment working with TTL logical levels. So, I guess, there will be no problem with them, and for powering the PIC probably I could use a stabilizer. But I don't know what to do about making compatible the CMOS logical levels that are going to be sent by the ICs with the PIC.

And another question, can you give me some good advices about putting protection on the device input from high voltages and big currents so that the chips won't burn out.

Thank you

You're asking two separate questions here:

1) Will the PIC be compatible with CMOS logic levels?

Yes, since the PIC is a CMOS device, and the range of values for acceptable inputs (low under the electrical specifications in the datasheet for your particular device) are fairly broad. The digital outputs (which are nearly GND, and Vcc) should also be capable of triggering any CMOS logic you may have.

2) How do I power my PIC off of 12V?

You didn't make it clear in your post, but presumably, you would also need to power your other logic with 5V, and not 12V, and thus, your logic levels should still be 5V and 0V (I don't recall any of the families being able to deal with really high Vcc voltages, beyond maybe 6 or 7 V). In that case, you just need a voltage regulator, say, something like an LM7805 (they're cheap--make sure to use 10 or 100 uF electrolytic capacitors on input and output to ensure output stability: you don't have anything too high speed, so you shouldn't need to worry too much about slowed responses as a result of these higher capacitances)

An example of an LM7805 (it's a genericized, or so heavily cross-licensed that it might as well be, part that dozens of companies produce and should be able to get to you for under a $1 per, in lower volumes):
http://www.fairchildsemi.com/pf/LM/LM7805.html

EDIT: I should mention that the 7805 takes in 12V, and outputs 5V to power your PIC, logic, etc.
 
Thank you for answering. I am sorry I didn't explain well enough in my original post.

So as far as I understood, I keep everything the way it was when I was powering the circuit from USB, just add this voltage regulator to the power supply line to make it 5V. And the capacitors I should put between the device input (the connector) and the PIC's pins (where there used to be nothing). Is that correct?

And would you mind to explain briefly why exactly electrolytic capacitors?
 
Last edited:
Yes, keep your circuit the way it used to be, but see Figure 7 of the datasheet linked in the link I gave earlier for how to connect the capacitors. You would not connect across the unused I/O pins of the PIC, though it is good practice to put CERAMIC bypass capacitors (usually something like 0.1 uF or thereabouts) between the power and ground pins of your ICs right next to the ICs themselves (the ones you're powering, not the voltage regulator ones):
http://www.seattlerobotics.org/Encoder/jun97/basics.html

The reason you use electrolytics for the regulator filter capacitors is that they're cheap, and do a reasonable job of removing voltage ripple on the input (and output). You also don't care if they're off by 50 or 80%, or that they 'leak' a fair bit, since you use such a large value anyway. Ceramics are smaller, and generally more expensive (for any given value, within a tolerance class). But their small size, low power dissipation (that leakage current gets turned to heat) and general non-polarization (unless you're dealing with tantalums) also make them ideal for bypass capacitors.

These broad generalizations are just what I've heard (and taken to heart), so someone else may weigh in differently. I should also point out that if you disassemble PC power supplies (or many other wall-supplied supplies that need very steady output) you'll find banks of high-value capacitors: these are mostly used to smooth out the ripples and eliminate the noise that they get from the input. NOTE: Do not disassemble power supplies without knowing what you're doing! These 'great big capacitors' sometimes retain charge for months and can give you a rather unpleasant (or even fatal) surprise!
 
Thank you, MATLABdude. You've been very helpful.
 

Similar threads

  • · Replies 13 ·
Replies
13
Views
5K
Replies
4
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 4 ·
Replies
4
Views
2K
  • · Replies 2 ·
Replies
2
Views
1K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 19 ·
Replies
19
Views
2K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
1
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K