|Try our online PLC Simulator- FREE. Click here now to try it.|
Learn quickly with our PLC Training DVD Series: on sale
Click here now for details!
Let's now take a look at how the input circuits of a plc work. This will give us a better understanding of how we should wire them up. Bad things can happen if we wire them up incorrectly!
Typically, dc input modules are available that will work with 5, 12, 24, and 48 volts. Be sure to purchase the one that fits your needs based upon the input devices you will use.
We'll first look at how the dc inputs work. DC input modules allow us to connect either PNP (sourcing) or NPN (sinking) transistor type devices to them. If we are using a regular switch (i.e. toggle or pushbutton, etc.) we typically don't have to worry about whether we wire it as NPN or PNP. We should note that most PLCs won't let us mix NPN and PNP devices on the same module. When we are using a sensor (photo-eye, prox, etc.) we do, however, have to worry about its output configuration. Always verify whether it's PNP or NPN. (Check with the manufacturer when unsure)
The difference between the two types is whether the load (in our case, the plc is the load) is switched to ground or positive voltage. An NPN type sensor has the load switched to ground whereas a PNP device has the load switched to positive voltage.
Below is what the outputs look like for NPN and PNP sensors.
On the NPN sensor we connect one output to the PLCs input and the other output to the power supply ground. If the sensor is not powered from the same supply as the plc, we should connect both grounds together. NPN sensors are most commonly used in North America.
Many engineers will say that PNP is better (i.e. safer) because the load is switched to ground, but whatever works for you is best. Just remember to plan for the worst.
On the PNP sensor we connect one output to positive voltage and the other output to the PLCs input. If the sensor is not powered from the same supply as the plc, we should connect both V+'s together. PNP sensors are most commonly used in Europe.
Inside the sensor, the transistor is just acting as a switch. The sensors internal circuit tells the output transistor to turn on when a target is present. The transistor then closes the circuit between the 2 connections shown above. (V+ and plc input).
The only things accessible to the user are the terminals labeled COMMON, INPUT 0000, INPUT 0001, INPUTxxxx... The common terminal either gets connected to V+ or ground. Where it's connected depends upon the type of sensor used. When using an NPN sensor this terminal is connected to V+. When using a PNP sensor this terminal is connected to 0V (ground).
A common switch (i.e. limit switch, pushbutton, toggle, etc.) would be connected to the inputs in a similar fashion. One side of the switch would be connected directly to V+. The other end goes to the plc input terminal. This assumes the common terminal is connected to 0V (ground). If the common is connected to V+ then simply connect one end of the switch to 0V (ground) and the other end to the plc input terminal.
The photocouplers are used to isolate the PLCs internal circuit from the inputs. This eliminates the chance of any electrical noise entering the internal circuitry. They work by converting the electrical input signal to light and then by converting the light back to an electrical signal to be processed by the internal circuit.Learn quickly with our PLC Training DVD Series: on sale
Click here now for details!