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

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

This site uses cookies. By clicking I accept, you agree to their use.