gpio: function replacement for gpio write calls
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com> Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
This commit is contained in:
committed by
Brendan Le Foll
parent
efc79d13c0
commit
1c7bd53bf3
@@ -584,6 +584,10 @@ mraa_gpio_write(mraa_gpio_context dev, int value)
|
||||
return pre_ret;
|
||||
}
|
||||
|
||||
if (IS_FUNC_DEFINED(dev, gpio_write_replace)) {
|
||||
return dev->advance_func->gpio_write_replace(dev, value);
|
||||
}
|
||||
|
||||
if (dev->value_fp == -1) {
|
||||
if (mraa_gpio_get_valfp(dev) != MRAA_SUCCESS) {
|
||||
return MRAA_ERROR_INVALID_RESOURCE;
|
||||
|
||||
Reference in New Issue
Block a user