9
0
Fork 0

STM32 I2C fix, documentation update, fixes for FreeBSD/ASH build

git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@3917 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
patacongo 2011-08-27 14:58:42 +00:00
parent 66859cc791
commit e1a8bc740d
8 changed files with 313 additions and 165 deletions

View File

@ -2030,4 +2030,9 @@
* tools/mkexport.sh: Extended the script that implements the top-level
'make export' logic. The script now also finds and bundles up all of
the architecture-specific header files as well.
* drivers/arch/arm/src/stm32/stm32_i2c.c: Add a reset to the I2C
initialization logic to prevent spurious interrups when the I2C
interrupts are enabled (submitted by Uros Platise).
* Scripts/makefiles/documents. Several adjustments, corrections and
typo fixes so that NuttX will build correctly on FreeBSD using the
ASH shell (submitted by Kurt Lidl).

View File

@ -28,6 +28,8 @@
| | |- arm
| | | `- src
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/arch/arm/src/lpc214x/README.txt?view=log">lpc214x/README.txt</a>
| | |- avr/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/arch/avr/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- sh/
| | | |- include/
| | | | |-<a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/arch/sh/include/m16c/README.txt?view=log">m16c/README.txt</a>
@ -48,6 +50,8 @@
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/arch/z80/src/z80/README.txt?view=log">z80/README.txt</a>
| | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/arch/README.txt?view=log"><b><i>README.txt</i></b></a>
| |- configs/
| | |- amber/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/amber/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- avr32dev1/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/avr32dev1/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- c5471evm/
@ -56,6 +60,8 @@
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/c5471evm/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- demo9s12ne64/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/demo9s12ne64/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- detron/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/detron/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- ea3131/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/ea3131/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- eagle100/
@ -73,6 +79,8 @@
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/ez80f910200zco/ostest/README.txt?view=log">ostest/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/ez80f910200zco/poll/README.txt?view=log">poll/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/ez80f910200zco/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- kwikstik-k40/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/kwikstik-k40/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- lm3s6965-ek/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/lm3s6965-ek/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/lm3s6965-ek/src/README.txt?view=log">src/README.txt</a>
@ -92,6 +100,8 @@
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/mcu123-lpc214x/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/mcu123-lpc214x/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/mcu123-lpc214x/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- micropendous3/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/micropendous3/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- mx1ads/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/mx1ads/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/mx1ads/src/README.txt?view=log">src/README.txt</a>
@ -120,14 +130,14 @@
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/pjrc-8051/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/pjrc-8051/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/pjrc-8051/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- rgmp/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- qemu-i486/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/qemu-i486/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/qemu-i486/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/qemu-i486/README.txt?view=log"><b><i>README.txt</i></b></a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/qemu-i486/README.txt?view=log"><b><i>README.txt</i></b | | |- rgmp/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/include/README.txt?view=log">include/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/rgmp/README.txt?view=log"><b><i>README.txt</i></b></a>></a>
| | |- sam3u-ek/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/sam3u-ek/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- sim/
@ -143,6 +153,10 @@
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/stm3210e-eval/RIDE/README.txt?view=log">RIDE/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/stm3210e-eval/src/README.txt?view=log">src/README.txt</a>
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/stm3210e-eval/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- sure-pic32mx/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/sure-pic32mx/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- twr-k60n512/
| | | `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/twr-k60n512/README.txt?view=log"><b><i>README.txt</i></b></a>
| | |- us7032evb1/
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/us7032evb1/bin/README.txt?view=log">bin/README.txt</a>
| | | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/configs/us7032evb1/include/README.txt?view=log">include/README.txt</a>
@ -189,20 +203,25 @@
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/nuttx/tools/README.txt?view=log"><b><i>README.txt</i></b></a>
`- apps/
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/README.txt?view=log"><b>README.txt</b></a>
|- examples/
| |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/examples/pashello/README.txt?view=log">pashello/README.txt</a>
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/examples/README.txt?view=log"><b><i>README.txt</i></b></a>
|- interpreters/
| |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/interpreters/ficl/README.txt?view=log"><b><i>ficl/README.txt</i></b></a>
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/interpreters/README.txt?view=log"><b><i>README.txt</i></b></a>
|- netutils/
| | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/netutils/ftpc/README.txt?view=log">ftpc/README.txt</a>
| | |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/netutils/telnetd/README.txt?view=log">telnetd/README.txt</a>
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/netutils/README?view=log"><b><i>README</i></b></a>
|- nshlib/
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/nshlib/README.txt?view=log"><b><i>README.txt</i></b></a>
|- examples/
| |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/examples/pashello/README.txt?view=log">pashello/README.txt</a>
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/examples/README.txt?view=log"><b><i>README.txt</i></b></a>
|- system/
| |- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/system/free/README.txt?view=log">free/README.txt</a>
| `- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/system/install/README.txt?view=log">install/README.txt</a>
`- vsn/
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/free/README.txt?view=log">free/README.txt</a>
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/hello/README.txt?view=log">hello/README.txt</a>
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/poweroff/README.txt?view=log">poweroff/README.txt</a>
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/ramtron/README.txt?view=log">ramtron/README.txt</a>
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/sdcard/README.txt?view=log">sdcard/README.txt</a>
|- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/sysinfo/README.txt?view=log">sysinfo/README.txt</a>
`- <a href="http://nuttx.svn.sourceforge.net/viewvc/nuttx/trunk/apps/vsn/sdcard/README.txt?view=log"><b><i>README.txt</i></b></a>

