Maximum Digital Input Voltage of an M2 Chip?

louie55

New Member
I've been scouring the Manuals, Datasheets, Forum, Google, and Wikipedia to try to find the maximum DC input voltage for a 14M2 PicAXE chip. I'm talking about a digital input signal, not the supply voltage. I will be using a 5V voltage regulator for the supply.

But my input signal for triggering my PicAXE program is going to be 32VAC. I will have this going through a Bridge Rectifier and filtered with a 10uF capacitor to smooth it out. (The reason I'm using such a small cap is because it won't be driving any current, it will only be used for the input pin as a digital 1. My circuit supply voltage will be coming from a different source.).

After rectifying and filtering the voltage, it will be about 45VDC. My question is how far do I have to drop this down using a voltage divider before it gets to the input of the PicAXE? Do I have to drop it all the way down to 5V? Or can the PicAXE handle a higher input voltage?

The only documentation I have found concerning this issue is on Wikipedia where it says:
Most Digital Inputs are protected by diode clamps to the power rails, which as well as offering good ESD protection, allows interfacing to high voltage signals often with little more than a current limiting resistor being required.
However, it doesn't define "High Voltage Signals".

I can use an 82K resistor and a 12K resistor to divide the voltage down to 5V, but I thought that if I could just use one resistor in series with the input pin as Wikipedia says, I could save some space as I am using a fairly small board and space is an issue.

But regardless of my circuit, it still would be nice to know the maximum input voltage of a PicAXE chip.

Thanks.
 

mrburnette

Senior Member
Louie55
Pick your PICAXE model from here and pull the full PDF Microchip manual:
http://www.picaxe.com/What-is-PICAXE/PICAXE-Chip-Labels/

It appears that you already know about ESD protection, but I would not venture beyond what RevEd states specifically since this is their forum. Take a look at what they do with the 10K & 22K resistors that manage RS232 signaling from +5 upwards and then adapt to suit.

-Ray
 

louie55

New Member
Pick your PICAXE model from here and pull the full PDF Microchip manual:
http://www.picaxe.com/What-is-PICAXE/PICAXE-Chip-Labels/
Thanks for this link. I didn't see those data sheets. All I found were the PicAXE manuals. But in the datasheet there, under DC characteristics for "Input High Voltage", it lists a minimum of 2V (TTL Buffer), but lists no Maximum voltages for this section. Surely there has to be a maximum?? Or can I just hook my 45VDC to the input with just a 10K resistor in series to limit current?

It appears that you already know about ESD protection, but I would not venture beyond what RevEd states specifically since this is their forum. Take a look at what they do with the 10K & 22K resistors that manage RS232 signaling from +5 upwards and then adapt to suit.
Where do I find this?

Thanks.
 

mrburnette

Senior Member
T
Where do I find this?

Thanks.
You are most welcome to the links. Re: Max voltage/ current on ESD for Microchips or RevEd's recommendations - well, I have never seen that published. My point earlier was you can take the RS232 spec and RevEd's values and calculate it for yourself.

Try Googling this " microchip max esd voltage "

So, my personal 'guess' as to why this is not published is that it would be less-than-smart to design for something that may be damaged with no way to verify the esd diodes are good... not like they have little poke-up parts that work like the "done" thermometers pressed into turkey breasts.
 
Last edited:

westaust55

Moderator
Surely there has to be a maximum?? Or can I just hook my 45VDC to the input with just a 10K resistor in series to limit current?
The data can be found in the Microchip datasheets.
For every micropcontroller (and most other chips) there is a section entitled: "Electrical Specifications"

The first subsection is; "Absolute Maximum Ratings"

To answer your question the line is:
Voltage on all other pins with respect to VSS ........................................................................... -0.3V to (VDD + 0.3V)
where Vdd is the supply voltage.
This applies not only to inputs but also outputs such as when one is used in open collector mode (as is the case for 1-Wire, READTEMP and i2c functions).

Note that this is the ABSOLUTE MAXIMUM. In reality you should not exceed the supply voltage Vdd
For this reason resistors or other devices are used to control the voltage applied to the microcontroller pins.
 

mrburnette

Senior Member
Hey, West,

re-read the Wiki post in post #1... what louie55 is after (I think) is how much current can the ESD diodes handle in a continuous manner so that a high-valued resistor can be calculated from: 45V - 5V - Vd = 40V / ?I = R. Where R is a single value resistor NOT part of a voltage divider and Vd is the esd diode forward drop.

