Browse Source

DataFlash: fix for HAL_GPIO_*

mission-4.1.18
Andrew Tridgell 11 years ago
parent
commit
1e2214f8d1
  1. 2
      libraries/DataFlash/DataFlash_APM1.cpp
  2. 4
      libraries/DataFlash/DataFlash_APM2.cpp

2
libraries/DataFlash/DataFlash_APM1.cpp

@ -93,7 +93,7 @@ void DataFlash_APM1::Init(const struct LogStructure *structure, uint8_t num_type @@ -93,7 +93,7 @@ void DataFlash_APM1::Init(const struct LogStructure *structure, uint8_t num_type
// init to zero
df_NumPages = 0;
hal.gpio->pinMode(DF_RESET,GPIO_OUTPUT);
hal.gpio->pinMode(DF_RESET,HAL_GPIO_OUTPUT);
// Reset the chip
hal.gpio->write(DF_RESET,0);
hal.scheduler->delay(1);

4
libraries/DataFlash/DataFlash_APM2.cpp

@ -93,8 +93,8 @@ void DataFlash_APM2::Init(const struct LogStructure *structure, uint8_t num_type @@ -93,8 +93,8 @@ void DataFlash_APM2::Init(const struct LogStructure *structure, uint8_t num_type
// init to zero
df_NumPages = 0;
hal.gpio->pinMode(DF_RESET, GPIO_OUTPUT);
hal.gpio->pinMode(DF_CARDDETECT, GPIO_INPUT);
hal.gpio->pinMode(DF_RESET, HAL_GPIO_OUTPUT);
hal.gpio->pinMode(DF_CARDDETECT, HAL_GPIO_INPUT);
// Reset the chip
hal.gpio->write(DF_RESET,0);

Loading…
Cancel
Save