Ok, I got UTF-8 encoding working by encoding the full block character using [16#E2, 16#96, 16#88], which corresponds to U+2588 "β". Moving forward, Iβll use this for creating a QR code with Version 10-M (byte mode). This version allows up to 213 characters to be encoded.
Ok I'm closer as I switch using WSTRING but in Visualization it does not respect LINE BREAKS. Instead it shows $n. See attached image.
Ok I closer as I switch using WSTRING but in Visualization it does not respect LINE BREAKS. Instead it shows $n. See attached image.
In Visualization, is there any way to make special characters in a string display properly in a Text object? I wrote a function block to create QR codes at runtime. My code uses β$DB,β which in ASCII should render as a solid block. The code works, but to display it in Visualization I had to create multiple rectangles with visibility bound to a BOOL array. That works, but since each BOOL must be exposed as a separate variable, it consumes most of the available monitoring resources. See Attached i...
In Visualization, is there any way to make special characters in a string display properly in a Text object? I wrote a function block to create QR codes at runtime. My code uses β$DB,β which in ASCII should render as a solid block. The code works, but to display it in Visualization I had to create multiple rectangles with visibility bound to a BOOL array. That works, but since each BOOL must be exposed as a separate variable, it consumes most of the available monitoring resources. See Attached i...
VarAccGetAddress does not return the correct address for TYPE_ARRAY or TYPE_USERDEF. When you use VarAccGetNode, it returns a proper IBaseTreeNode if you provide the full path of an array element or structure element, and it even provides the correct data type. The problem is that with TYPE_ARRAY, it returns the start address of the array rather than the indexed element. With TYPE_USERDEF, it only returns the offset of the element instead of the actual address. This causes many issues with nested...
I got this code working again. 3S/CoDeSys, your level of obfuscation and lack of documentation turns a simple task into a monumental complex challenge. The issue was that at some point the IecVarAccessLibrary changed and no longer allowed using IBaseTreeNode to retrieve a child or the number of children. The attached code has been updated to use IIecVarAccess6.VarAccBrowseGetChildByIndex instead. The code was also cleaned up but is still a work in progress. The current example only works one layer...
I got this code working again. 3S/CODESYS, your level of obfuscation and lack of documentation turns a simple task into a monumental challenge. The issue was that at some point the IecVarAccessLibrary changed and no longer allowed using IBaseTreeNode to retrieve a child or the number of children. The attached code has been updated to use IIecVarAccess6.VarAccBrowseGetChildByIndex instead. The code was also cleaned up but is still a work in progress. The current example only works one layer deep....
I got this code working again. 3S/CODESYS, your level of obfuscation and lack of documentation turns a simple task into a monumental challenge. The issue was that at some point the IecVarAccessLibrary changed and no longer allowed using IBaseTreeNode.getChild to retrieve a child or the number of children. The attached code has been updated to use IIecVarAccess6.VarAccBrowseGetChildByIndex instead. The code was also cleaned up and is still a work in progress. The current example only works one layer...
I got this code working again. 3S/CODESYS, your level of obfuscation and lack of documentation turns a simple task into a monumental challenge. The issue was that at some point the IecVarAccessLibrary changed and no longer allowed using IBaseTreeNode.getChild to retrieve a child or the number of children. The attached code has been updated to use IIecVarAccess6.VarAccBrowseGetChildByIndex instead. The code was also cleaned up and is still a work in progress. The current example only works one layer...
I had this code working in a previous version of CoDeSys to read variables from a GVL that were added to the Symbol configuration. The problem now is that when I get the _IBaseTreeNode_Parent, it returns a valid interface, but none of the methods or properties work. If you monitor the _IBaseTreeNode in the watch window, it does show the correct child count. However, it fails at step 30, where the child count incorrectly returns zero. In the image, you can see that the watch window displays the correct...