[stm32][ms2100] the reset/set gpio state for the ms2100 reset functionality was inverted, hopefully fixes Issue #384

This commit is contained in:
Stephen Dwyer
2013-03-29 16:17:01 -06:00
parent b5983c3c8f
commit c50058d6a2
@@ -31,12 +31,20 @@
#include <libopencm3/stm32/f1/gpio.h>
#include "mcu_periph/spi.h"
/**
* Here Reset indicates the Ms2100 is in normal state, i.e.
* the reset line is driven low (i.e. the GPIO is "reset")
*/
static inline void Ms2100Reset(void) {
GPIOC_BSRR = GPIO13;
GPIOC_BRR = GPIO13;
}
/**
* Here Set indicates the Ms2100 is in reset state, i.e.
* the reset line is driven high (i.e. the GPIO is "set")
*/
static inline void Ms2100Set(void) {
GPIOC_BRR = GPIO13;
GPIOC_BSRR = GPIO13;
}
#define Ms2100HasEOC() (gpio_get(GPIOB, GPIO5) != 0)