Search in sources :

Example 1 with MDualRelay

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

the class MDualRelayBrickletImpl method initSubDevices.

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

Aggregations

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