magic: prepare for FAT32 use
This commit is contained in:
parent
5a6d3a449f
commit
d9b0615ad5
@ -44,7 +44,8 @@ _appenddigitstrdef %1, (%2 >> (0 * 4)) & 0Fh
|
||||
%endif
|
||||
%endmacro
|
||||
|
||||
%macro magicoffset 3.nolist
|
||||
%macro magicoffset 2-3.nolist
|
||||
%if ISFAT1216DUAL
|
||||
%ifdef ISFAT12
|
||||
%define SYSOFFSET %2
|
||||
%elifdef ISFAT16
|
||||
@ -55,11 +56,21 @@ _appenddigitstrdef %1, (%2 >> (0 * 4)) & 0Fh
|
||||
; will be shown when assembling without either
|
||||
; of the ISFATx defines.
|
||||
%endif
|
||||
%else
|
||||
%define SYSOFFSET %2
|
||||
%ifnempty %3
|
||||
%error Not in dual mode
|
||||
%endif
|
||||
%endif
|
||||
%assign NEWOFFSET $ - Entry
|
||||
%if NEWOFFSET != SYSOFFSET
|
||||
_autohexitsstrdef NEWOFFSETHEX, NEWOFFSET
|
||||
%strcat _NEWOFFSETHEX _NEWOFFSETHEX,'h'
|
||||
%deftok NEWOFFSET _NEWOFFSETHEX
|
||||
%if ISFAT1216DUAL
|
||||
%error Magic offset %1 changed for FATFS, old=SYSOFFSET, new=NEWOFFSET
|
||||
%else
|
||||
%error Magic offset %1 changed, old=SYSOFFSET, new=NEWOFFSET
|
||||
%endif
|
||||
%endif
|
||||
%endmacro
|
||||
|
Loading…
Reference in New Issue
Block a user