This is an automated email from the ASF dual-hosted git repository.

aguettouche pushed a commit to branch pr385
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git

commit a9610e16bd11c2fa1323dee9077eb7cab4ee45b8
Author: Gregory Nutt <gn...@nuttx.org>
AuthorDate: Tue Feb 25 14:38:24 2020 -0600

    boards/z80/ez80/z20x:  Update CFLAGS and linker scripts.
    
    arch/z80/src/ez80/Toolchain.defs:  Update some CFLAGS to match CFLAGS from 
ZDS-II IDE.  Apparently, we must say that the CPU is an eZ80F91 event when 
compiler for eZ80F92.
    boards/z80/ez80/z20x:  Update linker scripts.
---
 arch/z80/src/ez80/Toolchain.defs                      | 13 ++++++++-----
 boards/z80/ez80/ez80f910200kitg/scripts/Make.defs     |  6 +++---
 boards/z80/ez80/ez80f910200zco/scripts/Make.defs      |  6 +++---
 boards/z80/ez80/makerlisp/scripts/Make.defs           |  6 +++---
 boards/z80/ez80/z20x/configs/nsh_flash/nsh.zdsproj    | 10 +++++-----
 boards/z80/ez80/z20x/configs/nsh_flash/nsh_flash.ztgt |  2 +-
 boards/z80/ez80/z20x/configs/nsh_flash/nsh_ram.ztgt   | 12 ++++++------
 boards/z80/ez80/z20x/configs/nsh_ram/README.txt       |  2 +-
 boards/z80/ez80/z20x/configs/nsh_ram/nsh.zdsproj      | 14 +++++++-------
 boards/z80/ez80/z20x/configs/nsh_ram/nsh_flash.ztgt   |  2 +-
 boards/z80/ez80/z20x/configs/nsh_ram/nsh_ram.ztgt     | 12 ++++++------
 boards/z80/ez80/z20x/configs/sdboot/.gitignore        |  8 ++++----
 boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj    | 14 +++++++-------
 boards/z80/ez80/z20x/configs/sdboot/sdboot_flash.ztgt |  2 +-
 boards/z80/ez80/z20x/configs/sdboot/sdboot_ram.ztgt   | 12 ++++++------
 boards/z80/ez80/z20x/scripts/Make.defs                |  6 +++---
 boards/z80/ez80/z20x/scripts/z20x_copytoram.linkcmd   |  3 ++-
 boards/z80/ez80/z20x/scripts/z20x_flash.linkcmd       |  3 +--
 boards/z80/ez80/z20x/scripts/z20x_ram.linkcmd         |  1 +
 19 files changed, 69 insertions(+), 65 deletions(-)

diff --git a/arch/z80/src/ez80/Toolchain.defs b/arch/z80/src/ez80/Toolchain.defs
index 3b64474..041c71f 100644
--- a/arch/z80/src/ez80/Toolchain.defs
+++ b/arch/z80/src/ez80/Toolchain.defs
@@ -111,8 +111,10 @@ ifeq ($(CONFIG_ARCH_CHIP_EZ80F91),y)
   ARCHCPUDEF = _EZ80F91
   ARCHFAMILY = _EZ80ACCLAIM!
 else ifeq ($(CONFIG_ARCH_CHIP_EZ80F92),y)
-  ARCHCPU = eZ80F92
-  ARCHCPUDEF = _EZ80F92
+  #ARCHCPU = eZ80F92
+  #ARCHCPUDEF = _EZ80F92
+  ARCHCPU = eZ80F91
+  ARCHCPUDEF = _EZ80F91
   ARCHFAMILY = _EZ80ACCLAIM!
 endif
 
@@ -122,14 +124,15 @@ ifeq ($(CONFIG_DEBUG_SYMBOLS),y)
   ARCHASMOPTIMIZATION = -debug -NOsdiopt
   ARCHOPTIMIZATION = -debug
 else
-  ARCHASMOPTIMIZATION = -nodebug -NOsdiopt
-  ARCHOPTIMIZATION = -nodebug
+  ARCHASMOPTIMIZATION = -nodebug -sdiopt
+  ARCHOPTIMIZATION = -NOdebug
 endif
 
 ifeq ($(CONFIG_DEBUG_NOOPT),y)
   ARCHOPTIMIZATION += -reduceopt
 #else
