HMI to Digital IO's without a PLC?

$aa6

G'day chelton .... Your help is much appreciated. CMD $AA6 is a "read only" and, I am already using that at the page top: DioOut_Full_WORD (see pic on forum page 3) Thanks to that CMD.. I can see the status of all D/IO's by converting that tag to binary and mapping the status tags to that: (All the colored ON's & OFF's) :)


Remember... the current big problem is how to write to s single bit of DO, without clearing the register, and you are left looking at only the bit you just changed. Only #AABB(data) does that... and it isn't in the Red Lion Driver... sniff!

BUT! Perhaps there's a way to create the command by doing something in "Programs" which can include the "$" in the data. (I think that must happen)

In my Database...take a look at the program section for UpdateConfigVariable .. look at the expression that can reformat the configuration of the module. (there isn't any good reason to do that with a D/IO module, but that ability was included in the driver , and #AABB(data) was not .... (Very Strange)

PS: Norm Galvin added that to my database

I'm thinking I am the first to try to control an ADAM-4055 using only a G3 Red Lion HMI. It's not really a silly idea (I think the forum sees a safety issue for not including a PLC) I really have some good reasons... what I should be doing is controlling the LinMot drive controller directly with the HMI ... might look into that next. :)

The Red Lion G3's are PLC's ..after all.

To be continued..I'll take a look at what you did to my database.. Thanks, Regards, Michael Lambert
 
I just realized you are trying to use CMD $AA6 to read output status like you read input status in your mod to my database example.. (thanks)

I've been spending some time studying your fixes for my program .. That is really appreciated .. I've added the Outputs and it looks like your ideas should work; but, so far no success .. will do my best & send the Database .. & hope you have time to look at it again. methinks the problem can only be solved two ways: 1) Red Lion Support installs #AABB(data) into their driver, or a Red Lion expert figures out how to send that CMD using the HMI's programs section.. Will post pictures soon.. Regards, Michael
 
chelton, you are awesome! You figured out how to properly display the D'IO tags and actually get a real time read of the ADAM modules status. Very Cool. I did make some changes to your database mod of my database.. so, things are looking good.


Actually the pages will look nothing like these in the final config. You won't see any tags.. just buttons that command the LinMot Drive to make many different waves, very simply, in a simple display.

chelton mods.jpg



chelton mods.jpg
 
Last edited:
Narko Thanks for the input. Red lion ain't cheap! They start near $1000


I just thought an old legacy model like the G304K2 worth about $200 "used" would have all the bells and whistles to talk directly to a ADAM-4000 series .. via ASCII or Modbus RTU & RS485 port.. this one almost does!... it's just that the Red Lion "driver" is a bit inadequate .. or I don't know what I'm doing... (probably the latter... :)
 
Last edited:
Lamboom, is it possible output word is actually the 4 bytes of BB(data) have you tried writing a value of say 1101 hex to set output 1 or 1100 hex to reset output 1?
 
No... but I will... :)

Remember... the driver says that it is using #AA not #AABB(data) I am able to write to a single bit... somehow... but it always clears the not written to bits

Check it yourself in Crimson 3.0... select all possible ADAM drivers (I don't think I can use Ver. 1.1) ...I'm using Ver 2.0 On the right when you click on PICK... you have many choices.. and they list the CMD syntax the driver is using... It actually lists #AA ... Well, there is no #AA in digital IO .. that CMD is for Analog!

The driver isn't written correctly .. Red Lion has to fix it, or I have to find a way to "send" the #AABB(data) command without using the driver... Tall order?
 
Last edited:
Chelton... Here's what you would get when you use #AABB(data)if it were available in the Red Lion Driver:

1) You want to write to all bits the value FF.
Send: # 01-00-FF Gives 1111-1111
2) OR...If You want to write to only bit 7 (Avantech calls the bit numbers "channels")
Send: # 01-17-01 Gives 0000-0001

3) If 1010-0010 is already there, you will get 1010-1011

4) Perhaps, You want to remove Bit 2 from that(or channel 2) then write: # 01-02-00 and you will get: 1000-1011

