Guest Guest_Rusty_K Posted April 30, 2004 Report Posted April 30, 2004 Hello, I am reading several BYTES from a PLC which each represent one ASCII character. How do I convert this so that WinCC will display the actual ASCII character and not the numeric ASCII code. Any help would be greatly appreciated. Cheers Mates! R.K.
jacekd Posted May 5, 2004 Report Posted May 5, 2004 Hi, create IOField of type Output and assign your byte tag to its Output Value property. Set its Display property to "No". In Events->Output Value->Change put the code below: char* data; data=SysMalloc(1); sprintf(data,"%c",(char)value); SetTagChar("TagString",data); SysFree(data); "TagString" is a WinCC internal tag of type string. Create second IOField of type Output and assign "TagString" to its Output Value property. Set its Data Format property to "String" and Output Format to "*". Regards, jacekd
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now