File tree Expand file tree Collapse file tree 4 files changed +38
-90
lines changed Expand file tree Collapse file tree 4 files changed +38
-90
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -75,8 +75,46 @@ COMPILER_ASSERT(DAPLINK_RAM_SHARED_START + DAPLINK_RAM_SHARED_SIZE == DAPLINK_RA
7575// Macro with the name of the main application header file.
7676#if defined(DAPLINK_BL )
7777#define DAPLINK_MAIN_HEADER "main_bootloader.h"
78+
79+ #include "virtual_fs.h"
80+
81+ COMPILER_ASSERT (DAPLINK_BUILD_KEY == DAPLINK_BUILD_KEY_BL );
82+
83+ // daplink_mode_file_name, daplink_url_name and
84+ // daplink_drive_name strings must be 11 characters
85+ // excluding the null terminated character
86+ static const char daplink_mode_file_name [11 ] = "START_IFACT" ;
87+
88+ __STATIC_FORCEINLINE bool daplink_is_bootloader ()
89+ {
90+ return true;
91+ }
92+
93+ __STATIC_FORCEINLINE bool daplink_is_interface ()
94+ {
95+ return false;
96+ }
97+
7898#elif defined(DAPLINK_IF )
7999#define DAPLINK_MAIN_HEADER "main_interface.h"
100+
101+ #ifdef DRAG_N_DROP_SUPPORT
102+ #include "virtual_fs.h"
103+ COMPILER_ASSERT (DAPLINK_BUILD_KEY == DAPLINK_BUILD_KEY_IF );
104+
105+ static const vfs_filename_t daplink_mode_file_name = "START_BLACT" ;
106+ #endif //DRAG_N_DROP_SUPPORT
107+
108+ __STATIC_FORCEINLINE bool daplink_is_bootloader ()
109+ {
110+ return false;
111+ }
112+
113+ __STATIC_FORCEINLINE bool daplink_is_interface ()
114+ {
115+ return true;
116+ }
117+
80118#else
81119#error "Neither DAPLINK_BL nor DAPLINK_IF are defined!"
82120#endif
@@ -87,9 +125,6 @@ typedef struct {
87125 uint32_t version ;
88126} daplink_info_t ;
89127
90- bool daplink_is_bootloader (void );
91- bool daplink_is_interface (void );
92-
93128#ifdef __cplusplus
94129}
95130#endif
Original file line number Diff line number Diff line change 3232extern "C" {
3333#endif
3434
35-
36- extern const vfs_filename_t daplink_mode_file_name ;
37-
3835/* Callable from anywhere */
3936
4037// Enable or disable the virtual filesystem
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments