FlexSim Knowledge Base
Announcements, articles, and guides to help you take your simulations to the next level.
Sort by:
Introduction   A new feature-version of FlexSim Simulation Software is released several times per year. In order for client PCs to be able to run a licensed version of the upgraded software, you may need to upgrade the activated license(s) on your license server. Licenses with a current maintenance subscription are eligible to be upgraded to the latest version.   If you don't understand how licensing works for different FlexSim versions, please review our Answers article FlexSim Version Numbering.   Overview   There are 6 main steps to upgrading the licenses hosted on your lmadmin or lmtools license server:   Check if you need to upgrade your license server files Return the licenses you intend to upgrade Upgrade your licenses Activate the upgraded license Reread the license Upgrade client PCs   Several of these steps have their own fully documented procedures. We'll link you to those resources below.   1. Check if you need to upgrade your license server files   If your organization's license server was installed previously and hosting licenses for FlexSim 25.1 or lower, it may need to be upgraded for compatibility with FlexSim 25.2 and higher. Click here to learn more or go directly to the latest license server files.   After you have upgraded your license server files, move on with the rest of the upgrade process, as outlined below.   2. Return the licenses you intend to upgrade   The steps to return a license-server-based license are fully documented. Choose the link below that best matches your needs, depending on whether your license server can connect to the Internet:   License Server - Return - Online License Server - Return - XML / Offline   Be sure to return ALL licenses you wish to upgrade.   3. Upgrade your licenses   NOTE: Licenses with expired maintenance will not upgrade. Timed licenses do not upgrade. Only permanent (not timed) licenses under current maintenance can be upgraded. Contact your salesperson for extending a subscription or other circumstances.   Log in to your FlexSim Account.   If you were already logged in to your FlexSim Account, in the top navigation menu hover over your initials icon and choose Reload Account.     Now in the top navigation menu, choose Licenses > List.     Check that the available seat count is equal to the total. All of a license’s seats should be returned for it to upgrade.   Click on the Upgrade Licenses button.     If you have several licenses to upgrade and all are owned by or shared with your FlexSim Account, they will all be upgraded at once. Please be patient while the upgrade process works in the background.   When the page refreshes, eligible licenses will have a new activation ID for the latest version of the software. Your license code indicates its version at the end of the code to help you know what versions your license will properly activate. Review license code format.   4. Activate the upgraded licenses   The steps to activate a license-server-based license are fully documented. Choose the link below that best matches your needs, depending on whether your license server can connect to the Internet:   License Server - Activation - Online License Server - Activation - XML / Offline   5. Reread the license   Your license server needs to start serving up your newly activated licenses. You can either restart your license manager service, or use your license manager's option to reread your licenses.   The steps to reread your licenses differ depending on which license manager you are using to host your licenses. Use these links to jump to instructions for the license manager you're using:   lmadmin lmtools+lmgrd   6. Upgrade client PCs   Finally, upgrade your PC with a version of FlexSim appropriate for your new license (learn how licenses work across versions).   After installing a new version of FlexSim, you will need to configure it to get a license from your license server. There are two ways a client PC can be configured. Choose the method below that most closely matches the main use case for your client PC:   Single-user client PCs - this method configures settings that are saved on a per-user basis. Multi-user client PCs - usually appropriate for a university computer lab or other shared-PC situation, where the configuration should be computer-based.   Having trouble licensing your client PC?   Verify client PC licensing to find out if your client PC is successfully getting a license from your new license server. Diagnose Client/Server connectivity issues that may be preventing your FlexSim software from obtaining a license. Discover other issues that may be preventing your client PC from obtaining a license by working through our License Server Troubleshooting tips.  
View full article
The instructions below are for offline/Manual XML licensing. If your server successfully connects to the Internet and to FlexSim's main license server, you can try our simpler online license return instructions. Assumed configurations All steps below assume that you followed the installation instructions as described in our license server installation instructions, and that all FlexSim's license server files were extracted to the location C:\FlexSim_LMTOOLS. Throughout these instructions we will reference files inside that folder. Find your fulfillment ID On your license server, run the flexsimserveractutil.exe program (C:\FlexSim_LMTOOLS\flexsimserveractutil\flexsimserveractutil.exe) by right-clicking and selecting Run as Administrator. In the FlexSim ServerActUtil program, go to Tools > View License Rights. Copy the Fulfillment ID for the Activation ID you are returning/upgrading by highlighting the Fulfillment ID and pressing Ctrl+C. Generate return request If your license server cannot connect to the Internet, you need to return manually. In the FlexSim ServerActUtil program, select Tools > Manual Activation > Generate Request. Choose the Return option. Paste the Fulfillment ID into the field using Ctrl+V. Browse to select a location and file name for your XML return request. Press the Generate button. Repeat for all licenses you wish to upgrade. This creates a return request XML file for each license you are upgrading. Copy the XML return request files to a location with Internet access. Log in to your FlexSim Account. Use the top page navigation to select your Licenses page, then choose Manual XML in the Licenses submenu: Drag your XML requests onto the dropzone (alternatively you can click the dropzone and browse to a file to upload). Your XML request will be uploaded and processed. If there are any errors, you will get more information about the problem which you can use in contacting your local FlexSim representative for help. If the XML request is successfully processed, you will be prompted to download the response XML file. Download your XML responses and transfer them back to your license server. Process each response XML file by opening flexsimserveractutil.exe and going to Tools > Manual Activation > Process Response. Browse to each response XML file and Process. Your licenses should be successfully returned. If you have any questions or problems, please search our Answers Community for possible solutions. There is a good chance someone else has already asked your question. Still not finding what you're looking for? Submit a new question and we'll check it out. If you're including any confidential information, such as license codes, be sure to mark your question as private! You can also contact your local FlexSim distributor for live phone, web, or email help.
View full article
Interacting with your licenses isn't something you do every day, but it doesn't need to be intimidating. We've documented all the main procedures you'll use to manage your FlexSim licenses like a pro.   When you purchased your FlexSim licenses you chose one of two methods for licensing your software. Click below to jump to the licensing procedures for your style of licenses:   Network Licensing Standalone Licensing Need a refresher on the differences between network and standalone licensing? Our Standalone vs Network Licensing.pdf is a basic intro or check out our in-depth article on License Models. Network Licensing With an in-house license server you don't activate your licenses directly in the software (as in standalone licensing). Instead, your FlexSim software is configured to obtain a seat from a license server in your organization's network. Your organization will need to provision, install, and maintain a license server.   Here are instructions for all the primary server licensing tasks.   Install, Configure, Activate Here are our instructions for installing, configuring, and licensing your server, and for configuring FlexSim to get a seat from your license server. This document covers both online and secure/offline scenarios.   PDF installation guide Online Answers articles index We have some shorter guides focused specifically on just the license activation step. If you already have an installed and configured license server, these guides are provided as a convenience for use in subsequent licensing procedures, like upgrading your licenses.   License Server - Activation - Online License Server - Activation - XML / Offline   Return You may occasionally need to migrate your licenses to a new license server or return your license as part of a license version upgrade.   License Server - Return - Online License Server - Return - XML / Offline   Repair In rare circumstances your activated license can become "broken". This means that even though the license is still activated on your server it is no longer able to serve seats to client PCs. This can happen if your server hardware or operating system changes significantly.   License Server - Repair - Online License Server - Repair - XML / Offline   Upgrade FlexSim releases new feature-versions several times per year. If the licenses activated on your license server are lower than the version of FlexSim software you're trying to run, FlexSim software won't be able to be licensed by your license server. You can learn more about how licensing works for a given version number in our Answers article FlexSim Version Numbering.   In this case you'll need to upgrade the activated licenses on your license server. If your maintenance is current, follow the procedure linked below to upgrade your license server for use with the latest versions of FlexSim. If your maintenance is expired contact your local FlexSim distributor to renew.   This article covers both online and secure/offline scenarios.   License Server - Upgrading your hosted licenses   Miscellaneous These items don't pertain to any particular licensing procedure but may be useful in some situations.   License Server - View licenses License Server - Delete fulfillment License Server - Troubleshooting tips License Server - Client/Server connectivity   Standalone Licensing With standalone licensing you'll activate a license code (also called an Activation ID) directly in FlexSim.   Below are detailed instructions for all the primary licensing tasks used in managing your standalone licenses:   Activation To apply a license to your computer, follow the linked instructions depending on whether your computer or network allows FlexSim to communicate online.   Standalone - Activation - Online Standalone - Activation - XML / Offline   Return Returning your license removes it from your computer and makes your seat available for a new activation. This is useful if you need to free up a seat for a colleague or move your license to a different computer. You may also return your license as part of the upgrade process for a new version of FlexSim - returning the old version so that you can activate an upgraded Activation ID.   Standalone - Return - Online Standalone - Return - XML / Offline   Repair In rare circumstances, your activated license can become "broken". This means that even though the license is still activated on your computer it no longer enables additional features allowed by your license type. This can happen if your computer hardware or operating system changes significantly.   There is no online method available. Please use the XML / Offline method. Standalone - Repair - XML / Offline   Upgrade FlexSim releases several new feature-versions per year. An upgraded version of the software requires an updated license key to enable its licensed features. Licenses with a current maintenance subscription are eligible to be upgraded to the new version. You can learn more about how licensing works for a given version number in our Answers article FlexSim Version Numbering.   If your maintenance is current, follow the procedure linked below to upgrade your license for use with the latest versions of FlexSim. If your maintenance is expired contact your local FlexSim distributor to renew.   This article covers both online and secure/offline scenarios:   Standalone - Upgrading your license   Miscellaneous These items don't pertain to any particular licensing procedure but may be useful in some situations.   Standalone - View licenses Standalone - Delete fulfillment
View full article
FlexSim licenses can either be standalone or network-based. Each license model has its pros and cons. Learn more about these two different license models. You're here because you've chosen network licensing and you're ready to get started. A license manager by any other name FlexSim is licensed using technology from Revenera's FlexNet. FlexNet is one of the top software licensing technologies and is used by many large software companies, including several others in the engineering software space. FlexNet offers two different license managers: lmtools and lmadmin. You decide which platform will work best for your organization's needs. (Spoiler alert: we like lmtools best). lmtools Hosting your FlexSim licenses with lmtools lmtools is a simple utility for creating and managing the licensing service that will serve your FlexSim licenses to your organization's client PCs. This basic utility isn't installed - it is a simple executable. It has no 3rd party dependencies. For maximum security, compatibility, and simplicity, FlexSim recommends using lmtools. Many organizations that add FlexSim to their toolkit already use lmtools for managing their license hosting services for other software, so using lmtools to manage your FlexSim licenses just makes sense. Even if your FlexSim purchase marks the first time your org has set up a license manager, lmtools is a great way to go, and is our recommended license manager. Visit Hosting your FlexSim licenses with lmtools for a complete reference on configuring your license server using lmtools. lmadmin Hosting your FlexSim licenses with lmadmin lmadmin is FlexNet's newer, shinier license manager. It includes a web-based front end, so all the administration is done from your web browser. It is more complex than lmtools, serving both the licensing service and a management front end, and lmadmin relies on Java, which you will need keep up to date with patches and security updates. FlexSim usually does not recommend lmadmin, mainly because of the more complex configuration needed to host and manage the web front end (including additional firewall considerations, an extra username and password, etc.), its reliance on Java, and the fact that many FlexSim users already host other software licenses using lmtools. Visit Hosting your FlexSim licenses with lmadmin for a complete reference on configuring your license server using lmadmin.
View full article
This article is used to aggregate all other licensing articles under one heading. You can use the navigation panel in Answers' right column to navigate between the various licensing articles in this tree. Sharing your licenses License Models Licensing Procedures Licensing Errors FlexSim Feature Limitations by License Type License server - feature pools - only checkout features for license type FlexSim Version Numbering, including how licensing works for a given version number In addition, the following links contain some general licensing tips. These will likely be added to a future article. A few of the items are outdated, but in general the advice is still good. General licensing tips (Mar 9, 2018) License Q&A (Jul 17, 2017)
View full article
I have created the following model to use elevator for different floor. I am not sure what I have missed out that the elevator is not working. Please advise me. Thanks multi-floor.fsm David
View full article
The following articles describe various error messages and numbers you may see as you work with your FlexSim licenses, along with possible solutions and workarounds.   flxActCommonHandleOpen (50003, 71000, 10103) flxActAppReturnSend (50018, 41145, 32) Manual activation error (50019, 41200, 19) Manual XML licensing error (50019, 42107, 10246) Licensing activation error (50041, 41143, 34)   Operations error: 7032 Invalid fulfillment ID Operations error: 7109 Invalid activation ID Operations error: 7131 Server activation is not allowed Operations error: 7174 Only deployed entitlement line item can be fulfilled Operations error: 7189 Client activation is not allowed Operations error: 7284 Cannot perform support actions on inactive fulfillment record Operations error: 7288 fulfill count exceeded the available seat count Operations error: 7466 The return of the fulfillment is denied Operations error: 7581 Online return/repair request is not originated from the original client machine   Trusted storage binding change detected
View full article
O presente vídeo tem como objetivo demostrar três formas de sincronizar eventos no FlexSim através da espera (Wait) por um período X, ou até algum outro evento (Wait for Event). Sincronização de Tarefas - WAIT no FlexSim (3 das n possibilidades)
View full article
Have you received this licensing error? Operations error: 7131 Server activation is not allowed to activate entitlement line item: Make sure the license model is a server license model. You may encounter this error if you attempt to activate a standalone license using flexsimserveractutil.exe on a license server. A standalone license is intended to be activated directly within FlexSim Simulation Software installed on a client PC. Please see our instructions for standalone licensing for the procedures to use with your standalone FlexSim licenses.
View full article
The instructions below are for Internet-connected license servers.   If your server cannot connect to the Internet or to FlexSim's main license server, try our offline/Manual XML license return instructions.   Assumed configurations   All steps below assume that you followed the installation instructions as described in our license server installation instructions, and that all FlexSim's license server files were extracted to the location C:\FlexSim_LMTOOLS. Throughout these instructions we will reference files inside that folder.   Find your fulfillment ID   On your license server, run the flexsimserveractutil.exe program (C:\FlexSim_LMTOOLS\flexsimserveractutil\flexsimserveractutil.exe) by right-clicking and selecting Run as Administrator.     In the FlexSim ServerActUtil program, go to Tools > View License Rights.     Copy the Fulfillment ID for the Activation ID you are upgrading by highlighting the Fulfillment ID and pressing Ctrl+C.     Attempt online return   When your license server returns a license over the the Internet, flexsimserveractutil.exe will communicate with the following FlexSim servers via HTTP (port 80) and HTTPS (port 443):   www.flexsim.com sw.flexsim.com sw1.flexsim.com license.flexsim.com   In the FlexSim ServerActUtil program, select Connect > Return.     Paste the Fulfillment ID into the field using Ctrl+V, and press the Return button.     After a few seconds and several status messages, you should receive an indication of success.     If you have any questions or problems, please search our Answers Community for possible solutions. There is a good chance someone else has already asked your question. Still not finding what you're looking for? Submit a new question and we'll check it out. If you're including any confidential information, such as license codes, be sure to mark your question as private! You can also contact your local FlexSim distributor for live phone, web, or email help.
View full article
O presente tutorial tem como objetivo demonstrar de forma resumida a construção e alteração de um modelo utilizando a biblioteca "Bottling", da qual utiliza o MassFlowConveyor, que é basicamente um conveyor desenvolvido pela equipe da FlexSim USA para a simulação principalmente de linhas de envase. Mass Flow Conveyor no FlexSim 2017 Update 1
View full article
Have you received this licensing error? Operations error: 7466 The return of the fulfillment is denied by the return policy because max return exceeded. This error indicates that returns are disabled for your license. Your license is configured for one-time activation onto a computer. If you believe your license should be able to transfer from one computer to another, please contact your local distributor to discuss the situation.
View full article
Have you received this licensing error?   Operations error: 7288 The activation of the fulfillment is denied by the activation policy because fulfill count exceeded the available seat count.     Here are some common reasons you may encounter this error, along with some possible solutions.   All seats are already in use   Problem: All the seats of this license are already activated. There are no available seats left to activate.   Solution: You must return a seat from a computer where it is currently activated. Once a seat has been successfully returned it is available for a new activation.   If you are not sure where your license is currently activated, there are two main methods for finding out:   Go on a hunt: On each computer where the license may be activated, check the license status by opening FlexSim and going to Help > License Activation > View Licenses tab > press the View Licenses button. This will show you the license information for the current PC. Check the history: You can view your activation/return history from your FlexSim account's licenses page. On the Licenses page, expand the folders until you can see the Activation ID you are trying to track down. Click the Activation ID to load the history for this license. This history includes dates/times of the activations and returns. If the information is available it will also list the computer name where the license was last activated and the Windows username of the logged in user who completed the action. If the computer where your license was activated has been stolen, destroyed, wiped, etc., please contact your local distributor to discuss a solution.   Activation ID is obsolete   Problem: You are trying to activate an obsolete activation ID. An activation ID can become obsolete if it has been cancelled, replaced, or upgraded.   Solution: Make sure to use the most up-to-date version of your license. Log in to your FlexSim account to view your latest license codes.   Consider the following scenario: You purchased a FlexSim license and were emailed a license code. You used that license on your laptop for several years, upgrading FlexSim as new versions were released and following the prompts to upgrade your license as needed. Now you have purchased a new laptop. You successfully returned your license from your previous laptop. On the new PC you installed FlexSim and needed to get it licensed. You looked up your original license code from your years-old email, but when attempting to activate you received error 7288.   The reason is that over the years as you upgraded FlexSim you also upgraded your license code. The old, original license code is obsolete. You must log in to your FlexSim account to get the most recent license code. With the new license code you are able to successfully activate your license on your new laptop.
View full article
Failed to connect to the license server   Have you ever encountered this error?   ERROR: flxActAppActivationSend - (50041, 41143, 34) "Failed to connect to the license server or Operations server. Recover: check connection and that server is operational."       This error indicates that your computer is not able to communicate with FlexSim's license server.   If your computer is purposely air-gapped, please use the Manual XML licensing methods listed at the bottom of this article.   Protocols, ports, and addresses   A license activation or return will attempt to make HTTP (port 80) and HTTPS (port 443) connections, currently with the following servers:   flexsim-fno.flexnetoperations.com license.flexsim.com www.flexsim.com sw.flexsim.com sw1.flexsim.com   Make sure these communications are allowed on your network.   To make sure you maintain compatibility with any possible future changes to our server configurations, consider configuring your network to allow communication with any *.flexsim.com subdomain.   Troubleshooting   Any of the following could prevent your FlexSim software from communicating with FlexSim's license servers:   Your computer is air-gapped or otherwise blocked from communicating over the Internet. The FlexSim software is not allowed to communicate over the Internet. FlexSim's above-listed addresses are blocked on your network or computer. Your network communicates through a proxy service but you haven't configured the proxy server settings inside FlexSim. FlexSim's license server may be down due to some outage or maintenance.   Let's look at solutions for each possibility:   1. No communication / connection issues   If your computer is disconnected from the Internet, you will need to connect in order to activate or return a license online. If this is not possible, please use the Manual XML licensing methods listed at the bottom of this article.   You may also see this error if you're on a flaky wi-fi connection, or a slow network connection. The communication must be solid enough that it does not time-out, where the client software is able to receive a response in a timely manner. If you are connected to the Internet but on a slow or unreliable connection, you can fall back to the Manual XML licensing methods, or you can retry the online activation multiple times - it may eventually complete successfully after several attempts.   2. FlexSim's communications are blocked   If your computer is connected and you can visit other sites, but FlexSim's licensing actions are still blocked, it could be due to an anti-virus solution or other security measure preventing the FlexSim Software's communications. Work with your IT team to disable such measures and test if FlexSim is allowed to communicate. If so, configure your security measures to allow FlexSim to communicate for licensing purposes, or if that is not possible, use the Manual XML licensing methods listed at the bottom of this article.   3. FlexSim's license server is blocked   Perhaps one or more of FlexSim's license server addresses (listed above) is blocked on your network. This could be a deliberate blocking of a specific address, or more likely a general block of a wider range of sites or IP addresses. Work with your IT team to determine if this is the case and if the block can be removed. If that is not possible, use the Manual XML licensing methods listed at the bottom of this article.   4. Proxy is not configured   If your network settings require that FlexSim communicates through a proxy server, you'll need to configure the software to do so.   For FlexSim version 23.0 and higher you'll do this directly in the software. From FlexSim's main menu, navigate to Help > License Activation > Advanced > Proxy Details. Fill in your proxy server information and click the Apply button.     If you're using an older version of FlexSim, you can download this attached model. This is an older model file compatible with FlexSim version 5.0 and up. It has a Model Control GUI that is an extension to the License Activation window that includes this extra tab where you can put proxy details.   proxy-details-v5.fsm   5. License is already activated but fulfillment is broken   The license you're trying to activate may already be activated on your computer, but in a broken or unusable state.   Follow the instructions for your license hosting situation to remove the broken fulfillments:   Standalone - Delete fulfillment License Server - Delete fulfillment   6. License server offline   There are circumstances when FlexSim's main license server can go offline. Most commonly this is due to regular updates or patches being applied. In this case the server will return to normal operation shortly. Please be patient and try again in a few minutes.   In cases where longer maintenance is planned you will find a notification at the top of this community indicating the purpose, date/time, and expected duration of such maintenance. This notification will be given as early as possible to help you plan around such downtime.   In rare circumstances an outage could be caused by a failure in one or more of the license server's databases, operating system, server hardware, networking, or data center. When such an outage occurs, we will post a notice at the top of this community and work to restore service as quickly as possible.   Help! I need support!   If none of the above suggestions work for you, please open a support ticket and include as many details as possible about what you've already tried and what you see happening.   Please be aware that if FlexSim's license server is online and other clients are able to activate and return their licenses successfully, that the issue is within your organization's network or on your computer. The proper place to turn to for support will be to your own internal IT teams. The above information, including the protocols, ports, and addresses and the different troubleshooting suggestions should be enough information to solve the issue.   Manual XML licensing   If you are not able to allow FlexSim to communicate over the Internet, please use our manual XML activation/return methods for offline systems:   Standalone - Activation - XML / Offline Standalone - Return - XML / Offline License Server - Activation - XML / Offline License Server - Return - XML / Offline  
View full article
When you try to activate offline, the following error might appear in the console: ERROR: flxActSvrActivationRespProcess - (50019, 42107, 10246) "Failure to process response for an unspecified reason. This error may be returned when a valid failure response is received, for example when the activation server denies a request. Recovery: check parameters used for the request." License Server Manual XML Activation error example: Standalone Manual XML Activation error example: If you encounter this error, check the response.xml file you are attempting to process. If it includes the text SERVER_CONFIG or CLIENT_CONFIG, but your Trusted Storage is already configured, you may receive this error. With Trusted Storage already successfully configured, you must generate a brand new activation request. Upload the new request to your FlexSim Account for processing. If the license is available you will be able to download the XML response. This response should process and successfully activate your license. Full instructions for performing manual XML licensing for license servers can be found in our license server installation instructions document. ===== Here are some other items to keep in mind with manual XML licensing on your license server: Download the response XML files and transfer them to their license server without modification. Modifying the XML files in any way will "break" them. This includes line endings and other white space. The files include checksums and if the files change they will not work. The destination license server needs to be the same system where the request was generated. The FlexNet Licensing Service 64 needs to be installed, be a high enough version, and be running properly as a Windows service. Checking these items is covered in our license server installation instructions starting on page 6 with 3. FlexNet Licensing Service. flexsimserveractutil.exe may need admin privileges to write to the proper places on the system. Be sure to right-click the application and choose Run as Administrator.
View full article
Have you received this licensing error?   An error occurred in the activation request Operations error: 7109 Invalid activation ID:     This error can occur when you are attempting to activate a standalone license online using the Activate tab.   You may encounter this error if you have incorrectly typed your activation ID, left the field blank, or if the system otherwise does not recognize the license code you have entered as a valid activation ID.   Some older versions of FlexSim also were not able to remove spaces or other whitespace from the beginning or end of the activation ID field, so be sure that any spaces or other extraneous characters are removed from both the beginning and ending of the license code text.
View full article
Have you received this licensing error? An error occurred in the activation request Operations error: 7189 Client activation is not allowed to activate: Check the license model to make sure a client can activate. You may encounter this error if you attempt to activate a network license directly within FlexSim software. A network license is intended to be installed on a license server using a FlexNet license manager - either lmtools or lmadmin. Please see our instructions for installing a license server, which also include directions for connecting your client software to the license server to obtain a license.
View full article
I was recently asked how a user can implement jerk, i.e. a rate of acceleration change, in the AGV module. The AGV module uses FlexSim's kinematics API to define the motion of AGVs along paths. The kinematics API does not natively support jerk. However, the AGV module has included a hook to allow developers, and audacious end users :-), to customize the kinematics that drive AGVs on paths. Using this hook, you can approximate jerk by breaking what would otherwise be a single kinematic, with a single acceleration/deceleration, into multiple smaller kinematics that gradually change the acceleration/deceleration of the object as it progresses. There are two ways to do this. The first option is to simply do it as an end user, confining your changes to your model, by customizing nodes in the tree. The second option is to do it as a module developer, using the module SDK. Adding Jerk as a User The AGV network uses an "AGV Customization Delegate" to allow for hooks to be placed at certain points in the AGV navigation logic. There is a default customization delegate that the AGV network uses, but you can override the logic of this default delegate by adding and configuring a special node at MODEL:/AGVNetwork>variables/customizationDelegate. But before I tell you how to do it, I want to explain a little more about how it works. I've attached three C++ files. The main ones you'll want to look at are AGVCustomizationDelegate.h and AGVCustomizationDelegate.cpp. These show the definition of the customization delegate class. In the header file, you'll see the definition of AGVCustomizationDelegate class. This class includes several methods, but the main method relevant here is addKinematics(). This method takes several parameters defining the context. Its responsibility is to add one or more kinematics, in the positive X direction, that will move the AGV the target distance along a path. The AGVCustomizationDelegate class is the default customization delegate used by the AGV network. The C++ files also define a subclass called UserAGVCustomizationDelegate, which overrides the methods of its parent class by delegating the logic to FlexScript code that the user can write in the model. So, now for actually doing it in the model. We want to instantiate an instance of UserCustomizationDelegate at the node MODEL:/AGVNetwork>variables/customizationDelegate, so that we can write FlexScript code to add the kinematics. Navigate in the tree to MODEL:/AGVNetwork>variables/customizationDelegate Right click on that node, and choose Edit > Designate this Node (so) In a script window execute the script: nodeadddata(so(), DATATYPE_SIMPLE) Add a subnode to that node named sdt::attributetree and give it the text: AGV::UserAGVCustomizationDelegate. Copy the node and then paste it onto itself. This will instantiate the UserAGVCustomizationDelegate. Right-click on the addKinematics subnode and choose Build > Toggle Node as FlexScript. Right-click on the addKinematics node and choose Explore > As Code. This will allow you to edit the code for adding kinematics. The header for field should be as follows (note this is determined by the evaluate() command in AGVCustomizationDelegate.cpp at line 71). treenode kinematics = param(1); // the kinematics node to call addkinematic()/getkinematics() on treenode section = param(2); // the associated travel path section double startAtTravelDist = param(3); // the agv cumulative travel distance at this point double distance = param(4); // the distance to travel on the path section (your addkinematics() calls should add up to this distance) double startTime = param(5); // the start time for the first addkinematic() call double startSpeed = param(6); // the initial speed to start at double endSpeed = param(7); // the target end speed (should be going this speed at the end) int reason = param(8); // reason for adding the kinematic (see AGVCustomizationDelegate.h) treenode endSpeedOut = param(9); // if target end speed cannot be reached, update this node's value with the actual end speed double peakSpeed = param(10); double acc = param(11); double dec = param(12); TaskExecuter agv = ownerobject(tonode(get(kinematics.up))); // the agv At this point you can customize how kinematics are added to the kinematics node in this code. To approximate jerk you would break it up into small addkinematic() commands that each change the acceleration/deceleration. Please refer to the kinematics api for more information on how to manipulate kinematics. Note that you should only use the addkinematic() and getkinematics() commands in this field (not initkinematics() or updatekinematics()), and the addkinematic() command should only tell the AGV to move forward in the X direction. Y and Z directions are ignored by the AGV travel logic. In other words, from a kinematics perspective, the AGV network "flattens" an AGV's path into movement in a straight line along the x axis. When you're finished adding kinematics, you should return the end time of the last added kinematic. This will be the same as the return value of the last called addkinematic() command. Adding Jerk as a Module Developer To implement jerk as a module developer, you would first create a module using the module SDK. Then you would include AGVClasses.h and AGVCustomizationDelegate.h in your project (do not include AGVCustomizationDelegate.cpp as it won't compile properly. I'm including that file just to be informative in this article). Then you would subclass AGVCustomizationDelegate with your own class that overrides the appropriate methods, specifically the addKinematics() method. Once you've done that, you would replace MODEL:/AGVNetwork>variables/customizationDelegate with an instance of your customized class, using the same steps described above, but using your own class name instead of AGV::UserAGVCustomizationDelegate. If you need more header files so you can access more information, i.e. the definition of TravelPathSection, the let us know and we can get them to you. agvheaderfiles.zip
View full article
We have released a beta version of our Emulation module. The Emulation module adds a tool that enables communication between FlexSim and OPC / Modbus Servers and PLCs. Help files are included in the FlexSim User Manual to assist you. This beta version must be installed with FlexSim 2017 Update 1. 32-bit and 64-bit installers can be downloaded through the downloads section in the Modules tab of the FlexSim website: FlexSim Downloads The following are known issues: Asynchronous Write for OPC Connections is not working. The option has been disabled. Please post any feedback or bug reports either as a comment to this article or you can email them to [email protected]
View full article
What is ODBC? FlexSim can use ODBC, and ODBC can connect to many different kinds of data sources, including files (like Excel) and databases. It allows you to use SQL queries to get data from any supported data source. ODBC uses a driver determine how to get data from a given data source. A driver is translator between ODBC and whatever data source you are querying. For example, there is a driver for Excel files. If you have that driver on your system, you could use ODBC to query data from Excel files. As another example, there is a driver for SAP HANA, the database for SAP. If you have that driver, then ODBC will know how to talk to SAP. This means that if the correct driver is installed, and is working correctly, that you can use FlexSim to query any ODBC data source. Using the Database Connector FlexSim has a tool called the Database Connector. You can use it to configure a connection to a database. This article uses that tool. For more information, see https://docs.flexsim.com/en/20.2/Reference/Tools/DatabaseConnectors/ As an example, let's say that you want to connect to Excel using ODBC. Assuming you have the Excel ODBC driver installed on your system, you can configure a Database Connector to look like this: Note that you must specify the full connection string. In the connection string, you can see that the driver and the file are specified. Then you can query the data in a given sheet with a query like this: SELECT * FROM [Sheet1$] You can find more information on querying Excel files at websites like this: https://querysurge.zendesk.com/hc/en-us/articles/205766136-Writing-SQL-Queries-against-Excel-files-Excel-SQL- If you use Office 365, you may need to install the Microsoft Access Database Engine 2016 Redistributable. This includes newer drivers for Excel and Access Be sure to install it with the /quiet flag on the command line. Instructions can be found in this troubleshooting guide: https://docs.microsoft.com/en-us/office/troubleshoot/access/cannot-use-odbc-or-oledb Note that FlexSim has an Excel tool, which is usually easier to use. This tool requires Excel to be installed, but does not require the ODBC driver for Excel to be installed on your computer. For more information, see https://docs.flexsim.com/en/20.2/Reference/Tools/ExcelInterface/. Excel makes a good example because most people have it, and it's easy to get the driver for it. Connection Strings Different kinds of connections require different connection strings. The following list has an example connection string for a few data sources: Excel Driver={Microsoft Excel Driver (*.xls, *.xlsx, *.xlsm, *.xlsb)};DBQ=Path\To\Excel\File.xlsx Access Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=Path\To\Access.accdb SQLite Driver={SQLite3 ODBC Driver};Database=Path\to\sqlite.db SAP HANA DRIVER={HDBODBC};UID=myUser;PWD=myPassword;SERVERNODE=myServer:30015 Checking for Drivers Note that each connection string specifies a driver, and then additional information. The additional information depends on the driver you are using. In order to determine which drivers are on your system, you need to open the ODBC Data Sources Administrator window. To do that, hit the windows key, and then type ODBC. Then choose the option called ODBC Data Sources (64 bit). If you are running 32-bit FlexSim, open the 32 bit version. Go to the Drivers tab. Here is what my Drivers tab looks like: You can see I have drivers for Access, Excel, SQL Server, and SQLite3. I don't have drivers for SAP HANA. If I did, you'd see a driver named HDBODBC in the list. To access that kind of database, I'd need to install that driver. You can also see that the name of the driver used the the connection string must match exactly to what is shown here. Other Info You may see an exception appear when you test the connection to your database. If the view shows that the connection succeeded, then it has succeeded. The exception happens because FlexSim tries to get a list of tables from the database that it's querying. FlexSim may not guess correctly for your particular data source. That exception can be safely ignored. If you used the old db() commands in the past, consider upgrading to using the Database Connector. It will be orders of magnitude faster to read in an entire table.
View full article
Top Contributors