# Extended Reality Application Framework for a Digital-Twin-Based Smart Crane
## 2 Materials and Methods
### Measurement Setup  
To evaluate the performance of the XR application development framework, the responsiveness test with three communication middleware was conducted. The measurement setup (see Figure 7) consisted of a desktop hosting the simulation environment in Ubuntu and the XR environment in Windows, a Raspberry Pi 4 Model B 2 GB hosting GraphQL \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Class** & **Name** & **Format** & **Ref\_Type** & **Data Source** & **Description** \\ \hline \multirow{9}{*}{Design} & Hoist\_height\_max & float & constant & Unity & Hoist maximum height \\  & Hoist\_height\_min & float & constant & Unity & Hoist minimum height \\  & Hoist\_speed\_max & float & constant & Unity & Hoist maximum speed \\  & Hoist\_capacity & float & constant & Unity & Hoist maximum capacity \\  & Trolley\_range\_max & float & constant & Unity & Trolley maximum range \\  & Trolley\_range\_min & float & constant & Unity & Trolley minimum range \\  & Trolley\_speed\_max & float & constant & Unity & Trolley maximum speed \\  & Bridge\_range\_max & float & constant & Unity & Bridge maximum location \\  & Bridge\_range\_min & float & constant & Unity & Bridge minimum range \\  & Bridge\_speed\_max & float & constant & Unity & Bridge maximum speed \\  & Coefficient\_microspeed & float & constant & Unity & Microspeed scale factor \\  & Coefficient\_inching\_speed & float & constant & Unity & Predefined speed for inching \\  & Coefficient\_inching\_distance & float & constant & Unity & Predefined distance for inching \\ \hline \multirow{9}{*}{Status} & HoistPosition & float & variable & Middleware & The height of the hook block \\  & TrolleyPosition & float & variable & Middleware & The location of the trolley \\  & BridgePosition & float & variable & Middleware & The location of the bridge \\ \hline \multirow{9}{*}{Control} & Inching & Boolean & variable & Unity/Middleware & Inching button status \\  & MicroSpeed & Boolean & variable & Unity/Middleware & Microspeed button status \\  & SwayControl & Boolean & variable & Unity/Middleware & Swaycontrol button status \\  & RopeAngleFeatureBypass & Boolean & variable & Unity/Middleware & Rope angle button status \\  & SwayControl\_SlingLength\_mm & int & variable & Unity/Middleware & The slip length \\  & Hoist.Up & Boolean & variable & Unity & Whether hoist moves up \\  & Hoist.Down & Boolean & variable & Unity & Whether hoist moves down \\  & Hoist.Speed & float & variable & Unity & The speed of the hoist \\  & Trolley.Forward & Boolean & variable & Unity & Whether roulley moves forward \\  & Trolley.Backward & Boolean & variable & Unity & Whether roulley moves \\  & Trolley.Speed & float & variable & Unity & The speed of trolley \\  & Bridge.Forward & Boolean & variable & Unity & Whether bridge moves forward \\  & Bridge.Backward & Boolean & variable & Unity & Whether bridge moves \\  & Bridge.Speed & float & variable & Unity & The speed of bridge \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Definition of data in the XR environment: The research defined the data class, name, basic format, reference type, source, and description to keep consistency with the internal and external interface. The Format defined the data basic type, such as int, float, char, etc. The reference type was categorized as constant and variable. The data source represented the source of the data. The Description depicted the definition of the data. interface server, and MQTT mosquito broker, and a switch providing the local network. The desktop had an Intel i9-10900 KF processor and 64 GB RAM. Figure 8 depicts the data transmission processes based on three communication middleware. For the responsiveness test, the perception layer of the simulated model was deployed in Gazebo running in Ubuntu. We firstly control the simulated crane in Gazebo developed in the perception layer, then through the bridge between ROS and OPC UA, the OPC UA server was able to read data from the Gazebo.