IoT & Connectivity Tips | ThingWorx & Kepware PTC
Recently active
Step 8: TasksStep 9: File Transfer ExampleStep 10: Support Other PlatformsStep 11: Next Steps Step 8: Tasks If you are using the built-in Tasker to drive data collection or other types of repetitive or periodic activities, create a function for the task. Task functions are registered with the Tasker and then called at the rate specified after they are registered. The Tasker is a very simple, cooperative multitasker, so these functions should not take long to return and most certainly must not go into an infinite loop. The signature for a task function is found in [C SDK HOME DIR]/src/utils/twTasker.h. The function is passed a DATETIME value with the current time and a void pointer that is passed into the Tasker when the task is registered. After creating this function, it will need to be registered using the twApi_CreateTask function after the connection is created. Below shows an example of creating this function, registering this function, and how this function c
Guide ConceptStep 1: Examples and Strategy Learn how to create factory line solutions the can help take you to the next level Guide Concept This project will introduce more complex aspects of the ThingWorx application and solution building. Following the steps in this guide, you will develop your own IoT application or get a jump start in how to utilize ThingWorx for your needs. We will teach you how to create a focused rules engine or service level logic to be used with the ThingWorx Platform. You'll learn how to Create automated machine processesUse Services, Alerts, and Subscriptions to handle processes without human interactionIntegrating complex logic with straight forward step by step systems NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete ALL parts of this guide is 60 minutes Step 1: Examples and Strategy Download the attached FoodIndustry.zip and extract/import the contents.
Step 3: Creating Machine ProcessesStep 4: Automating ProcessesStep 5: Handling Cooking MachinesStep 6: Next Steps Step 3: Creating Machine Processes Having data and properties without moving parts would be useless. We already setup services on how to perform an inspection in the last guide. This time around, let's form processes to create our products and generate any alerts whenever we've finished production. We won't show too much into our recipe (it's a family secret), but we will highlight some concepts to help with making our machine process smoother.We won't go into creating an SMT line. For a complete guide on how to create such an application you can view our Monitor an SMT Assembly Line guide. Events and Subscriptions Let's create events for the cook time being done and a subscriptions on how to handle these scenarios. Open the Fizos.BrautsMachine.ThingTemplate template and go to the Events tab.Click the + Add bu
Guide ConceptStep 1: What Are FunctionsStep 2: Create an Expression Discover how ThingWorx Functions can be implemented in a compelling Mashup design. Guide Concept This project will introduce how to create complex user interfaces that are built by using simple Mashup functions. Following the steps in this guide, you will build a web application with multiple layers.We will teach you how to create a professional user interface that effectively conveys information to users. You'll learn how to Navigate to other UIsCreate expressions and validationsCreate event routers and data handlingCreate confirmation modals/pop-upsCreate status messages NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete ALL parts of this guide is 60 minutes Step 1: What Are Functions In the Mashup Builder, we utilize Functions to create added capabilities in our Mashups. Whether we are navigating to another Mashup or triggerin
Step 3: Create Validation and StatusStep 4: Create Confirmation ModalStep 5: Create Navigation Step 3: Create Validation and Status With our MyFunctionsMashup Mashup open, let's add a Validation. A Validation is similar to an Expression, except you have the added capability of triggering Events based on a True or False outcome of your validation. We will use the Validation to check and confirm the Text Field we created only has the values we added in our Functions. Let's also add two Status Message Functions that will show whether or not a user has added any text outside of what we want. Open the MyFunctionsMashup Mashup to the Design tab.Click the green + button in the Functions area. In the New Function modal, select Validator. Set the Name to isDataClean. Click Next. Click Add Parameter.Set the Name to text and ensure the Base Type is STRING. Add the following code to the Expression are:if(tex
Step 6: Create Event RouterStep 7: Next Steps Step 6: Create Event Router What do you do when a user can perform multiple events in which data is generated, and want those outputs to go through the same exact process? An Events Router Function is your solution. The Events Router Function allows for multiple data sources to be funneled to one location. Let's create a simple example in our MyFunctionsMashup Mashup. In this Mashup, we'll add two Text Field Widgets and a Label Widget. The two Text Field Widgets will take user input and then an Events Router will send the output to the Label. Let's start! Open the MyFunctionsMashup Mashup to the Design tab.Click on the Widgets tab.Type in the Filter text box for Text Field. Drag and drop TWO (2) Text Field Widgets to the Mashup Canvas.Type in the Filter text box for Label. Drag and drop ONE (1) Label Widget to the Mashup Canvas.We now have all the Widgets we need for this
Guide ConceptStep 1: What Are Dynamic GridsStep 2: Create A Dynamic Grid Discover how ThingWorx advance tree grids and grids can be implemented in a compelling Mashup design. Guide Concept This project will introduce how to create complex user interfaces that are built by using Mashup grids and JavaScript services. Following the steps in this guide, you will build a web application with advanced data displays.We will teach you how to create a professional user interface that effectively conveys information to users. You'll learn how to Create dynamic tree grids to display hierarchy.Create dynamic grids to display growing data number of data points. NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete this guide is 30 minutes Step 1: What Are Dynamic Grids In the Mashup Builder, we utilize Functions to create added capabilities in our Mashups. Whether we are navigating to another Mashup or triggerin
Step 3: Create A Tree GridStep 4: Next Steps Step 3: Create A Tree Grid With our MyFunctionsMashup Mashup open, let's add a Validation. A Validation is similar to an Expression, except you have the added capability of triggering Events based on a True or False outcome of your validation. We will use the Validation to check and confirm the Text Field we created only has the values we added in our Functions. Let's also add two Status Message Functions that will show whether or not a user has added any text outside of what we want. Open the MyFunctionsMashup Mashup to the Design tab.Click the green + button in the Functions area. In the New Function modal, select Validator. Set the Name to isDataClean. Click Next. Click Add Parameter.Set the Name to text and ensure the Base Type is STRING. Add the following code to the Expression are:if(text === "NO") { result = true; } else
Guide ConceptStep 1: Completed ExampleStep 2: Understanding Directory ServicesStep 3: Configure ThingWorx and ApacheDSStep 4: Import Users Into ThingWorxStep 5: Next Steps Create users, security groups, and provide a method to authenticate with LDAP. Guide Concept LDAP allows for a layer of security within your company or organization to be utilized for authentication or user management. These concepts and steps will allow you to focus on development of your application while still allowing the ability to utilize the power of ThingWorx! We will teach you how to enable LDAP authentication in ThingWorx and configuring ThingWorx to connect to a LDAP server. You'll learn how to How to enable LDAP Authentication on ThingWorxConfiguring ThingWorx to connect to an LDAP serverImporting users from LDAP NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete this guide is 60 minutes Step 1: Completed Example Dow
Step 5: Mashup Builder APIStep 6: Mashup Builder Callbacks Step 5: Mashup Builder API The following APIs can be accessed by a widget in the context of the Mashup Builder: API Description this.jqElementId This is the DOM element ID of your object after renderHtml(). this.jqElement This is the jquery element. this.getProperty(name) / this.setProperty(name,value) Note that every call to this function will call afterSetProperty() if it’s defined in the widget. this.updatedProperties() This function should be called anytime properties are changed in the widget so t
Step 7: Widget Lifecycle at RuntimeStep 8: Runtime APIs available to WidgetsStep 9: Runtime Callbacks Step 7: Widget Lifecycle at Runtime When a Widget is first created, the runtime will obtain any declared Properties by calling the runtimeProperties() function. The property values that were saved in the Mashup definition will be loaded into your object without your code being called in any way. After the Widget is loaded but before it’s displayed on the screen, the runtime will call renderHtml() for you to return the HTML for your object. The runtime will render that HTML into the appropriate place in the DOM. Immediately after that HTML is added to the DOM, you will be called with afterRender(). This is the time to do the various jQuery bindings (if you need any). It is only at this point that you can reference the actual DOM elements, and you should only do this using code such as: // note that this is a jQuery object var widg
Step 10: Building and ImportingStep 11: TipsStep 12: Next Steps Step 10: Building and Importing After you’ve completed your code updates, it’s time to build and import! Below are instructions for building with the framework you have set for the project. Build Extension with Ant Go to the Package explorer view.Right click on build-extension.xml.Hover over Run As and select Ant Build. Your console output will indicate BUILD SUCCESSFUL. This will build your project and create the extension zip in the your_project->build->distributions folder of your project. Build Extension with Gradle Right click on your project ->Gradle (STS)->Tasks Quick Launcher. Set Project from the drop-down menu to your project name and type Tasks as build.Press Enter. Your console window will display BUILD SUCCESSFUL. Your extension has been created and stored as a zip file in your_project->
Guide ConceptStep 1: Top Level LayoutStep 2: Import DataStep 3: Map MashupStep 4: Navigation Panel Discover how ThingWorx Widgets can be implemented in a compelling Mashup design. Guide Concept This project will introduce how to create complex user interfaces that are built by combining simple Widgets and basic styling. Following the steps in this guide, you will build a web application showing both geographic and table based information. We will teach you how to create a professional user interface that effectively conveys information to users. You'll learn how to Organize UI elements in a Mashup layoutUse the Repeater widget effectivelyUse Styles to customize UI elements within a Mashup NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete ALL parts of this guide is 60 minutes Step 1: Top Level Layout A Mashup like this does take some time to assemble, but is built by layering simple Widgets.
Step 5: Collection WidgetStep 6: Customize CollectionStep 7: Detail Panel Step 5: Collection Widget A Collection widget is used to display information from a collection of Things. Similar to a Grid Widget, the Collection widget gives you complete control over how data is displayed by binding data to an embedded static Mashup. In the first part of this step we will create a static Mashup with Parameters bound to its widgets. Next, we will configure a Collection widget to use the static Mashup we create. In the next step we will customize the Collection styling. Create Static Mashup Click the Browse tab on the far left of Composer, in the Visualizations section, click Mashups .Click + New to create a Mashup.Select Static Mashup, then click OK. Name your Mashup TractorListFormatIf Project is not already set, click the + in the Project text box and select the PTCDefaultProject.Click Save.Click the Design tabIf Project is not
Step 8: Learn More About WidgetsStep 9: Next Steps Step 8: Learn More About Widgets For more details on how to use and customize Widgets highlighted in this guide, refer to: Widget Link to How-ToLayoutCustomizable and Responsive UIGaugeDisplay Property Values with a GaugeStyleDefine Your UI StyleNavigationCustomizable and Responsive UIGoogle MapDisplay Geolocation Data in Your UI Step 9: Next Steps Congratulations! You've successfully completed the Design an Effective UI guide, and learned best practices for building a complex Mashup that includes maps, menus, and detail sections all working together effectively for an enhanced user experience. Learn More We recommend the following resources to continue your learning experience: Capability Guide ExperienceObject-Oriented UI Design Tips Additional Resources If you have questions, issue
Guide ConceptStep 1: Import SPC AcceleratorStep 2: Configure Properties for SPC monitoring Configure streaming asset properties for SPC monitoring. Guide Concept Note: This guide is intended only as a starting point and is not a fully developed or supported solution. This accelerator has been developed using ThingWorx 8.5 and should not be used with any previous versions of the software. This project introduces you to configuring Properties from your connected streaming assets for Statistical Process Control (SPC) monitoring. Following the steps in this guide, you will learn how multiple connected assets and their Properties can be displayed in a hierarchy tree. You will then configure these Properties using predetermined set points, and upper and lower control points for the assets. Finally, you will learn to navigate the monitoring of the Properties. We introduce some of the basic building blocks of an SPC accelera
Step 3: Monitor SPC PropertiesStep 4: Next Steps Step 3: Monitor SPC Properties Once the properties have been configured, you are ready to progress on to SPC monitoring. This is done by viewing the PTC.SPC.Monitoring_MU Mashup. NOTE: Once a property has been configured for SPC monitoring, 2-5 minutes must pass before the accelerator has collected enough streaming values to perform SPC calculations. During this time, you may see an item that has 2 OOC rules violated; “Collecting Enough Data to Begin Monitoring” and “… to Compute Capability”. Within Property SPC Status, click an item from the grid that has 0 in the OOC column. See that the Out of Control Rules area is blank, since there are no currently-violated SCP rules for that selected property. Both CP and CPK are above 1.0, showing that the process is capable. All the points in the charts are blue, as they do not violate any OOC rules. Within Property SPC Status, click an it
Guide ConceptStep 1: Completed ExampleStep 2: Define OrganizationStep 3: Security and PermissionsStep 4: Deploy ApplicationStep 5: Logging and TroubleshootingStep 6: Next Steps Guide Concept This project will introduce how to get your application ready for usage by actual users or ready to collect data. Following the steps in this guide, you will be ready to present your finished application to users so they can benefit from its functionality. Deploying your application provides the ability for users to access it from anywhere, anytime and enables your edge devices to communicate with your application 24/7. We will teach you how to deploy your ThingWorx IoT application to be ready for whatever experience you've molded it to be. You'll learn how to Create login screens, users and user groupsDefine security permissionsDeploy applicationIdentify and troubleshoot issues NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time t
Guide ConceptStep 1: Completed ExampleStep 2: Create Style DefinitionStep 3: Customize Style Definitions Convey information about IoT data effectively by customizing style definitions and implementing event-based logic Guide Concept This project will help you identify how you would like to create an experience for Users. Following the steps in this guide, you will use color schemes to convey information quickly and effectively, for example to alert users of critical events. With ThingWorx Composer, you can implement Styles and States in your Mashups to enhance your user experience. We will teach you how to create an affective IoT application experience that looks great and easy to navigate. How the UI is presented can influence users and their enjoyment of the application. You'll learn how to Create a Style DefinitionCustomize Style DefinitionsCreate and implement State DefinitionsImplement event-based state changes NOTE: This guid
Step 4: Create and Implement State DefinitionsStep 5: Implementing Event-Based State ChangesStep 6: Next Steps Step 4: Create and Implement State Definitions A state definition is a collection of style definitions, along with rules for when to apply each style definition. The rule plus the style definition is a state. In the HelloWorldPlayground Mashup, if the Gauge Widget goes to 10 and the Increment the Count button is clicked once again, the Gauge starts back at 0. This value change is displayed in the Line Chart when it is refreshed. Nevertheless, it would be helpful to have a way to show a user that they’re encroaching 10 and will have to restart, such as the Gauge changing colors in the section. This and many other uses is where State Definitions become useful and go hand and hand with Style Definitions. Create Style Definition to Represent State Change First, let’s create Style Definitions to represent the changes in the count. The default St
Guide ConceptStep 1: Create Thing ShapeStep 2: Add Properties to Thing ShapeStep 3: Next Steps Use Thing Shapes to create groups of related Properties Guide Concept Save time and effort by modeling a solution in ThingWorx using Thing Shapes to group Properties.A logical group of Properties can be applied to Things and Thing Templates. You'll learn how to Create a Thing ShapeAdd Properties to a Thing Shape NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete this guide is 30 minutes Step 1: Create Thing Shape In this section you will create a Thing Shape for sensor properties of a MXChip development board. Thing Shapes are components that contain Properties and Services. In Java programming terms, they are similar to an interface. Start on the Browse folder icon of ThingWorx Composer.Under the Modeling section of the left-hand navigation panel hover over Thing Shapes, then click the
Guide ConceptThingWorx Analytics OverviewThingWorx Analytics Video GuideNext Steps A series of training videos for ThingWorx Analytics Guide Concept This guide provides a series of training videos covering ThingWorx Analytics Server and Platform Analytics. It is recommended that they be viewed in order. Additionally, a downloadable .zip with additional training materials is provided. You'll learn how to Use ThingWorx AnalyticsUnderstand the Analytics Thought ProcessBasic Analytics concepts (data types, variables, modeling)Descriptive AnalyticsPredictive Analytics modeling techniquesFamiliarity with other topics: Prescriptive Analytics, Clustering, Time Series, Anomaly DetectionAcquire basic knowledge of how to create an end-to-end Smart ApplicationDeepen your Foundation and Analytics understandingNOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete all parts of this guide is 12 hours ThingWo
Step 3: Creating Customer DataStep 4: Expanding Logistics ModelsStep 5: Next Steps Step 3: Creating Customer Data Now let’s begin creating the customer data. Just enough examples for us to understand what is happening at each step. Let’s create at least 4 customers by following the steps below: Open the Fizos.Customers.DataTable Data Table and go to the services tab.Open the AddDataTableEntries service to be executed. This service will allow us to create some general data to work with. You can create as many as you like for this test. Click the values parameter to start creating entries.After clicking + Add, and enter data for customers. Try to add at least 1 Factor data tag for each customer. Save your entry and create a second entry with any location and tags you like. We aren’t adding vehicles as of yet, but we will in the next section.After saving, don’t forget to execute the service with the two entries s
GUIDE CONCEPTStep 1: Examples and StrategyStep 2: Expanding Customer Models Learn how to create systems to handle logistics and production distribution GUIDE CONCEPT This project will introduce complex aspects of the ThingWorx Composer and solution building. Following the steps in this guide, you will develop your own IoT application or get a jump start in how to utilize ThingWorx for your needs. We will teach you how to create a focused rules engine or service level logic to be used with the ThingWorx Platform. YOU'LL LEARN HOW TO Create automated logistical processesUse Services, Alerts, and Subscriptions to handle processes without human interactionIntegrating complex logic with straight forward step by step systems NOTE: This guide's content aligns with ThingWorx 9.3. The estimated time to complete All parts of this guide is 60 minutes. Step 1: Examples and Strategy This guide builds on the knowledge gain
GUIDE CONCEPTStep 1: Learning Path OverviewStep 2: Setup PLCStep 3: Create PLC ProjectStep 4: Configure ThingWorx Kepware ServerStep 5: TroubleshootingStep 6: Next Steps GUIDE CONCEPT This guide introduces connecting an Allen-Bradley PLC to ThingWorx Kepware Server. YOU'LL LEARN HOW TO Create and run a simple ladder logic application on an Allen-Bradley PLCConnect the PLC to ThingWorx Kepware Server NOTE: The estimated time to complete this guide is 30 minutes. Step 1: Learning Path Overview Assuming you are using this guide as part of the Rockwell Automation Learning Path, then you have now completed each of the following installations: 1. Connected Components Workbench 2. ThingWorx Kepware Server 3. ThingWorx Foundation (for Windows) In this continued step, you'll now connect an Allen-Bradley PLC to Connected Components Workbench and then to
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.