https://www.automationdirect.com/LED-message-display
(VID-VW-0003)
Learn how to use numeric and text variables to help make your PLC projects easier to use and maintain.
With the Viewmarq you can dynamically update real-time data without having to regenerate the entire message each time. That makes your life easy. Take this example - it has a static title with a real-time current production number as a numeric variable and a scrolling daily message at the bottom as a string variable so the program can change that message anytime it wants. And it is so easy with the ViewMarq - all you have to do is create one message with place holders for the things you want to change - in this case it will be the count and the daily message. Then all your PLC program has to do is send data updates to the ViewMarq for those place holders. It doesn't have to re-generate the entire message each time. Let's see how: Step 1: Create the message with placeholders for the count and text message. Here's our static text. I want the count here, so I click on the numeric variable button. We'll use numeric variable number 1, make it 5 digits long - we don't need any decimal places because we are counting whole units here - and I think I want leading zeros for this example. So my display is going to look like this. And that is my place holder for where the number is going to go. I want my daily message to go down here, so I insert a string variable. Let's go ahead and use string variable number 3. Note that you have 16 available to use. And I don't need all 100 characters, but 6 is too few. Let's set aside 18 characters for this message. And that's it -I have created the message. Now I just copy that message and drop it into my PLC project. The PLC would then send that message, just once, to format the display. Step 2: Have the PLC update the Variables. There's two ways you can update these variables. One: Use an ASCII string Or two Write directly to the Variable's Modbus register in the Viewmarq. To do it using an ASCII string, just double click on the place holder and hit copy. That will copy this string so you can drop it in your PLC project. Once it is in your PLC project, you need to remember to change the ID number to the right ID and put whatever text you want displayed right here. And the numeric variable is very similar. You double click on the label, hit copy, and drop this string into your PLC project. Again, changing the ID number and whatever number you want to display goes right here. Now how you transfer that information to the ViewMarq from the PLC depends on your PLC, of course. But there is a really good example of how to use Variables in the DoMore and Productivity3000 How To Videos. So be sure to check those out to see an actual step by step example and don't forget the user manual. It has some great examples too. To update the ViewMarq Variables via Modbus, just go to the help file, click on how to update variables, and in here you will find a chart. Here's one chart for the 16 available string variables and their Modbus address. Then there is another chart down here with all the addresses for the 32 numeric variables. You just have the PLC write the value to one of those Modbus memory locations, and they will appear on the screen wherever they are needed. Can you send more than one variable at once? Sure, just grab one, let's grab this one here. I'm going to paste it into notepad for a second. Change my ID, and I'll change the number when I get down to the PLC program, but, the key point is, suppose I want to send some more numeric variables. I just keep appending them to the string. There would be numeric variable #2. Numeric Variable - oh I don't know -number 8? You can put as many as you want, but don't forget, the ViewMarq can only handle 500 characters at a time. Don't exceed that. Can I mix numeric and string variables? Sure. I just go grab my string variable, copy that string, append it to my string. I don't need the ID, of course. We already have that back here. And I would insert my string in place of that X. Once you write the variable to the Viewmarq - it stays, even if you change the formatted string. For example, suppose I have this message with a measurement in Meters and this message with it in centimeters. I didn't have to re-send that variable, simply writing either message picks up the variable data that's already in the ViewMarq. You can also use the same variable as many times as you want in the same message - even if the format is different. Here's the same example we just did. Both of these are using the same numeric variable, they are just formatted differently. For example, if I change the value of this one numeric variable, and send it to the ViewMarq, Both of these get updated. Again, they are both looking at the same numeric variable. Well, that ought to be enough to get you going. Please let us know if you need any help. Automation Directs Tech Support is always Free and only an e-mail or phone call away. ViewMarq: Cost Effective, Industrial Messaging made simple. From Automation Direct.
Voted #1 mid-sized employer in Atlanta
Check out our
job openings