Manually controlling PLC outputs - Newbie

AegisSailor

Member
Join Date
Jun 2008
Location
Maryland
Posts
4
Hi all,

First, you should know that I know next to nothing about PLC's, so please excuse the (probably) silly questions.

I'm thinking using a PLC in the design of a new controller for an device of ours. The local control panel plugs directly into the device and has four switches that operate relays, and 8 panel meters that read a 0 to 30V DC voltage.

I also require the ability to remotely control the device via a custom Visual Basic program & laptop. In my existing design, I'm using a variety of serial to ethernet converters and analog to digital converters to accomplish this. Works great, but I think I can simplify the operation.

My first question is, can a PLC be manually controlled remotely via custom program? In other words, rather than a user turning a switch physically connect to a PLC input, can I programatically activate a paticular output (or simulate an input) based on a user's mouse click?

Second, can simple PLC's perform analog-to-digital conversion of a 0-30Vdc signal? Can I read that voltage programatically?

Finally, can serial devices be hooked up to a PLC? If so, can I transmit serial commands to the serial device via the PLC programmatically?

Thanks in advance for your help!

Roger
 
Greetings AegisSailor, welcome to the forum.

If I may say so it appears that when you say you know next to nothing you really mean that you really don't even know what a PLC is, much less how one works, or what one does. Never fear though, we can help. Everyone here was once where you are. Near the top of this web page is a link labeled Learn PLCs. Click on that link and follow the tutorial for a basic introduction to PLCs. It barely scratches the surface however, some PLCs are fairly sophisticated computers.


AegisSailor said:
Hi all,

First, you should know that I know next to nothing about PLC's, so please excuse the (probably) silly questions.

I'm thinking using a PLC in the design of a new controller for an device of ours. The local control panel plugs directly into the device and has four switches that operate relays, and 8 panel meters that read a 0 to 30V DC voltage.

I also require the ability to remotely control the device via a custom Visual Basic program & laptop...
First off, what you are describing is what the industry calls an HMI program, HMI = Human-Machine interface.


My first question is, can a PLC be manually controlled remotely via custom program? In other words, rather than a user turning a switch physically connect to a PLC input, can I programatically activate a paticular output (or simulate an input) based on a user's mouse click?

The short answer is yes. However I'm assuming that the control system will also need to control the output, so its a much better practice to have the HMI program read/write a bit in the PLCs internal memory and then program the PLC to turn on/off the output in response to the the state of that bit.

Second, can simple PLC's perform analog-to-digital conversion of a 0-30Vdc signal? Can I read that voltage programatically?
Most PLC inputs are 0-10V inputs or 4-20mA inputs, which are industry norm. A signal conditioner will typically be used that measures the 30VDC value and transmits it to the PLC using a 10V or 4-20mA signal.

Finally, can serial devices be hooked up to a PLC? If so, can I transmit serial commands to the serial device via the PLC programmatically?
You can program the PLC to transmit serial commands to an attached device.
 
Last edited:
I have seen PLC programs that run the gamut, so don't get confused or overwhelmed.

for example - I had a task to connect communications between an HMI and a PLC, radio over about 5 miles. After installing the radios, I had no signal on the HMI, and while troubleshooting, found the following:

HMI was ONE SCREEN, monitoring FOUR INPUTS. The window wasn't even done right, I spent some time straightening it up. Still, no luck.

I went to the PLC location, and plugged in - THERE WAS NO PROGRAM IN THE PLC! What they had done was configure the HMI "screen" to monitor the direct inputs on the PLC. While that can be done easily, all alarming was on the HMI, and any valve closure required a trip to reset it.

They spent 8 grand on that system - unfortunately, we didn't do it, and in less than two weeks they turned it off forever, due to the remote platform having to be manned 24/7.

