//Create a class for three axis package ThreeAxis import SmartThing.SmartThings public class ThreeAxises extends SmartThings { List threeAxises = new ArrayList() ThreeAxises(Closure sendEvent, boolean init) { // Only initialize one time since we only have one device for each capability threeAxises = smartThings // Initialization String id = "threeAxisID0" String label = "threeAxis" String displayName = "threeAxis" LinkedHashMap threeAxis if (init) threeAxis = [x:0, y:0, z:0] else threeAxis = [x:1, y:2, z:3] threeAxises.add(new ThreeAxis(sendEvent, id, label, displayName, threeAxis)) } // Methods to return values def getCurrentThreeAxis() { List tmpValues = new ArrayList() tmpValues.add(threeAxises[0].getCurrentThreeAxis()) return tmpValues } }