StorageManager: add storage aread for CAN Dynamic Node Alloc

This commit is contained in:
Siddharth Purohit 2019-09-19 11:02:18 +08:00 committed by Andrew Tridgell
parent 53cea84bf8
commit 1197ab9479
2 changed files with 7 additions and 4 deletions

View File

@ -65,7 +65,8 @@ const StorageManager::StorageArea StorageManager::layout_default[STORAGE_NUM_ARE
{ StorageParam, 8192, 1280}, { StorageParam, 8192, 1280},
{ StorageRally, 9472, 300}, { StorageRally, 9472, 300},
{ StorageFence, 9772, 256}, { StorageFence, 9772, 256},
{ StorageMission, 10028, 6228}, // leave 128 byte gap for expansion { StorageMission, 10028, 5204}, // leave 128 byte gap for expansion
{ StorageCANDNA, 15232, 1024},
#endif #endif
}; };
@ -95,7 +96,8 @@ const StorageManager::StorageArea StorageManager::layout_copter[STORAGE_NUM_AREA
{ StorageParam, 8192, 1280}, { StorageParam, 8192, 1280},
{ StorageRally, 9472, 300}, { StorageRally, 9472, 300},
{ StorageFence, 9772, 256}, { StorageFence, 9772, 256},
{ StorageMission, 10028, 6228}, // leave 128 byte gap for expansion { StorageMission, 10028, 5204}, // leave 128 byte gap for expansion
{ StorageCANDNA, 15232, 1024},
#endif #endif
}; };
#endif // STORAGE_NUM_AREAS == 1 #endif // STORAGE_NUM_AREAS == 1

View File

@ -27,7 +27,7 @@
storage. Use larger areas for other boards storage. Use larger areas for other boards
*/ */
#if HAL_STORAGE_SIZE >= 16384 #if HAL_STORAGE_SIZE >= 16384
#define STORAGE_NUM_AREAS 14 #define STORAGE_NUM_AREAS 15
#elif HAL_STORAGE_SIZE >= 15360 #elif HAL_STORAGE_SIZE >= 15360
#define STORAGE_NUM_AREAS 11 #define STORAGE_NUM_AREAS 11
#elif HAL_STORAGE_SIZE >= 8192 #elif HAL_STORAGE_SIZE >= 8192
@ -52,7 +52,8 @@ public:
StorageRally = 2, StorageRally = 2,
StorageMission = 3, StorageMission = 3,
StorageKeys = 4, StorageKeys = 4,
StorageBindInfo= 5 StorageBindInfo= 5,
StorageCANDNA = 6
}; };
// erase whole of storage // erase whole of storage