Search in sources :

Example 1 with MIndustrialQuadRelay

use of org.openhab.binding.tinkerforge.internal.model.MIndustrialQuadRelay in project openhab1-addons by openhab.

the class MIndustrialQuadRelayBrickletImpl method initSubDevices.

/**
     * <!-- begin-user-doc -->
     * <!-- end-user-doc -->
     * 
     * @generated NOT
     */
@Override
public void initSubDevices() {
    ModelFactory factory = ModelFactory.eINSTANCE;
    for (int i = 0; i < 4; i++) {
        MIndustrialQuadRelay relay = factory.createMIndustrialQuadRelay();
        relay.setUid(uid);
        String subId = "relay" + String.valueOf(i);
        logger.debug("addSubDevice " + subId);
        relay.setSubId(subId);
        relay.init();
        relay.setMbrick(this);
        getMsubdevices().add(relay);
    }
}
Also used : MIndustrialQuadRelay(org.openhab.binding.tinkerforge.internal.model.MIndustrialQuadRelay) ModelFactory(org.openhab.binding.tinkerforge.internal.model.ModelFactory)

Aggregations

MIndustrialQuadRelay (org.openhab.binding.tinkerforge.internal.model.MIndustrialQuadRelay)1 ModelFactory (org.openhab.binding.tinkerforge.internal.model.ModelFactory)1