ELE239 - Programmable Controllers
Examines installation, programming, interfacing, and concepts of troubleshooting programmable controllers.
Programmable Logic Controllers: A Practical Approach to IEC 61131-3 using CoDeSys - Dag Hanssen
Velocio Ace 11 PLC
5V 2A Wall Plug
USB to Mini USB Cable w Data
Class Video Playlist
Welcome to ELE 239! I will be posting content and labs each Friday and following with solutions and updates the following week. This post serves as an introduction to the course, syllabus, and the structure. Feel free to reach out if you need anything. Make sure to have all the class materials by the end of next week!
Watch the intro video and read the syllabus. Contact me with any questions! Please introduce yourself on Canvas in the dicussion forum. We will be using Canvas as a discussion and announcement tool. Make sure you can log into Canvas!
For next class...
Watch the introduction video for the class.
Respond to the Canvas Discussion post introducing yourself and read others' posts to get to know people in the class!
Read Part I, Chapter 1 & 2 of Programmable Logic Controllers - Hanssen
Download and install Codesys 3.5 for Windows using the above links. Codesys is also available on the lab laptop computers for your use on campus.
Thank you for introducing yourself and getting started on our class! Hopefully you can access Canvas properly and participate on the discussion. This week we will install Codesys and test its functionality. We will also review the readings and provide some additional support.
Please utilize the Codesys Development Help as needed. It is also available in Codesys. Watch the intro video and begin your first program. We will be creating a simple program to just test our development environment and see if everything is working properly. This excercise will provide context as we progress.
Lab 1: Development Environment
We will be utilizing Codesys and the IEC standard to write our programs. This week will be a short introduction to Codesys to help familiarize yourself with the program and its features. Refer to help documentation when needed. Follow below:
Follow along with the tutorial to create a simple program in a virtual PLC.
Create a new 'Standard Project' in Codesys. Name your project 01ELE239IntroLastname.
Setup your device to be the 'CODESYS Control Win V3' using Ladder Logic.
Open your PLC_PRG (PRG) by double-clicking on the left in the devices tree.
Notice the Program Tools, Program Construction and Program Variable docking windows. In the Program Tools list, find the 'Contact' and drag it over to the 'Start Here' icon in the Pogram Construction window.
Rename the ??? variable to Button1 and make sure it is BOOL.
Find the 'Coil' element and drag it onto the contact labeled Button1. Name the Coil Light as a BOOL.
Find the Online dropdown and select Simulation mode. Then Login to the controller.
From here you can test all your possible scenarios for the I/O. Start your simulation and play with the values in the table.
The Debug dropdown will allow you to Start the controller and Write Values that you selected.
Add 2 more rungs with different variable names. Can you make one of the coils activate the other two contacts, in turn activating three coils at the same time? How would you accomplish this?
For next class...
Read Part I, Chapter 3 of Programmable Logic Controllers - Hanssen
Answer the questions in the discussion and provide 2 responses to other posts. Make sure to comment and question other students' responses!
Make sure you work through Lab 1 to have a working single rung proram and simulation. Then build the other two rungs as you think they should be. Reach out if you need nay help with this!
You should have successfully developed your first ladder logic diagram program in Codesys. Make sure it does exactly what you want by simulating and testing values. Don't forget to post on the discussion from last week.
Create a mental model of a simple automated system you use regularly or are familiar with. I won't constrain you to anything in particular, but a good example would be the basic heating/cooling system, a carnival ferris wheel, a pinball machine, a home security system, or something that senses/detects and changes based on that reading! Get creative.
Model your simple system as a flow chart. To quickly do this, try draw.io and use different geometries to determine different things. Your goal is to make sure you build a process loop. You learned about a variety of sensors from the readings.
Make sure that your system includes a sensor/reading, control/set point, controller, predetermined values, and a way to modify the system.
Feel free to use this as an example: Simple Heating Process Loop.
Post your system on the appropriate discussion board for feedback.
Lab 2: Beginning our Program
In Codesys we will develop a unique program for our control process loops. We will simulate and make sure that everything is working and meets the needs of the system.
Start by listing the variables you need for your system.
Use the top section to develop your variables before you begin your program.
In the above example I would create a setpoint (INT), start (BOOL), stop (BOOL), indicatorLight (BOOL), temperature (INT) to create a simple system.
This system would have a user-defined setpoint, start the heating at a certain temperature reading, turn on an indicator light when heating, and shutdown when temperature is reached.
We will begin the process by creating a simple start/stop function and if you would like you can include a reset here. We want the system to turn on with the user, but stay on until asked to do so.
Create a rung that starts the system and continues to stay on regardless of the user.
Make sure to use the defined variables from earlier. If you can begin laying out your whole system. What are you missing in your logic? What would make it easier?
Ensure all variables are labeled and your start/stop rung is complete. Test it in simulation and have it activate another rung with a simple coil.
For next class...
Read Part III, Chapter 5 - Chapter 6.6.5 of Programmable Logic Controllers - Hanssen
Answer the questions in both discussions. Comment on 2 other posts for each and try to help out or ask questions if you are not sure!
You should have successfully built a simple start/stop function in Codesys. Make sure it does exactly what you want by simulating and testing values. Don't forget to post on the discussion from last week.
Week 3 Lab Solution
Lab 3: Full Process Loop
For next class...