[beken-72xx] Update base core to new structure

This commit is contained in:
Kuba Szczodrzyński
2023-03-04 11:09:27 +01:00
parent c579219427
commit bc328657aa
58 changed files with 510 additions and 392 deletions

View File

@@ -2,6 +2,10 @@
#pragma once
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
inline void printf_nop(const char *fmt, ...) {}
#define FAL_PRINTF printf_nop
@@ -10,6 +14,10 @@ inline void printf_nop(const char *fmt, ...) {}
// Flash device configuration
extern const struct fal_flash_dev flash0;
#ifdef __cplusplus
} // extern "C"
#endif
#define FAL_FLASH_DEV_NAME "flash0"
#define FAL_FLASH_DEV_TABLE \
@@ -33,6 +41,6 @@ extern const struct fal_flash_dev flash0;
#include <fal_def.h>
/**
* @brief Root partition table, representing the entire flash.
* @brief "Root" partition entry, representing the entire flash.
*/
extern fal_partition_t fal_root_part;

View File

@@ -36,9 +36,8 @@
/* MCU Endian Configuration, default is Little Endian Order. */
// #define FDB_BIG_ENDIAN
#include <printf_config.h>
#if LT_DEBUG_FDB
#include <libretuya.h>
#include <printf/printf.h>
#define FDB_PRINT(...) __wrap_printf(__VA_ARGS__)
#define FDB_DEBUG_ENABLE

View File

@@ -2,7 +2,11 @@
#pragma once
#include <LibreTuyaConfig.h>
#include <lt_config.h>
#ifdef __cplusplus
extern "C" {
#endif // __cplusplus
#define PRINTF_HAS_DISABLE 1
@@ -127,3 +131,7 @@ void putchar_p(char c, unsigned long port);
int __wrap_##name(char *s, size_t count, const char *format, va_list arg) { \
return vsnprintf(s, count, format, arg); \
}
#ifdef __cplusplus
} // extern "C"
#endif