Sonsivri

Electronics => Projects => Topic started by: sgoum on October 03, 2012, 08:44:23 08:44



Title: 8bit pic with internal OPAMP
Post by: sgoum on October 03, 2012, 08:44:23 08:44
Hello

Does anybody know if there is an 8 bit PIC with internal OPAMP?



Title: Re: 8bit pic with internal OPAMP
Post by: metal on October 03, 2012, 09:14:13 09:14
This is your friend: http://www.microchip.com/maps/microcontroller.aspx


Title: Re: 8bit pic with internal OPAMP
Post by: Jef Patat on October 03, 2012, 10:21:33 10:21
Used/selected a lot of PICs but never seen such a thing, never searched for it neither.  Why would you need it in one chip?  What is your goal?


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 03, 2012, 11:09:24 11:09
There are. PIC16F1782, 1783, (1784, 1786, 1787), PIC16F785, PIC16HV785

Ones in brackets are 'future products'.

Also, see Microchip's application note about using the internal comparator (more PICs have one than an op-amp) on page 31 in this doc:

http://ww1.microchip.com/downloads/en/DeviceDoc/41215c.pdf


Title: Re: 8bit pic with internal OPAMP
Post by: metal on October 03, 2012, 12:20:57 12:20
Are OPAMPs and COMPARATORs the same?


Title: Re: 8bit pic with internal OPAMP
Post by: sgoum on October 03, 2012, 01:09:48 13:09
Are OPAMPs and COMPARATORs the same?

You have to use external components to set the gain

Posted on: October 03, 2012, 02:06:00 14:06 - Automerged

Used/selected a lot of PICs but never seen such a thing, never searched for it neither.  Why would you need it in one chip?  What is your goal?
Less components - cost -routes on PCB etc


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 03, 2012, 01:41:04 13:41
While opamps and comparators are at first glance similar, they are different enough that they are not simply interchangeable. I think they should have different symbols.

Comparators are designed to produce only a saturated output, rather than an arbitrary output level; effectively they are single-bit analogue to digital converters. They respond as quickly as possible to input changes which is at the expense of the stability required of an opamp with feedback (using feedback with a comparator is a good way to invite oscillation).

The output stage of a comparator is usually a lot simpler than an opamp because it does not need to have a linear output.

Long story short: comparators make poor opamps, and opamps make poor comparators. That of course depends on how much performance is needed.


Title: Re: 8bit pic with internal OPAMP
Post by: Ichan on October 03, 2012, 07:15:36 19:15
I use F785 many times, mostly the opamp used for amplifying the voltage drop on r-shunt for current sensing, this way the r-shunt can be in small value.

Just know about F1872/3 - interesting device.

-ichan


Title: Re: 8bit pic with internal OPAMP
Post by: Sideshow Bob on October 03, 2012, 09:17:23 21:17
You have to use external components to set the gain

Posted on: October 03, 2012, 02:06:00 14:06 - Automerged

Less components - cost -routes on PCB etc
Are you looking for a micro with a PGA(Programmable Gain Amplifiers) have not seen one of those around


Title: Re: 8bit pic with internal OPAMP
Post by: solutions on October 03, 2012, 09:42:42 21:42
Why bother?

Use an AVR - they have a real op amp in them


Title: Re: 8bit pic with internal OPAMP
Post by: max on October 03, 2012, 09:56:01 21:56
there are situations where one or more comparators left unconnected in the circuit, you can use it as a low frequency op-amp see the attached diagram.


Title: Re: 8bit pic with internal OPAMP
Post by: Ichan on October 03, 2012, 10:13:35 22:13
Use an AVR - they have a real op amp in them

What AVR is that? If you mean ADC with programmable gain like on M128 then the one in F785 is more appropriate to called as a real op-amp, it has all 3 opamp pinout accessible - can be treated truly like a real one. There are two real opamps on F785, read the datasheet and related application notes - you will be amazed, but the new F1872/3 with PSMC + 12bit ADC + DAC is really tempting.

-ichan


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 03, 2012, 10:27:29 22:27
The F1872/3 look really interesting, particularly:

Internal 32MHz oscillator
2 x PSMC (Programmable Switch Mode Controller):
    Dedicated 16bit PWM
    Digital and/or analog feedback control of PWM frequency
    Dead-band control / auto-shutdown & restart
3 x Fast Comparators with selectable Voltage Reference
2 x Operation Amplifiers (rail-to-rail in and out)
11 x 12-bit ADC with Voltage Reference

I'm just popping over to Microchip again to order a few samples...


Title: Re: 8bit pic with internal OPAMP
Post by: Sideshow Bob on October 03, 2012, 10:29:10 22:29
Why bother?

Use an AVR - they have a real op amp in them
What do you define as a real opamp (in this setting) then. I do not know AVRs but found the setup in MSP430 quite tempting http://www.ti.com/lit/ml/slap118/slap118.pdf Not used it my self. But kept an eye on this way of thinking for future projects


