Altova MobileTogether Designer

You can simulate what happens when an MQTT message is received. Press F5 to start the simulator (screenshot below).

MTDSimulatorOnMsgsReceivedMQTT

To simulate messages received, we use an XML sample file that is located by default in your MobileTogether Designer application folder. See the Options dialog (Simulation 2 tab) for the file path to this file. This file contains XML data that simulates messages received. So you can use it to test the action tree that will be executed when a message is received.

 

Note:If the XML sample file is in a write-protected folder (which is often the case with Windows application folders), you might need to open MobileTogether Designer with administrator privileges. This would enable you to save changes to the sample data (about which see below). To start MobileTogether Designer as an administrator, right-click its shortcut in Windows and select the command to start it as an administrator.

 

Start the MobileTogether Designer simulator by pressing F5. In the simulator, use the Simulate Reception of Message toolbar button (circled green in the screenshot above) to open the Messages dialog.

 

In the dialog that appears, you can do the following:

 

In the Messages dialog (screenshot below), the data displayed in the dialog's table is the data in the XML sample file. Each row represents one received message. The Content column contains the text of the message.

MTDSimulateMQTTBroadcastMsgRcd

To simulate the reception of a message in the solution, select a message row and click Send and Close. The action tree of the solution will be executed with the data of the selected message and you can check whether actions were executed as you wanted. In the Messages dialog (screenshot above), you can edit the descriptions of messages and also delete a selected message. If you click Save after making changes, then the changes will be saved back to the XML sample file.

 

The messages from the sample XML file are also available in the dropdown list of the Simulate Reception of Message toolbar button. Select a message in the dropdown list to simulate its receipt. Additionally, you can record a new message by first toggling on Record a message in the dropdown list of commands and then simulating the sending and receipt of a message. Whatever messages are sent while the recording is toggled on will be displayed in the Messages table (screenshot above). You can modify the descriptions as required and save the messages back to the XML sample file.

© 2018-2024 Altova GmbH