Jump to content

Recommended Posts

We need an option to to perform an ASCII to NUM operation on a Integer basis.

Right now, If I have the ASCII values stored in contiguous integers, I have to jump through hoops to make the conversion.

It is nice to store the ascii values separately in the integers so you can look at those integers and see what is in there without it be combined as a double byte.

Or ........ as a plan B, allow me to "view" the MIs in BYTE mode using the format column of the operand window.

Link to comment
Share on other sites

Hi Damian,

I think you have today several good options:

1. ASCII to NUM function in Strings menu;

2. Define the vector, which holds the ASCII string in "Memory" window (bottom window in VisiLogic;

If you want to "open" the vector fo two characters per MI to one character per MI, you can use the function "Transpose" (Strings menu).

Please let me know if these options answer your request.

BTW - when I have ASCII string, I set the view of the operands ot HEX. This helps me very much to "see" the text inside. Of course, it's much less elegant than the options I already pointed. Just for fast review...

Link to comment
Share on other sites

Hi Damian,

I think you have today several good options:

1. ASCII to NUM function in Strings menu;

2. Define the vector, which holds the ASCII string in "Memory" window (bottom window in VisiLogic;

If you want to "open" the vector fo two characters per MI to one character per MI, you can use the function "Transpose" (Strings menu).

Please let me know if these options answer your request.

BTW - when I have ASCII string, I set the view of the operands ot HEX. This helps me very much to "see" the text inside. Of course, it's much less elegant than the options I already pointed. Just for fast review...

Hi Emil,

The ASCII to NUM function will only work with BYTE packed characters, which is my original complaint.

I'm not sure where you are going with #2. But to me the underlying point is that I don't want to have to write code to separate them out (or compact them), and that I can think of several reasons why I might not want more than one ascii value compressed into the same operand.

The Procol Copy Buffer function for example allows me to copy ASCII input as byte packed or integer packed. If I choose Integer packed, it renders the ASCII to NUM function useless.

Viewing the values in the operand in HEX is a good suggestion, and that is the way I normally do.

Thanks,

D

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...