use of com.zsmartsystems.zigbee.IeeeAddress in project com.zsmartsystems.zigbee by zsmartsystems.
the class TelegesisEndDeviceAnnounceEventTest method testExtended.
@Test
public void testExtended() {
TelegesisEndDeviceAnnounceEvent event = new TelegesisEndDeviceAnnounceEvent();
event.deserialize(stringToIntArray("ZED:1234567890ABCDEF,9876,44,AA"));
System.out.println(event);
assertEquals(new IeeeAddress("1234567890ABCDEF"), event.getIeeeAddress());
assertEquals(Integer.valueOf(0x9876), event.getNetworkAddress());
assertEquals(Integer.valueOf(68), event.getRssi());
assertEquals(Integer.valueOf(0xAA), event.getLqi());
}
use of com.zsmartsystems.zigbee.IeeeAddress in project com.zsmartsystems.zigbee by zsmartsystems.
the class TelegesisEndDeviceAnnounceEventTest method testBasic.
@Test
public void testBasic() {
TelegesisEndDeviceAnnounceEvent event = new TelegesisEndDeviceAnnounceEvent();
event.deserialize(stringToIntArray("ZED:1234567890ABCDEF,9876"));
System.out.println(event);
assertEquals(new IeeeAddress("1234567890ABCDEF"), event.getIeeeAddress());
assertEquals(Integer.valueOf(0x9876), event.getNetworkAddress());
assertNull(event.getRssi());
assertNull(event.getLqi());
}
use of com.zsmartsystems.zigbee.IeeeAddress in project com.zsmartsystems.zigbee by zsmartsystems.
the class TelegesisMobileDeviceAnnounceEventTest method testBasic.
@Test
public void testBasic() {
TelegesisMobileDeviceAnnounceEvent event = new TelegesisMobileDeviceAnnounceEvent();
event.deserialize(stringToIntArray("MED:1234567890ABCDEF,9876"));
System.out.println(event);
assertEquals(new IeeeAddress("1234567890ABCDEF"), event.getIeeeAddress());
assertEquals(Integer.valueOf(0x9876), event.getNetworkAddress());
assertNull(event.getRssi());
assertNull(event.getLqi());
}
use of com.zsmartsystems.zigbee.IeeeAddress in project com.zsmartsystems.zigbee by zsmartsystems.
the class TelegesisReceiveMulticastEventTest method testRemoteAddress.
@Test
public void testRemoteAddress() {
TelegesisReceiveMulticastEvent event = new TelegesisReceiveMulticastEvent();
event.deserialize(stringToIntArray("MCAST:000D6F000005A666,04=test"));
System.out.println(event);
assertEquals(new IeeeAddress("000D6F000005A666"), event.getRemoteAddress());
assertTrue(Arrays.equals(stringToIntArray("test"), event.getMessageData()));
}
use of com.zsmartsystems.zigbee.IeeeAddress in project com.zsmartsystems.zigbee by zsmartsystems.
the class TelegesisReceiveUnicastEventTest method testRemoteAddressRssiLqi.
@Test
public void testRemoteAddressRssiLqi() {
TelegesisReceiveUnicastEvent event = new TelegesisReceiveUnicastEvent();
event.deserialize(stringToIntArray("UCAST:000D6F000005A666,04=test,A0,45"));
System.out.println(event);
assertEquals(new IeeeAddress("000D6F000005A666"), event.getRemoteAddress());
assertTrue(Arrays.equals(stringToIntArray("test"), event.getMessageData()));
assertEquals(Integer.valueOf(160), event.getRssi());
assertEquals(Integer.valueOf(69), event.getLqi());
}
Aggregations