-#  ARCHOPTIMIZATION += -optsize
+#  ARCHOPTIMIZATION += -promote -NOreduceopt -optsize
+  ARCHOPTIMIZATION += -promote -NOreduceopt
 endif
 
 # Tool names/paths.
diff --git a/boards/z80/ez80/ez80f910200kitg/scripts/Make.defs 
b/boards/z80/ez80/ez80f910200kitg/scripts/Make.defs
index 5673ca8..ae25e7f 100644
--- a/boards/z80/ez80/ez80f910200kitg/scripts/Make.defs
+++ b/boards/z80/ez80/ez80f910200kitg/scripts/Make.defs
@@ -57,7 +57,7 @@ endif
 ARCHASMCPUFLAGS = -cpu:$(ARCHCPU) -NOigcase
 ARCHASMLIST = -list -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
 ARCHASMWARNINGS = -warn
-ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILYDEF)=1 
-define:__ASSEMBLY__
+ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILY)=1 
-define:__ASSEMBLY__
 AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) 
$(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)
 
 # Compiler definitions
@@ -67,11 +67,11 @@ ARCHCPUFLAGS = -chartype:S -promote -cpu:$(ARCHCPU) 
-NOgenprintf -NOmodsect \
 ARCHLIST = -keeplst -NOlist -NOlistinc -keepasm
 ARCHPICFLAGS =
 ARCHWARNINGS = -warn
-ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILYDEF)
+ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILY)
 ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
 CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHLIST) $(ARCHCPUFLAGS) 
$(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
 
-CPPDEFINES = -D$(ARCHFAMILYDEF) -D$(ARCHCPUDEF) -D__ASSEMBLY__
+CPPDEFINES = -D$(ARCHFAMILY) -D$(ARCHCPUDEF) -D__ASSEMBLY__
 CPPINCLUDES = -I$(TOPDIR)$(DELIM)include
 CPPFLAGS = $(CPPDEFINES) $(CPPINCLUDES)
 
diff --git a/boards/z80/ez80/ez80f910200zco/scripts/Make.defs 
b/boards/z80/ez80/ez80f910200zco/scripts/Make.defs
index f2f587b..b167135 100644
--- a/boards/z80/ez80/ez80f910200zco/scripts/Make.defs
+++ b/boards/z80/ez80/ez80f910200zco/scripts/Make.defs
@@ -57,7 +57,7 @@ endif
 ARCHASMCPUFLAGS = -cpu:$(ARCHCPU) -NOigcase
 ARCHASMLIST = -list -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
 ARCHASMWARNINGS = -warn
-ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILYDEF)=1 
-define:__ASSEMBLY__
+ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILY)=1 
-define:__ASSEMBLY__
 AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) 
$(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)
 
 # Compiler definitions
@@ -67,11 +67,11 @@ ARCHCPUFLAGS = -chartype:S -promote -cpu:$(ARCHCPU) 
-NOgenprintf -NOmodsect \
 ARCHLIST = -keeplst -NOlist -NOlistinc -keepasm
 ARCHPICFLAGS =
 ARCHWARNINGS = -warn
-ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILYDEF)
+ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILY)
 ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
 CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHLIST) $(ARCHCPUFLAGS) 
$(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
 
-CPPDEFINES = -D$(ARCHFAMILYDEF) -D$(ARCHCPUDEF) -D__ASSEMBLY__
+CPPDEFINES = -D$(ARCHFAMILY) -D$(ARCHCPUDEF) -D__ASSEMBLY__
 CPPINCLUDES = -I$(TOPDIR)$(DELIM)include
 CPPFLAGS = $(CPPDEFINES) $(CPPINCLUDES)
 
diff --git a/boards/z80/ez80/makerlisp/scripts/Make.defs 
b/boards/z80/ez80/makerlisp/scripts/Make.defs
index 4af5ba0..c722657 100644
--- a/boards/z80/ez80/makerlisp/scripts/Make.defs
+++ b/boards/z80/ez80/makerlisp/scripts/Make.defs
@@ -57,7 +57,7 @@ endif
 ARCHASMCPUFLAGS = -cpu:$(ARCHCPU) -NOigcase
 ARCHASMLIST = -list -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
 ARCHASMWARNINGS = -warn
-ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILYDEF)=1 
-define:__ASSEMBLY__
+ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILY)=1 
-define:__ASSEMBLY__
 AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) 
