Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

Analog In - Analog Out -- Like a Industrial PLC

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> AVR
View previous topic :: View next topic  
Author Message
WanaGo

Bascom Member



Joined: 15 Aug 2008
Posts: 111

newzealand.gif
PostPosted: Sat Oct 03, 2009 10:45 pm    Post subject: Analog In - Analog Out -- Like a Industrial PLC Reply with quote

Hello.

I am use to using industrial PLC's in my job, and adjusting my way of thinking to use Microcontrollers is a little confusing at times.

I have the digitals sorted, however the analogs are phasing me.

Basically I am wanting to know if you can get any external chips, that maybe use the I2C bus or SPI bus, that allow you to connect 1 or more analog inputs and analog outputs to the micro.

ie, 0-20mA or 0-10V capable analog inputs, like what a huge range of industrial sensors use.

and 0-20mA or 0-10V capable analog ouputs, for controlling analog devices.

Do such chips exist?

I am basically trying to see if a microcontroller is capable of doing the job of a PLC, for a mates home engineering workshop (which is more kitted out than most engineering shops you find).

Any help in directing me towards chips that would be able to do this, would be excellent.

I know micros have ADC, but I just dont think this is going to cut what I need. Having something on a SPI/I2C bus will make the job simplier I feel. The chip can sample as fast as it is capable and provide the micro with a value, or vice versa.

Regards
James
Back to top
View user's profile
WanaGo

Bascom Member



Joined: 15 Aug 2008
Posts: 111

newzealand.gif
PostPosted: Sat Oct 03, 2009 11:24 pm    Post subject: Reply with quote

I have found a chip made by Analog Devices called AD420.

This chip takes SPI input from a micro, and outputs either 0-20mA, 4-20mA, 0-24mA which can then be converted to 0-10V if required.

Has anyone ever used this chip? As it looks to be quite a find and should do what I am hoping.

Now I just need to find a input version.
Back to top
View user's profile
WanaGo

Bascom Member



Joined: 15 Aug 2008
Posts: 111

newzealand.gif
PostPosted: Sun Oct 04, 2009 12:21 am    Post subject: Reply with quote

AD7985 could be an option for 0-20mA to SPI, although it appears its 0-20mA @ 5V, which I am not sure if that is compatible with industrial products, as I think industrial products are based on a 24V signal...
Back to top
View user's profile
AdrianJ

Bascom Expert



Joined: 16 Jan 2006
Posts: 2483
Location: Queensland

australia.gif
PostPosted: Sun Oct 04, 2009 6:34 am    Post subject: Reply with quote

I use extensively the Maxim Max5102 which are dual output 8 bit DACS with 0-5 volt output. Converting this to anything else just needs some opamps set to the right gains, and of course suitable supplies.
For input I use either the ADC already built in to the AVRs, or sometimes Texas TLC2543 if I need 12 bit accuracy or more channels.

Both these and the MAX5102 are SPI devices.

Converting from current mode like 4-20 ma signals is easy enough, although there are dedicated chips for this. I dont use 4-20 ma signals in any stuff I handle, so no experience there.

_________________
Adrian Jansen
Computer language is a framework for creativity
Back to top
View user's profile Visit poster's website
WanaGo

Bascom Member



Joined: 15 Aug 2008
Posts: 111

newzealand.gif
PostPosted: Sun Oct 04, 2009 8:30 am    Post subject: Reply with quote

oh brilliant - always up for using devices with others have used before!

Can you point me towards the 0-20mA to voltage chips you hve used before please?

I noticed the AD chips I mentioned in the posts above, are quite pricey, due to their resolution I am guessing. No point going over board if its not needed. Ill check out those chips you suggested now.

Thank you
Back to top
View user's profile
AdrianJ

Bascom Expert



Joined: 16 Jan 2006
Posts: 2483
Location: Queensland

australia.gif
PostPosted: Sun Oct 04, 2009 9:02 am    Post subject: Reply with quote

Converting from current to voltage is just a resistor, in simple terms. Feed the current through a suitable resistor, read off the voltage.
_________________
Adrian Jansen
Computer language is a framework for creativity
Back to top
View user's profile Visit poster's website
jmpe

Bascom Member



Joined: 05 Aug 2007
Posts: 7
Location: Gelsenkirchen

germany.gif
PostPosted: Mon Jan 24, 2011 4:55 pm    Post subject: Reply with quote

Perhaps a bit late.
Like adrian already mentioned, the AD420. This is a 3-wire mA chip.
His brother is AD421, a loop powerd mA chip.
Whould have a baby-brother AD422, but they never produced in mass
This is as far AD goes and idiotic expansive.
OK, ADuM824 is a micro version, but who's paying the bill.

Burr-Brown (now Texas Instruments) has building-blocks:
XTR-series (all loop-powered except XTR100)
RCV-series (Converts mA loop-powered to 5Vsignals) ADC-ready
mcs12xx (Micro controled possibilities 8051) to do with BASCOM8051
Reading these data-sheets will explain how it will work.
Normal prized.

Lots of pleasure reading
JMPE
Back to top
View user's profile
hgrueneis

Bascom Member



Joined: 04 Apr 2009
Posts: 906
Location: A-4786 Brunnenthal

austria.gif
PostPosted: Sun Jan 30, 2011 6:24 pm    Post subject: Reply with quote

Had to add a bit.
If you want to stay low cost with analog output and want voltages of 24 Volt or higher, then use PWM, buffer it with an open collector gate or mosfet and use a low cost LP filter. That way you get an industrial D/A converter with virtually unlimited voltage (similar to digital amplifiers).
An Optocoupler in between is also a good thing if high voltages are used.
Hubert
Back to top
View user's profile
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> AVR All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum