We are still working on migrating to the new Bosch Connected Industry Online Portal. Stay tuned! Click here for the latest updates.
10-19-2023 02:40 PM
Hello,
we try to implement Nexeed MatControl module and GTL labels (apart from common implementation with MatLabels). The problem is presence of special control ASCII characters in GTL label, when sending the whole label content to MES:
As you can see, Cognex scanner sends the control characters as $1E or $1D but MatControl for some reason, needs data as:  or  .
We tried to replace the dolar characters with the required sequence, it looks good in PLC string buffer. But, when we send the data to MES (as a STRING identifier variable), it is received incorrectly, with four additional characters after every ampersand: amp; This, of course, renders the whole string unrecognizable for MES.
Is there some solution, how to send charecters like & or > to MES with DDL communication over OpConXML format? I guess the hash sign is not a problem.
Thank you
10-19-2023 04:06 PM
you using the function for replace character for MAT label from the NexeedScanner?
Unit.ParCmd.Read.ReplaceCtrlChar := true;
10-20-2023 12:54 PM
No, we don't use that functionality. Thanks for the hint, we'll try it next week. Nevertheless, the documentation states, that it encloses ASCII number between two hashes, so it is not what MatControl wants:
10-20-2023 03:07 PM
The way ReplaceCtrlChar works was actually introduced in coordination with MatControl in order to avoid the XML escape sequence problem you are describing. The source code documentation is not exactly correct, though. Actually, the characters are replaced with [#n#] where n is the decimal value of the byte, either one or two digits.
10-24-2023 08:55 AM - edited 10-24-2023 09:00 AM
Hello Nexidator,
we tried the ReplaceCtrlChar function yesterday, the answer is yes and no. Yes, it is behaving like you said, and no, the MatControl still doesn't accept that.
[)>[#30#]06[#29#]12PGTL3[#29#]9K11[#29#]1JUN33149511912766247[#29#]14D20210418[#29#]16D20200316
So, if there is no other option how to send the control ASCII characters directly, would it be possible to replace the chars in the scanned string in PLC and send it then to MES?
How to properly encode characters in DDL OpConXML event, that MES recieves exactly this:  ? I believe only the ampersand is problem.
Thanks