I am using a CC100 controller along with the MQTT client from the IIOT_SL library in CODESYS. My program runs perfectly on a PC runtime, but on the CC100, setting the xEnable parameter of the MQTT client function block to true causes the CODESYS runtime to crash. However, if I manually set this variable while CODESYS is online, it works fine.
Has anyone encountered this issue before and could offer some assistance?
Hello
Which FW / CODESYS version and Device description you are using ?
Do the crash happens right away after setting xEnable to TRUE ?
Do you use encryption ?
Is this related to the Client FB or Publish FB ?
Maybe you could add a POU for implicit check to see if there is a Bound issue for instance.
We are using firmware version 26. I can confirm that the crash occurs immediately after setting xEnable to TRUE in the program. However, if I set xEnable to TRUE manually using CTRL + F7, the issue does not occur.
We are using an encrypted connection but without client-side certificates.
The issue is specifically related to the Client FB.
Regarding the POU for implicit checks, I have already implemented them, but the crash still occurs.
Any further assistance would be greatly appreciated.
Thank you for your clarifications. It turns out the problem was due to another library; I was initializing a value with a size that was too large, which worked on the PC runtime but not on the CC100.
While we are discussing this library, I noticed that the FB Client has a parameter for attaching the connection to a background process, but Codesys provides very little information in the online help. Do you know how to use this feature?
You can create an instance of the function block “AsyncProperty” from the Net Base Sevices library and then pass it to the interface input itfAsyncProperty. In the declaration, you can initialize the Fb with the desired values of the task.
How did you activate the Codesys library license on the CC100?
When I try to activate a license via the Codesys license manager, I get an error message that this is not possible on the CC100.
I understand that the IoT library is included in the CC100 license.
However, I can’t add the HVAC KNX Library to the CC100 via the Codesys license manager because you can’t add additional Codesys licenses to the CC100. I was wondering if anyone has encountered this problem. The CC100 is perfect for building control, and it’s a shame it can’t communicate directly with KNX via an additional library.