Help - Search - Members - Calendar
Full Version: AWT, ST FILE and CH0
Forums.MrPLC.com > PLCs and Supporting Devices > Allen Bradley
vanilla_gorilla
I'm trying to get my 5/05 to throw ascii data to the serial port (ch0).
I'm having trouble setting up or understanding the ST file.
Where it is located and how I even put data "into it" as the source file for an AWT.
Is the ST jut a pointer, and the data is stored in a regular #N ??
Bob O
I have not done what you are asking using the AWT but I will try to help with the creating of the String [ST] file. You need to create the ST file first by right clicking on Data file -> New -> type -> String and then enter how many elements you would like.

Hope this helps,

Bob O.

vanilla_gorilla
QUOTE(Bob O @ May 22 2006, 06:45 AM) [snapback]34338[/snapback]
I have not done what you are asking using the AWT but I will try to help with the creating of the String [ST] file. You need to create the ST file first by right clicking on Data file -> New -> type -> String and then enter how many elements you would like.

Hope this helps,

Bob O.



Yep that helps, its a start.......!
OkiePC
QUOTE(vanilla_gorilla @ May 22 2006, 07:22 AM) [snapback]34344[/snapback]
QUOTE(Bob O @ May 22 2006, 06:45 AM) [snapback]34338[/snapback]
I have not done what you are asking using the AWT but I will try to help with the creating of the String [ST] file. You need to create the ST file first by right clicking on Data file -> New -> type -> String and then enter how many elements you would like.

Hope this helps,

Bob O.



Yep that helps, its a start.......!




I did this many years ago, and I remember having trouble figuring out how to load the data in the ST file. I remember having to use the "^" symbol and the "/" symbol and it seemed that a certain keystroke combination was required to get them to appear in the data table. I wish I could remember more about my struggles with the RSLogix5 editor...



Every time I've done serial communications, it's amounted to a lot of trial and error to get everything set up right. Pay very close attention to all the settings for CH0 and compare with the receiving device requirements. Often you have to translate terminology differences between manufacturers.



You can use AWA to simplify the data tables if your receiving device(s) require a termination character that is consistent.



Hope this helps...

Spedley
ST9:0.LEN is a word value containing the strings length. It is the same as ...
ST9:0.DATA[0] This is the start of a 42 word array.
ST9:0.DATA[1] to ST9:0.DATA[41] contain the ASCII data as two characters per 16bit word - although they are annoyingly in the wrong order (if I remember correctly).

If possible it is much easier to use the ASCII instructions such as ACI, AEX, AIC etc which means you can dont have to use DATA[] at all.

Also like OkiePC says, use AWA instead of AWT unless your messages are longer than 82 characters.

Also, watch out for the bug when you setup CH0 as user, if sometimes sets it as system and you cant change it back unless you fiddle about. Vey annoying.
Doug-P
Once you've opened the STx:y data part, you can directly type in what you want sent, as in: :"The quick brown fox...". The caret '^' before a character denotes an ASCII control character, as in:"^M^J" will send an ASCII carriage return followed by a line feed. It will appear in the string exactly as it does in the quotes.

The (back?)slash character allows you to enter hex values directly.

ACI and AIC convert integers and ASCII back and forth.

If you need to intermix text with numbers in your outgoing string, the ACN instruction will do this.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2010 Invision Power Services, Inc.