I have seen the type of information discussed in design documents where individual components are used, but for uC and packaged electronics the ratings are usually the non-destructive energy (Watts or Joules) that can be dissipated and not a steady-state value.

At least this is what I think he wants.
 

louie55

New Member
westaust55: I did also see that line in the datasheet but it seemed to contradict the line I found on Wikipedia so wasn't sure if that was the right spec for what I wanted.

mrburnette: I don't want to express the idea that I'm trying to do anything more that just input a digital "high" signal into the PicAXE using 32VAC as a source. Anything more complicated or in-depth than that is beyond the scope of what I'm trying to do. If using a 2-Resistor voltage divider is the easiest, best way to do that, then I will do it. I can find the space on my board for it.


This was more a question based on curiosity since I couldn't find the answer to the question at the time. If I need to drop the signal down to match the supply voltage, then that is what I will do.

I have one more question pertaining to this subject concerning the pull-down of the input pin, but I will post a schematic picture in my next post to illustrate what I want to ask. A picture is worth about 10,000 words in electronics! Off to draw it.....
 

louie55

New Member
Ok, here is the (Very Simplified) drawing:

Circuit-Drawing.jpg

As you can see, I have a 5VDC Supply. I also have the 45VDC input signal (Created from Rectifying/Filtering the 32VAC Signal). The Voltage divider will drop the voltage down to around 5V for the input pin, however, my question is where do I ground the voltage divider? Do I ground it to the 45V ground or the 5V ground?? I thought that since the chip is referencing 0 Volts from the 5V ground, that if the 10K resistor (also acting as a pull-down) wasn't connected to the 5V ground that the input pin might not be pulled down correctly if the resistor was connected to the 45V ground.

Or, can the 5V and 45V ground be connected together? It didn't seem like that would be a good idea, but I'm not sure. I've never worked with 2 seperate supplies like this before, that is why I'm not quite sure how to proceed.

As is probably apparent, I'm not an expert in electronics, I'm still what could be called a "beginner", though I do have some experience.

Any help would be appreciated. Thanks.
 

Attachments

mrburnette

Senior Member
But my input signal for triggering my PicAXE program is going to be 32VAC. I will have this going through a Bridge Rectifier and filtered with a 10uF capacitor to smooth it out. (The reason I'm using such a small cap is because it won't be driving any current, it will only be used for the input pin as a digital 1. My circuit supply voltage will be coming from a different source.)
What is your intent? Are you just wishing to monitor the AC supply to detect on/off or is the PICAXE input more complex?

Generally, with two single-ended power supplies, a common GND is required to establish "0" Volts or Low logic level. But going back to your original post, you talk about a "separate source" so I want to make certain in my mind that the neutral AC reference for both sources are in fact the same. If so, then a common ground can be established - if not, something like an opto-isolator may be required.

So, a simple statement of what you wish to achieve by the monitoring activity would be helpful.

- Ray
 

louie55

New Member
What is your intent? Are you just wishing to monitor the AC supply to detect on/off or is the PICAXE input more complex?
Just a simple on or off is all I need. Nothing complex.

I'll give some more detailed info on my power supply. Here's a drawing of it:

Circuit-Drawing-2.jpg

Both supplies are coming from the same transformer which is connected to 120VAC on the Primary side. And the Secondary Side has 5 Wires. 3 of them are a center-tap setup and the output of one side to the center tap is 32VAC. 2 other wires output 12VAC.

The 12VAC becomes my 5VDC Circuit Supply and the 32VAC becomes my input signal. As seen in the drawing the 32VAC supply is controlled by external circuitry that I just represented with a box in the drawing since what it contains isn't important to the discussion. Suffice it to say that the external circuitry will turn the 32VAC on and off at certain times which my Microcontroller will need to monitor.

Also, before you think I'm crazy for designing a circuit this way, I didn't design it. I must interface with existing (OLD [Circa 1950s]) circuitry and I have no choice in the matter, so this is how I must get my power and my input signal for my board.

So, yes, if you go back to the original AC Supply, they do share a common neutral.

Hope this helps in answering my question.

Thanks!
 

MartinM57

Moderator
I don't have a data sheet handy, and not sure the data is in there anyway. I'd assume the ESD diodes can take no more than 0.5mA

The download circuit uses 22K to protect the PICAXE from a max of 15v (RS232 logic zero) so it's in that ballpark.

