Search in sources :

Example 1 with SYS_VERSION_RESPONSE

use of com.zsmartsystems.zigbee.dongle.cc2531.network.packet.system.SYS_VERSION_RESPONSE in project com.zsmartsystems.zigbee by zsmartsystems.

the class ZigBeeNetworkManager method getStackVersion.

private String getStackVersion() {
    if (!waitForHardware()) {
        logger.info("Failed to reach the {} level: getStackVerion() failed", DriverStatus.NETWORK_READY);
        return null;
    }
    SYS_VERSION_RESPONSE response = (SYS_VERSION_RESPONSE) sendSynchronous(new SYS_VERSION());
    if (response == null) {
        return null;
    } else {
        StringBuilder builder = new StringBuilder();
        builder.append("Software=");
        builder.append(response.MajorRel);
        builder.append(".");
        builder.append(response.MinorRel);
        builder.append(" Product=");
        builder.append(response.Product);
        builder.append(" Hardware=");
        builder.append(response.HwRev);
        builder.append(" Transport=");
        builder.append(response.TransportRev);
        return builder.toString();
    }
}
Also used : SYS_VERSION_RESPONSE(com.zsmartsystems.zigbee.dongle.cc2531.network.packet.system.SYS_VERSION_RESPONSE) SYS_VERSION(com.zsmartsystems.zigbee.dongle.cc2531.network.packet.system.SYS_VERSION)

Aggregations

SYS_VERSION (com.zsmartsystems.zigbee.dongle.cc2531.network.packet.system.SYS_VERSION)1 SYS_VERSION_RESPONSE (com.zsmartsystems.zigbee.dongle.cc2531.network.packet.system.SYS_VERSION_RESPONSE)1