ctrlX reads wrong text of drive parameter Diagnose S-0-0095

Hello,

i'd like to read out axis status with CtrlX.

Therefore parameter Diagnose S-0-0095 of the drive is read. Everything is working fine but:

The text which is read and shown has an bad annex.

This is shown in my own WebVisu-application:

In CtrlX it looks that way:

The declaration is:

fbStringAxisStatus_ECATRead: IL_ECATSoeRead;
strAxisStatusStatus: IL_ST_SOE_STRING;

The same with another text:

Text in ctrlX DRIVE is shown as it should be, correctly.

Even if status.text is cleared after/before reading within ctrlX:

Is there an issue with EtherCat settings or any other idea?

Thanks

Best reply by joeG

Codesys uses null-terminated strings, the string is missing the null at the end. You can use the IL_BufferToString function to get a properly terminated string.

ย 

View original
1
2 replies