AutomationDirect LogoExample Programs


 

We supply these programs as examples of how to apply the various instructions in our PLC’s. Please try to use these examples in their original form before modifying them for your particular application. We have had many calls claiming that the examples don't work and found that a mistake had been made when the example was re-entered by hand. The examples posted here have been run on equipment in our lab. If you are having difficulty with one of the examples check the following:

If you still have problems give us a call.

Thank you - The AutomationDirect Technical Support Team

THE INFORMATION PROVIDED IN AUTOMATIONDIRECT TECHNOTES IS PROVIDED "AS IS" WITHOUT A GUARANTEE OF ANY KIND. These documents are provided by our technical support department to assist others. We do not guarantee that the data is suitable for your particular application, nor do we assume any responsibility for them in your application.

Directory:

Please note: additional sample programs for C-more Operator Interface panels can be found at the c-more.automationdirect.com site.

Instructions: The program you will download depends on which CPU you have. Find your CPU in the colored columns on the right, and click the WinZIP icon WinZIP Archive to download the right example program. The absence of an icon for a given CPU means that the example is not applicable for or will not work with that CPU.

General Examples

05

06

105

205

305

350

405

CLICK

P3000

Do-
more

EP-MISC-001 Simple program that adjusts the PLC clock to account for Daylight Saving Time. Can be used in DL250, 350, 450 and DL05 if the optional memory cartridge is installed.
WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-002 This file shows how the square root of a value between 1 and 9999 could be calculated. The resulting value has 2 implied decimal points. The square root is determined by using an iterative approximation, and therefore this algorithm requires a long time to execute.
  WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-004 This example shows how to convert the current value of a timer or counter so that it appears to count down instead of up. This is useful for displays on an operator interface or for relational contacts to trigger an action at a low limit.
WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive
EP-MISC-005 This project uses two buttons pushed together for three seconds to latch an output.
WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive
EP-MISC-006 This is a simple example of how to use pointers.
WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-007 This program utilizes a pointer routine to store the accumulated time of T0 into successive double word V-memory locations beginning at V2000. Each time C0 changes from OFF to ON the accumulated time is loaded into the current memory location pointed to then the pointer location is incremented by 2 for a double word. This program is coded for the D2-250 Using Pointers it shows how to increment and move through a series of registers.
  WinZIP Archive   WinZIP Archive            
EP-MISC-008 This project will create a table of values generated by measuring the times an input is energized.
WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-009 This program shows how to implement a push-down stack in ladder using the MOV instruction.
WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-010 DL450 PLC Only. This program calculates the Standard Deviation on a Table of 10 BCD Double Words. See readme.txt inside the ZIP file for more details
            WinZIP Archive      
EP-MISC-011 Calibrating analog I/O with a non-zero starting point
WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-MISC-012 Off-Delay Timer WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive PDF Document PDF Document PDF Document
EP-MISC-013 Adding two tables using consecutive V-Memory locations with pointers WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive
EP-MISC-014 How to create a FIFO (First In First Out) Stack WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive
EP-MISC-017 Creating a Non-linear function with look-up table   WinZIP Archive                
EP-MISC-018 This example provides a 24-hr clock value for use in Time-of-day operations.   WinZIP Archive                
EP-MISC-019 Program showing various functions using ladder vs Iboxes       WinZIP Archive            
EP-MISC-020 Basic double safety switch program               WinZIP Archive    
EP-MISC-021 PLC controlled motor latching program               WinZIP Archive    
EP-MISC-022 Analog scaling and negative number math       WinZIP Archive            
EP-MISC-024 Do-more introduction example                   WinZIP Archive

 

Communications

05

06

105

205

305

350

405

CLICK

P3000

Do-
more

EP-COM-001 Example of how to configure port 2's communication parameters.
PDF Document PDF Document   PDF Document Link PDF Document PDF Document      
EP-COM-002 This program shows how communication errors can be detected when using the RX and WX instructions.
WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-COM-003 Networking multiple GS drives with the standard instruction set in the DL05 and D2-250
WinZIP Archive WinZIP Archive   WinZIP Archive     WinZIP Archive      
EP-COM-004 Networking multiple GS drives with the new Modbus instruction set in the DL06 and D2-260
  WinZIP Archive   WinZIP Archive            
