mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-21 04:33:10 +08:00
configs/z80sim/nsh and pashello converted to kconfig-frontends and Windows native build
git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5418 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -3759,3 +3759,8 @@
|
||||
type. Requested by Freddie Chopin.
|
||||
* include/stdlib/lib_rand.c: Various additional changes so that the integer
|
||||
value zero can be returned. Requested by Freddie Chopin.
|
||||
* arch/z80/src/Makefile.sdcc*, z80/up_mem.h: Redesign Z80 build so that it
|
||||
no longer depends on Bash scripts.
|
||||
* configs/z80sim/nsh and pashello: Converted to (1) used the kconfig-frontends
|
||||
configuration tool, and (2) to build natively under Windows. The NSH
|
||||
configuration is verified; the pashello configuration needs a more TLC.
|
||||
|
||||
@@ -12,10 +12,10 @@ Contents
|
||||
o Getting a TRS80 emulator and DOS disks
|
||||
o Loading an executable into xtrs
|
||||
o Configuring NuttX
|
||||
o Reconfiguring NuttX
|
||||
o Reconfiguring for Linux, OSX, or Cygwin
|
||||
o SDCC
|
||||
o Building the SDCC toolchain
|
||||
o SDCC Update
|
||||
o Newer SDCC Versions
|
||||
|
||||
Getting a TRS80 emulator and DOS disks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
@@ -85,6 +85,42 @@ Configuring NuttX
|
||||
cd -
|
||||
. ./setenv.sh
|
||||
|
||||
Reconfiguring NuttX
|
||||
^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
These configurations all use the kconfig-frontends, mconf-based configuration
|
||||
tool. To change this configuration using that tool, you should:
|
||||
|
||||
a. Build and install the mconf tool. See nuttx/README.txt and
|
||||
misc/tools/README.txt
|
||||
|
||||
b. Execute 'make menuconfig' in nuttx/ in order to start the reconfiguration
|
||||
process.
|
||||
|
||||
Reconfiguring for Linux, OSX, or Cygwin
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
All of the z80 configurations in this this directory are set up to build in a
|
||||
Windows CMD.exe shell. This configuration requires the MinGW host compiler
|
||||
and severl GNUWin32 tools (see discussion in the top-level NuttX/README.txt
|
||||
file).
|
||||
|
||||
These configurations can be converted to run under Linux (or Cygwin or OSX),
|
||||
by modifying the configuration file as follows:
|
||||
|
||||
-CONFIG_HOST_WINDOWS=y
|
||||
-CONFIG_WINDOWS_NATIVE=y
|
||||
+CONFIG_HOST_LINUX=y
|
||||
|
||||
-CONFIG_Z80_TOOLCHAIN_SDCCW=y
|
||||
+CONFIG_Z80_TOOLCHAIN_SDCCL=y
|
||||
|
||||
You may need to first manually change the CONFIG_APPS_DIR="..\apps" definition
|
||||
in the .config file because the backslash may upset some Unix-based tools.
|
||||
|
||||
You cannot use the default setenv.bat in these Unix-like enviroments because
|
||||
that is a Windows batch file. Use configs/z80sim/script/setenv.sh instead.
|
||||
|
||||
SDCC
|
||||
^^^^
|
||||
|
||||
|
||||
@@ -104,18 +104,18 @@
|
||||
* Private Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
static int up_setup(struct uart_dev_s *dev);
|
||||
static void up_shutdown(struct uart_dev_s *dev);
|
||||
static int up_attach(struct uart_dev_s *dev);
|
||||
static void up_detach(struct uart_dev_s *dev);
|
||||
static int up_ioctl(struct file *filep, int cmd, unsigned long arg);
|
||||
static int up_receive(struct uart_dev_s *dev, uint32_t *status);
|
||||
static void up_rxint(struct uart_dev_s *dev, bool enable);
|
||||
static bool up_rxavailable(struct uart_dev_s *dev);
|
||||
static void up_send(struct uart_dev_s *dev, int ch);
|
||||
static void up_txint(struct uart_dev_s *dev, bool enable);
|
||||
static bool up_txready(struct uart_dev_s *dev);
|
||||
static bool up_txempty(struct uart_dev_s *dev);
|
||||
static int up_setup(FAR struct uart_dev_s *dev);
|
||||
static void up_shutdown(FAR struct uart_dev_s *dev);
|
||||
static int up_attach(FAR struct uart_dev_s *dev);
|
||||
static void up_detach(FAR struct uart_dev_s *dev);
|
||||
static int up_ioctl(FAR struct file *filep, int cmd, unsigned long arg);
|
||||
static int up_receive(FAR struct uart_dev_s *dev, unsigned int *status);
|
||||
static void up_rxint(FAR struct uart_dev_s *dev, bool enable);
|
||||
static bool up_rxavailable(FAR struct uart_dev_s *dev);
|
||||
static void up_send(FAR struct uart_dev_s *dev, int ch);
|
||||
static void up_txint(FAR struct uart_dev_s *dev, bool enable);
|
||||
static bool up_txready(FAR struct uart_dev_s *dev);
|
||||
static bool up_txempty(FAR struct uart_dev_s *dev);
|
||||
|
||||
/****************************************************************************
|
||||
* Private Variables
|
||||
@@ -185,7 +185,7 @@ static uart_dev_t g_uartport =
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_setup(struct uart_dev_s *dev)
|
||||
static int up_setup(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
outp(RESET, 0);
|
||||
outp(CONTROL, ctrl);
|
||||
@@ -203,7 +203,7 @@ static int up_setup(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_shutdown(struct uart_dev_s *dev)
|
||||
static void up_shutdown(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -222,7 +222,7 @@ static void up_shutdown(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_attach(struct uart_dev_s *dev)
|
||||
static int up_attach(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
// SDCC complains here
|
||||
// *((void (*)()) XMIT_INT_VECTOR) = rs232_xmitisr;
|
||||
@@ -246,7 +246,7 @@ static int up_attach(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_detach(struct uart_dev_s *dev)
|
||||
static void up_detach(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
outp(WRINTMASK, *(char *)WRINTMASK_SHADOW &= ~(MASK_ERR_INT | MASK_RECV_INT | MASK_XMIT_INT));
|
||||
*((int *) XMIT_INT_VECTOR) = 0x35fa;
|
||||
@@ -261,7 +261,7 @@ static void up_detach(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_ioctl(struct file *filep, int cmd, unsigned long arg)
|
||||
static int up_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
||||
{
|
||||
*get_errno_ptr() = ENOTTY;
|
||||
return ERROR;
|
||||
@@ -277,7 +277,7 @@ static int up_ioctl(struct file *filep, int cmd, unsigned long arg)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_receive(struct uart_dev_s *dev, uint32_t *status)
|
||||
static int up_receive(FAR struct uart_dev_s *dev, unsigned int *status)
|
||||
{
|
||||
// uint8_t ch = z80_lowputc();
|
||||
|
||||
@@ -293,7 +293,7 @@ static int up_receive(struct uart_dev_s *dev, uint32_t *status)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_rxint(struct uart_dev_s *dev, bool enable)
|
||||
static void up_rxint(FAR struct uart_dev_s *dev, bool enable)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -305,7 +305,7 @@ static void up_rxint(struct uart_dev_s *dev, bool enable)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_rxavailable(struct uart_dev_s *dev)
|
||||
static bool up_rxavailable(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -318,7 +318,7 @@ static bool up_rxavailable(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_send(struct uart_dev_s *dev, int ch)
|
||||
static void up_send(FAR struct uart_dev_s *dev, int ch)
|
||||
{
|
||||
z80_lowputc(ch);
|
||||
}
|
||||
@@ -331,7 +331,7 @@ static void up_send(struct uart_dev_s *dev, int ch)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_txint(struct uart_dev_s *dev, bool enable)
|
||||
static void up_txint(FAR struct uart_dev_s *dev, bool enable)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -343,7 +343,7 @@ static void up_txint(struct uart_dev_s *dev, bool enable)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_txready(struct uart_dev_s *dev)
|
||||
static bool up_txready(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -356,7 +356,7 @@ static bool up_txready(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_txempty(struct uart_dev_s *dev)
|
||||
static bool up_txempty(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -12,10 +12,10 @@ Contents
|
||||
^^^^^^^^
|
||||
|
||||
o Configuring NuttX
|
||||
o Reconfiguring NuttX
|
||||
o Reconfiguring for Linux, OSX, or Cygwin
|
||||
o SDCC
|
||||
o Building the SDCC toolchain
|
||||
o SDCC Update
|
||||
o Newer SDCC Versions
|
||||
|
||||
Configuring NuttX
|
||||
^^^^^^^^^^^^^^^^^
|
||||
@@ -32,35 +32,19 @@ Configuring NuttX
|
||||
|
||||
NOTES:
|
||||
|
||||
1. This configuration uses the mconf-based configuration tool. To
|
||||
change this configuration using that tool, you should:
|
||||
|
||||
a. Build and install the mconf tool. See nuttx/README.txt and
|
||||
misc/tools/
|
||||
|
||||
b. Execute 'make menuconfig' in nuttx/ in order to start the
|
||||
reconfiguration process.
|
||||
1. This configuration uses the mconf-based configuration tool. See the
|
||||
"Reconfiguring" section below for information about changing this
|
||||
configuration.
|
||||
|
||||
2. The default setup for this configuration uses a windows native build.
|
||||
As of this writing, the native Windows build still does not work.
|
||||
See the section entitled "Reconfiguring for Linux, OSX, or Cygwin"
|
||||
which will give you the steps you would need to do to convert this
|
||||
configuration to build in other, Unix-like environments.
|
||||
|
||||
This configuration was last verified sucessfully prior to the
|
||||
3. This configuration was last verified sucessfully prior to the
|
||||
the configure to Kconfig/mconf tool using SDCC 2.6.0 built to run
|
||||
natively under Cygwin.
|
||||
|
||||
3. This configuration can be converted to run under Linux (or Cygwin or
|
||||
OSX), by modifying the configuration file as follows:
|
||||
|
||||
-CONFIG_HOST_WINDOWS=y
|
||||
-CONFIG_WINDOWS_NATIVE=y
|
||||
+CONFIG_HOST_LINUX=y
|
||||
|
||||
-CONFIG_Z80_TOOLCHAIN_SDCCW=y
|
||||
+CONFIG_Z80_TOOLCHAIN_SDCCL=y
|
||||
|
||||
You make also have to change the value of CONFIG_APPS_DIR. You cannot
|
||||
use the default setenv.bat. Use configs/z80sim/script/setenv.sh instead.
|
||||
|
||||
nsh
|
||||
|
||||
This configuration file builds NSH (examples/nsh). This
|
||||
@@ -74,7 +58,22 @@ Configuring NuttX
|
||||
cd -
|
||||
. ./setenv.sh
|
||||
|
||||
pashello
|
||||
NOTES:
|
||||
|
||||
1. This configuration uses the mconf-based configuration tool. See the
|
||||
"Reconfiguring" section below for information about changing this
|
||||
configuration.
|
||||
|
||||
2. The default setup for this configuration uses a windows native build.
|
||||
See the section entitled "Reconfiguring for Linux, OSX, or Cygwin"
|
||||
which will give you the steps you would need to do to convert this
|
||||
configuration to build in other, Unix-like environments.
|
||||
|
||||
3. This configuration was last verified sucessfully prior to the
|
||||
the configure to Kconfig/mconf tool using SDCC 2.6.0 built to run
|
||||
natively under Cygwin.
|
||||
|
||||
pashello
|
||||
|
||||
Configures to use examples/pashello for execution from FLASH
|
||||
See examples/README.txt for information about pashello.
|
||||
@@ -89,6 +88,57 @@ Configuring NuttX
|
||||
cd -
|
||||
. ./setenv.sh
|
||||
|
||||
NOTES:
|
||||
|
||||
1. This configuration uses the mconf-based configuration tool. See the
|
||||
"Reconfiguring" section below for information about changing this
|
||||
configuration.
|
||||
|
||||
2. The default setup for this configuration uses a windows native build.
|
||||
See the section entitled "Reconfiguring for Linux, OSX, or Cygwin"
|
||||
which will give you the steps you would need to do to convert this
|
||||
configuration to build in other, Unix-like environments.
|
||||
|
||||
3. This configuration was last verified sucessfully prior to the
|
||||
the configure to Kconfig/mconf tool using SDCC 2.6.0 built to run
|
||||
natively under Cygwin.
|
||||
|
||||
Reconfiguring NuttX
|
||||
^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
These configurations all use the kconfig-frontends, mconf-based configuration
|
||||
tool. To change this configuration using that tool, you should:
|
||||
|
||||
a. Build and install the mconf tool. See nuttx/README.txt and
|
||||
misc/tools/README.txt
|
||||
|
||||
b. Execute 'make menuconfig' in nuttx/ in order to start the reconfiguration
|
||||
process.
|
||||
|
||||
Reconfiguring for Linux, OSX, or Cygwin
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
All of the z80 configurations in this this directory are set up to build in a
|
||||
Windows CMD.exe shell. This configuration requires the MinGW host compiler
|
||||
and severl GNUWin32 tools (see discussion in the top-level NuttX/README.txt
|
||||
file).
|
||||
|
||||
These configurations can be converted to run under Linux (or Cygwin or OSX),
|
||||
by modifying the configuration file as follows:
|
||||
|
||||
-CONFIG_HOST_WINDOWS=y
|
||||
-CONFIG_WINDOWS_NATIVE=y
|
||||
+CONFIG_HOST_LINUX=y
|
||||
|
||||
-CONFIG_Z80_TOOLCHAIN_SDCCW=y
|
||||
+CONFIG_Z80_TOOLCHAIN_SDCCL=y
|
||||
|
||||
You may need to first manually change the CONFIG_APPS_DIR="..\apps" definition
|
||||
in the .config file because the backslash may upset some Unix-based tools.
|
||||
|
||||
You cannot use the default setenv.bat in these Unix-like enviroments because
|
||||
that is a Windows batch file. Use configs/z80sim/script/setenv.sh instead.
|
||||
|
||||
SDCC
|
||||
^^^^
|
||||
|
||||
|
||||
@@ -1,44 +0,0 @@
|
||||
############################################################################
|
||||
# configs/z80sim/nsh/appconfig
|
||||
#
|
||||
# Copyright (C) 2011-2012 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in
|
||||
# the documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||
# used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
############################################################################
|
||||
|
||||
# Path to example in apps/examples containing the user_start entry point
|
||||
|
||||
CONFIGURED_APPS += examples/nsh
|
||||
|
||||
# The NSH Library
|
||||
|
||||
CONFIGURED_APPS += system/readline
|
||||
CONFIGURED_APPS += nshlib
|
||||
|
||||
+444
-166
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,50 @@
|
||||
@echo off
|
||||
|
||||
rem configs/z80sim/nsh/setenv.bat
|
||||
rem
|
||||
rem Copyright (C) 2012 Gregory Nutt. All rights reserved.
|
||||
rem Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
rem
|
||||
rem Redistribution and use in source and binary forms, with or without
|
||||
rem modification, are permitted provided that the following conditions
|
||||
rem are met:
|
||||
rem
|
||||
rem 1. Redistributions of source code must retain the above copyright
|
||||
rem notice, this list of conditions and the following disclaimer.
|
||||
rem 2. Redistributions in binary form must reproduce the above copyright
|
||||
rem notice, this list of conditions and the following disclaimer in
|
||||
rem the documentation and/or other materials provided with the
|
||||
rem distribution.
|
||||
rem 3. Neither the name NuttX nor the names of its contributors may be
|
||||
rem used to endorse or promote products derived from this software
|
||||
rem without specific prior written permission.
|
||||
rem
|
||||
rem THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
rem "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
rem LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
rem FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
rem COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
rem INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
rem BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
rem OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
rem AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
rem LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
rem ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
rem POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
rem This is the location where I installed in the MinGW compiler. With
|
||||
rem this configuration, it is recommended that you do NOT install the
|
||||
rem MSYS tools; they conflict with the GNUWin32 tools. See
|
||||
rem http://www.mingw.org/ for further info.
|
||||
|
||||
set PATH=C:\MinGW\bin;%PATH%
|
||||
|
||||
rem This is the location where I installed the SDCC toolchain for windows.
|
||||
|
||||
set PATH=C:\Program Files (x86)\SDCC/bin;%PATH%
|
||||
|
||||
rem This is the location where I installed the GNUWin32 tools. See
|
||||
rem http://gnuwin32.sourceforge.net/.
|
||||
|
||||
set PATH=C:\gnuwin32\bin;%PATH%
|
||||
echo %PATH%
|
||||
@@ -1,45 +0,0 @@
|
||||
#!/bin/bash
|
||||
# configs/z80sim/nsh/setenv.sh
|
||||
#
|
||||
# Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in
|
||||
# the documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||
# used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
if [ "$(basename $0)" = "setenv.sh" ] ; then
|
||||
echo "You must source this script, not run it!" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z ${PATH_ORIG} ]; then export PATH_ORIG=${PATH}; fi
|
||||
|
||||
export SDCC_BIN=/usr/local/bin
|
||||
export PATH=${SDCC_BIN}:/sbin:/usr/sbin:${PATH_ORIG}
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
@@ -1,43 +0,0 @@
|
||||
############################################################################
|
||||
# configs/z80sim/pashello/appconfig
|
||||
#
|
||||
# Copyright (C) 2011 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in
|
||||
# the documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||
# used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
############################################################################
|
||||
|
||||
# Path to example in apps/examples containing the user_start entry point
|
||||
|
||||
CONFIGURED_APPS += examples/pashello
|
||||
|
||||
# Path to the Pascal p-code runtime interpreter module
|
||||
|
||||
CONFIGURED_APPS += interpreters/pcode
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,50 @@
|
||||
@echo off
|
||||
|
||||
rem configs/z80sim/pashello/setenv.bat
|
||||
rem
|
||||
rem Copyright (C) 2012 Gregory Nutt. All rights reserved.
|
||||
rem Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
rem
|
||||
rem Redistribution and use in source and binary forms, with or without
|
||||
rem modification, are permitted provided that the following conditions
|
||||
rem are met:
|
||||
rem
|
||||
rem 1. Redistributions of source code must retain the above copyright
|
||||
rem notice, this list of conditions and the following disclaimer.
|
||||
rem 2. Redistributions in binary form must reproduce the above copyright
|
||||
rem notice, this list of conditions and the following disclaimer in
|
||||
rem the documentation and/or other materials provided with the
|
||||
rem distribution.
|
||||
rem 3. Neither the name NuttX nor the names of its contributors may be
|
||||
rem used to endorse or promote products derived from this software
|
||||
rem without specific prior written permission.
|
||||
rem
|
||||
rem THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
rem "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
rem LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
rem FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
rem COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
rem INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
rem BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
rem OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
rem AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
rem LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
rem ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
rem POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
rem This is the location where I installed in the MinGW compiler. With
|
||||
rem this configuration, it is recommended that you do NOT install the
|
||||
rem MSYS tools; they conflict with the GNUWin32 tools. See
|
||||
rem http://www.mingw.org/ for further info.
|
||||
|
||||
set PATH=C:\MinGW\bin;%PATH%
|
||||
|
||||
rem This is the location where I installed the SDCC toolchain for windows.
|
||||
|
||||
set PATH=C:\Program Files (x86)\SDCC/bin;%PATH%
|
||||
|
||||
rem This is the location where I installed the GNUWin32 tools. See
|
||||
rem http://gnuwin32.sourceforge.net/.
|
||||
|
||||
set PATH=C:\gnuwin32\bin;%PATH%
|
||||
echo %PATH%
|
||||
@@ -1,45 +0,0 @@
|
||||
#!/bin/bash
|
||||
# configs/z80sim/pashello/setenv.sh
|
||||
#
|
||||
# Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in
|
||||
# the documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||
# used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
|
||||
if [ "$(basename $0)" = "setenv.sh" ] ; then
|
||||
echo "You must source this script, not run it!" 1>&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z ${PATH_ORIG} ]; then export PATH_ORIG=${PATH}; fi
|
||||
|
||||
export SDCC_BIN=/usr/local/bin
|
||||
export PATH=${SDCC_BIN}:/sbin:/usr/sbin:${PATH_ORIG}
|
||||
|
||||
echo "PATH : ${PATH}"
|
||||
@@ -70,18 +70,18 @@
|
||||
* Private Function Prototypes
|
||||
****************************************************************************/
|
||||
|
||||
static int up_setup(struct uart_dev_s *dev);
|
||||
static void up_shutdown(struct uart_dev_s *dev);
|
||||
static int up_attach(struct uart_dev_s *dev);
|
||||
static void up_detach(struct uart_dev_s *dev);
|
||||
static int up_ioctl(struct file *filep, int cmd, unsigned long arg);
|
||||
static int up_receive(struct uart_dev_s *dev, uint32_t *status);
|
||||
static void up_rxint(struct uart_dev_s *dev, bool enable);
|
||||
static bool up_rxavailable(struct uart_dev_s *dev);
|
||||
static void up_send(struct uart_dev_s *dev, int ch);
|
||||
static void up_txint(struct uart_dev_s *dev, bool enable);
|
||||
static bool up_txready(struct uart_dev_s *dev);
|
||||
static bool up_txempty(struct uart_dev_s *dev);
|
||||
static int up_setup(FAR struct uart_dev_s *dev);
|
||||
static void up_shutdown(FAR struct uart_dev_s *dev);
|
||||
static int up_attach(FAR struct uart_dev_s *dev);
|
||||
static void up_detach(FAR struct uart_dev_s *dev);
|
||||
static int up_ioctl(FAR struct file *filep, int cmd, unsigned long arg);
|
||||
static int up_receive(FAR struct uart_dev_s *dev, unsigned int *status);
|
||||
static void up_rxint(FAR struct uart_dev_s *dev, bool enable);
|
||||
static bool up_rxavailable(FAR struct uart_dev_s *dev);
|
||||
static void up_send(FAR struct uart_dev_s *dev, int ch);
|
||||
static void up_txint(FAR struct uart_dev_s *dev, bool enable);
|
||||
static bool up_txready(FAR struct uart_dev_s *dev);
|
||||
static bool up_txempty(FAR struct uart_dev_s *dev);
|
||||
|
||||
/****************************************************************************
|
||||
* Private Variables
|
||||
@@ -151,7 +151,7 @@ static uart_dev_t g_uartport =
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_setup(struct uart_dev_s *dev)
|
||||
static int up_setup(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return OK;
|
||||
}
|
||||
@@ -165,7 +165,7 @@ static int up_setup(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_shutdown(struct uart_dev_s *dev)
|
||||
static void up_shutdown(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -184,7 +184,7 @@ static void up_shutdown(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_attach(struct uart_dev_s *dev)
|
||||
static int up_attach(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return OK;
|
||||
}
|
||||
@@ -199,7 +199,7 @@ static int up_attach(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_detach(struct uart_dev_s *dev)
|
||||
static void up_detach(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -211,7 +211,7 @@ static void up_detach(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_ioctl(struct file *filep, int cmd, unsigned long arg)
|
||||
static int up_ioctl(FAR struct file *filep, int cmd, unsigned long arg)
|
||||
{
|
||||
*get_errno_ptr() = ENOTTY;
|
||||
return ERROR;
|
||||
@@ -227,7 +227,7 @@ static int up_ioctl(struct file *filep, int cmd, unsigned long arg)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static int up_receive(struct uart_dev_s *dev, uint32_t *status)
|
||||
static int up_receive(FAR struct uart_dev_s *dev, unsigned int *status)
|
||||
{
|
||||
uint8_t ch = z80_lowgetc();
|
||||
*status = 0;
|
||||
@@ -242,7 +242,7 @@ static int up_receive(struct uart_dev_s *dev, uint32_t *status)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_rxint(struct uart_dev_s *dev, bool enable)
|
||||
static void up_rxint(FAR struct uart_dev_s *dev, bool enable)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -254,7 +254,7 @@ static void up_rxint(struct uart_dev_s *dev, bool enable)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_rxavailable(struct uart_dev_s *dev)
|
||||
static bool up_rxavailable(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -267,7 +267,7 @@ static bool up_rxavailable(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_send(struct uart_dev_s *dev, int ch)
|
||||
static void up_send(FAR struct uart_dev_s *dev, int ch)
|
||||
{
|
||||
z80_lowputc(ch);
|
||||
}
|
||||
@@ -280,7 +280,7 @@ static void up_send(struct uart_dev_s *dev, int ch)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static void up_txint(struct uart_dev_s *dev, bool enable)
|
||||
static void up_txint(FAR struct uart_dev_s *dev, bool enable)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -292,7 +292,7 @@ static void up_txint(struct uart_dev_s *dev, bool enable)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_txready(struct uart_dev_s *dev)
|
||||
static bool up_txready(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
@@ -305,7 +305,7 @@ static bool up_txready(struct uart_dev_s *dev)
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
static bool up_txempty(struct uart_dev_s *dev)
|
||||
static bool up_txempty(FAR struct uart_dev_s *dev)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user