|AutomationDirect Live Chat|
Understanding how the Do-more engine is configured and how it works is a key to success. This brief overview will help make your project go a lot smoother!
We saw in the quick start video that writing a simple program for a Do-more PLC is quick and easy and that’s because Do-more does so much for you. Writing a program that uses more resources like com ports or servers is just as quick and easy if you understand 3 key things about the Do-more architecture. Number one: Devices. It’s important to understand that your program doesn’t talk directly to the hardware. Instead, your program tells a software interface how it wants the hardware to behave, and that interface – which we call a device - controls the hardware. The beauty of the device is it knows how to handle the hardware for whatever you set it up to do. It takes all the low level buffer management, handshaking, error processing, etc. off your back. For example, the serial port is a hardware thing, but maybe I want it to behave as a simple ASCII streaming device. I select that interface - or device – tweak the settings and I’m done. Now when I send data the device takes acre of all the low level details. If I want that port to behave as a Modbus RTU Client, I select that device, tweak a similar list of things - the device only asks you for the things it needs - and now it’s ready. If I want an instruction to send data to the Modbus RTU client we just setup, I just select that and I’m done. Now all data from this instruction will use the RTU client. If I want to switch to use the built-in Ethernet port, I just select that. Done. No other changes to the program or the configuration. What if I wanted to send data out an add-on serial port module and I haven’t setup the device yet? Well look at this. You can setup the new serial port device - which Do-more created for you automatically - right from within the instruction! Now just use that device and away you go. We just setup three different ways to get data out of the Do-more and all we did was swap out devices! That’s the power of this device centric model. Most instructions don’t need devices – like reading or writing directly to I/O. But even in that case the program still doesn’t talk to the hardware – it writes to memory which is mapped directly to hardware through a device. So the key take away here is only devices talk directly to hardware. Which is why we say the Do-more PLC is device centric. Devices isolate you from all the low level stuff so you can just focus on what needs to get done and not worry about the how. The Device does it for you. Key Thing number two: Memory Like most of today’s modern programming languages, Do-more’s memory is strongly typed. Which means, Do-more knows exactly what each memory location is intended to represent. It doesn’t have to guess if a particular memory location is an unsigned or signed integer, for example. And because if fundamentally knows what each memory type represents, you can do things like compare a real number with an integer or even do math on mixed memory types. And here’s a great example: Suppose you have 10 inputs and you need to know if any 7 are active. That would be a HUGE task to do in ladder code. But Do-more knows inputs are a binary type, so you can just sum all 10 inputs and if, that sum, is greater than or equal to 7, turn the output on, otherwise turn it off. How about that? That’s the power of Do-more’s typing. It just works. Which makes your programming life a whole lot easier. Number three: System Configuration. Do-more is setup by default to handle basic projects mostly because its smart enough to figure a lot of things out on it’s own like when you add extra I/O modules – that’s all automatic. You don’t have to do anything except use them and if necessary maybe setup a few things right from the dashboard. So many times that’s all you’ll ever need. As your projects start using more and more resources and devices, then you’ll want to use the system configuration dialog because you can customize the hardware, devices, servers, and even modify the memory usage. The key thing to remember is, you’ll want to start at the top and work your way down. Why? Because each item in this configuration can affect the items below it. So first you configure the CPU which can affect all of these items, then you configure the I/O which can affect all of these items, then you configure the modules, then the devices, etc. The cool thing about starting at the top and working your way down, is when you reach the bottom you know you haven’t missed anything and all the bases are covered. Can you jump in the middle and change something if you want to? Sure. Just remember it can affect the items below it. Of course, anytime you change the system configuration, it needs to be written to the PLC to take affect. Well that’s it. The Do-more is Device Centric – you configure and talk to the devices, they take all the low level hardware control off of your back, Memory is strongly typed which makes your programming job easier and more reliable, and the system configuration is best approached in a top down fashion – it helps you make sure all the bases are covered and just makes things work out smoother. If you need any help, please contact AtomationDirect’s free award winning support team during regular business hours. They will be happy to help. Spend Less, Do-More. With AutomationDirect.