Search talk: gets

 
<< < 1 2 (Page 2 of 2)

Post by karel-bas on Loosing connection to emulation running on Linux CODESYS Forge talk (Post)
Hello, I am trying to emulate my code but for some reason my Codesys IDE keeps loosing connection to the emulator. I am constantly pinging virtual machine on which its running and its running fine, but codesys refuses to reconect to it, and is not able to rediscover it. Codesys 3.5 SP20 Patch 1 I have linux installed like image in attachment.(using version 4.12) Linux VM is set up to use up to 4 cores and 8gb of ram, with nothing else runing on it. I dont have a license so I am aware that the emulation shouldnt run for more then 120 minutes I am able to, login, get sysinfo, reboot etc from codesys IDE for certain period of time (5minutes) then my connection gets lost, sometimes I can login again, but sometimes i have to reboot the VM. Any suggestions what might be the issue ?
Last updated: 2024-09-19

Post by steven-schalm on Github Actions CI/CD tasks - development topic CODESYS Forge talk (Post)
hello kevinrn, I've been looking for a solution to the CI/CD issue for a long time. Briefly about me... I am 32 and software architect for Codesys V3 and fullstack dev for web (VueJS, NestJS) in a small company in Erfurt (Germany). https://www.rex-at.de/. Through my web part, we already have CI/CD running well via GitLab (YAML-based configuration file (.gitlab-ci.yml), which defines which pipelines and jobs are executed when certain events occur) with everything you know. Stages for npm packages - prepare (GitVersion, npm install or whatever) - build (vite, tsc or whatever) - testing (vitest, jest or whatever) - deploy (npm packages) And similar for monorepo's or backend services (in NestJS) as DockerImages. For Codesys we have been building an OOP framework for years (~50 libraries now), which is currently managed via SVN and a specially written Svn-Watcher (in Python) gets commits and runs and builds everything together and deploys it to an FTP server and network drive. Why do we still have SVN? Because we are unfortunately still tied to the safety integration of Codesys and can therefore only go to SP15 at most with our controller/Eckelmann. But soon there will be an update and there will be no more obstacles to using Git. Hence my questions: 1. the basic idea is to run a local Windows Runner on some machine? 2. install Codesys on the machine where the runner is running? 3. powershell & python scripts are then used to execute builds (compile, build, sign libraries) & deploys? 4. can the Github action also be used in GitLab? ChatGPT has already told me that it's not the same, but it doesn't hurt to ask. Do you have any ideas on this? Greetings :D
Last updated: 2024-08-20

