AP_HAL: replace HAVE_FILESYSTEM_SUPPORT with backend defines

This commit is contained in:
Peter Barker 2023-05-15 11:44:22 +10:00 committed by Peter Barker
parent 86db236647
commit ee8a762e1d
4 changed files with 2 additions and 8 deletions

View File

@ -144,10 +144,6 @@
#error "No CONFIG_HAL_BOARD_SUBTYPE set"
#endif
#ifndef HAL_OS_POSIX_IO
#define HAL_OS_POSIX_IO 0
#endif
#ifndef HAL_OS_SOCKETS
#define HAL_OS_SOCKETS 0
#endif

View File

@ -3,7 +3,6 @@
#define HAL_BOARD_NAME "Linux"
#define HAL_CPU_CLASS HAL_CPU_CLASS_1000
#define HAL_MEM_CLASS HAL_MEM_CLASS_1000
#define HAL_OS_POSIX_IO 1
#define HAL_OS_SOCKETS 1
#define HAL_STORAGE_SIZE 16384
#define HAL_STORAGE_SIZE_AVAILABLE HAL_STORAGE_SIZE

View File

@ -3,7 +3,6 @@
#define HAL_BOARD_NAME "SITL"
#define HAL_CPU_CLASS HAL_CPU_CLASS_1000
#define HAL_MEM_CLASS HAL_MEM_CLASS_1000
#define HAL_OS_POSIX_IO 1
#define HAL_OS_SOCKETS 1
#define AP_FLASHSTORAGE_TYPE 3

View File

@ -4,7 +4,7 @@
#include <AP_HAL/AP_HAL.h>
#if HAL_OS_POSIX_IO
#if AP_FILESYSTEM_POSIX_ENABLED
#include <stdio.h>
#endif
@ -61,7 +61,7 @@ void loop(void)
// also do a raw printf() on some platforms, which prints to the
// debug console
#if HAL_OS_POSIX_IO
#if AP_FILESYSTEM_POSIX_ENABLED
::printf("Hello on debug console at %.3f seconds\n", (double)(AP_HAL::millis() * 0.001f));
#endif