$(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)
 
 # Compiler definitions
@@ -67,11 +67,11 @@ ARCHCPUFLAGS = -chartype:S -promote -cpu:$(ARCHCPU) 
-NOgenprintf -NOmodsect \
 ARCHLIST = -keeplst -NOlist -NOlistinc -keepasm
 ARCHPICFLAGS =
 ARCHWARNINGS = -warn
-ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILYDEF)
+ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILY)
 ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
 CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHLIST) $(ARCHCPUFLAGS) 
$(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
 
-CPPDEFINES = -D$(ARCHFAMILYDEF) -D$(ARCHCPUDEF) -D__ASSEMBLY__
+CPPDEFINES = -D$(ARCHFAMILY) -D$(ARCHCPUDEF) -D__ASSEMBLY__
 CPPINCLUDES = -I$(TOPDIR)$(DELIM)include
 CPPFLAGS = $(CPPDEFINES) $(CPPINCLUDES)
 
diff --git a/boards/z80/ez80/z20x/configs/nsh_flash/nsh.zdsproj 
b/boards/z80/ez80/z20x/configs/nsh_flash/nsh.zdsproj
index 4e2585e..190c4f7 100644
--- a/boards/z80/ez80/z20x/configs/nsh_flash/nsh.zdsproj
+++ b/boards/z80/ez80/z20x/configs/nsh_flash/nsh.zdsproj
@@ -107,8 +107,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">Standard</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0FFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
@@ -196,7 +196,7 @@
 <option name="debug" type="boolean" change-action="assemble">true</option>
 <option name="debugcache" type="boolean" change-action="none">true</option>
 <option name="igcase" type="boolean" change-action="assemble">false</option>
-<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx</option>
+<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx\</option>
 </options>
 </tool>
 <tool name="Librarian">
@@ -227,8 +227,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">Standard</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0BFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
diff --git a/boards/z80/ez80/z20x/configs/nsh_flash/nsh_flash.ztgt 
b/boards/z80/ez80/z20x/configs/nsh_flash/nsh_flash.ztgt
index 03c2326..b691cd5 100644
--- a/boards/z80/ez80/z20x/configs/nsh_flash/nsh_flash.ztgt
+++ b/boards/z80/ez80/z20x/configs/nsh_flash/nsh_flash.ztgt
@@ -20,7 +20,7 @@
       <device />
       <externalAddress>200000</externalAddress>
       <externalAutoSelect>false</externalAutoSelect>
-      <externalRamLower>40000</externalRamLower>
+      <externalRamLower>040000</externalRamLower>
       <externalRamUpper>0BFFFF</externalRamUpper>
       <manufacturer />
       <units>1</units>
diff --git a/boards/z80/ez80/z20x/configs/nsh_flash/nsh_ram.ztgt 
b/boards/z80/ez80/z20x/configs/nsh_flash/nsh_ram.ztgt
index 6170e6d..8f78f6b 100644
--- a/boards/z80/ez80/z20x/configs/nsh_flash/nsh_ram.ztgt
+++ b/boards/z80/ez80/z20x/configs/nsh_flash/nsh_ram.ztgt
@@ -37,15 +37,15 @@
          </CS0>
          <CS1>
             <busMode>0</busMode>
-            <controlRegister>8</controlRegister>
-            <lower>8</lower>
-            <upper>F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS1>
          <CS2>
             <busMode>0</busMode>
-            <controlRegister>28</controlRegister>
-            <lower>20</lower>
-            <upper>9F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS2>
          <CS3>
             <busMode>0</busMode>
diff --git a/boards/z80/ez80/z20x/configs/nsh_ram/README.txt 
b/boards/z80/ez80/z20x/configs/nsh_ram/README.txt
index f6a6791..db71007 100644
--- a/boards/z80/ez80/z20x/configs/nsh_ram/README.txt
+++ b/boards/z80/ez80/z20x/configs/nsh_ram/README.txt
@@ -7,7 +7,7 @@ nsh.zfpproj is a simple project that will allow you to use the 
Smart Flash
   Programming.  NOTE:  As of this writing this project does not work, probably
   due to RAM configuration in the project.  Use ZDS-II instead as is described
   in the upper README.txt file
-nsh_flash.ztgt is the target file that accompanies the project files.  This
+nsh_ram.ztgt is the target file that accompanies the project files.  This
   one is identical to boards/scripts/z20x_ram.ztgt.
 nsh_ram.ztgt is the target file that accompanies the project files.  This
   one is identical to boards/scripts/z20x_flash.ztgt.
diff --git a/boards/z80/ez80/z20x/configs/nsh_ram/nsh.zdsproj 
b/boards/z80/ez80/z20x/configs/nsh_ram/nsh.zdsproj
index f737e27..8ca8230 100644
--- a/boards/z80/ez80/z20x/configs/nsh_ram/nsh.zdsproj
+++ b/boards/z80/ez80/z20x/configs/nsh_ram/nsh.zdsproj
@@ -1,4 +1,4 @@
-<project type="Executable" project-type="Standard" configuration="Release" 
created-by="d:5.3.0:17021001" modified-by="d:5.3.0:17021001" ZDSII="ZDSII - 
eZ80Acclaim! 5.3.0 (Build 17041303)">
+<project type="Executable" project-type="Standard" configuration="Release" 
created-by="d:5.3.0:17021001" modified-by="d:5.3.0:19052909" ZDSII="ZDSII - 
eZ80Acclaim! 5.3.3 (Build 19083001)">
 <cpu>eZ80F92</cpu>
 
 <!-- file information -->
@@ -107,8 +107,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">AllRam</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0FFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
@@ -196,7 +196,7 @@
 <option name="debug" type="boolean" change-action="assemble">true</option>
 <option name="debugcache" type="boolean" change-action="none">true</option>
 <option name="igcase" type="boolean" change-action="assemble">false</option>
-<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx</option>
+<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx\</option>
 </options>
 </tool>
 <tool name="Librarian">
@@ -227,8 +227,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">AllRam</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0BFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
@@ -258,4 +258,4 @@
 <breakpoints>
 </breakpoints>
 
-</project>
+</project>
\ No newline at end of file
diff --git a/boards/z80/ez80/z20x/configs/nsh_ram/nsh_flash.ztgt 
b/boards/z80/ez80/z20x/configs/nsh_ram/nsh_flash.ztgt
index 03c2326..b691cd5 100644
--- a/boards/z80/ez80/z20x/configs/nsh_ram/nsh_flash.ztgt
+++ b/boards/z80/ez80/z20x/configs/nsh_ram/nsh_flash.ztgt
@@ -20,7 +20,7 @@
       <device />
       <externalAddress>200000</externalAddress>
       <externalAutoSelect>false</externalAutoSelect>
-      <externalRamLower>40000</externalRamLower>
+      <externalRamLower>040000</externalRamLower>
       <externalRamUpper>0BFFFF</externalRamUpper>
       <manufacturer />
       <units>1</units>
diff --git a/boards/z80/ez80/z20x/configs/nsh_ram/nsh_ram.ztgt 
b/boards/z80/ez80/z20x/configs/nsh_ram/nsh_ram.ztgt
index 6170e6d..8f78f6b 100644
--- a/boards/z80/ez80/z20x/configs/nsh_ram/nsh_ram.ztgt
+++ b/boards/z80/ez80/z20x/configs/nsh_ram/nsh_ram.ztgt
@@ -37,15 +37,15 @@
          </CS0>
          <CS1>
             <busMode>0</busMode>
-            <controlRegister>8</controlRegister>
-            <lower>8</lower>
-            <upper>F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS1>
          <CS2>
             <busMode>0</busMode>
-            <controlRegister>28</controlRegister>
-            <lower>20</lower>
-            <upper>9F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS2>
          <CS3>
             <busMode>0</busMode>
diff --git a/boards/z80/ez80/z20x/configs/sdboot/.gitignore 
b/boards/z80/ez80/z20x/configs/sdboot/.gitignore
index 739fb85..23b9603 100644
--- a/boards/z80/ez80/z20x/configs/sdboot/.gitignore
+++ b/boards/z80/ez80/z20x/configs/sdboot/.gitignore
@@ -1,6 +1,6 @@
-nsh.hex
-nsh.map
-nsh.lod
-nsh.wsp
+sdboot.hex
+sdboot.map
+sdboot.lod
+sdboot.wsp
 *.asm
 Debug
diff --git a/boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj 
b/boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj
index 70f4367..0400938 100644
--- a/boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj
+++ b/boards/z80/ez80/z20x/configs/sdboot/sdboot.zdsproj
@@ -1,4 +1,4 @@
-<project type="Executable" project-type="Standard" configuration="Release" 
created-by="d:5.3.0:17021001" modified-by="d:5.3.0:17021001" ZDSII="ZDSII - 
eZ80Acclaim! 5.3.0 (Build 17041303)">
+<project type="Executable" project-type="Standard" configuration="Release" 
created-by="d:5.3.0:17021001" modified-by="d:5.3.0:19052909" ZDSII="ZDSII - 
eZ80Acclaim! 5.3.3 (Build 19083001)">
 <cpu>eZ80F92</cpu>
 
 <!-- file information -->
@@ -107,8 +107,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">Standard</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0FFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
@@ -196,7 +196,7 @@
 <option name="debug" type="boolean" change-action="assemble">true</option>
 <option name="debugcache" type="boolean" change-action="none">true</option>
 <option name="igcase" type="boolean" change-action="assemble">false</option>
-<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx</option>
+<option name="outputdir" type="string" 
change-action="compile">..\..\..\nuttx\</option>
 </options>
 </tool>
 <tool name="Librarian">
@@ -227,8 +227,8 @@
 <option name="padhex" type="boolean" change-action="build">false</option>
 <option name="fplib" type="string" change-action="build">Real</option>
 <option name="useadddirectives" type="boolean" 
change-action="build">false</option>
-<option name="linkconfig" type="string" 
change-action="build">CopyToRam</option>
-<option name="flashinfo" type="string" 
change-action="build">000000-0001FF</option>
+<option name="linkconfig" type="string" change-action="build">Standard</option>
+<option name="flashinfo" type="string" 
change-action="build">000000-0000FF</option>
 <option name="ram" type="string" change-action="build">040000-0BFFFF</option>
 <option name="rom" type="string" change-action="build">000000-03FFFF</option>
 <option name="extio" type="string" change-action="build">000000-00FFFF</option>
@@ -258,4 +258,4 @@
 <breakpoints>
 </breakpoints>
 
-</project>
+</project>
diff --git a/boards/z80/ez80/z20x/configs/sdboot/sdboot_flash.ztgt 
b/boards/z80/ez80/z20x/configs/sdboot/sdboot_flash.ztgt
index 03c2326..b691cd5 100644
--- a/boards/z80/ez80/z20x/configs/sdboot/sdboot_flash.ztgt
+++ b/boards/z80/ez80/z20x/configs/sdboot/sdboot_flash.ztgt
@@ -20,7 +20,7 @@
       <device />
       <externalAddress>200000</externalAddress>
       <externalAutoSelect>false</externalAutoSelect>
-      <externalRamLower>40000</externalRamLower>
+      <externalRamLower>040000</externalRamLower>
       <externalRamUpper>0BFFFF</externalRamUpper>
       <manufacturer />
       <units>1</units>
diff --git a/boards/z80/ez80/z20x/configs/sdboot/sdboot_ram.ztgt 
b/boards/z80/ez80/z20x/configs/sdboot/sdboot_ram.ztgt
index 6170e6d..8f78f6b 100644
--- a/boards/z80/ez80/z20x/configs/sdboot/sdboot_ram.ztgt
+++ b/boards/z80/ez80/z20x/configs/sdboot/sdboot_ram.ztgt
@@ -37,15 +37,15 @@
          </CS0>
          <CS1>
             <busMode>0</busMode>
-            <controlRegister>8</controlRegister>
-            <lower>8</lower>
-            <upper>F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS1>
          <CS2>
             <busMode>0</busMode>
-            <controlRegister>28</controlRegister>
-            <lower>20</lower>
-            <upper>9F</upper>
+            <controlRegister>0</controlRegister>
+            <lower>0</lower>
+            <upper>0</upper>
          </CS2>
          <CS3>
             <busMode>0</busMode>
diff --git a/boards/z80/ez80/z20x/scripts/Make.defs 
b/boards/z80/ez80/z20x/scripts/Make.defs
index 6ef267d..dab450e 100644
--- a/boards/z80/ez80/z20x/scripts/Make.defs
+++ b/boards/z80/ez80/z20x/scripts/Make.defs
@@ -42,7 +42,7 @@ endif
 ARCHASMCPUFLAGS = -cpu:$(ARCHCPU) -NOigcase
 ARCHASMLIST = -list -NOlistmac -name -pagelen:56 -pagewidth:80 -quiet
 ARCHASMWARNINGS = -warn
-ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILYDEF)=1 
-define:__ASSEMBLY__
+ARCHASMDEFINES = -define:$(ARCHCPUDEF)=1 -define:$(ARCHFAMILY)=1 
-define:__ASSEMBLY__
 AFLAGS = $(ARCHASMCPUFLAGS) $(ARCHASMINCLUDES) $(ARCHASMLIST) 
