Connecting to PLC (Encoder Emulation)

Hi All

I work at a manufacturing plant and we have 3rd party hardware and software that monitors industrial machinery (primarily speeds).

For training and testing we need to be able to emulate one of the machines. The hardware is based on the Omron CP1L-EM30DT1-D PLC - (

I was going to build something simple using a variable speed DC motor and encoder wheel to generate pulses, but then it dawned on me, can't I just use an arduino and software to send variable frequency pulses? It doesn't need to be very accurate. We'd probably want a range of 1,000 to 60,000 per hour.

I'll admit that I know nothing about PLC's (yet), so I'm looking for guidance.

What would I need to send pulses to this PLC? I'm trying to get some information from our vendor too. They said I could do something simple with a push button (but I'm trying to get more info). Not sure if this would help determine what I need to do.

Initially, I'll use constants in the sketch to set the speed on startup, but long term, I'd add some kind of speed control using a rotary switch or pot and hard buttons for stop and start.

Thanks in advance


I understand that you are trying to use an Arduino to emulate a machine which sends pulses to a PLC. It sounds like the PLC is programmed and knows what to do with the pulses it gets from the machine.

First, you will need to define the voltage, and minimum pulse width requirements of the input pulse to the PLC. Depending on the input impedance there may be some current requirement for the pulse.

From a quick look at the data sheet you linked I think the PLC requires 24vdc pulses. The Arduino can only generate pulses which go from 0v (LOW) to 5V(HIGH), but the length and frequency of the pulses can easily be changed.

If, the PLC does require pulses of 24v, you will be needing to use the Arduino to switch a transistor which will actually switch 24v on and off to the PLC input.