Compare commits

...

3 Commits

Author SHA1 Message Date
Brendan Le Foll
c65a1de3ba mraa: update to version 0.6.0
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-02-11 10:40:16 +00:00
Thomas Ingleby
6135628b1c src/mraa.c: mux mapped
Don't own gpio of muxes, so it isnt unexported.

Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-02-10 17:38:13 +00:00
Brendan Le Foll
7ee0227489 Revert "setup_mux_mapped: use HIGH/LOW instead"
This reverts commit 6c73a8adce as it breaks
galileo gen1 muxing.

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-02-10 17:38:08 +00:00
3 changed files with 15 additions and 11 deletions

View File

@@ -18,7 +18,7 @@ include (GetGitRevisionDescription)
git_describe (VERSION "--tags")
if ("x_${VERSION}" STREQUAL "x_GIT-NOTFOUND")
message (WARNING " - Install git to compile a production libmraa!")
set (VERSION "v0.5.4-dirty")
set (VERSION "v0.6.0-dirty")
endif ()
message (INFO " - libmraa Version ${VERSION}")

View File

@@ -66,6 +66,13 @@ This changelog is meant as a quick & rough guide to what has changed between
versions. The API is now fairly stable but when new calls/features are added
they are listed here. Anything pre 0.2.x is ignored.
**0.6.0**
* add device path queries for uart
* add platform configuration querying
* gpio sample added
* improve i2c/spi write/read API for python & nodejs
* performance improvements on edison & galileo
**0.5.4**
* pwm read_* fix introduced in 0.5.3
* improved npmpkg support

View File

@@ -154,17 +154,14 @@ mraa_setup_mux_mapped(mraa_pin_t meta)
if (mux_i == NULL) {
return MRAA_ERROR_INVALID_HANDLE;
}
// this function will sometimes fail, however this is not critical as
// long as the write succeeds - Test case galileo gen2 pin2
mraa_gpio_dir(mux_i, MRAA_GPIO_OUT);
mraa_gpio_owner(mux_i, 0);
if (meta.mux[mi].value) {
if (mraa_gpio_dir(mux_i, MRAA_GPIO_OUT_HIGH) != MRAA_SUCCESS) {
mraa_gpio_close(mux_i);
return MRAA_ERROR_INVALID_RESOURCE;
}
} else {
if (mraa_gpio_dir(mux_i, MRAA_GPIO_OUT_LOW) != MRAA_SUCCESS) {
mraa_gpio_close(mux_i);
return MRAA_ERROR_INVALID_RESOURCE;
}
if (mraa_gpio_write(mux_i, meta.mux[mi].value) != MRAA_SUCCESS) {
mraa_gpio_close(mux_i);
return MRAA_ERROR_INVALID_RESOURCE;
}
mraa_gpio_close(mux_i);
}