Thingworx基础操作步骤(2)

2018-12-11 23:11

2. Task 2. Add a property for the vending machine humidity.

1. Click Properties in the ThingWorx Explorer. 2. Click the Add My Property button. 3. Type CurrentHumidity in the Name field.

4. Type Vending Machine Current Humidity in the Description field. 5. Click the Base Type list to expand it. 6. Select NUMBER. 7. Type % in the Units field.

8. Verify that Persistent is not selected and then click Done and Add to add the property to the VendingMachineShape.

3. Task 3. Add a property for the humidity set point.

1. Type VMHumiditySetpoint in the Name field.

2. Type Vending Machine Humidity Setpoint in the Description field. 3. Click the Base Type list to expand it. 4. Select NUMBER. 5. Type % in the Units field. 6. Select the Persistent check box.

7. Click Done and Add to add the property to the VendingMachineShape.

4. Task 4. Add a property for the current temperature.

1. Type CurrentTemperature in the Name field.

2. Type Vending Machine Temperature in the Description field. 3. Click the Base Type list to expand it. 4. Select NUMBER. 5. Type F in the Units field.

6. Verify that the Persistent check box is not selected and then click Done and Add to add the property to the VendingMachineShape.

5. Task 5. Add a property for the temperature set point.

1. Type VMTemperatureSetpoint in the Name field.

2. Type Vending Machine Temperature Setpoint in the Description field. 3. Click the Base Type list to expand it. 4. Select NUMBER. 5. Type F in the Units field. 6. Select the Persistent check box.

7. Click Done and Add to add the property to the VendingMachineShape.

6. Task 6. Add a property for the field service technician.

1. Type FieldServiceTech in the Name field.

2. Type Vending Machine Field Service Technician in the Description field. 3. Click the Base Type list to expand it.

4. Click under the scroll bar to scroll down to USERNAME in the drop-down list. 5. Select USERNAME.

6. Select the Persistent check box.

7. Click Done and Add to add the property to the VendingMachineShape.

7. Task 7. Add a property for the vending machine location.

1. Type Location in the Name field.

2. Type Vending Machine Location in the Description field. 3. Click the Base Type list to expand it. 4. Select LOCATION.

5. Select the Persistent check box.

6. Click Done to add the property to the VendingMachineShape. 7. Click the Save button.

8. Task 8. View the thing shape using the REST API.

1. Navigate to http://localhost/Thingworx/ThingShapes/ in Chrome. 2. Click under the scroll bar to scroll down to VendingMachineShape. 3. Click the VendingMachineShape link. 4. Click the Instance Property Definitions link.

2.9、Creating a Thing Template

1. Task 1. Create the VendingMachineTemplate thing template.

1. Click the Thing Templates link in the ThingWorx Explorer. 2. Click the New button.

3. Type VendingMachineTemplate in the Name field. 4. Type Vending Machine Template in the Description field. 5. Type A in the Tags field.

6. Select Applications: ThingWorxTraining. 7. Type G in the Base Thing Template field. 8. Select GenericThing.

9. Type V in the Implemented Shapes field. 10. Select VendingMachineShape. 11. Type V in the Implemented Shapes field. 12. Select VendingMachineSupportShape. 13. Click the Save button.

2. Task 2. Explore the properties, services, events, and subscriptions.

1. Click Properties in the ThingWorx Explorer.

2. Click under the scroll bar to scroll down and view both properties inherited from the VendingMachineSupportShape and the

VendingMachineShape. 3. Click the Services link. 4. Click the Events link. 5. Click the Expand

icon to expand Generic Events under the Base ThingTemplate events.

6. Click the Subscriptions link.

3. Task 3. View the ThingShape using the REST API.

1. Navigate to http://localhost/Thingworx/ThingTemplates/ in Chrome. 2. Click the VendingMachineTemplate link.

2.10、Creating a Thing

Task 1. Create a vending machine thing.

1. Type +T in the spotlight search field. 2. Select +Thing.

3. Type VM-TR1 in the Name field. 4. Type VM-TR1 in the Description field. 5. Type A in the Tags field.

6. Select Applications: ThingWorxTraining. 7. Type V in the Tags field.

8. Select EquipmentTypes: Vending Machine. 9. Type V in the Thing Template field. 10. Select VendingMachineTemplate.

11. Verify that the Active check box is selected and click the Save button.

2.11、Duplicating a Thing

1. Task 1. Duplicate a Thing.

1. Click the Things link in the ThingWorx Explorer.

2. Select the check box in the VM-TR1 row of the Things table. 3. Click the Duplicate button. 4. Type VM-TR2 in the Name field.

5. Type VM-TR2 in the Description field, overwriting the current contents. 6. Verify that the Active check box is selected and click the Save button.

2. Task 2. Duplicate another Thing.

1. Select the Explorer

tab.

2. Select the check box in the VM-TR1 row of the Things table. 3. Click the Duplicate button. 4. Type VM-TR3 in the Name field.

5. Type VM-TR3 in the Description field, overwriting the current contents. 6. Verify that the Active check box is selected and click the Save button.

2.12、REST API Method and Headers

2.13、Creating a Responsive Mashup to View and Edit Thing Properties

1. Task 1. Create a responsive mashup.

1. Type +M in the spotlight search field. 2. Select +Mashup. 3. Click the Done button.

2. Task 2. Divide the layout area.

1. Type La in the Filter Widgets field of the Widgets panel. 2. Select Layout.

3. Drag the Layout widget from the upper-left panel to the upper-center panel. 4. Select the Left Sidebar check box. 5. Click the Done button. 6. Select the Workspace tab.

7. Verify that the Layout is selected in the Workspace panel. Then, click the Spacing drop-down list for the layout. 8. Select none.

9. Type 150 in the LeftSidebarWidth property field and press TAB. 10. Type 40 in the PctColumn1 property field and press TAB. 11. Select the Widgets tab.

12. Verify that La is still populated in the filter field of the Widgets panel and drag Layout to the sidebar. 13. Select Vertical.

14. Validate that two rows, no header, and no footer are selected and click Done. 15. Select the Workspace tab.

16. Verify that the Layout within the left sidebar is selected in the Workspace panel. Then, click the Copy

panel.

17. Click the center column in the upper-middle panel or Column 1 in the Workspace panel to select it. 18. Click the Paste

icon.

icon in the upper-middle

19. Click the right-most column in the upper-middle panel or Column 2 in the Workspace panel to select it. 20. Click the Paste

icon.

Enlarge Image

3. Task 3. Add a list of the vending machines to the upper-left corner of the layout.

1. Select the Widgets tab.

2. Type Li in the filter field of the Widgets panel. 3. Select the List widget.

4. Drag the List widget to the upper-left corner of the layout.

5. Verify that the Data tab is selected in the upper-right panel and click the Add entity 6. Click the Select Entity drop-down list to expand it. 7. Select Thing Templates.

8. Type V in the Search ThingTemplates field. 9. Select VendingMachineTemplate. 10. Type geti in the Select Services filter. 11. Click the Add

icon for the GetImplementingThings method.

icon.

12. Select the Mashup Loaded? check box. 13. Click the Done button.

14. Select the GetImplementingThings service. 15. Click the Expand 16. Click the Expand

icon next to All Data in the Data panel. icon next to Parameters in the Data panel.

17. Select the All Data row of the Data panel. 18. Drag the All Data row to the list. 19. Select Data. 20. Select the To-Do tab.


Thingworx基础操作步骤(2).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:有机实验思考题及参考答案

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: