mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 06:39:11 +00:00
52_I2C_MCP23017: bugfix - some attributes are forgotten if iodev not present
git-svn-id: https://svn.fhem.de/fhem/trunk@26423 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
f4136d692a
commit
fda6cfd17a
@ -130,7 +130,7 @@ sub I2C_MCP23017_Init($$) { #Geraet beim anlegen/booten
|
|||||||
data => $regval,
|
data => $regval,
|
||||||
}) if (defined $hash->{I2C_Address});
|
}) if (defined $hash->{I2C_Address});
|
||||||
} else {
|
} else {
|
||||||
return "no IODev assigned to '$hash->{NAME}'";
|
Log3 $hash, 3, "no IODev assigned to '$hash->{NAME}'";
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -226,7 +226,7 @@ sub I2C_MCP23017_Attr(@) {
|
|||||||
data => $regval,
|
data => $regval,
|
||||||
}) if (defined $hash->{I2C_Address});
|
}) if (defined $hash->{I2C_Address});
|
||||||
} else {
|
} else {
|
||||||
return "no IODev assigned to '$hash->{NAME}'";
|
Log3 $hash, 3, "no IODev assigned to '$hash->{NAME}'";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return ($msg) ? $msg : undef;
|
return ($msg) ? $msg : undef;
|
||||||
@ -296,7 +296,7 @@ sub I2C_MCP23017_SetRegPair { #set register pair for Por
|
|||||||
}) if (defined $hash->{I2C_Address});
|
}) if (defined $hash->{I2C_Address});
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
return "no IODev assigned to '$hash->{NAME}'";
|
Log3 $hash, 3, "no IODev assigned to '$hash->{NAME}'";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
###############################################################################
|
###############################################################################
|
||||||
|
Loading…
Reference in New Issue
Block a user