EDIT: some people don't like a design relying on the ESD diodes. I'd probably use a divider, as that also guarantees a logic 0 when the signal being measured is floating, which may happen when your circuit is switched off?
 
Last edited:

louie55

New Member
some people don't like a design relying on the ESD diodes. I'd probably use a divider, as that also guarantees a logic 0 when the signal being measured is floating, which may happen when your circuit is switched off?
Yes, that seems to me to be the best method too after more research. Just awaiting more help on how exactly to ground my divider. (See my last 2 posts & drawings)
 

srnet

Senior Member
I don't have a data sheet handy, and not sure the data is in there anyway. I'd assume the ESD diodes can take no more than 0.5mA

EDIT: some people don't like a design relying on the ESD diodes. I'd probably use a divider, as that also guarantees a logic 0 when the signal being measured is floating, which may happen when your circuit is switched off?
The Microchip data sheets are ambiguous on the topic, read it one way and the diodes are capable of 25ma, but I have seen a tech note that suggests a long term max of 500uA, which is enough in any case.

And whilst the max pin voltage is quoted at +\- 0.3v, this would seem to apply to pins with shared digital and anaolue inputs, and pins that are digital only ought to be +\- 0.6v.

I would also use a divider with a grounding resistor, so you dont get false results when the measured voltage is floating.

However for this application, having now seen the circuit, I would be suggesting an opto-isolator ........
 

westaust55

Moderator
For the 14M2 see the datasheet: http://ww1.microchip.com/downloads/en/DeviceDoc/41440B.pdf
On page 121 there is a typically circuit with the ESD diodes shown.

also under the heading: Analog Input Connection Considerations
A simplified circuit for an analog input is shown in Figure 19-3. Since the analog input pins share their connection with a digital input, they have reverse biased ESD protection diodes to VDD and VSS. The analog input, therefore, must be between VSS and VDD. If the input voltage deviates from this range by more than 0.6V in either direction, one of the diodes is forward biased and a latch-up may occur.
Some more reading on ESD can be had here:
http://ww1.microchip.com/downloads/en/AppNotes/00595B.pdf


A common theme seems to be that latch-up may occur if the ESD diodes forward conducts.

My own approach (as expressed above by others) has been to use resistor dividers.
For simple 5V - 3V level interface the use of a FET transistor (eg 2N7000) or chips which when operating on 3V specifically have 5V tolerant inputs (eg 74LVC245A).
 

srnet

Senior Member
The only caveat to the resistor devider approach, is that it does rely on the input voltage being fairly consistent, if it varies a lot then you can exceed the pin input volts at one end, or not have a porper logic 1 at the other.

An opto isolator would solve this problem, and avoid any possible issues with supply interaction, noise or grounding issues for instance.
 

Dippy

Moderator
Good advice.
There is a lot of info about higher voltages going into PIC inputs around.
But there is a whole World of difference between what-can-be-done and 'Best Practice'.

Yes, you can rely on the clamps assuming you restrict the current.
The latch up is a possibility, but we don't know under what conditions that happened.
And was it 1:100 or 1:1E6? None of us here know.
So, it is probably a bottom-covering statement by Microchip.

In fact there is a current App Note describing how to do this with no mention of latch-up.
To improve the clamping efficiency and speed you could parallel some Schottky diodes.
I have done 'scope measurements which prove the benefits of this.
Not forgetting a suitable R (or even 2 x R for belt&braces).
You must also remember that clamping is basically diverting excess oomph onto power lines, so you must ensure that these lines can absorb that extra lump. Guide: make sure the limiting res keeps the current through clamps very low.

But in your case this may not be the best method anyway.
A bridge + Cap + R would probably work OK.
But what about response speed?
If it is very important then the 10uF cap discharge time may not be ideal.
This hasn't been mentioned.

The Bridge/cap/Pot-div would be safer.
Another option is Res + Zener. I've used this 100% with level-shifting serial comms.
The afforementioned opto isolator is safest.
You can get AC versions to save the need for a bridge. Small cap on o/p.
These methods mean you don't stress the internal clamps.
So, several methods. Choose the one most appropriate.
 

mrburnette

Senior Member
Just a simple on or off is all I need. Nothing complex.

I'll give some more detailed info on my power supply. Here's a drawing of it:

View attachment 10561

Both supplies are coming from the same transformer which is connected to 120VAC on the Primary side. And the Secondary Side has 5 Wires. 3 of them are a center-tap setup and the output of one side to the center tap is 32VAC. 2 other wires output 12VAC.

