AP_HAL: mapped the different sizes of storage for all VR boards

This commit is contained in:
LukeMike 2014-11-14 15:09:16 +01:00 committed by Andrew Tridgell
parent 6a93148b92
commit edd0f13845
2 changed files with 13 additions and 3 deletions

View File

@ -231,15 +231,25 @@
#define HAL_BOARD_NAME "VRBRAIN"
#define HAL_CPU_CLASS HAL_CPU_CLASS_150
#define HAL_OS_POSIX_IO 1
#define HAL_STORAGE_SIZE 8192
#define HAL_STORAGE_SIZE_AVAILABLE HAL_STORAGE_SIZE
#define HAL_BOARD_LOG_DIRECTORY "/fs/microsd/APM/LOGS"
#define HAL_BOARD_TERRAIN_DIRECTORY "/fs/microsd/APM/TERRAIN"
#define HAL_INS_DEFAULT HAL_INS_VRBRAIN
#define HAL_BARO_DEFAULT HAL_BARO_VRBRAIN
#define HAL_COMPASS_DEFAULT HAL_COMPASS_VRBRAIN
#define HAL_SERIAL0_BAUD_DEFAULT 115200
#if defined(CONFIG_ARCH_BOARD_VRBRAIN_V45)
#define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_VRBRAIN_V45
#define HAL_STORAGE_SIZE 8192
#elif defined(CONFIG_ARCH_BOARD_VRBRAIN_V51)
#define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_VRBRAIN_V51
#define HAL_STORAGE_SIZE 16384
#elif defined(CONFIG_ARCH_BOARD_VRUBRAIN_V51)
#define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_VRUBRAIN_V51
#define HAL_STORAGE_SIZE 8192
#else
#define CONFIG_HAL_BOARD_SUBTYPE HAL_BOARD_SUBTYPE_NONE
#define HAL_STORAGE_SIZE 8192
#endif
#else
#error "Unknown CONFIG_HAL_BOARD type"

View File

@ -7,7 +7,7 @@
#include "AP_HAL_VRBRAIN_Namespace.h"
#include <systemlib/perf_counter.h>
#define VRBRAIN_STORAGE_SIZE 4096
#define VRBRAIN_STORAGE_SIZE HAL_STORAGE_SIZE
#define VRBRAIN_STORAGE_MAX_WRITE 512
#define VRBRAIN_STORAGE_LINE_SHIFT 9
#define VRBRAIN_STORAGE_LINE_SIZE (1<<VRBRAIN_STORAGE_LINE_SHIFT)