Post by rkohser on Scripted Git clone / checkout being blocked by "Project Environment" popup CODESYS Forge talk (Post)
Hi, I am trying to build a CI/CD pipeline around our codesys projects. The only entry point if the git url and branch, as we do not put our project file under source control, so we needed to find a way to git clone from the python scripting engine. This is currently how we do this : system.commands["Git", "Clone"].execute( "ProjectLocation=" + project_dir, "ProjectName=" + project_file_name, "RemoteUrl=" + project_git_remote_url, "GitProjectStoragePath=" + project_git_local_dir, ) system.commands["Git", "Checkout", "Branch"].execute( "PrimaryProjectHandle=0", "BranchName=origin/" + project_git_branch ) This works fine, except that, depending on the environment and the project, the "Project Environment" popup gets displayed to suggest for some updates, and waits for a user interaction, even with the "--noUI" flag injected as parameter. I investigated the VersionUpdateFlags, but the problem is that the git clone is an atomic operation that clones and directly opens the generated project without the possibility to inject any updateFlags argument (only used in the ScripProjects.open() function. I also tried to simulate some keyboard events acknowledge the window from script but I did not find the right location for the SendKeys statement, I think before the git clone call is too early and after is too late. So I am wondering if there would be some other way to do that. Is there some more proper scripting api for the git add on ? Is there a global configuration of the VersionUpdateFlags that would allow the popup to be disabled outside from any project context ? Is there some way to automatically acknowledge this kind of messages in a "--noUI" mode ? What do you suggest ? Thanks for your help, Roland Edit : I managed to solve my problem by following these steps in my pipeline : - create a template of a project and opt file preconfigured not to open the popup - open this project - initialize an empty git repo - add the remote, fetch and checkout the needed branch -> no popup is displayed, hourra Edit2 : The initial question was raised on a CODESYS V3.5 SP18 Patch 2 profile. Since CODESYS 3.5.19.30 a scripting API is available for Codesys Git that allows cloning a project with the support of VersionUpdateFlags https://content.helpme-codesys.com/en/CODESYS%20Git/_git_using_scripting.html
Last updated: 2024-01-19

Post by hwillems on Ranges, Lambdas, on Fixed arrays of structs CODESYS Forge talk (Post)
I do datastructures and algorithms in Codesys. For example a Struct of Person with thing's like IdNumber, Name, Age etc. as example. Now i do all kind of calculations, filters. So i have this pretty big Fixed Array with Structs. On this struct i want to do simple stuff you can do easily in C++/Python/Rust etc. For example i want to do this: AvererageAge := Average(Peoples.Age); Then it will return the average of all members ages. Or Sort struct on age etc. Or sort on alphabetical Name. Or use Lambda functions to filter/mutate out things like, filter out everybody above 18 years old. Or remove people who it's name start with "A". Currently i have to write my own custom function for example sorting on Age. And make a super specific function based on that particulare datastructure. Here an Example: (*Before calling this FIlter method, set the mNodeFilterSwitch to the desired filter.*) CASE mNodeFilterSelect OF (********************************[ Status Filters ]***********************************) NodeID: FOR x := ACS_OUT_BEGIN TO ACS_OUT_END BY 1 DO FOR y := ACS_IN_BEGIN TO ACS_IN_END BY 1 DO IF marrNode[y].Status.oiNodeID > marrNode[y + 1].Status.oiNodeID THEN mNodeTemp := marrNode[y + 1]; marrNode[y + 1] := marrNode[y]; marrNode[y] := mNodeTemp; END_IF; END_FOR; END_FOR; Started: FOR x := DES_OUT_BEGIN TO DES_OUT_END BY -1 DO FOR y := DES_IN_BEGIN TO DES_IN_END BY -1 DO IF marrNode[y].Status.oxStarted > marrNode[y - 1].Status.oxStarted THEN mNodeTemp := marrNode[y - 1]; marrNode[y - 1] := marrNode[y]; marrNode[y] := mNodeTemp; END_IF; END_FOR; END_FOR; Starting: FOR x := DES_OUT_BEGIN TO DES_OUT_END BY -1 DO FOR y := DES_IN_BEGIN TO DES_IN_END BY -1 DO IF marrNode[y].Status.oxStarting > marrNode[y - 1].Status.oxStarting THEN mNodeTemp := marrNode[y - 1]; marrNode[y - 1] := marrNode[y]; marrNode[y] := mNodeTemp; END_IF; END_FOR; END_FOR; END_CASE; I have like 30+ of these in the enum. Not really DRY code right? These are custom made bubble sort filters in a function. You pass in the Datastructure, and say what function you want. (This is an enum collection of sorting functions) And then the Array with Nodes of Structs gets ordered. Why can't we have Iterators and Lambda's and build in standard functions like regular languages? Also i use bubble sort because it's the easiest to implement because i can't get this to code DRY. Problem with ST (Even the new one with classes) that it's very limited for programming datastructures and algorithms. Yes you still not want dynamic memory and you need to choose the correct algorithm so you know the most extreme edge cases regarding the time it takes to execute the algorithms.(Real-time execution) How are other people dealing with this? Here for example saw some software using an adjusted ST language and having FOR EACH possibility: https://www.fernhillsoftware.com/help/iec-61131/structured-text/st-for-each.html You can then build your own custom Iterator functions. I wish the IEC 61131-3 standard would be more expressive and having more standard modern features, but still keep close to the fact of no dynamics memory and real-time systems.
Last updated: 2023-08-31

Post by ihatemaryfisher on Sorting array of any-sized structure CODESYS Forge talk (Post)
In my machine's operation, I need to display multiples tables containing arrays of structured variables. The arrays change during operation, and my supervisor has advised me to write a new bubble-sort for each array. I think I can make a function to sort an array of any data type. This was my own project, and I'm a relatively new coder. I want to know the weaknesses in my approach, and a better method, if one exists. As far as I can test, the function accepts an array of a structured variable of any size, and sort it by any VAR in that structure. But it relies heavily on pointers, which I've heard are bad practice? Function call: // SORT BY BYTE-SIZED VAR IF xDoIt[6] THEN FUNBubbleSortSansBuffer( IN_pbySourcePointer := ADR(astArray[1]), // address of first byte in first element of array IN_pbyComparePointer:= ADR(astArray[1].byCompByte), // points to first byte of the comparing variable (variable you sort by) IN_uiStructureSize := SIZEOF(TYPE_STRUCTURE), // size, in bytes, of the structured variable IN_uiCompareSize := SIZEOF(astArray[1].byCompByte), // size, in bytes, of the comparing variable (variable you sort by) diArrayElements := UPPER_BOUND(astArray,1), // number of elements in array IN_xSmallToLarge := xSortOrder // whether to sort by small2large or large2small ); END_IF Function: FUNCTION FUNBubbleSortSansBuffer : BOOL VAR_INPUT IN_pbySourcePointer : POINTER TO BYTE; // points to beginning of array (first byte of first element) IN_pbyComparePointer: POINTER TO BYTE; // points to first byte of the comparing variable (variable you sort by) IN_uiStructureSize : UINT; // size, in bytes, of the structured variable IN_uiCompareSize : UINT; // size, in bytes, of the comparing variable (variable you sort by) diArrayElements : DINT; // number of elements in array IN_xSmallToLarge : BOOL; // whether to sort by small2large or large2small END_VAR VAR j : DINT; // repeat iteration over array until array ends i : DINT; // iterarte over array, swapping when necesary k : DINT; // iterator from 1 to size of structure (stepping 'through' a single element in array) dwSize : DWORD; // internal var for use in MEMUtils.MemCpy(<size>) // FOR SORTING BY BYTE VAR pbySourcePointer : POINTER TO BYTE; pbySourcePointer2 : POINTER TO BYTE; pbyComparePointer : POINTER TO BYTE; pbyComparePointer2 : POINTER TO BYTE; pbyPointerToBuffer : POINTER TO BYTE; // pointer to single byte buffer byBufferByte : BYTE; // single byte buffer END_VAR dwSize := UINT_TO_DWORD(IN_uiStructureSize); // get structure size (number of bytes) pbyPointerToBuffer := ADR(byBufferByte); // assign pointer to address of buffer byte (because MEMUtils.MemCpy requires a pointer input) CASE IN_uiCompareSize OF // depending on the size of the VAR to sort by (current functionality for BYTE and WORD/INT 1: // BYTE (8 BIT) FOR j := 1 TO diArrayElements DO // for number of elements in array FOR i := 1 TO (diArrayElements-1) DO // same thing, but row[i+1] row is included in swap logic pbySourcePointer := IN_pbySourcePointer + dwSize*(i-1); // point at #1 byte in array element[i] pbySourcePointer2 := pbySourcePointer + dwSize; // point at #1 byte in array element[i+1] // NOTE: because of memory locations, each array element is offset from one another by a number of bytes equal to the size of the structure // We can "walk" from array[i] to array[i+1] via steps equal to the size of the structure // e.g., ADR(array[i+1]) == ADR(array[i]) + SIZEOF([array datatype]) pbyComparePointer := IN_pbyComparePointer + dwSize*(i-1); // point to sorting variable in array element[i] pbyComparePointer2 := pbyComparePointer + dwSize; // point to sorting variable in array element[i+1] // using sort order (small -> large/large -> small) IF SEL(IN_xSmallToLarge, (pbyComparePointer2^ > pbyComparePointer^),(pbyComparePointer2^ < pbyComparePointer^)) THEN // This is where it gets tricky. We've identified pointers for the starting bytes of aArray[i] and aArray[i+1] // and we know the size of aArray[i]. We are going to swap individual bytes, one at a time, from aArray[i] and aArray[i+1] // this allows us to use only a single byte var as a buffer or temporary data storage // e.g., consider a structure consisting of a word, a byte, and a string. it is stored like this // |------WORD-------| |--BYTE-| |STRING------...| // astArray[1] == 1000 0100 0010 0001 1100 0011 1010 1010.... etc // astArray[2] == 0001 0010 0100 1000 0011 1100 0101 0101.... etc // performing a single swap (copy into a buffer, etc.) of the first byte of each array element creates this // astArray[1] == 0001 0100 0010 0001 1100 0011 1010 1010.... etc // astArray[2] == 1000 0010 0100 1000 0011 1100 0101 0101.... etc // incrementing the pointer adresses for the swap by 1 and swapping again swaps the next byte in each array element // astArray[1] == 0001 0010 0010 0001 1100 0011 1010 1010.... etc // astArray[2] == 1000 0100 0100 1000 0011 1100 0101 0101.... etc // continuing this from k to SIZEOF(TYPE_STRUCTURE) results in a toally swapped row FOR k := 1 TO IN_uiStructureSize DO // copy single byte[k] of array element 1 to buffer MEMUtils.MemCpy(pbyDest := (pbyPointerToBuffer), pbySrc := (pbySourcePointer+k-1), dwSize := 1); // copy single byte[k] of array element 2 to 1 MEMUtils.MemCpy(pbyDest := pbySourcePointer+k-1, pbySrc := (pbySourcePointer2+k-1), dwSize := 1); // copy buffer to byte[k] array element 2 MEMUtils.MemCpy(pbyDest := (pbySourcePointer2+k-1), pbySrc := pbyPointerToBuffer, dwSize := 1); END_FOR END_IF END_FOR END_FOR
Last updated: 2023-08-17

Post by sushela on Temu $100 Off Coupon Coupon {"[acq615756]"} Up to $100 Off CODESYS Forge talk (Post)
Are you ready to save big on your next shopping spree? With the Temu Coupon code $100 Off, you're just a step away from unlocking unbeatable Coupons on a wide range of products. For those in the USA, Canada, Middle East, and Europe, codes acq615756 and acq615756 are your keys to maximum savings. These codes promise incredible benefits, making them ideal for avid shoppers across these regions. Whether you're searching for the Temu Coupon code 2024 for existing customers or the Temu $100 Off Coupon Coupon, we've got you covered. We ensure you get the best deals available, every time. Temu Coupon Code $100 Off For New Users New users, rejoice! By using our Coupon code on the Temu app, you'll enjoy the highest benefits available. The Temu Coupon $100 Off and Temu Coupon code 40 off for existing users make saving easy and exciting. acq615756: Flat $100 Off Coupon for new users. acq615756: $100 Off Coupon bundle for new customers. acq615756: Up to $100 Off Coupon bundle for multiple uses. acq615756: Free shipping to 68 countries. acq615756: Extra 30% off on any purchase for first-time users. Each code is designed to maximize your savings experience, ensuring you get more for less every time you shop. How To Redeem The Temu $100 Off Coupon Code For New Customers? Eager to redeem your Temu $100 Off Coupon? Follow these simple steps: Visit the Temu app and create a new account. Browse through the vast catalog and add items to your cart. Proceed to checkout. Enter the Temu 40 off Coupon code in the provided field. Enjoy your newly Couponed total and complete your purchase. By following these steps, you'll unlock amazing savings on your first order. Temu Coupon Code $100 Off For Existing Users Existing users, don't feel left out! We've got exclusive Coupon codes just for you. By using our codes on the Temu app, you can continue to enjoy amazing Coupons and offers. The Temu 40 off Coupon code and Temu Coupon code for existing customers ensure that loyal users always get the best deals. acq615756: $100 Off extra Coupon for existing Temu users. acq615756: $100 Off Coupon bundle for multiple purchases. acq615756: Free gift with express shipping all over the USA/Canada. acq615756: Extra 30% off on top of existing Coupons. acq615756: Free shipping to 68 countries. With these codes, your shopping experience remains rewarding, ensuring continuous savings. How To Use The Temu Coupon Code $100 Off For Existing Customers? If you're an existing user, using your Temu Coupon code 40 off is straightforward. Follow the steps below: Open the Temu app and log into your account. Select the items you wish to purchase and add them to your cart. Head to checkout. Enter the Temu Coupon code for existing users in the designated field. Confirm your order with the new Couponed total. Enjoy your savings and shop more with confidence! How To Find The Temu Coupon Code $100 Off? Looking for the Temu Coupon code $100 Off first order? Here's how you can find it: Sign up for the Temu newsletter to receive verified and tested Coupons directly to your inbox. Follow Temu’s social media pages to get the latest Temu Coupons 40 off. Visit trusted Coupon sites where you'll find the latest and working Temu Coupon codes. Ensure you're always in the loop with the best deals available. How Temu $100 Off Coupons Work? The Temu Coupon code $100 Off first time user is a gateway to incredible savings. These codes provide a flat $100 Off Coupon on your total purchase, making shopping a pleasure. To use the Temu Coupon code 40 percent off, simply enter the code during checkout. The system will automatically deduct $100 Off from your total, allowing you to enjoy significant savings. Whether you're a new or existing user, these Coupons ensure you get the best value for your money. How To Earn $100 Off Coupons In Temu As A New Customer? To earn the Temu Coupon code $100 Off as a new customer, follow these steps: Sign up for a new account on the Temu app. Complete your first purchase by entering the Temu 40 off Coupon code first order. Enjoy the Coupons and explore additional offers available exclusively for new members. By following these steps, you ensure that your first shopping experience on Temu is both rewarding and affordable. What Are The Advantages Of Using Temu $100 Off Coupons? Using our Coupons on the Temu app and website provides numerous benefits. Here are some advantages: Temu $100 Off Coupon code legit: Ensures authenticity and reliability. Coupon code for Temu 40 off: Flat $100 Off Coupon on the first order. $100 Off Coupon bundle for multiple uses. 90 % Coupon on popular items. Extra 30% off for existing Temu customers. Up to 90% off on selected items. Free gift for new users. Free delivery to 68 countries. With these benefits, your shopping experience is bound to be both economical and enjoyable. Temu Free Gift And Special Coupon For New And Existing Users There are multiple benefits to using our Temu Coupon codes. The Temu $100 Off Coupon code and $100 Off Temu Coupon code ensure that every customer gets the best deal. acq615756: $100 Off Coupon for the first order. acq615756: Extra 30% off on any item. acq615756: Free gift for new Temu users. acq615756: Up to 90 % Coupon on any item on the Temu app. acq615756: Free gift with free shipping in 68 countries including the USA and UK. Each code unlocks unique benefits, ensuring a delightful shopping experience. Pros And Cons Of Using Temu Coupon Code $100 Off Using the Temu Coupon $100 Off code and Temu free Coupon code 40 off has its pros and cons: Pros: Flat $100 Off Coupon. Extra Coupons for existing customers. Free shipping to 68 countries. $100 Off Coupon bundles. Free gifts on select purchases. Cons: Limited to digital app users. Some codes have specific regional restrictions. May not apply to certain high-demand items. Terms And Conditions Of The Temu $100 Off Coupon Code In 2024 Before using the Temu Coupon code $100 Off free shipping and Temu Coupon code $100 Off reddit, keep these terms in mind: Our Coupon codes don’t have any expiration date. Valid for both new and existing users in 68 countries worldwide. No minimum purchase requirements. Only one Coupon code can be used per purchase. Exclusive deals may vary based on region and product availability. Final Note The Temu Coupon code $100 Off provides an unparalleled shopping experience, ensuring you get the best value for your money. Whether you're a new or existing user, these codes unlock incredible savings. Remember, the Temu $100 Off Coupon is your ticket to a rewarding shopping journey. Happy shopping and saving! FAQs Of Temu $100 Off Coupon 1. What is the benefit of using the Temu Coupon code $100 Off? The Temu Coupon code $100 Off offers a flat $100 Off Coupon on your purchase, allowing you to save significantly on a wide range of products. Can existing users use the Temu $100 Off Coupon? Yes, existing users can enjoy Coupons by using the Temu Coupon code for existing customers. These codes provide additional savings on top of ongoing promotions. How can I find the latest Temu Coupons? Sign up for the Temu newsletter, follow their social media pages, or visit trusted Coupon sites to get the latest Temu Coupons 40 off. Are there any restrictions on the Temu Coupon code $100 Off? The Temu Coupon code $100 Off free shipping has no minimum purchase requirements but is limited to one use per order and may have regional restrictions. Do Temu Coupon codes expire? Our Temu Coupon codes have no expiration date, ensuring you can use them anytime.
Last updated: 2024-10-26

<< < 1 2 (Page 2 of 2)

Showing results of 31

Sort by relevance or date