nealmp

MrPLC Member
  • Content count

    3
  • Joined

  • Last visited

Community Reputation

0 Neutral

About nealmp

  • Rank
    Hi, I am New!

Profile Information

  • Country United States
  1. Yep, I had realized that about 5 minutes after I posted this thread that I had forgotten to add the .DATA[0] suffix in my copy instruction, therefore when I executed the instruction it was copying into the length of the string rather than its data, giving me a length of the ASCII value I was copying. A newbie mistake on my part.
  2. Okay, I figured something out. Earlier when I tried copying it straight from the tag reading from the console into a string, it had been copying into the length instead of data. I can tell it to copy into the data set of my string and it will give me the ascii character. Might have been what I was missing.
  3. I have been using RSLogix programming for a little time now, and I have run into a problem with converting ASCII characters coming in from a remote console into usable data in my program. Right now they are stored in tags of a data type SINT, or signed integer. I would like to convert them to a string of an equivalent value to the incoming data for comparison. For example, a character of incoming data could contain a value of 121, which is equivalent to 'y' as an ASCII string. I would like to convert it into that character so that I can compare and evaluate the next step of my project. I am aware of the DTOS and STOD functions that are at my disposal, but I am missing some in between step. Or perhaps I am on the wrong thought process altogether. I am not sure.   My work associate described them as having 8 bits of data in which I have to pack into a new string whose length I must define. Does anyone know what I am missing?