You can start that simple (please don't!) or you can add whatever gadgets and gidgets you can think of for your control. A good HMI product will handle so much that you would otherwise write in code that it will save you money, and your customer's money.

Good luck, read the material listed on this website, and go forth!
 
Thanks for the help guys, I really appreciate it. I've done some more research after being encouraged by your responses, so let me run a scenario by you to see if I understand what I think I do.

My project has fit inside a portable case, so I'm thinking using this PLC system (with appropriate CPU) because of it's size.

I believe I use the programing port during run time to create a serial link between my PC and the PLC, enabling my VB application to control PLC functions.

I use an analog input expansion module to read the output of a signal conditioner, and then use scaling to determine the actual voltage being measured by the conditioner. This data is retrievable during run-time via the PC-PLC serial link.

I use the PLC's DC inputs to detect local switch closures. I use a relay output expansion module to operate the device being controlled.

Finally, to read the RS-485 serial data transmitted by my device I use the second serial port on the PLC CPU or a serial expansion module, which can receive the serial data and make that available during run-time to my PC via the PC-PLC serial link.


Do I have all that right? I just want to be sure I understand how this all works. I'm especially concerned about establishing a serial or Ethernet link to the PLC so I can can control it with a VB application. I'm a bit worried about that because a quick search on the term "HMI" returns software costing thousands of dollars, which makes me think it must be a hard thing to do.

Thanks again for your help,

Roger
 
AegisSailor said:
My project has fit inside a portable case, so I'm thinking using this PLC system (with appropriate CPU) because of it's size.

Or you can use this expandable "brick" style
D0-06DR-D
instead of what you listed above.

AegisSailor said:
I use an analog input expansion module to read the output of a signal conditioner, and then use scaling to determine the actual voltage being measured by the conditioner. This data is retrievable during run-time via the PC-PLC serial link.

And use this analog module.
F0-04AD-1

AegisSailor said:
I use the PLC's DC inputs to detect local switch closures. I use a relay output expansion module to operate the device being controlled.

The "brick" I linked to has the inputs and the relay outs already built in. Plus it has the complete instruction set (yours does not), plus it has all the comm port abliies of the unit you selected and the ability to use rs485 natively no adapter is needed

AegisSailor said:
Finally, to read the RS-485 serial data transmitted by my device I use the second serial port on the PLC CPU or a serial expansion module, which can receive the serial data and make that available during run-time to my PC via the PC-PLC serial link.

If you are needing two rs485 ports then you will have to get a
D0-DCM


AegisSailor said:
Do I have all that right? I just want to be sure I understand how this all works. I'm especially concerned about establishing a serial or Ethernet link to the PLC so I can can control it with a VB application.


You did mention serial, so I'm presuming your computer has a serial port ( these are getting harder to find these days).
 
It might be useful at this point to make a block diagram of the machine to use as a guide in helping us understand your concept.
And, if you can describe what your machine does, we may be able to guide you in further simplifying things.

So far, I understand that you have panel meters reading a DC voltage, and four switches. BTW, Many panel meters offer an analog output that would be compatible with the PLC 0-10vdc or milliamp input modules.

So what device is there that requires a serial connection? If you wire the field devices directly to PLC cards, and can connect to the PLC via a sinlge ethernet to serial adapter, then you can allow the PLC to control the outputs, and/or have a mode in which the VB application writes to addresses in the logic which can (selectively) control them.

The VB application then should be able to read any value from the PLC including the real I/O (digital and analog) and any of its internal memory.

The nitty gritty details are usually the stumbling blocks when it comes to writing custom code to talk to a PLC, but it has all been done before and there are experts on this site that can get you there.
 
I am really beginning to believe that this may be a the way to go. My current system works fine, but I'd like to simplify it and reduce the possible points of failure.

I am controlling the Vehicle Service Module (VSM) used to operate electronics & ordnance on board sounding rockets. My device monitors battery voltages, arm status, and event timer health and status. It also operates a LEDEX solenoid switch which arms the ordnance.

The suggestion about a block diagram was a good one, so here it is on my Flickr account or you can view a PDF of it in the attachment to this post.

Thanks,

Roger
 
Awesome drawing!

Now I can see why you are looking for multiple serial devices. So, what do the event timers do, and what is a "sounding rocket"?

Also, how fast must the controller respond to inputs and update outputs?

PLCs tend to trade speed for reliability, so that may weigh heavily in your selection (there are some very fast scanning PLCs out there).
 
Does homeland security know what you are up to?

Seriously one thing to note from your block diagram are the 5V inputs. There are 5V TTL cards available for some PLC's but they are not real common. 24V DC is kind of standard for PLC's, not sure if that is possible in your application though.
 
Great comments guys, thanks.

The term "sounding rocket" dates from the days when it was common for universities to pay to fly science experiments into space aboard sub-orbital rockets. We still do that sometimes, but most sounding rockets today are employed as targets for the military.

We launch rockets on a ballistic trajectory outside the atmosphere and do certain things to make them look like real-world ballistic missiles fired from enemy shores. The Navy shoots them down. We just fired two of them in Hawaii last week, you might have heard about it on the news.

Anyway, the timers in the VSM trigger various ordnance related events during flight such as spin-up motor ignition, second stage ignition, de-spin, and payload separation. I work on the electronics for all that, plus various launch systems. I've just never had the opportunity to work with PLC's before, and this re-design seems like a good excuse. While still on the launcher, these timers transmit a continuous RS-485 stream containing a bunch of status information. In flight, that same info is passed to the telemetry stack, but this project isn't concerned with that.

As far as the 5 volts goes, it would actually be easier for me to use the 24 volts that everything else runs on, I was only toying with the 5 volt idea to minimize the voltage I had to send through the ordnance arming state circuit. So if 24 volts is standard for triggering inputs, I'll just stick with that.

I'm not so concerned with speed, for this application a bit of latency is not a problem, however reliability is HIGHLY important. People get nervous if something breaks and we are left unable to safe the ordnance. :)

Thanks again for the comments and help, keep'em comming! I'm learning a lot!
 
Last edited:

Similar Topics

To quickly test a plc output which is wired to a relay do I dob a cable between the output and 24vdc+ source I.e something with 24vdc+ live such...
Replies
6
Views
688
Hi there, I am trying to determine the input, output, and config assembly and entering it into a beckhoff plc, and couldn''t get proper active...
Replies
22
Views
7,351
Hello everyone‚ Fairly new to PLC prog I seek your advise concerning what is said in my thread title; I program using workbench components; I...
Replies
1
Views
1,252
We have a customer that requires a CISCO network switches by government regulation. We are using a IE-4000-8GT4G-E industrial network switch. I...
Replies
37
Views
18,610
Dear Sirs, I have several Siemens MasterDrives (of dubious parentage) and I'm not sure if they are operational or not. I have an old laptop...
Replies
9
Views
2,803
Back
Top Bottom