The 12VAC becomes my 5VDC Circuit Supply and the 32VAC becomes my input signal. As seen in the drawing the 32VAC supply is controlled by external circuitry that I just represented with a box in the drawing since what it contains isn't important to the discussion. Suffice it to say that the external circuitry will turn the 32VAC on and off at certain times which my Microcontroller will need to monitor.

Also, before you think I'm crazy for designing a circuit this way, I didn't design it. I must interface with existing (OLD [Circa 1950s]) circuitry and I have no choice in the matter, so this is how I must get my power and my input signal for my board.

So, yes, if you go back to the original AC Supply, they do share a common neutral.

Hope this helps in answering my question.

Thanks!
OK. Since you are using 2 isolated coils on a common ferrite form (transformer) and since there is black-box switching involved on the 32VAC winding, I can only recommend that you use an Optoisolator. Establishing a common ground after the DC rectification is certainly possible; however, my concern is your black-box (non-relevant to the discussion item... NOTE- everything is relevant) that can introduce back-EMF into the transformer and thereby adversely affect the co-winding for the LM7805 used for the 5V. A common-ground "could" create a situation where a transient might propagate by ground loop current. With a high quality switching supply, it is very common to see a common ground being established, but design precautions are taken to ensure that any ground currents stay within the supply cage.

Consider an opto-isolator for interfacing to the PICAXE and your circuit will be significantly more robust.

- Ray
 

louie55

New Member
my concern is your black-box (non-relevant to the discussion item... NOTE- everything is relevant) that can introduce back-EMF into the transformer and thereby adversely affect the co-winding for the LM7805 used for the 5V.
Well, what is inside the "black box" is printed on a schematic that is 13" X 11" so I didn't really want to explain the whole thing. That 32VAC output is powering about 6 relay coils, some of which are actually 24VDC because that 32V also gets rectified to 24VDC in that "Black Box". However, to get to my circuit, the voltage passes through one toggle switch contact (which is usually always on), and 2 relay contacts. So maybe that might make a difference. But not sure if I need any switch debounce in my circuit because as soon as the PicAXE senses a high signal, it will switch to a different section of the program and won't be monitoring the input pin again for a few seconds, so a little switch bounce should be acceptable.

Consider an opto-isolator for interfacing to the PICAXE and your circuit will be significantly more robust.
Ok, I will do some research on that. I've never actually heard of an opto-isolator until now, so let me go read a bit........

Ok, it seems an opto-isolator is simply a type of solid-state relay which isolates the input from the output. So, I would need to run my input signal to the isolator, then the output would be switching my 5V supply to the input pin. Is this correct?

Any suggestions on which opto-isolator I should use? Any chance of a simple example drawing? Do I need any external transistors or do I just need the isolator and some resistors? Also, what voltage do I input to the isolator?

Any help would be appreciated.

Thanks.
 

mrburnette

Senior Member
PS2532-Example.jpg

Check out some practical devices: TLP504A, LTV-816 (COM-00314 Sparkfun), etc. Look up the datasheets and examples.

You can configure the the open collector/emitter device as pull-up or pull-down with an appropriate resistor... or use the optional weak pull-up resistor in the PICAXE if it meets your requirements... generally will, but was designed for switches and shorting-connectors, so you need to verify that there is enough current at 5V to drive the transistor into the LOW logic state for the PICAXE. In your case, edit the 50 Ohm current limiting resistor to a higher value and calculate for constant on-time with the 40+ volts you intend to use for the internal LED. The datasheet will help here... the "CTR" value will help you with the LED nominal current.

Prototype just the optoisolator and a PICAXE with a few lines of code... verify you have it right. Then move forward with the integration.

And then since you are in the U.S., your choices for supplier is vast!

- Ray
 
Last edited:

hippy

Technical Support
Staff member
if I could just use one resistor in series with the input pin as Wikipedia says, I could save some space as I am using a fairly small board and space is an issue.
The official situation is that pins should not have more than the manufacturer's stated absolute maximum voltage applied, usually Vdd + 0.3V for PICmicro / PICAXE.

Reality is that higher voltages can usually be applied without observable adverse consequences with appropriate current limiting as Wikipedia indicates, as many engineers have been doing for years, and as Microchip have also demonstrated being used for PICmicro in their past application notes.

Three things are essential; that the input pin has ESD or ( internal or external ) clamping diodes to Vdd ( and/or Vss ), the injection current does not exceed the maximum allowed, the injection current is not large enough to change Vdd or Vss outside of their maximum ranges.

