1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-15 20:35:33 +03:00

FLASH Full (re)configurability (#5720)

This commit is contained in:
jflyper 2018-04-20 04:55:17 +09:00 committed by Michael Keller
parent 6b632bf65e
commit f9f05ecad5
2 changed files with 8 additions and 0 deletions

View file

@ -3345,6 +3345,9 @@ const cliResourceValue_t resourceTable[] = {
#if defined(USE_USB_MSC)
{ OWNER_USB_MSC_PIN, PG_USB_CONFIG, offsetof(usbDev_t, mscButtonPin), 0 },
#endif
#ifdef USE_FLASH
{ OWNER_FLASH_CS, PG_FLASH_CONFIG, offsetof(flashConfig_t, csTag), 0 },
#endif
};
static ioTag_t *getIoTag(const cliResourceValue_t value, uint8_t index)

View file

@ -66,6 +66,7 @@
#include "pg/beeper.h"
#include "pg/beeper_dev.h"
#include "pg/dashboard.h"
#include "pg/flash.h"
#include "pg/max7456.h"
#include "pg/pg.h"
#include "pg/pg_ids.h"
@ -983,6 +984,10 @@ const clivalue_t valueTable[] = {
#ifdef USE_USB_MSC
{ "usb_msc_pin_pullup", VAR_UINT8 | MASTER_VALUE | MODE_LOOKUP, .config.lookup = { TABLE_OFF_ON }, PG_USB_CONFIG, offsetof(usbDev_t, mscButtonUsePullup) },
#endif
// PG_FLASH_CONFIG
#ifdef USE_FLASH
{ "flash_spi_bus", VAR_UINT8 | MASTER_VALUE, .config.minmax = { 0, SPIDEV_COUNT }, PG_FLASH_CONFIG, offsetof(flashConfig_t, spiDevice) },
#endif
};
const uint16_t valueTableEntryCount = ARRAYLEN(valueTable);