View File

@ -324,7 +324,7 @@ clean_context:
check_context:
@if [ ! -e ${TOPDIR}/.config -o ! -e ${TOPDIR}/Make.defs ]; then \
echo "" ; echo "Nuttx has not been configured:" ; \
echo " cd tools; ./configure.sh <target>\n" ; echo "" ;\
echo " cd tools; ./configure.sh <target>" ; echo "" ; \
exit 1 ; \
fi

View File

@ -2,9 +2,19 @@ README
^^^^^^
o Installation
- Installing Cygwin
- Download and Unpack
- Semi-Optional apps/ Package
- Installation Directories with Spaces in the Path
- A Note about Header Files
o Configuring NuttX
o Toolchains
- Cross-Development Toolchains
- NuttX Buildroot Toolchain
o Shells
o Building NuttX
- Building
- Re-building
o Documentation
INSTALLATION
@ -51,7 +61,7 @@ Download and Unpack:
match the various instructions in the documentation and some scripts
in the source tree.
Semi-Optional apps/ package.
Semi-Optional apps/ Package:
All NuttX libraries and example code used to be in included within
the NuttX source tree. As of NuttX-6.0, this application code was
@ -66,7 +76,7 @@ Semi-Optional apps/ package.
Download the unpack the apps tarball in the same directly where you
unpacked the NuttX tarball. After you unpack the apps tarball, you
will have a new directory called apps-versioin (where the version
will have a new directory called apps-version (where the version
should exactly match the version of the NuttX tarball). Again, you
might want to rename the directory to simply apps/ to match what
you read in the documentation
@ -81,10 +91,10 @@ Semi-Optional apps/ package.
This is important because the NuttX build will expect to find the
apps directory in that (default) location. )That default location
can be changed by editting your NuttX configuration file, but that
can be changed by editing your NuttX configuration file, but that
is another story).
Installation Directories with Spaces in the Path
Installation Directories with Spaces in the Path:
The nuttx build directory should reside in a path that contains no
spaces in any higher level directory name. For example, under
@ -187,6 +197,36 @@ NuttX Buildroot Toolchain
This toolchain is available for both the Linux and Cygwin development
environments.
SHELLS
^^^^^^
The NuttX build relies on some shell scripts. Some are inline in the
Makefiles and many are exectuble scripts in the tools/. directory. The
scripts were all developed using bash and many contain bash shell
dependencies.
Most of the scripts begin with #!/bin/bash to specifically select the
bash shell. Some still have #!/bin/sh but I haven't heard any complaints
so these must not have bash dependencies.
There are two shell issues that I have heard of:
1. Linux where /bin/sh refers to an incompatible shell (like ksh or csh).
In this case, bash is probably avaiable and the #!/bin/bash at the
beginning of the file should do the job. If any scripts with #!/bin/sh
fail, try changing that ti #!/bin/bash and let me know about the change.
2. FreeBSD with the Bourne Shell and no bash shell.
The other, reverse case has also been reported on FreeBSD setups that
have the Bourne shell, but not bash. In this base, #!/bin/bash fails
but #!/bin/sh works okay. My recommendation in this case is to create
a symbolic link at /bin/bash that refers to the Bourne shell.
There may still be issues, however, with certain the bash-centric scripts
that will require modifications.
BUILDING NUTTX
^^^^^^^^^^^^^^
@ -196,7 +236,7 @@ Building
any special build directories. Assuming that your Make.defs is setup
properly for your tool chain and that setenv.sh contains the path to where
your cross-development tools are installed, the following steps are all that
are equired to build NuttX:
are required to build NuttX:
cd ${TOPDIR}
. ./setenv.sh
@ -226,16 +266,16 @@ Re-building
make clean_context all
This 'make' coimmand will remove of the copied directories, re-copy them,
This 'make' command will remove of the copied directories, re-copy them,
then make NuttX.
CYGWIN BUILD PROBLEMS
^^^^^^^^^^^^^^^^^^^^^
If you see strange behaviour when building under Cygwin then you may have
If you see strange behavior when building under Cygwin then you may have
a problem with your PATH variable. For example, if you see failures to
locate files that are clearly present, that may mean that you are using
the wrong version of a tool. For example, you may not be using Cywgin's
the wrong version of a tool. For example, you may not be using Cygwin's
'make' program at /usr/bin/make. Try:
$ which make
@ -268,12 +308,15 @@ NuttX documentation is also available online at http://www.nuttx.org.
Below is a guide to the available README files in the NuttX source tree:
nuttx
|
|- arch/
| |
| |- arm
| |- arm/
| | `- src
| | `- lpc214x/README.txt
| |- avr/
| | `- README.txt
| |- sh/
| | |- include/
| | | |-m16c/README.txt
@ -294,6 +337,8 @@ Below is a guide to the available README files in the NuttX source tree:
| | `- z80/README.txt
| `- README.txt
|- configs/
| |- amber/
| | `- README.txt
| |- avr32dev1/
| | `- README.txt
| |- c5471evm/
@ -302,6 +347,8 @@ Below is a guide to the available README files in the NuttX source tree:
| | `- README.txt
| |- demo0s12ne64/
| | `- README.txt
| |- detron/
| | `- README.txt
| |- ea3131/
| | `- README.txt
| |- eagle100/
@ -319,6 +366,8 @@ Below is a guide to the available README files in the NuttX source tree:
| | |- ostest/README.txt
| | |- poll/README.txt
| | `- README.txt
| |- kwikstik-k40/
| | `- README.txt
| |- lm3s6965-ek/
| | |- include/README.txt
| | |- src/README.txt
@ -338,6 +387,8 @@ Below is a guide to the available README files in the NuttX source tree:
| | |- include/README.txt
| | |- src/README.txt
| | `- README.txt
| |- micropendous3/
| | `- README.txt
| |- mx1ads/
| | |- include/README.txt
| | |- src/README.txt
@ -349,7 +400,7 @@ Below is a guide to the available README files in the NuttX source tree:
| | |- include/README.txt
| | |- src/README.txt
| | `- README.txt
| |- nucleus1g/
| |- nucleus2g/
| | `- README.txt
| |- olimex-lpc1766stk/
| | `- README.txt
@ -366,11 +417,11 @@ Below is a guide to the available README files in the NuttX source tree:
| | |- include/README.txt
| | |- src/README.txt
| | `- README.txt
| |- rgmp/
| |- qemu-i486/
| | |- include/README.txt
| | |- src/README.txt
| | `- README.txt
| |- qemu-i486/
| |- rgmp/
| | |- include/README.txt
| | |- src/README.txt
| | `- README.txt
@ -389,6 +440,10 @@ Below is a guide to the available README files in the NuttX source tree:
| | |- RIDE/README.txt
| | |- src/README.txt
| | `- README.txt
| |- sure-pic32mx/
| | `- README.txt
| |- twr-k60n512/
| | `- README.txt
| |- us7032evb1/
| | |- bin/README.txt
| | |- include/README.txt
@ -418,9 +473,6 @@ Below is a guide to the available README files in the NuttX source tree:
| `- README.txt
|- drivers/
| `- README.txt
|- examples/
| |- pashello/README.txt
| `- README.txt
|- fs/
| |- mmap/
| | `- README.txt
@ -436,3 +488,35 @@ Below is a guide to the available README files in the NuttX source tree:
| `- README.txt
`- tools/
`- README.txt
apps
|- examples/
| |- pashello/README.txt
| `- README.txt
|- interpreters/
| |- ficl
| | `- README.txt
| `- README.txt
|- netutils/
| |- ftpc
| | `- README.txt
| |- telnetd
| | `- README.txt
| `- README.txt
|- nshlib/
| `- README.txt
|- system/
| |- free/README.txt
| `- install
| `- README.txt
|- vsn/
| |- hello/README.txt
| |- poweroff
| | `- README.txt
| |- ramtron
| | `- README.txt
| |- sdcard
| | `- README.txt
| `- sysinfo
| `- README.txt
`- README.txt

