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. Quote
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 Quote
Recommended Posts
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.