Title: Re: 8bit pic with internal OPAMP
Post by: metal on October 04, 2012, 01:09:00 01:09
No, some AVRs contain comparators, but I don't know how valid it is calling them OPAMPs : )
Where did you read it, solutions?

Posted on: October 04, 2012, 04:03:25 04:03 - Automerged

Ichan, foxyrick: did you mean PIC16F1782/3 ?


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 04, 2012, 08:06:13 08:06
Ichan, foxyrick: did you mean PIC16F1782/3 ?

Yes.

The difference between the two is that the PIC16F1783 has twice as much memory as the PIC16F1782. Still not much at 7K program memory and 512 bytes RAM, but it's enough for a small program. Since these chips seem intended for purely control-based applications, they would likely not need much of a user interface (and subsequent code space) anyway.



Title: Re: 8bit pic with internal OPAMP
Post by: sgoum on October 04, 2012, 09:07:59 09:07
Are you looking for a micro with a PGA(Programmable Gain Amplifiers) have not seen one of those around
PSoc from Cypress.
I do use them, but they are expensive for wat i want to do.

The reasson I'm searching for a PIC is that a have a library for UC1701 LCD controller so I don,t have to do all the coding from the beginning.


Title: Re: 8bit pic with internal OPAMP
Post by: metal on October 04, 2012, 12:24:59 12:24
You can port it, provided in C, this is an easy job!


Title: Re: 8bit pic with internal OPAMP
Post by: solutions on October 04, 2012, 12:42:14 12:42
Sorry..I was being sloppy. PGA, not OA


Title: Re: 8bit pic with internal OPAMP
Post by: alien on October 04, 2012, 03:54:20 15:54
There are. PIC16F1782, 1783, (1784, 1786, 1787), PIC16F785, PIC16HV785

Ones in brackets are 'future products'.

Also, see Microchip's application note about using the internal comparator (more PICs have one than an op-amp) on page 31 in this doc:

http://ww1.microchip.com/downloads/en/DeviceDoc/41215c.pdf

Dear All,
Two years back i raised support ticket at Microchip support site..the issue i asked about was whether Comparators on some low end devices like 16f676 etc can be used as OP AMP.. .. i even tried again with this..and again raised a support ticket..i even provided them the reference of that "TIPs n TRICKS" (  http://ww1.microchip.com/downloads/en/DeviceDoc/41215c.pdf) document in which they had shown this trick.. but  they never replied.. nor they ever bothered to acknowledge my issue..i even once raised this issue in Mchip forum..but there too no body was sure about it..and as i can remember..i even tried this stuff..but what i can recall..i was not successful in this...

EDIT : the link to my post at Microchip forum about this comparator/OP AMP Issue ( as was mentioned above) >>>
http://www.microchip.com/forums/tm.aspx?m=401593


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 04, 2012, 06:05:19 18:05
I did wonder about that, when I saw a diagram of the comparator circuit and it included a logic gate or two immediately after the comparator output. I can't remember if it was any particular PIC, or in general, but I'll try to find the diagram again.


Title: Re: 8bit pic with internal OPAMP
Post by: Gallymimu on October 04, 2012, 11:05:41 23:05
I know you are looking specifically for 8 bit parts, but I'll throw this out there anyway:

Several of the new DSPIC33E and PIC24E series parts have opamps built in and many of them are under $2 in volume.

Reference manual section: http://ww1.microchip.com/downloads/en/DeviceDoc/70357D.pdf

The PIC24EP64MC202 for instance has multiple opamps onchip

see page 2 of the datasheet for this series http://ww1.microchip.com/downloads/en/DeviceDoc/70657E.pdf


Title: Re: 8bit pic with internal OPAMP
Post by: Mr. Spock on October 05, 2012, 04:31:07 16:31
See also Holtek. They have an ARM Cortex-M3 with internal OPAMPs


Title: Re: 8bit pic with internal OPAMP
Post by: Magnox on October 05, 2012, 07:53:35 19:53
Regarding Microchip's notes on using the comparator as an opamp, I can't see it myself. Attached is the comparator circuit from the 18F4550, the others I've looked at so far are similar where it matters.

Note that the comparator is immediately followed by an exclusive or gate. The output of the comparator itself is not made available externally but rather the output of the logic gate is. Doesn't look very analogue to me.

Obviously the left hand at Microchip doesn't know what the right hand is doing with the comparators. I'll have to wire one up when I get a spare minute and try it out, but my guess is that the circuit in the datasheet is correct. Perhaps there is a PIC that doesn't have the logic gate, but I can't find it.

Perhaps that's why Microchip never answered those questions...



Title: Re: 8bit pic with internal OPAMP
Post by: Mentor on March 09, 2013, 06:06:22 18:06
As someone already said, some MSP430s from Texas Instruments have internal opamps. They also have a free C compiler and IDE too, and most chips are really cheap, and some even have DIP packages.
I really prefer to use PICs, but sometimes it is worth looking for new possibilities.