If the injection current is too high then there can be issues with parasitic powering which may prevent a PICmicro / PICAXE from generating a clean reset.
 

Dippy

Moderator
Ah, the diagram clears up things.

Do as RAY suggests. Forget all else as you hadn't (in your original post) described the ground arrangements - nothing to do with mains Neutral.

You will need a sutiable current limiting resistor. You can calculate that with a slightly modded Ohm's Law.
Don't run the opto LED to the max.
Your transistor side current will be small to switch an Input pin on/off so just about any old Opto Isolator will do.

Go to a big vendor and search their site. Just type it in the search box and press the tit.
Find a couple of options and post them here.
I would choose the cheapest transistor style you can find. Speed and (typical) CTR are largely unimportant in this application.
 

louie55

New Member
How about this one?:

http://www.toshiba.com/taec/components2/Datasheet_Sync/206/4215.pdf

This one can handle AC input so then I would not need the rectifier or capacitor. I would just need a 1W 1.6K resistor in series with the 32VAC signal to limit the current to around 20mA. Does this sound right?

Also, after looking at various pages about opto-isolators, I see that the best way to set them up is with the output inverting. Meaning, when the input is ON, the output is OFF. Is this the correct "normal" way to hook these up?

Here's a quick drawing I threw together:

Circuit-Drawing-3.jpg

Does it look close? Or am I missing something?

Thanks.
 

mrburnette

Senior Member
I do not see an issue with your selection (have not downloaded and read the PDF.). Looking at your proposed schematic, the 1K emitter resistor could be as High as 10K since the uC input pin is a light-load. Remember that the AC voltage is specified in RMS and not peak!! :eek:

As for the internal LEDs, verify their power requirements... you may be able to getaway with 10mA... their sole purpose is to shine photons on the base of the photo transistor and there is not too much distance to travel!

- Ray
 

louie55

New Member
Well the Recommended Operating Conditions of the isolator I chose are:

LED Forward Current: 16mA Typical, 20mA Max
Collector Current: 1mA Typical, 10mA Max

I chose resistors that would give me 20mA LED current (Just to make sure that the transistor is completely saturated) and 5mA collector current.

(Note: The 20mA max on the LED is just the recommended max, not the absolute max that it can handle. The absolute max is 60mA)

So, the design looks ok?

I will just have to change my BASIC code to monitor for the input pin going LOW instead of HIGH.
 

mrburnette

Senior Member
Just convert the RMS AC voltage to peak volts to calculate the current limiting resistor for the LED. Then breadboard and test...
- Test the LED current (AC current) limiting resistor with your transformer and VOM/Scope
- Test your Optoisolator with your chosen resistor to +5V and watch the voltage switch on VOM as you jumper the AC side
- connect to PICAXE for smoke test
- update code

Just an old man's suggestion... when you order an inexpensive part like an optoisolator, get at least 2. In your early days of experimentation, you will often need the second device. Later, with experience, you get to build up a nice supply of small components.

- Ray
 

louie55

New Member
Ok, thanks for the info.

I'll change the 1.6K resistor to a 2.2K Resistor because I was going by RMS.