$(ARCHASMWARNINGS) $(ARCHASMOPTIMIZATION)
 
 # Compiler definitions
@@ -52,11 +52,11 @@ ARCHCPUFLAGS = -chartype:S -promote -cpu:$(ARCHCPU) 
-NOgenprintf -NOmodsect \
 ARCHLIST = -keeplst -NOlist -NOlistinc -keepasm
 ARCHPICFLAGS =
 ARCHWARNINGS = -warn
-ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILYDEF)
+ARCHDEFINES = -define:$(ARCHCPUDEF) -define:$(ARCHFAMILY)
 ARCHINCLUDES = $(ARCHSTDINCLUDES) $(ARCHUSRINCLUDES)
 CFLAGS = $(ARCHWARNINGS) $(ARCHOPTIMIZATION) $(ARCHLIST) $(ARCHCPUFLAGS) 
$(ARCHINCLUDES) $(ARCHDEFINES) $(EXTRADEFINES)
 
-CPPDEFINES = -D$(ARCHFAMILYDEF) -D$(ARCHCPUDEF) -D__ASSEMBLY__
+CPPDEFINES = -D$(ARCHFAMILY) -D$(ARCHCPUDEF) -D__ASSEMBLY__
 CPPINCLUDES = -I$(TOPDIR)$(DELIM)include
 CPPFLAGS = $(CPPDEFINES) $(CPPINCLUDES)
 
diff --git a/boards/z80/ez80/z20x/scripts/z20x_copytoram.linkcmd 
b/boards/z80/ez80/z20x/scripts/z20x_copytoram.linkcmd
index 2c50296..bf4015b 100644
--- a/boards/z80/ez80/z20x/scripts/z20x_copytoram.linkcmd
+++ b/boards/z80/ez80/z20x/scripts/z20x_copytoram.linkcmd
@@ -28,9 +28,10 @@ RANGE RAM $040000 : $0BFFFF
 RANGE EXTIO $000000 : $00FFFF
 RANGE INTIO $000000 : $0000FF
 
-CHANGE TEXT is CODE
 CHANGE CODE is RAM
+CHANGE TEXT is CODE
 CHANGE STRSECT is CODE
+
 ORDER .RESET,.IVECTS,.STARTUP,CODE,DATA
 COPY CODE ROM
 COPY DATA ROM
diff --git a/boards/z80/ez80/z20x/scripts/z20x_flash.linkcmd 
b/boards/z80/ez80/z20x/scripts/z20x_flash.linkcmd
index a7b6ad9..4b5ff57 100644
--- a/boards/z80/ez80/z20x/scripts/z20x_flash.linkcmd
+++ b/boards/z80/ez80/z20x/scripts/z20x_flash.linkcmd
@@ -28,8 +28,7 @@ RANGE RAM $040000 : $0BFFFF
 RANGE EXTIO $000000 : $00FFFF
 RANGE INTIO $000000 : $0000FF
 
-CHANGE TEXT is CODE
-CHANGE STRSECT is CODE
+CHANGE STRSECT is ROM
 
 ORDER .RESET,.IVECTS,.STARTUP,CODE,DATA
 COPY DATA ROM
diff --git a/boards/z80/ez80/z20x/scripts/z20x_ram.linkcmd 
b/boards/z80/ez80/z20x/scripts/z20x_ram.linkcmd
index ad4c1b3..cbc949f 100644
--- a/boards/z80/ez80/z20x/scripts/z20x_ram.linkcmd
+++ b/boards/z80/ez80/z20x/scripts/z20x_ram.linkcmd
@@ -33,6 +33,7 @@ CHANGE .STARTUP is RAM
 CHANGE TEXT is CODE
 CHANGE CODE is RAM
 CHANGE STRSECT is CODE
+
 ORDER .RESET,.IVECTS,.STARTUP,CODE,DATA
 
 DEFINE __low_romdata = copy base of DATA

Reply via email to