Post by gseidel on Using an Axis of an Axis Group in Torque Conctrol
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi manuknecht, the axis group currently always writes the axis set torque values. If no dynamic model has been configured for the axis group, then the set torques are written to 0. The solution for your use case is to call SMC_GroupUpdate [0] before you call SMC_SetTorque on the axes. This way, the axis group will write 0 to the set torques in the call to SMC_GroupUpdate(), and SMC_SetTorque then will write the desired set torque. Best regards, Georg [0] https://content.helpme-codesys.com/en/libs/SM3_Robotics/Current/SM3_Robotics/POUs/AdministrativeConfiguration/Computation/SMC_GroupUpdate.html
    
    Last updated: 2025-09-09
    
    
      
        Post by durallymax on Persistent Vars
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Looking for a better way to manage Persistent Variables. We tend to have local vars in our FBs that need persistence through downloads as the systems are updated/altered on a regular basis. Retain would suffice if we had an easy mechanism to backup and restore like we can with Persistent variables and recipes. Although not having to remember that step with Persistent variables is preferred. We're running into issues with persistent storage capacity (WAGO PFC200) using the Persistent variable list (and adding all instances). It appears there are many ways to handle this, some with recipes, some with files, others with application manager. Is there a solution that exists that is as simple as declaring as Persistent and managing elsewhere? Or do we need to move onto periodically writing CSVs?
    
    Last updated: 2025-09-22
    
    
      
        Post by reinholdgaylord on CAA File Handling: "Read only" error
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi, sorry for the late reply. After some investigation, the read-only error was being triggered by a FAT-fs filesystem panic on the kernel end, probably caused by unfinished write/reads causing corruption. I found this thread https://forge.codesys.com/forge/talk/Engineering/thread/e637d252b7/geometry dash lite which seems to give a solution of using SysProcess to send the 'sync' command to the console immediately following a write to prevent issues if power is lost or, in my case, if the unit is harshly power cycled. Indeed this seems to resolve the issue bar the worst possible edge cases. Thank you so much!
    
    Last updated: 2025-09-25
    
    
      
        Post by alexgooi on Licensing info not available.
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Dear Forum I have the following config: Codesys_IDE 3.5.20 Codesys_Virtual_Control 4.13 Codesys_License_Server 4.13 I know these are not the newest versions, but in my mind these should work. I have the same problem here. I have the license server installed on the host, and in the docker container(Codesys virtual control) I'm able to ping the license server. In the /conf/codesyscontrol/CODESYSControl_User.cfg I have added the following config: [CmpCodeMeter] EnableNetLicenses=1 LicenseServer.1="ip address of the host" I have tried it via the wbm web-page. I can create new license containers over there, but still no luck. I also have tried to run the docker container with the -s "server_IP" command. I have searched for some tutorial's but I couldn't find it. If anyone has some clue or can give me a push in the right direction it would be very very welcome!
    
    Last updated: 2025-09-29
    
    
      
        Post by alexgooi on Licensing info not available.
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Thank you for the response, The empty softcontainer does not become visible unfortunately, but I think I can get that back to working. I think I'm misunderstanding something. You are pointing to the Softcontainer number and the ticket code, I thought that I needed to fill in the virtual control containers serial code is this a misunderstanding? And if this is indeed the case, how is the link between the server (softcontainer) and the Codesys control docker container made? If I have multiple Codesys docker containers running on the same docker server, how is the correct license distributed to the correct Codesys runtime container?
    
    Last updated: 2025-10-02
    
    
      
        Post by ranadheer on Implementation of IEC-104
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi Everyone, As we didn't have client for IEC - 104 - only server server is available , so because of that we are trying to make establish the communication between the external simulator as a Client and codesys itself as a server. We are looking for the variable behavior from CODESYS has to change according to the message triggered by the CLIENT (we are using simulator Application like Redisant). We are able to see the log data as the status of triggering the SCS from Client received to the Log data of the codesys device(attached screen shot of it) and in simulator panel we had set the details to trigger the data from Redisant to Codesys. Current Status: The project builds and runs successfully, but I need guidance on how to connect this to an external IEC-104 simulator for testing and visualization by using demo mode.
    
    Last updated: 2025-10-14
    
    
      
        Post by ranadheer on Implementation IEC-104
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi Everyone, As we didn't have client for IEC - 104 - only server server is available , so because of that we are trying to make establish the communication between the external simulator as a Client and codesys itself as a server. We are looking for the variable behavior from CODESYS has to change according to the message triggered by the CLIENT (we are using simulator Application like Redisant). We are able to see the log data as the status of triggering the SCS from Client received to the Log data of the codesys device(attached screen shot of it) and in simulator panel we had set the details to trigger the data from Redisant to Codesys. Current Status: The project builds and runs successfully, but I need guidance on how to connect this to an external IEC-104 simulator for testing and visualization by using demo mode.
    
    Last updated: 2025-10-14
    
    
      
        Post by andrax on Save Recipe on Paspberry
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Unfortunately not. The folder does not work. There are neither error messages nor any other indication that this may be due to missing rights. I have searched the entire forum and also tested the Codesys example. The simple recipe management generally does not work! The Raspi crashes with the extended recipe management from the example. I have now found another sample that works. https://forge.codesys.com/forge/talk/Engineering/thread/61c6a04b79/ Many thanks to mcodem. After some trial and error I have found out: xcreate must be called at least once at runtime. After that xload_write and xread_save work All other functions do not work. It is also possible to save to the /home/Documents folder. So it is not due to the rights. It would be nice if Codesys would check where the problem really lies.
    
    Last updated: 2023-12-30
    
    
      
        Post by jmohre on External file with relative path
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      I try to add a simple text file to my PLC application, so that is download everytime the application is downloaded to the target. What I did is to add an external file to the application and this works perfect as long as the external file location does not change. It looks like the external file path is stored absolute in project. But if different users work on the project they may have different locations where for their working directory. Is there an option to store the external file path relative e.g. to the project file? Or does s.o. know a different solution to add a text file to application in order to download automatically with the application? Thanks
    
    Last updated: 2024-01-04
    
    
      
        Post by askjong on Update variables when OPC UA Client updates. Error ID: 268468277 BadAttributeIdInvalid 
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi, I'm connecting to a OPC UA Server using the Data Soruce Manager OPC UA Client. This works well until the OPC UA Server updates and the OPC UA list doesn't match up when i did last clicked the "Update variables" to add variables. All the variables are still the exists and none are removed from the server, but more are added during the engineering process. The error message i get in CODESYS is "Error in OPC UA call BadAttributeIdInvalid, Error ID: 268468277". The issues is fixed when i press the "Update variables" button and just press ok without adding or removing any variables in the list. Is there a way to either automatically update the browsepath if it fails or on startup, or to trigger it by code?
    
    Last updated: 2024-01-08
    
    
      
        Post by yang123 on EtherCAT Can't reconnect to servo drive 
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      I am using Ethercat Master 4.6.0.0 and have use the automatic restart slaves feature. But we found of after the Ethercat communication normal and slave drive power-off and power-on the slave can't reconnect sucess. The PLC Log show the drive was al status "6#34 : Invalid DC Timeout Error" and its was reconnection sucess first but seconced later the drive will show the "16#2C : Fatal Sync error" and then drive will can't reconnection. Other slave are reconnect sucess which was link after the can't reconnect's drive the drive was OMRON R88D-1SN
    
    Last updated: 2024-01-23
    
    
      
        Post by matt-s on HMI Pushbutton/Move Instruction
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      I am having an issue where the manual start/stop push buttons on the HMI are supposed to take the pumps/blowers out of auto. The logic I have attached works for the pumps, but not the blower. From what I can tell it is the exact same logic, but it is not writing a 0 to the Auto PB variable. Attached is the logic, cross reference list to show nothing else is writing to it, and the HMI screen. Any help? Am I missing something? I am using a Groov Epic PR1, my software version is 3.5 SP19 Patch 5 32 Bit.
    
    Last updated: 2024-01-25
    
    
      
        Post by matthew on New Ladder Diagram conversion does not work due to missing features 
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi It looks like in the new ladder there is no way to remove unused FB call parameters or update the function block? It's quite often where you have a function block with multiple uses and not all the parameters are required. Need the ability to leave an input/output blank without getting an compile error Expression expected instead of '' Also double clicking on the FB no longer opens the underlying FB code and view what it was doing online. Dragging and dropping a variable does not work, only using the selection works. Will these be available in the V1.0 release or just best to stick to the old ladder until it's available? Thanks
    
    Last updated: 2024-01-28
    
    
      
        Post by ewi04 on How to upload application file to remote controller (offline) ?
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi, I am looking for a good way to update a decice remotely. The devices are distributed worldwide and have normally no connection to the internet. The CODESYS Automation Server can't help here. So I want to update the decices via USB stick. I have written my own code* to update the files that are created with ‘Create boot application’. But sometimes strange things happen: visu elements are present, but are not found the application is no longer registered and therefore no longer starts I have not yet found out why these errors occur. Has anyone had similar problems or found a better way? Is there perhaps a CODESYS library or something else? Many thanks! *the code deletes the directories on the device and copies the new directories from the USB stick while the system is running (goes without saying)
    
    Last updated: 2024-02-05
    
    
      
        Post by alexgooi on Is it possible in the log to see previous shutdown
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi DavidBo, In general Codesys is used to control equipment and an exception is the worst thing that can happen in your installation. If you cannot prevent the exception from triggering, you could implement a Try catch statement, with this solution your controller keeps on running and you are able to handle the exception. __TRY //This statement will trigger an exception Result := 4/0; __CATCH(exc) //Handle the exception HandleException(exc, strExceptionText => strExceptionText); // From the Codesys help file //Create a log file //-------------------------------------------------------- __ENDTRY What you also could do is implement implicit checks, these functions cover most of the exceptions (like dividing by zero) See picture But in general avoid a complete controller shutdown!
    
    Last updated: 2024-02-09
    
    
      
        Post by karol-abktech on Raspberry and problem with runtime
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hi, My problem is with raspberry pi 4 with 2 GB ram,. Install codesys is correct but runtime works only few seconds or I can connect with device few seconds. I can ping raspberry and in system info I can see " !!!! Warning: no runtime license - running in demo mode(~2 hours)" but it is 2 minutes after runtime. When I press Start runtime I have another few seconds when I can connect to raspberry. After this time I couldn't find device. Of course, reapet start runtime works every time on few second. Raspberry is new and works with fresh install raspberry os 32 bit. Where should I start looking for solve of my problem ?
    
    Last updated: 2024-02-14
    
    
      
        Post by alexgooi on Codesys licensing explanation
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Dear Forum, We are currently switching to a native Codesys controller, and I'm currently trying to determine the correct license. I have a question regarding the Modbus instances. With the Standard S license this is set to 4 (See picture). In our projects we are using a lot of communications to Modbus servers using a Codesys Controller, for this communication I'm using the ModbusFB library (supplied by 3S) (see picture). In my project I would like to use more than 4 instances of the ClientTCP FB. My question is, is this now capped at 4 possible connections with the standard S license. Or do these function blocks have a different relation with the license? Some clarity on this topic would be very welcome. Thank you in advance
    
    Last updated: 2024-02-15
    
    
      
        Post by timvh on Profinet fault with codesys control V3 - Receive packet error 
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Are you using the Control Win SL (installed together with the development environment of CODESYS)? If yes, you might want to consider using the CODESYS RTE instead. This has real-time capabilities (running on separate core(s)). But to be able to use this, you have to install the CODESYS Ethernet driver for your network interface to be able to let the RTE access the network port also in realtime. See: https://store.codesys.com/en/codesys-control-rte-sl-bundle.html https://content.helpme-codesys.com/en/CODESYS%20Control/_rtsl_windows_rts_v3.html PS, I haven't tested this myself yet, but you could try to use the SetCommunicationState method of the Profinet controller to see if you can reset and start the bus communication: result := PN_Controller.SetCommunicationState(eRequestedState := DED.DEVICE_TRANSITION_STATE.START); PS, if you are located in the Netherlands or Belgium, we could also provide the license(s) for you.
    
    Last updated: 2024-02-28
    
    
      
        Post by timvh on Profinet fault with codesys control V3 - Receive packet error 
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Are you using the Control Win SL (installed together with the development environment of CODESYS)? If yes, you might want to consider using the CODESYS RTE instead. This has real-time capabilities (running on separate core(s)). But to be able to use this, you have to install the CODESYS Ethernet driver for your network interface to be able to let the RTE access the network port also in realtime. See: https://store.codesys.com/en/codesys-control-rte-sl-bundle.html https://content.helpme-codesys.com/en/CODESYS%20Control/_rtsl_windows_rts_v3.html PS, I haven't tested this myself yet, but you could try to use the SetCommunicationState method of the Profinet controller to see if you can reset and start the bus communication: result := PN_Controller.SetCommunicationState(eRequestedState := DED.DEVICE_TRANSITION_STATE.START); PS, if you are located in the Netherlands or Belgium, we could also provide the license(s) for you.
    
    Last updated: 2024-02-28
    
    
      
        Post by riccardo on Web Browser special tools errors
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Goodmoning everyone, I hope a codesys tecnichian will see this post. I serched on the forum and I found many topic about this tool but very few reaplies. I am tring to use the Web Browser tool, but it doesn't seem to work properly. I put several links in several forms: https://google.com http://google.com/ http://www.google.com http://www.google.com/ http://www.studiojomega.it/ . . . https://192.168.1.101/u-os-app-codesys/application/visualization/webvisu.htm But I obtain always errors; mainly 400 and 404 and in the normal visu this message appears "www.Google.com has refuse the connection". Is the codesys browser able to work as every other browser or has it some limitation? There is some particular precaution to consider when I pass the link to the codesys browser? Thanks in advance, Riccardo
    
    Last updated: 2024-02-29
    
    
      
        Post by nmcc on Viewing PDF in WebBrowser Visual Element
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      I am trying to show a PDF in a WebBrowser element. I have the file saved to the drive of the HMI/PLC. I am linking it in the URL parameter of the WebBrowser using the following directory link. 'http://localhost:8080/$$sdcard$$/FileName.pdf'. This allows for the program to download without any errors. When I navigate to that screen it is just a white box and nothing shows. I attempted putting the same link in the show parameter and I get a loading icon on my cursor when monitoring the HMI with my PC. Any help is appreciated. Thank you.
    
    Last updated: 2024-02-29
    
    
      
        Post by mp9876 on Device logon problem following fresh install
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Yes it had been the case I believe as I have seen that message regarding they were not the same. I had update the device though to match them and that still did not fix the problem. I gotta say I wanted to get out of that situation and attempted a lot of things and then I did two things at the same time that fixed my problem: Wiped the 64 bit version and installed the 32 bit version Installed latest SP20 I wish I knew which one of these actions fixed the problem but now I gotta catch up on this IDE learning; it's been quite a learning experience I have to say! Thank you very much for your time and advice; much appreciated!
    
    Last updated: 2024-03-19
    
    
      
        Post by struccc on Release SP20 - Changes in behaviour?
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Dear all, I've just started to migrate some of my ancient projects to SP20. There is one strange error (?) I have noticed so far. In a method call, depending on the circumstances I would like to return reference to an object, or an invalid reference: METHOD Add_EVT_OUT : REFERENCE TO FB_MSG VAR END_VAR IF __ISVALIDREF(refMSG_Entry) THEN Add_EVT_OUT REF= MANAGER.AddMsg_EVT_OUT( refMSG_Entry, _Get_EVT_Message(MSG_EVENT.OUT), _Get_EVT_AddCode(MSG_EVENT.OUT) )^; ELSE Add_EVT_OUT := 0; END_IF So far setting a reference variable to 0, did this. But now, the expression Add_EVT_OUT := 0; gives an error: [ERROR] DB_WTP_370: Add_EVT_ACK MSG_TRIGGER_EXT: C0032: Cannot convert type 'BIT' to type 'REFERENCE TO FB_MSG' Naturally... I can write: Add_EVT_OUT := DWORD#0; But is this the correct way? Is there any constant I could use instead, like "NULL"? Or this is totally wrong and to be avoided?
    
    Last updated: 2024-03-24
    
    
      
        Post by struccc on Release SP20 - Changes in behaviour?
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      This... is not very practical for me - as I have a bunch of different classes - it's just doesn't seems to be very practical to define a NULL for each of them... Something like this I use in parameter definitions. For example: VAR_INPUT refVFD_Drive : REFERENCE TO FB_VFD_Drive := GVL_DUMMY.Dummy_VFD; END_VAR I use this to prepare objects for code I don't control: Typycally visualizations - had many troubles with references set on the fly, right before opening a corresponding visualization... And yes, the instance in GVL_Dummy reports itself as "Fake", so it does not influence the actual application at all. Actually this way I could invalidate a reference, just to set it to a "Dummy" instance.
    
    Last updated: 2024-03-25
    
    
      
        Post by albzen on EtherCat Slaves diagnosis
    
    
       CODESYS Forge
    
    
      talk
    
    (Post)
    
    
      Hello everybody, I'm working on a RunTime Plc (Codesys 3.5.16/18.20) connected to an EtherCat bus with many devices. The bus has some communication fault but I don't know how understand which is the device or the cable that has the trouble. To understand the cause of the problem I would like to read the WKC (Working counter) of the devices (0x0300...0x030C), how is explained in EtherCat documents, but it seems that the read of the counter is disabled. Attached there is an extract of the Ethercat document. Can anyone give me some advice about how and with function can I read it. Thank you in advance!
    
    Last updated: 2024-03-29
    
To search for an exact phrase, put it in quotes.  Example: "getting started docs"
To exclude a word or phrase, put a dash in front of it.  Example: docs -help
To search on specific fields, use these field names instead of a general text search.  You can group with AND or OR.