Also, yes, I always order extra of every cheap component. When a component only costs 50 cents or less, you might as well get a few extra in case you burn one up and for future projects (also if your paying freight, it isn't worth it to only order a couple small components). I've already exploded a transistor and burnt up a 555 timer with my in-experience. :D

I will try all this out and post back some time in the future.

If you or anyone else has any more input on my circuit please post it!

Thanks!
 

MartinM57

Moderator
I think you need a capacitor across the PICAXE input - at and close to (~1v?) about the zero crossing of the AC the opto-isolator will not be conducting and I would predict that you will get 'logic 1' spikes at twice the supply frequency. If you happen to read the input at that time, you will read a logic 1 I.e. equivalent to no supply.

Value of the cap? You could work it out with some math, you could do some investigations with different values and a scope, or you could put some test code in the PICAXE (loop until logic 1 is read; light a LED;pause 1 sec;goto start) and increase the value until the LED never comes on...then double it. Gut feel says start with 220nF or so (maybe!)

EDIT: oh, and maybe a parallel high'ish resistor across the cap to discharge it between spikes
 
Last edited:

Armp

Senior Member
Yes, you can rely on the clamps assuming you restrict the current.
The latch up is a possibility, but we don't know under what conditions that happened.
And was it 1:100 or 1:1E6? None of us here know.
So, it is probably a bottom-covering statement by Microchip.

In fact there is a current App Note describing how to do this with no mention of latch-up.
Can you give the App Note number please?
 

Armp

Senior Member
I have that App Note, but it's dated 1997, and relates to the 16C5X family built in a very different process than the M2 chip technology. I guess I misunderstood your use of 'current'?

BTW - Microchip Doc TB3009 "Common 8-Bit PIC® Microcontroller I/O Pin Issues" http://ww1.microchip.com/downloads/en/DeviceDoc/93009A.pdf , dated 2008 says:

Note: Passing current through the ESD protection diodes of the device is outside of the operating
conditions of the device causing potentially shortened device life span and incorrect functionality
Until RevEd offers free replacement of dead PICAXES I'll take Microchip's advice....
 

louie55

New Member
I think you need a capacitor across the PICAXE input - at and close to (~1v?) about the zero crossing of the AC the opto-isolator will not be conducting and I would predict that you will get 'logic 1' spikes at twice the supply frequency. If you happen to read the input at that time, you will read a logic 1 I.e. equivalent to no supply.

Value of the cap? You could work it out with some math, you could do some investigations with different values and a scope, or you could put some test code in the PICAXE (loop until logic 1 is read; light a LED;pause 1 sec;goto start) and increase the value until the LED never comes on...then double it. Gut feel says start with 220nF or so (maybe!)

EDIT: oh, and maybe a parallel high'ish resistor across the cap to discharge it between spikes
Ok, I will try this out during testing.

My PicAXE will be constantly looping and monitoring the pin for a LOW signal. And the AC Supply will be off during that time so it shouldn't get any false readings should it? And when the AC supply switches on, even if the input signal does start switching LOW,HIGH,LOW,etc.. quickly, as soon as the PicAXE detects the first low, it will activate, so it might work the way I have it drawn?

But, like you said, it's better to do some testing with an LED and see for myself. I'll try a capacitor/resistor and see what happens.
 

Peter M

Senior Member
Hi all, a rather old post, but from the data sheets supplied by the link from westaus55 it would appear a pins absolute max current on those diodes is 20mA. yes I was wanting to know as well. I want some protection incase an i/p goes over where it is meant to be.
thanks all for saving me a lot of time.
24589
 

AllyCat

Senior Member
Hi,

Yes, that is the specification, what is the issue? It's the reason for generally putting a resistor in series with most (PICaxe) inputs, for example the 22k in the Serial/Programming input to tolerate the (possible) +/- 15 volts of "real" RS232 inputs. The "cautious" approach is to use the diodes only for (electrostatic) "protection", not as a functional component.

Also, note that currents flowing in the "negative" (substrate) protection diode(s) can upset the ADC performance. Thus there used to be an "Enhanced Serial Download Circuit" in Manual 1, but now that is considered "obsolete" with the TTL programming levels from the AXE027 and most "RS232" USB serial adapters.

Cheers, Alan.
 

inglewoodpete

Senior Member
Also, note that currents flowing in the "negative" (substrate) protection diode(s) can upset the ADC performance. Thus there used to be an "Enhanced Serial Download Circuit" in Manual 1, but now that is considered "obsolete" with the TTL programming levels from the AXE027 and most "RS232" USB serial adapters.
The "Enhanced Serial Download Circuit" in Manual 1 is only "obsolete" when ADC is used in combination with TTL-serial cables. Firstly, I still use an AXE026 and a RS232 (motherboard based) com port on my desktop computer - so not obsolete for me.

This thread is getting confused and off topic but it is/was about using up to 45 volts AC as an input to a PIC or PICAXE. If ADC is used on the same chip that has an AC input on another pin, then the Enhanced port input/output as well as port protection still need to be considered.
 

John West

Senior Member
Just a note on design philosophy. If space and cost (large-scale production) considerations are not critical, I always try to do all signal conditioning off-chip, and not rely on built-in chip protections. I consider them a 'last resort' function that is best not counted upon on a constant or even regular basis. Due to their tiny size and the fact that they are part of a die manufacturing process that can be imperfect and not fully characterized, (and what ever really is?) I go with external components for reliability. That way I avoid having to do things like determine the effect of the additional heat dissipation on that portion of the chip die etc, and I can safely leave unknowns unknown while ensuring that my circuit performs reliably for as long as possible.
 
Top