EP-COM-005 Master project:
This project contains simple logic for reading the inputs from an DL05 / 06 slave and placing their status in C0-C17 in the master. It also writes C20-C37 to the outputs on the slave.
Slave project:
This project can be used in conjunction with the master project to setup the slave to turn off its outputs if the master PLC stops communicating with it.
WinZIP Archive WinZIP Archive           WinZIP Archive    
EP-COM-006 An example program for the D2-250 CPU and the ERM to communicate with an HA-EDRV2 and a SJ100 Hitachi drive
      WinZIP Archive            
EP-COM-008 Ladder example for receiving ASCII input. Typical application would be a bar code scanner or weight scale that sends data to the PLC and does not require any communication from the PLC
  WinZIP Archive   WinZIP Archive       WinZIP Archive    
EP-COM-009 Ladder example for sending commands to an SCL drive from port 2 of a D2-260       WinZIP Archive            
EP-COM-010 Ladder example for sending commands to an SCL drive from port 2 of a Click PLC               WinZIP Archive    
EP-COM-011 How to print without leading zeroes (D2-250, D2-250-1)       WinZIP Archive            
EP-COM-012 ASCII Receive and Send example               WinZIP Archive    
EP-COM-013 ASCII String Creation with checksum                 WinZIP Archive  
EP-COM-014 Ladder example for sending commands to an SCL drive from the Do-more PLC serial port                   WinZIP Archive

 

Counters

05

06

105

205

305

350

405

CLICK

P3000

Do-
more

EP-CT-001 Example of how to calculate RPM for a device connected to the High Speed Counter inputs on the 105 CPU.
    WinZIP Archive              
EP-CT-002 This app shows how to combine Straight Velocity and Accel/Decel profiles in mode 30.
      WinZIP Archive            
EP-CT-003 This file that contains two projects for 105 mode 30 pulse output; one for trapezoidal profile and one for registration. These projects are enhancements of the examples show in the manual on pages 3-31 and 3-34 in that they provide logic for using a momentary start pushbutton instead of a maintained button.
    WinZIP Archive              
EP-CT-004 CTRIO programming examples for Pulse Output functions
      WinZIP Archive            
EP-CT-005 Making both quadrature counting channels of a CTRIO retentive on power cycle       WinZIP Archive            
EP-CT-006 Example program for making 2 CTRIO modules in an 06 retentive on power cycle   WinZIP Archive                
EP-CT-007 Example program for counting/rate using interrupt input on DC input Click PLC               WinZIP Archive    

 

Operator Interface

05

06

105

205

305

350

405

CLICK

P3000

Do-
more

EP-OP-001 Example of how to detect that the Optimation panel is no longer communicating from within the CPU.
WinZIP Archive WinZIP Archive WinZIP Archive WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-OP-002 This app note shows how the date & time can be changed using the OP-1510 panel. It only works in the 250, 350, 440 & 450 CPU with the date & time instructions.
  WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-EZ-001 This example has an EZ Touch project and a DirectSoft32 Ladder program that shows how to set the PLC Clock for the (250,350,440,450 and 05(with optional D0-01MC module installed)) using the DATE and TIME instructions.
WinZIP Archive WinZIP Archive   WinZIP Archive   WinZIP Archive WinZIP Archive      
EP-EZ-002 These two files are an example for the EZ-TEXT panels and DL205 PLC family that gives several demonstrations of how to use the panel for viewing and changing messages and data, for emergency messages controlled by the PLC, and how to configure the options on the TEXT panel.
  WinZIP Archive   WinZIP Archive            
EP-EA-001 Changing CMore and CMore Micro Screens From the PLC and Panel (see related Tech Note)   WinZIP Archive                
EP-EA-004 Program to detect when an operator interface or other master device changes a register value in a PLC               WinZIP Archive