You can see how valuable this CMD is.

If you go back a few posts to to your post:


"The command is #AABB(Data).
So to set a single output at address 15h
#151101(cr)
Where
15 - Address of unit, 1- Set single output,1 - Output number 1, 01 - Set output to 1 "


You have it down... it works perfectly on a test module using Avantech's user program.
 
Narko Thanks for the input. Red lion ain't cheap! They start near $1000


I just thought an old legacy model like the G304K2 worth about $200 "used" would have all the bells and whistles to talk directly to a ADAM-4000 series .. via ASCII or Modbus RTU & RS485 port.. this one almost does!... it's just that the Red Lion "driver" is a bit inadequate .. or I don't know what I'm doing... (probably the latter... :)

No you're good mate.
It's certainly worth putting in the effort. I had used Redlion data stations for protocol conversions but never had used hmis.
I'll be watching this thread to find out how it all come together 😊
 
Narko .. thanks for the good thoughts.. it's people like your countryman (chelton) that have helped a lot over the years... :)


Will let you know when the thread is "RESOLVED"
 
Lamboom, you are showing images of the 4055 with multiple outputs set? What command are you sending to do this. You have said that writing a bit turns off all the other outputs. I think the redlion must be using #AABB but the documention may be lacking. If the Adam 4055 responded and modified its outputs by sending an incorrect command that would surprise me. According to the command list for the 4055 the only command that affects the outputs is the #AABB command.
 
Hi chelton .... you should have a copy of our joint database .. It's rather tricky, it comes from using program1 and the binary number representation of the decimal input of "Curve Number" .

It should be somewhere in the last few posts... I'll look .. standby


Yes... it's there post #50
 
Last edited:
Status

FYI to anyone who's interested. The Status so far at easily interacting with the remote D/IO module ADAM-4055 using only a Red Lion G3 HMI .. is working well, (see picture on post #49) there is a snag however, there is a CMD which ADAM-4055 is designed to use for writing directly to individual DO bits, or the entire DO register that isn't available in the Red Lion Driver Ver. 2.0. There doesn't appear to be a workaround.

The CMD is #AABB(data) well explained in previous posts, should you be interested. I've asked Red Lion to incorporate the CMD into their driver. So far, no word back.

At one time Red Lion must have regarded these modules to be meaningful, or they wouldn't have produced two drivers (Ver 1.1 & 2.0) to accommodate the incorporation into G3 HMI systems.

But that was then... And, as we all know, this is .... now (sadly).... welcome to 2020 and what is certain to be a different way to doing things.

I thought sure it was possible to make this work, got some great help from Red Lion, and this Forum (as usual) But, without the ability to write to a single DO bit without affecting all the others, this system will not support control of a LinMot drive which is communicating via D/IO.

to be continued.. watch this space... :)
 
without the ability to write to a single DO bit
Start with the current value of the DO word

To turn on any bit without affecting the other bits: DOWord = DOWord OR (2 ^ BitNumber)
To turn off any bit without affecting the others: DOWord = DOWord AND ((2^16-1) -(2^BitNumber))

Assuming a 16-bit word and BitNumber is in the range of 0 to 15.
 

Similar Topics

Hello, I have a Mitsubishi FX3G 14M PLC and a E615 HMI from Mitsubishi/Beijer. I'm using GXWorks 2 to do the programming and I have no problem...
Replies
4
Views
126
Good people of PLCs.net, I am currently working with an HMI that is advantech 1250H, that communicates with a 1769 Compact logix and Currently...
Replies
2
Views
76
Hello all, I know its not good practice to have duplicate destructive bits when writing plc code, but I'm wondering about writing to the same tag...
Replies
2
Views
120
Hi All, As a precaution my company has been collecting copies all the HMI and PLC programs. I have recorded copies of most of our sites...
Replies
0
Views
76
Hello all! So I have one project with a S7-1214 and a MTP1500 "Project1" and one project with another S7-1214 "Project2". Both of these PLC:s need...
Replies
6
Views
116
Back
Top Bottom