Search in sources :

Example 1 with MIndustrialDigitalIn

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

the class MBrickletIndustrialDigitalIn4Impl 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++) {
        MIndustrialDigitalIn digitalIn = factory.createMIndustrialDigitalIn();
        digitalIn.setUid(getUid());
        String subId = "in" + String.valueOf(i);
        logger.debug("addSubDevice: {}", subId);
        digitalIn.setSubId(subId);
        digitalIn.init();
        digitalIn.setMbrick(this);
        getMsubdevices().add(digitalIn);
    }
}
Also used : ModelFactory(org.openhab.binding.tinkerforge.internal.model.ModelFactory) MIndustrialDigitalIn(org.openhab.binding.tinkerforge.internal.model.MIndustrialDigitalIn)

Aggregations

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