cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you get an answer that solved your problem? Please mark it as an Accepted Solution so others with the same problem can find the answer easily. X

Create A Thing Shape

No ratings

 

 

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.

 

CreateThingShape.png

 

You'll learn how to

 

  • Create a Thing Shape
  • Add 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.

 

  1. Start on the Browse folder icon of ThingWorx Composer.
  2. Under the Modeling section of the left-hand navigation panel hover over Thing Shapes, then click the + button.
     

    new-thingshape.png

  3. Type ThermostatShape in the Name field.
     

    new-thermostat-shape.png

  4. If Project is not already set, click the + in the Project text box and select the PTCDefaultProject.
  5. Click Save.

 

 

Step 2: Add Properties to Thing Shape

 

  1. Click Properties and Alerts tab at the top of your Thing Shape.

    thermostat-thingshape-click-properties.png

     

  2. Click + Add.
  3. Enter the Property name in the Name field as shown in the table below.

    Name Base     Type           Persistent?       Logged?
    humidityNUMBER X
    messageIdSTRINGX 
    temperatureNUMBER X
  4. Select the appropriate Base Type from the drop-down menu.

    thermostat-thingshape-add-properties.png

     

  5. Check Persistent and/or Logged according to the table.

    NOTE: When Persistent is selected, the property value will be retained during a system restart. Properties that are not persisted will be reset to the default during a system restart. When Logged is selected, every property value change will be automatically logged to a specified Value Stream.

  6. Click Check +.

    TIP: When adding multiple properties at once, click Done and Add after each, once you've entered a Name, selected a Base Type and any other criteria. If adding a single property, click Done.

  7. Repeat steps 4 through 6 for each of the properties in the rows of the table.
  8. Click the done Check. You'll see that these Properties have been created for the ThermostatShape.

    thermostat-thingshape-saved.png

     

  9. Click Save.

 

 

Step 3: Next Steps

 

Congratulations! You've successfully completed the Create A Thing Shape, and learned how to:

  • Create a new Thing Shape
  • Add Properties to the Thing Shape

 

This is the last guide in the Azure MXChip Development Kit Learning Path.  If you wish to return to the Learning Path, click the link.

 

Learn More

 

The following resources continue your learning experience:

 Resource       Link
BuildData Model Introduction
ExperienceObject-Oriented UI Design Tips

 

Additional Resources

 

If you have questions, issues, or need additional information, refer to:


 Resource       Link

CommunityDeveloper Community Forum
SupportThing Shape Support Help Center
 

 

 

Version history
Last update:
‎Nov 17, 2022 05:29 PM
Updated by:
Labels (2)
Contributors