PLC programming beginner

javmen99

Member
Join Date
May 2003
Posts
6
I'm new to the PLC world. I have a Automation direct system with a DL205 base and 250-1 CPU. I've read through the tutorial (PLC.net) and the programming software handbook so I have a basic understanding of how the PLC should be programmed and ran. My output unit is the D2-04TRS that's supposed to be powering a electric valve (120 v, 15 watts) I ran my simple program and the output unit just made a buzzing sound and the valve didn't open up. It appears that the control unit was working, but the valve didn't respond. Can anyone help me with writing a simple program to get started or any advice where I can get help? I've attached the program and pseudo code that I will eventually write the entire program.

Thx
Dave
 
For those of you without DirectSOFT, here's Dave's "program"...

X0
|----] [-------------------------( Y0 )
|
|--------------------------------( END )


.
Yes, that's the whole thing!... :D

I think you can safely rule out any problem with the program. I thought perhaps you had a timer set too short or something, but that's DEFINITLY not the case here. Input ON = Output ON

Re-check all your wiring, there's something fishy. One possibility... Are you using the on-board DC power supply to turn on the valve? You can use the on-board supply for your inputs, but don't use it to drive loads (outputs). You may be overloading it.

Remember, it's only a 300ma supply!... (n)

beerchug

-Eric
 
I just noticed your "pseudo code" document.... Here it is for easier viewing:

Start Program

Initial heat up
 Turn on y00
 Turn on y02
 Turn on y20
 Turn on y22
 If x0 = 170o F (from thermocouple input) go to next step
 Turn off y22
 Turn off y02
Step two
 Turn on y03
 Turn on y10
 Turn on y00
 Turn on y20
 Start timer
 When Timer reaches 3 minutes go to next step
Step Three
 Turn off y20
 Turn off y22
 Turn off y00
 Turn off y03
 Turn off y10
 Reset timer to zero
 When timer reaches 15 minutes go to next step
Step Four
 Turn on y01
 Turn on y03
 Turn on y10
 Turn on y22
 Turn on y20
 When x0 = 155o F go to next step
Step Five
 Turn off y01
 Turn off y03
 Turn off y10
 Turn off y22
 Turn off y20
 Reset timer to zero
 When timer reaches 30 minutes go to next step
Step Six
 Turn on y01
 Turn on y03
 Turn on y10
 Turn on y20
 Turn on y22
 When x0 = 178o F go to next step
Step Seven
 Turn on y01
 Turn on y03
 Turn on y11
 Turn on y20
 Turn off y22
 Turn off y10
 Reset timer
 When timer reaches 5 minutes End program


Writing down your sequence BEFORE sitting down to program the PLC is good practice!... From your layout, I guess you're used to 'computer' programming? Wait 'til you see how much easier it is with a PLC! We'll get started on that once the valve is functioning... ;)

beerchug

-Eric
 
I have to learn to read more carefully!...

Ignore my comment about using the on-board supply... shutit

You are using 120VAC... 🙃

beerchug

-Eric
 
Dave,

I think we will need a bit more info on how your system is setup before we can help you. I have a few idea's about what might be wrong, but there is no sense sending you down the wrong path.

For starters give us your full system layout, what modules are in what slots just as they physically are with part numbers. Then we can go fro there.
 
Eric, Icky

I think you were right, I do have the valve directly wired to the PLC. (I'm a young ME not EE). I think I'll need an alternate wiring plan for the vavles (Which are all controlled by the D2-04TRS's). Any ideas?

The other outputs I have going to a relay bank that can handle the higher amps(ZL-CM08RL 120) and controlled by the D2-08TR.

Should I wire the valves like I have the higher amp loads?

Here's a picture that should help explain:
 
Ok, that explains the "BUZZ". You do not have any discrete inputs for the system.

What you need is to get the D2-ANLG-M and use the pointer method for setting up your thermocouple module. You can get the correct chapter here: http://ftp.automationdirect.com/documentation/d2anlg/ch7.pdf

Pages 5-14 explain how to set the jumpers and how to program for the pointer method. In addition to this setup you will need to mask the sign bits from the input. This is found on page 15 and 16.

Now you can check the memory location for it being at the correct temperature with a comparitive contact. Ex. V2000 >= k2000 for 200.0 degrees.

To check your relays try replacing the X0 with SP3. This will turn the relay on for 30 seconds and off for 30 seconds.

Hope this helps.
 
I take it from the color code that you are using type R thermocouples. Unless the wire is from Germany and this is a type E. Hard to tell without the sheath color. Be sure you set the jumpers for the right type of thermocouple.

Bit of a warning, you might end up with noisy thermocouple readings with that unshielded wire. Shielded wire will give much more stable readings.
 
Javmen PMed me with a "How should I wire these valves?" question, but this needs to stay on the forum...

From your pictures, it 'looks' like it's wired right. I assume the black wires are 120VAC 'HOT' and the red wires go out to the loads (valves). Although, in the picture of the valve, I see a red wire and, from what I can tell, a black wire? I hope that black wire winds up connecting to the 120VAC 'NEUTRAL' leg.

Think of the PLC output module as a simple switch. As shown in the wiring diagram for that module, it should be wired like this:

D2-04TRS
+------+
| C0 |
120VAC(H) <--------------------|-(x) |
VALVE A | |
/| | 0 |
120VAC(N) <-------/ | /--------|---(x)|
|/ | |
| C1 |
120VAC(H) <--------------------|-(x) |
VALVE B | |
/| | 1 |
120VAC(N) <-------/ | /--------|---(x)|
|/ | |
| C2 |
120VAC(H) <--------------------|-(x) |
VALVE C | |
/| | 2 |
120VAC(N) <-------/ | /--------|---(x)|
|/ | |
| C3 |
120VAC(H) <--------------------|-(X) |
VALVE D | |
/| | 3 |
120VAC(N) <-------/ | /--------|---(X)|
|/ | |
+------+


.
If you hook the valve up to 120VAC directly, does it function? You never know, the valve may be the culprit!... (n)

beerchug

-Eric
 

Similar Topics

How do you code it to when you push a button attached to X001, it turns on Y001. Then, the next time you push the button attached to X001 it...
Replies
4
Views
1,611
J
I'm new to the PLC world. I have a Automation direct system with a DL205 base and 250-1 CPU. I've read through the tutorial (PLC.net) and the...
Replies
3
Views
4,887
Hello colleagues, Some time ago I started my adventure with programming. With your help and the courses, things are starting to come together...
Replies
13
Views
681
Dear All, I need a sample PLC program to count the output pulse of a mass flow meter so that a specific amount of mass (for example 100gm)can be...
Replies
2
Views
146
Back
Top Bottom