View File

@ -129,14 +129,26 @@ struct stm32_i2c_inst_s {
#if CONFIG_STM32_I2C1
struct stm32_i2c_priv_s stm32_i2c1_priv = {
.base = STM32_I2C1_BASE,
.refs = 0
.refs = 0,
.msgc = 0,
.msgv = NULL,
.ptr = NULL,
.dcnt = 0,
.flags = 0,
.status = 0
};
#endif
#if CONFIG_STM32_I2C2
struct stm32_i2c_priv_s stm32_i2c2_priv = {
.base = STM32_I2C2_BASE,
.refs = 0
.refs = 0,
.msgc = 0,
.msgv = NULL,
.ptr = NULL,
.dcnt = 0,
.flags = 0,
.status = 0
};
#endif
@ -443,13 +455,24 @@ static int stm32_i2c_init(FAR struct stm32_i2c_priv_s *priv)
#if CONFIG_STM32_I2C1
case STM32_I2C1_BASE:
/* enable power and reset the peripheral */
modifyreg32(STM32_RCC_APB1ENR, 0, RCC_APB1ENR_I2C1EN);
modifyreg32(STM32_RCC_APB1RSTR, 0, RCC_APB1RSTR_I2C1RST);
modifyreg32(STM32_RCC_APB1RSTR, RCC_APB1RSTR_I2C1RST, 0);
/* configure pins */
if (stm32_configgpio(GPIO_I2C1_SCL)==ERROR) return ERROR;
if (stm32_configgpio(GPIO_I2C1_SDA)==ERROR) {
stm32_unconfiggpio(GPIO_I2C1_SCL);
return ERROR;
}
/* attach ISRs */
irq_attach(STM32_IRQ_I2C1EV, stm32_i2c1_isr);
irq_attach(STM32_IRQ_I2C1ER, stm32_i2c1_isr);
up_enable_irq(STM32_IRQ_I2C1EV);
@ -459,13 +482,24 @@ static int stm32_i2c_init(FAR struct stm32_i2c_priv_s *priv)
#if CONFIG_STM32_I2C2
case STM32_I2C2_BASE:
/* enable power and reset the peripheral */
modifyreg32(STM32_RCC_APB1ENR, 0, RCC_APB1ENR_I2C2EN);
modifyreg32(STM32_RCC_APB1RSTR, 0, RCC_APB1RSTR_I2C2RST);
modifyreg32(STM32_RCC_APB1RSTR, RCC_APB1RSTR_I2C2RST, 0);
/* configure pins */
if (stm32_configgpio(GPIO_I2C2_SCL)==ERROR) return ERROR;
if (stm32_configgpio(GPIO_I2C2_SDA)==ERROR) {
stm32_unconfiggpio(GPIO_I2C2_SCL);
return ERROR;
}
/* attach ISRs */
irq_attach(STM32_IRQ_I2C2EV, stm32_i2c2_isr);
irq_attach(STM32_IRQ_I2C2ER, stm32_i2c2_isr);
up_enable_irq(STM32_IRQ_I2C2EV);
@ -748,7 +782,7 @@ FAR struct i2c_dev_s * up_i2cinitialize(int port)
return NULL;
#endif
/* Get structure and enable power */
/* Get I2C private structure */
switch(port) {
#if CONFIG_STM32_I2C1

View File

@ -81,6 +81,14 @@ BOARDDIR = $(TOPDIR)/arch/$(CONFIG_ARCH)/src/board
LIBGCC = "${shell $(CC) -print-libgcc-file-name}"
ifeq ($(HOSTOS),FreeBSD)
HOST_ARCH = ${shell uname -m 2>/dev/null || echo "Other"}
ifeq ($(HOST_ARCH),amd64)
LDFLAGS += -melf_i386
LIBGCC = "/usr/lib32/libgcc.a"
endif
endif
VPATH = chip:common:$(ARCH_SUBDIR)
all: $(HEAD_OBJ) libarch$(LIBEXT)

View File

@ -1,5 +1,5 @@
sycall/README.txt
=================
syscall/README.txt
==================
This directory supports a syscall layer from communication between a
monolithic, kernel-mode NuttX kernel and a separately built, user-mode

View File

@ -1,8 +1,8 @@
#!/bin/bash
############################################################################
# tools mkdeps.sh
# tools/mkdeps.sh
#
# Copyright (C) 2007-2009 Gregory Nutt. All rights reserved.
# Copyright (C) 2007-2009, 2011 Gregory Nutt. All rights reserved.
# Author: Gregory Nutt <spudmonkey@racsa.co.cr>
#
# Redistribution and use in source and binary forms, with or without
@ -34,12 +34,10 @@
#
############################################################################
WD=
#
# Usage:
function show_usage ()
show_usage ()
{
echo ""
echo "$progname [OPTIONS] CC -- CFLAGS -- file [file [file...]]"
@ -69,7 +67,7 @@ function show_usage ()
exit 1
}
function dodep ()
dodep ()
{
unset fullpath
if [ -z "$altpath" ]; then
@ -94,7 +92,7 @@ function dodep ()
fi
$cc -M $cflags $fullpath || \
{ echo "# ERROR: $cc -M $cflags $fullpath FAILED" ; exit 4 ; }
( echo "# ERROR: $cc -M $cflags $fullpath FAILED"; exit 4; )
}
unset cc