Commit Graph

14019 Commits

Author SHA1 Message Date
Alexander Oryshchenko
643234dbcc arm/arm/src/stm32: Corrections to STM32 F4 I2C to restore functionality. 2018-02-13 08:51:53 -06:00
Gregory Nutt
4a36c946e1 Trivial update to some comments. 2018-02-12 14:46:40 -06:00
Gregory Nutt
4e32861c3c Changes from review of last PR + some updated comments. 2018-02-11 16:42:37 -06:00
Matt Thompson
10de81ebdf Merged in extent3d/nuttx/dma (pull request #597)
SAMDL DMA fixes and experimental SPI support

* SAMDL: Fix DMA controller support

* SAMDL: Added experimental DMA support to SPI driver. spi_exchange() uses a pair of DMA channels for TX and RX

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-11 22:07:18 +00:00
Harald Gutsche
3a029ed185 Merged in hg42/nuttx/lpc17-disable-FDR-2 (pull request #596)
disable LPC17 FDR when not used (second fix)

if a boot loader sets the fractional divider (FDR) the baud rate in
nuttx will be wrong (multiplied by this fraction).

This also has to be added to lpc17_lowputc.c

Unfortunately the constant used for shifting the bits was wrong in the header file, so it took some time to realize this...

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-11 21:24:47 +00:00
Gregory Nutt
a524b33f2c Update some comments 2018-02-11 10:30:45 -06:00
Mateusz Szafoni
118e97ff37 Merged in raiden00/nuttx (pull request #595)
Master

stm32_hritm: add interface to set timer frequency, fix slave timers reset configuration, change POWER_INFO to TIMER_INFO

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-11 13:12:00 +00:00
Matt Thompson
2bb5795e54 Merged in extent3d/nuttx/usb-calibration (pull request #594)
SAMDL: Added loading factory USB calibration data from NVRAM

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-11 13:10:19 +00:00
Matt Thompson
399d59028f Merged in extent3d/nuttx/eic-edge (pull request #593)
SAMDL: Fix EIC interrupt edge sensitivity for pin numbers > 8

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-10 23:24:06 +00:00
Matt Thompson
db05107711 Merged in extent3d/nuttx/clockconfig (pull request #592)
SAMDL: Added FDPLL clock support. Fixed sequence of OSC32K calibration setup

* SAMDL: Added FDPLL clock support. Fixed sequence of OSC32K calibration setup

* fixed code style

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-10 23:20:42 +00:00
Gregory Nutt
642d7e3ce2 Squashed commit of the following:
configs/flipnclick-pic32mz:  Add an nxlines configuration for use in testing the custom HiletGo Click board.
    arch/mips/src/pic32mz:  Correct some SPI-related typos.  configs/flipnclick-pic32mz: Finishes integration of HiletGo OLED. drivers/lcd:  Finish support for HiletGo OLED.
    drivers/lcd:  Add configuration support for HiletGo OLED.  configs/flipnclick-pic32mz:  Add board support for HiletGo OLED.
2018-02-10 09:43:12 -06:00
Alan Carvalho de Assis
9e4cd2f720 arch/arm/src/xmc4/: Fix USIC_BRG_SCLKCFG definition 2018-02-09 13:00:20 -06:00
Gregory Nutt
73ec87109f arch/mips/src/mips32: In up_idle, the kludge that was conditionally enabled if the work queue was enable appears to be needed even when he work queue is not enabled on the PIC32MZ.
arch/mips/src/pic32mz: Fix some typos in debug instrumentation in pic32mz-gpio.c; fix some types releated to UART5 configuration in pic32mz-serial.c.

configs/flipnclick-pic32mz/nsh:  Switch serial console to UART3.  There is some problem with the UART4 RX pin documentation or configuration.
2018-02-09 11:11:44 -06:00
Gregory Nutt
0e6ef003ff Fix some coding standard violations in the last PR. 2018-02-08 16:42:21 -06:00
hg42
da051fb3d9 Merged in hg42/nuttx/lpc17-disable-FDR (pull request #591)
disable LPC17 FDR when not used

* disable LPC17 FDR when not used

    if a boot loader set the fractional divider (FDR) the baud rate in
    nuttx will be wrong (multiplied by this fraction).

    So if it is not used, it should be disabled.

    LPC176x docs say:
    "
    DIVADDVAL Baud-rate generation pre-scaler divisor value.
    If this field is 0, fractional baud-rate generator will
    not impact the UARTn baudrate.

    MULVAL Baud-rate pre-scaler multiplier value.
    This field must be greater or equal 1 for UARTn to operate properly,
    regardless of whether the fractional baud-rate generator is used or not.
    "

    So DIVADDVAL is set to 0 and MULVAL is set to 1.

* symbols found and added

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-08 22:37:58 +00:00
Gregory Nutt
de34b4523f sched/ and arch/arm/src/armv7-a: Replace a few more occurrences of this_task() with current_task(cpu) in an effort to get the i.MX6 working in SMP mode again. It does not yet work, sadly. 2018-02-06 11:17:33 -06:00
Gregory Nutt
8aa1538506 arch/arm/src/armv7-a: Found some additional places were the new this_task() function cannot be called in the i.MX6 SMP configuration. 2018-02-06 10:33:28 -06:00
Masayuki Ishikawa
c8a372702a sched/sched: SMP: Fix this_task() to be an atomic operation. In the previous implementation, this_task() was defined in sched.h by using just a macro current_task(this_cpu()). However, I found that this is not atomic and actually sometimes switching CPU happened in executing the macro when we tested audio steaming plus executing commands via telnet. This change resolves this issue by implementing atomic this_task()in sched_thistask.c which is newly introduced. 2018-02-04 16:59:09 -06:00
Gregory Nutt
31278bc163 Kconfigs: Add comments and a dependency. 2018-02-04 16:32:14 -06:00
Gregory Nutt
8187858d79 Fix a typo just introduced to a Kconfig file 2018-02-04 15:53:01 -06:00
Gregory Nutt
5beab6fbf0 spin_lock_irqsave() and spin_unlock_irqrestore() are only valid if the CPU supports global disabling of interrupts. 2018-02-04 15:41:22 -06:00
Gregory Nutt
5c5d19f1c8 Some ommissions from previous commit. 2018-02-04 12:36:51 -06:00
Gregory Nutt
1e59d9dd14 armv7-a, armv7-r, armv7-m: Add atomic read-add-write and read-subtract-write functions. 2018-02-04 12:22:03 -06:00
Gregory Nutt
2683f713ab Make sure that labeling is used consistently in all function headers (part 3). 2018-02-01 12:17:03 -06:00
Gregory Nutt
1567b82429 Make sure that labeling is used consistently in all function headers (part 2). 2018-02-01 12:03:55 -06:00
Gregory Nutt
7cf88d7dbd Make sure that labeling is used consistently in all function headers. 2018-02-01 10:00:02 -06:00
Stewart
be81893b55 arm/src/kinetis: Correct some Ethernet PHY register bit tests for the KSZ8081 PHY. 2018-02-01 07:24:36 -06:00
Gregory Nutt
1550ef2f54 arch/arm/src/lpc43xx: Correct a typo introduced in last large set of changes 2018-01-31 11:32:43 -06:00
Gregory Nutt
da50646bcf sched/wdog: wd_start() is an internal OS function and should not set the errno value. Reviewed and updated every call to wd_start() to verify if return value is used and if so if the errno value is accessed. 2018-01-31 10:09:14 -06:00
Matt Thompson
1f10a9c576 Merged in extent3d/nuttx/i2c (pull request #588)
SAMDL: Added I2S register definitions

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-31 13:29:23 +00:00
Gregory Nutt
3521aaf944 Squashed commit of the following:
binfmt/, configs/, grahics/, libc/, mm/, net/, sched/:  OS references to the errno variable should always use the set_errno(), get_errno() macros
    arch/arm/src/stm32 and stm32f7:  Architecture-specific code is not permitted to modify the errno variable.  drivers/ and libc/:  OS references to the errno variable should always use the set_errno(), get_errno() macros
2018-01-30 17:57:36 -06:00
Gregory Nutt
82982f7972 sched/: Fix several inappropriate accesses to get_errno() that were missed in previous changes (some going back to nuttx-.23). Add new nxsched_setscheduler() and nxsched_getaffinity() which are equivalent to their counterparts without the nx on front. These versions do not modify the errno value. Changed all calls within the OS to use these newer versions of the functions. 2018-01-30 16:16:41 -06:00
Gregory Nutt
170a50c690 Squashed commit of the following:
sched/sched:  Correct some build issues introduced by last set of changes.
    sched/sched:  Add new internal OS function nxsched_setaffinity() that is identical to sched_isetaffinity() except that it does not modify the errno value.  All usage of sched_setaffinity() within the OS is replaced with nxsched_setaffinity().
    sched/sched:  Internal functions sched_reprioritize() and sched_setpriority() no longer movidify the errno value.  Also renamed to nxsched_reprioritize() and sched_setpriority().
    sched/sched:  Add new internal OS function nxsched_getscheduler() that is identical to sched_getscheduler() except that it does not modify the errno value.  All usage of sched_getscheduler() within the OS is replaced with nxsched_getscheduler().
    sched/sched:  Add new internal OS function nxsched_setparam() that is identical to sched_setparam() except that it does not modify the errno value.  All usage of sched_setparam() within the OS is replaced with nxsched_setparam().
    sched/sched:  Add new internal OS function nxsched_getparam() that is identical to sched_getparam() except that it does not modify the errno value (actually, the previous value erroneously neglected to set the errno value to begin with, but this fixes both issues).  All usage of sched_getparam() within the OS is replaced with nxsched_getparam().
2018-01-30 11:08:18 -06:00
Matt Thompson
20016b841a Merged in extent3d/nuttx (pull request #587)
SAMDL: Added Timer Compare for Control registers header

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-29 19:20:00 +00:00
Bob Feretich
a0cd711334 I have a SPI bus with both Mode 0 and Mode 3 devices on it. After performing SPI I/O to a Mode 0 device, switching to a Mode 3 device locked up the SPI interface. Only zeroes would be read. I traced the reason for the lock-up to arm/arm/src/stm32f7/stm32_spi.c function spi_setmode(). Changing the mode causes a spurious SPI clock transmission that confuses the stm32f7 SPI input hardware. This problem is solved by (1) changing the SPI mode with SPI (and perhaps DMA) disabled, and (2) flushing the receive FIFO if the mode change results in garbage in the FIFO. 2018-01-29 07:23:52 -06:00
Matt Thompson
c5e231bedd SAMDL: Added Analog Comparator headers and basic initialization 2018-01-28 21:11:37 -08:00
Mateusz Szafoni
0afbcb0bab Merged in raiden00/nuttx (pull request #585)
Master

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-28 13:46:17 +00:00
raiden00pl
cec8709ec1 stm32/Kconfig: fix COMP7 dependency
stm32_hrtim: add HRTIM push-pull mode configuration

stm32f334-disco: add buck-boost converter mode
2018-01-28 11:06:08 +01:00
Gregory Nutt
67d09e831b Fix recurring typo: *tino->*tion 2018-01-27 13:34:58 -06:00
Gregory Nutt
12e3e47d3c Update comments, mostly spelling errors. 2018-01-27 09:37:46 -06:00
Gregory Nutt
49d07162bf arch/arm/src/stm32: stm32_rtcc.h should be used to access BKP registers on F2, F3, and F4. 2018-01-26 11:34:48 -06:00
Gregory Nutt
bffa425233 arch/arm/src/stm32: stm32_bkp.h should only be used for STM32 F1 2018-01-26 11:26:40 -06:00
Gregory Nutt
fc387b9aa0 arch/arm/src/stm32: Remove bogus definitions of STM32_BKP_BASE from the F2, F3, and F4 memory maps. Unlike the F1, these parts do not have a separate BKP address region. The BKP registers are with the RTCC address regions. 2018-01-26 11:18:46 -06:00
Gregory Nutt
9e60dffc5a arch/srm/src/stm32f7: Remove confusing, redundant, and misleading STM32_BKP_BASE definitions. 2018-01-26 08:50:21 -06:00
Frank Benkert
e15fc0b65a arch/arm/src/samv7/sam_lowputc.c: Fix undefined variable when using USART1 for other purposes than UART (e.g. SPI). 2018-01-26 07:52:45 -06:00
Matt Thompson
2bc4967c0f Merged in extent3d/nuttx (pull request #583)
SAMDL: Added DMAC header for SAMD, fixed up sam_dmac to compile with debugging enabled
2018-01-25 20:15:58 +00:00
Matt Thompson
d314feab82 Merged in extent3d/nuttx (pull request #582)
SAMDL: Added SAMD DAC header file. Fixed SAMD EVSYS header. Added SAMD TC header file. Fixed some minor typos

* SAMD External Interrupt Controller (EIC) support

* removed comment

* SAMDL: SPI must be disabled before changing the mode bits in CTRLA register

* arch/arm/src/lc823450: Assign I2S IRQ handling to CPU0

    Previous commit assumed that the caller is running on CPU0.
    However, the caller sometimes runs at CPU1.  This patch will
    assign the caller to CPU0 explicitly.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Change irqwarn() to ASSERT() in up_ack_irq()

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Update README.txt and defconfigs

    Update comments on SMP in README.txt
    Enable SYSTEM_TIME64 in defconfigs.
    Enable INSTRUMENTATION in rndis configuration.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configst/stm3240g-eval:  Remove only bogus logic to start the NX server.  That was there only to support the knxwm configuration and was implemented priorit to boardctl(BOARCIOC_NX_START).

* drivers/input/ft5x06.c:  Remove cool logic to disable polling when there there is no client waiting for read data.  That was a great idea to save CPU cycles when there is nothing reading from the touchscrren but, unfortunately, does not work with readers that open the driver in non-blocking mode.  So I think we just have to eat the CPUs even when there is nothing waiting for touchscreen input.

* configs/lpcxpresso-lpc54628/lvgl:  Add LittlevGL graphics demo configuration.

*  configs/lpcxpresso-lpc54628: Update README

* include/termios.h:  Update comments; fix long lines.

* sched/semaphore: Add ASSERT(false) in nxsem_post() if no waiting task is found.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* sched/sched/sched_sporadic.c: fix compiler error when priority inheritance is enabled.  Noted by eunb.song@samsung.com

* Change ASSERT(false) to DEBUGPANIC().

* Documentation: Fix copy/paste error in NX graphics document.  Noted by Henjiu Kang.

* sched/sched:  Fix some priority inheritance related issues noted during review of logic.  Also add some REVISIT comments for some issues noted in the design.

* Update README and some comments

* Issue #85: /dev/userleds is not working for nucleo-l432kc fixed

* configs/nucleo-l432kc: Fix numerous cloning errors/typos.

* Update TODO list

* NUCLEO F432KC typo fixed, correct name is L432KC

    Just README.txt and comments affected, no changes in the code

* Merged in raiden00/nuttx (pull request #579)

    Master

    * stm32_hritm: add interface to get timer clock frequency

        stm32_hrtim: fix timer freq calculation

        stm32_hrtim: add compar/capture registers significant bits checking

        stm32_hrtim: minor changes

    * stm32f334-disco: add buck converter and boost converter logic

    Approved-by: Gregory Nutt <gnutt@nuttx.org>

* fs/userfs: use correct req type in userfs_truncate, remove use of undeclared buf

* Merged in david_alessio/nuttx/refactor-pll-setup (pull request #581)

    Refactor pll setup

    * fix typo in #def

    * refactor PLL setup code...

    * refactored PLL/CLK config, easier, checks for correctness

    * call go_os_start if STACK_COLORIZED

    * smarter config of EXTCLK output freq

    * cosmetic

    Approved-by: Gregory Nutt <gnutt@nuttx.org>

* The existence of the network driver ioctl() method should depend on CONFIG_NETDEV_IOCTL rather than CONFIG_NETDEV_PHY_IOCTL.  The former enables the method, the later enables a subset of possible driver IOCTLs.  This change should be basically a no-operation.  The affected ioctl methods only support those subset of driver IOCTLs selected by CONFIG_NETDEV_PHY_IOCTL and the network logic will tolerate a nul ioctl method.

* net/tcp:  Write buffering logic should not wait for a free buffer if the socket was opened non-blocking.  Also, rename the TCP write buffering macros from WRB_* to TCPWB_* to make room in the namespace for write buffering with other protocols.

* net/udp:  Remove some conditional logic that was true if there is only a single network device, but not true in the multi-device context.

* This commit adds an as-of-yet untested implemented of UDP write buffering.

    Squashed commit of the following:

        net/udp:  Address most of the issues with UDP write buffering.  There is a remaining issue with handling one network going down in a multi-network environment.  None of this has been test but it is certainly ready for test.  Hence, the feature is marked EXPERIMENTAL.
        net/udp:  Some baby steps toward a corrected write buffering design.
        net/udp:  Remove pesky write buffer macros.
        Eliminate trailing space at the end of lines.
        net/udp:  A little more UDP write buffering logic.  Still at least on big gaping hole in the design.
        net/udp:  Undefined CONFIG_NET_SENDTO_TIMEOUT.
        net/udp:  Crude, naive port of the TCP write buffering logic into UDP.  This commit is certainly non-functional and is simply a starting point for the implementatin of UDP write buffering.
        net/udp:  Rename udp/udp_psock_sendto.c udp/udp_psock_sendto_unbuffered.c.

* net/udp:  In sendto(), return EHOSTUNREACH if if the network is down.

* net/udp:  Resolves final design issues with UDP write buffering.  100% code complete but also 100% untested.

* net/udp and tcp:  Yet another (cosmetic) change to UDP and TCP write buffer macro naming.

* net/udp:  UDP write buffering is basically functional but needs a lot more verification.

* net/udp:  Fix memory leak with UDP + write buffer is closed.  Also update TODO and comments and refresh a configuration.

* Update some comments.

* drivers/mtd/at24xx.c: Correct page size for AT24C02 part.

* arch/arm/src/stm32:  Make STM32 usable with an external RTC.   drivers/timers/ds3231.c:  Correct some debug statments.

* arch/arm/src/stm32/stm32_spi.c: Removed unnecessary (and incorrect) speed limitation

* arch/arm/src/stm32/stm32f40xxx_i2c.c:  Correct some recent changes to STM32F4 I2C that broke poll mode of operation.

* configs/flipnclick-sam3x:  Using JTAG (vs. Bossac) I was finally able to load code and verify the basic NSH configuration.  Updated READMEs.  Also switched to USART0 (vs UART0) for the serial console because I was not getting bi-directional communication on the VCOM.

* SAMDL: Added SAMD DAC header file. Fixed SAMD EVSYS header. Added SAMD TC header file. Fixed some minor typos

* fix typo

* added missing EVCTRL register bits in TC

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-25 11:55:40 +00:00
Alexander Oryshchenko
d1cfcabb1f arch/arm/src/stm32/stm32f40xxx_i2c.c: Correct some recent changes to STM32F4 I2C that broke poll mode of operation. 2018-01-24 06:58:47 -06:00
Alexander Oryshchenko
a7e56359a4 arch/arm/src/stm32/stm32_spi.c: Removed unnecessary (and incorrect) speed limitation 2018-01-24 06:57:17 -06:00
Alexander Oryshchenko
dd4fc9f5c3 arch/arm/src/stm32: Make STM32 usable with an external RTC. drivers/timers/ds3231.c: Correct some debug statments. 2018-01-24 06:55:14 -06:00
Gregory Nutt
a8b6be4aaf The existence of the network driver ioctl() method should depend on CONFIG_NETDEV_IOCTL rather than CONFIG_NETDEV_PHY_IOCTL. The former enables the method, the later enables a subset of possible driver IOCTLs. This change should be basically a no-operation. The affected ioctl methods only support those subset of driver IOCTLs selected by CONFIG_NETDEV_PHY_IOCTL and the network logic will tolerate a nul ioctl method. 2018-01-22 08:17:45 -06:00
David Alessio
6ae6ecc958 Merged in david_alessio/nuttx/refactor-pll-setup (pull request #581)
Refactor pll setup

* fix typo in #def

* refactor PLL setup code...

* refactored PLL/CLK config, easier, checks for correctness

* call go_os_start if STACK_COLORIZED

* smarter config of EXTCLK output freq

* cosmetic

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-22 13:20:35 +00:00
Mateusz Szafoni
5af7e3de2a Merged in raiden00/nuttx (pull request #579)
Master

* stm32_hritm: add interface to get timer clock frequency

    stm32_hrtim: fix timer freq calculation

    stm32_hrtim: add compar/capture registers significant bits checking

    stm32_hrtim: minor changes

* stm32f334-disco: add buck converter and boost converter logic

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-21 18:28:09 +00:00
Matt Thompson
1ec8a6f34c Merged in extent3d/nuttx (pull request #575)
SAMDL: SPI must be disabled before changing the mode bits in CTRLA register

* SAMD External Interrupt Controller (EIC) support

* removed comment

* SAMDL: SPI must be disabled before changing the mode bits in CTRLA register

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-18 12:33:41 +00:00
Masayuki Ishikawa
0184f8818a Merged in masayuki2009/nuttx.nuttx/lc823450_fixes (pull request #576)
lc823450 fixes

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-18 12:32:41 +00:00
Masayuki Ishikawa
a3ed16dd30 arch/arm/src/lc823450: Change irqwarn() to ASSERT() in up_ack_irq()
Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2018-01-18 14:02:24 +09:00
Masayuki Ishikawa
d43c52cf03 arch/arm/src/lc823450: Assign I2S IRQ handling to CPU0
Previous commit assumed that the caller is running on CPU0.
However, the caller sometimes runs at CPU1.  This patch will
assign the caller to CPU0 explicitly.

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2018-01-18 13:55:12 +09:00
Gregory Nutt
3ff30608ef arch/arm/src/samdl: Mostly cosmetic improvements to previous commit. 2018-01-17 11:39:43 -06:00
Gregory Nutt
2d95fa6d2a arch/arm/src/samdl: Correct a link time error if CONFIG_SAMDL_EIC is not enabled. 2018-01-17 11:16:21 -06:00
Evgeniy Bobkov
7d36a81806 Fixes two bugs in multi-block SD-card operations on the STM32F7 platform. arch/arm/src/stm32f7: DBLOCKSIZE must be the size of SD-card block, not the total amount of transferred bytes. drivers/mmcsd: respect SDIO_CAPS_DMABEFOREWRITE on CMD25. 2018-01-16 12:41:02 -06:00
Mateusz Szafoni
fd5d811b0a Merged in raiden00/nuttx (pull request #569)
Master

* stm32f33xxx_hrtim.h: fix some definitions

* stm32_hrtim: fix some bugs

    stm32_hrtim: fix deadtime configuration

    stm32_hrtim: add interface to change outputs SET/RST configuration

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-14 19:00:18 +00:00
Gregory Nutt
8f94ce46f9 arch/arm/src/lpc54xx: The basic SPI driver is code complete but still untested. This driver is 'basic' in that in only supports polled mode operations. 2018-01-14 12:09:26 -06:00
Gregory Nutt
134bac3810 arch/arm/src/lpc54xx: Add configuration logic to the empty SPI driver. Still missing all data tranfer logic. 2018-01-13 15:38:55 -06:00
Matt Thompson
48355b32dc Merged in extent3d/nuttx (pull request #568)
SAMD External Interrupt Controller (EIC) support

* SAMD External Interrupt Controller (EIC) support

* removed comment

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-01-12 13:11:58 +00:00
Matt Thompson
f5cac7c45a SAMDL fix g_spi2ops and g_spi2dev using incorrect values 2018-01-11 13:00:08 -08:00
Matt Thompson
537c9a27d1 arch/arm/src/samdl: In sam_spibus_initialize(), the pinmux configuration was smashing the previous CTRLA register configuration. There are also some typos in samd_spi.h 2018-01-11 07:34:56 -06:00
Masayuki Ishikawa
7460773d7b arch/arm/src/lc823450: Introduce DVFS
This version only supports manual mode and Vdd1 is fixed to 1.2V.

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2018-01-10 16:13:00 +09:00
Gregory Nutt
7d4451ee86 Squashed commit of the following:
configs/flipnclick-pic32mz:  Switch the serial console to UART4.  Clean up some minor issues the LED options.
    configs/flipnclick-pic32mz:  Add support for two on-board buttons:  T1 and T2.
    configs/flipnclick-pic32mz:  Adds basic board support for the Mikroe Flip&Click PIC32MZ board.  Initial commit is just the configs/pic32mz-starterkit with some name chanages.
2018-01-08 14:21:49 -06:00
Gregory Nutt
6fe1f5a96c Squashed commit of the following:
arch/mips/src/pic32mz:  Commits the basic architecture port for the PIC32MZEF.
    arch/mips/src/pic32mz:  Begin adding PIC32MZEF files. Initial commit are simply PIC32MZEC files with name changes.
    arch/mips/include/pic32mz:  Add support for the PIC32MZEF family.
2018-01-08 10:01:23 -06:00
raiden00pl
01dc86da3d stm32/chip.h: minor fixes for STM32F334 2018-01-03 19:07:51 +01:00
Gregory Nutt
e7db11fc55 arch/arm/src/lpc54xx: LPC54xx Ethernet driver no long depends on EXPERIMENTAL. 2018-01-02 11:17:25 -06:00
Gregory Nutt
d04f166d84 arch/arm/src/lpc54xx: Add some hooks for future 802.1q VLAN support. configs/lpcxpresso-lpc54628: Automatically bring up network in the netnsh configuration. 2018-01-02 08:49:09 -06:00
Gregory Nutt
c3d3e91a3f arch/arm/src/lpc54xx: Correct handling of the Ethernet RBU error. With this fix, Ethernet now appears to be fully functional although still undertested. 2018-01-01 15:08:19 -06:00
Gregory Nutt
24b594cbc4 arch/arm/src/lpc54xx: Back out address filtering change in commit 3c65be8c1a 2018-01-01 11:17:32 -06:00
Gregory Nutt
3c65be8c1a arch/arm/src/lpc54xx: Fix a few more Ethernet issues related to buffer management and address filtering. 2018-01-01 08:54:31 -06:00
Gregory Nutt
fd10eaf1fb arch/arm/src/lpc54xx: Fix several more issues in bring-up of Ethernet driver. Still not fully functional. 2017-12-31 17:16:21 -06:00
Gregory Nutt
f624c504d1 arch/arm/src/lpc54xx: Fixes a few more Ethernet bring up bugs. Rx seems to work; Tx does not. 2017-12-31 14:49:13 -06:00
Gregory Nutt
b2adb4917f arch/arm/src/lpc54xx: Add register level debug output for Ethernet testing. Fixed a few start up problems. Still hangs on start-up, however. 2017-12-31 11:11:57 -06:00
Gregory Nutt
63c055e1ee arch/arm/src/lpc54xx: Ethernet. Remove last of #warning issues. No compiles with no warnings/errors. 2017-12-30 19:46:37 -06:00
Gregory Nutt
2de08627e0 arch/arm/src/lpc54xx: Finishes open design issues with AVBTP multi-channel operation. 2017-12-30 19:05:39 -06:00
Gregory Nutt
13b5d4de96 arch/arm/src/lpc54xx: Resolves some design issues with multicast address filtering and also with AVBTP multi-channel operation (the latter design is still incomplete). 2017-12-30 17:19:37 -06:00
Gregory Nutt
f23fb9dd14 arch/arm/src/lpc54xx: Completes basic packet transfer logic for Ethernet drivers. Still some unfinished logic for IPv6 multicast logic and for various non-mainstream configurations. But it is ready for tested. configs/lpcxpresso-lpc54628: Add a netnsh configuration that will be used to test the Ethernet driver. Untested on initial commit. 2017-12-30 12:51:57 -06:00
Gregory Nutt
2fb441b145 arch/arm/src/lpc54xx: Adds Ethernet Tx done handling. 2017-12-29 17:28:38 -06:00
Gregory Nutt
6315f6468d arch/arm/src/lpc54xx: Adds basic Ethernet interrupt handling. Still missing all of the descriptor and packetk buffer handling logic. 2017-12-29 14:29:52 -06:00
Gregory Nutt
5146725edc arch/arm/src/lpc54xx: Addes packet buffer and DMA descriptor logic 2017-12-29 13:17:43 -06:00
Gregory Nutt
5394681dea arch/arm/src/lpc54xx: Finishes basic MAC configruation. Began adding DMA descriptor definitions. 2017-12-29 10:27:20 -06:00
Gregory Nutt
ebdc3b9b58 arch/arm/src/lpc54xx: Continuing with Ethernet initializatino logic. Added MTL initialization and partial MAC initialization. 2017-12-28 11:44:02 -06:00
Gregory Nutt
66f632c3a3 arch/arm/src/lpc54xx: Add some Ethernet DMA initialization logic. 2017-12-27 13:54:59 -06:00
Gregory Nutt
cb9e1e7716 arch/arm/src/lpc54xx: Add some Ethernet PHY initialization logic. 2017-12-27 12:01:24 -06:00
Gregory Nutt
31330b2479 arch/arm/src/lpc54xx: Add a little -- very little -- Ethernet initialization logic. 2017-12-26 16:30:57 -06:00
Gregory Nutt
f5c5f89592 arch/arm/src/lpc54xx: Add (incomplete) Ethernet register definition file. Add framework for an Ethernet driver. Initial commit is just the drivers/skeleton.c with naming updated for the LPC54. 2017-12-26 12:55:58 -06:00
Gregory Nutt
edef041f93 arch/arm/src/lpc54xx: Add support for a random number generator. 2017-12-26 10:20:41 -06:00
Gregory Nutt
0b91074850 arch/arm/src/lpc54xx: Add an RTC driver and a RTC character driver lower half. configs/lpcxpresso-lpc54628: Add logic to register the RTC character driver if it is enabled. Enable the RTC and RTC character driver in the NSH configuration. 2017-12-25 13:56:06 -06:00
Gregory Nutt
7e7bdd181f Cosmetic fixes to comments, README, and other trivial corrections. 2017-12-25 10:45:47 -06:00
Gregory Nutt
458f9f4e67 arch/arm/src/lpc54xx: More WDT-related changes. 2017-12-24 15:40:46 -06:00
Gregory Nutt
3119629ff0 arch/arm/src/lpc54xx: Bring in WWDT driver from LPC43. 2017-12-24 15:00:20 -06:00
Gregory Nutt
382989a1b9 arch/arm/src/lpc54xx: DMA driver is code compelete. Untested and still needs more review. 2017-12-24 14:28:39 -06:00
Gregory Nutt
321c524c5f arch/arm/src/lpc54xx: Add DMA register definition file and skeletal DMA driver. The initial commit of the DMA driver is simply the LPC43xx GPDMA driver with name changes and all all register access removed. 2017-12-24 10:55:46 -06:00
Gregory Nutt
7ce881051a lpc43/lpc54 SDMMC: Add missing test for response errors in interrupt handler. 2017-12-23 18:13:53 -06:00
Gregory Nutt
0a5d9af33c lpc43/54 SDMMC: Remove some useless code. lpc54: Fix typos in the IOCON register definition file. Lpcxpresso-Lpc54628: Fix typols in board.h file 2017-12-23 14:25:21 -06:00
Gregory Nutt
b329b8c1e4 Squashed commit of the following:
lpc43/54 SDMMC:  Wading through bits trying to make sense out of what is a event want interrupt which deal mostly with commands+responses and what is a data transfer event.  DTO is the only wildcard.  I think this clear now but DMA transfers will fail with CRC error.
    lpc43/54 SDMMC:  DTO is a wait event, not a transfer event.
    lpc43/54 SDMMC:  Significant simplication to previous design.  More debug output.
    lpc43/54 SDMMC:  Don't allow duplicate events in waitmask and xfrmask.
    lpc43/54 SDMMC:  Not all interrupts were being disabled at the end of a transfer.
    lpc43/54 SDMMC:  Defer enabling DMA transfer interrupts until after command has been sent.
2017-12-23 11:42:04 -06:00
Gregory Nutt
6fa734457d lpc43/lpc54 SDMDC: Don't enable internal DMA in the control register if not doing internal DMA. Clear pending DMA-related interrupts before enabling them. 2017-12-22 15:16:14 -06:00
Gregory Nutt
1117a6e8ce Revert "lpc43xx and lpc54xx: No handling the wide bus MMC/SD interface correctly."
This reverts commit 4d6bf46480.
2017-12-22 14:39:59 -06:00
Gregory Nutt
9994bacf7e Revert "Fix some missing semicolons in conditional logic of last commit."
This reverts commit f0d36ebf1f.
2017-12-22 14:39:47 -06:00
Alan Carvalho de Assis
fa234a7026 configs/bambino-200e: Add LPC43 SDMMC board support to Bambino-200E and fix errors/warns 2017-12-22 12:30:36 -06:00
Gregory Nutt
f0d36ebf1f Fix some missing semicolons in conditional logic of last commit. 2017-12-22 12:28:17 -06:00
Gregory Nutt
4d6bf46480 lpc43xx and lpc54xx: No handling the wide bus MMC/SD interface correctly. 2017-12-22 11:59:45 -06:00
Gregory Nutt
bfb3eb38be LPC54/43: SDMMC driver: Need to disable DMA interrupts at completion of DMA. 2017-12-22 11:03:54 -06:00
Alan Carvalho de Assis
3ce21c5fe1 arch/arm/src/lpc43xx: Fix some small issues on LPC43 SDMMC driver 2017-12-22 10:23:09 -06:00
Gregory Nutt
6ed875a63b Leverage the LPC54xx back to the LPC43xx (where it came from originally)
Squashed commit of the following:

    arch/arm/src/lpc43xx:  SDMMC driver now builds for the LPC43 (provided that the proper definitions appear in the board.h file).
    arch/arm/src/lpc43xx:  Update basic changes to the ported lpc54xx driver for lpc43xx clocking and GPIOs.
    arch/arm/src/lpc43xx:  Brings in the LPC54xx SD/MMC driver with absolutely no changes other than changing all occurences of 54 to 43.
    arm/arm/src/lpc43xx:  Add build support for the lpc54 SDMMC driver.
    lpc54 SDMMC:  Check for successful data transfer last.  Checking first means that we miss errors.
2017-12-22 08:16:19 -06:00
Gregory Nutt
7add46bab5 lpc54 SDMMC. Some trivial naming improvements. 2017-12-22 07:19:13 -06:00
Michael Jung
cd48087c58 arch/arm/src/arm/up_cache.S: Fix cp15_invalidate_dcache. In cases where more than one dcache line was to be invalidated, a missing branch label would result in a false branch target into cp15_flush_idcache. Also the .size macro was fixed for both cp15_invalidate_dcache. 2017-12-22 06:54:37 -06:00
Gregory Nutt
c431177c0f LPC54xx: Update a README; fix a error in a DEBUGASSERTION in the SDMMC driver. 2017-12-21 12:19:15 -06:00
Gregory Nutt
d9f58fad39 Which these changes DMA now works on the LPC54xx
Squashed commit of the following:

    arch/arm/src/lpc54xx:  SDMMC fixes.. DMA should not be enabled on non-DMA transfers, the burst setting in FIFOTH is supposed to match the burst setting in the BMOD reseters, Add DMA error interrupt support.
    arch/arm/src/lpc54xx:  Mostly costmetic changes to the SDMMC driver.
2017-12-21 09:35:36 -06:00
Masayuki Ishikawa
4e64e6b3c3 Merged in masayuki2009/nuttx.nuttx/smp_fixes (pull request #561)
SMP fixes

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-12-21 12:31:04 +00:00
Gintaras Drukteinis
52fccefe4f arch/arm/src/lpc43xx: Add Windowed Watchdog Timer (WWDT) driver. Tested on LPC4357 but should be
compatible for all LPC43xx MCUs.
2017-12-21 06:23:48 -06:00
Masatoshi.Tateishi
5414d68161 arch/arm/src/lc823450: Add SP_DMB() into lc823450_testset.c
In lc823450, ldrex and strex are not supported. So we implemented
up_testset() with H/W Mutex. However, there was a bug in memory
access order. This change ensures correct memory access order in
up_testset() for lc823450.

Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>
2017-12-21 17:39:19 +09:00
Gregory Nutt
b26c70b11f arch/arm/src/lkpc54xx: In SDMMC driver, fix an error which was clobbering the interrupt mask register (xfrmask). Also, add a kludge for the missing DTO interrupt. 2017-12-20 18:39:10 -06:00
Gregory Nutt
eef12f1f91 arch/arm/src/lpc54xx: In SDMMC driver, add logic to transfer data when TXDR or RXDR interrupts occur. Also, add logic to set the RX watermark to 2 when receiving short, non-DMA data transfers. 2017-12-20 17:27:52 -06:00
Gregory Nutt
8938550072 arch/arm/src/lpc54xx: In SDMMC driver, don't do DMA if the entire transfer will fit in the FIFO. 2017-12-20 14:38:09 -06:00
Gregory Nutt
96e6835793 arch/arm/sr/lpc54xx: Add support for power pin to SDMMC driver. Some fixes from initial testing. 2017-12-20 13:42:57 -06:00
Gregory Nutt
31db67cad7 arch/arm/src/lpc54xx: SDMMC pin configurations should have SLEW on and FILTER off. 2017-12-20 11:47:30 -06:00
Gregory Nutt
c867d42018 arch/arm/src/lpc54xx: Add support for card detect and write protect to SDMMC driver. configs/lpcxpresso-lpc54628: Add logic to bring up SDMMC. 2017-12-20 10:52:05 -06:00
Masayuki Ishikawa
c2e50351e4 Merged in masayuki2009/nuttx.nuttx/lc823450_http_streaming (pull request #560)
lc823450 http streaming

* arch/arm/src/lc823450: Use spinlock APIs in lc823450_gpio.c

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Add a warning message in up_ack_irq()

    In SMP mode, H/W interrupts should be handled on CPU0 to avoid deadlocks.

    Other changes:
    Fix a potential race condition in up_enable_irq()
    Use spinlock APIs instead of critical section APIs.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Enable HRT_TIMER in lc823450_timerisr.c

    Other changes:
    Fix style violations and call up_enable_irq() to assign CPU0 for IRQ handling.
    Use spinlock APIs instead of critical section APIs.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Fix race conditions in dma/usbdev.

    In SMP mode, critical data must be protected explicitly.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Update README.txt

    Add notes on .gdbinit and networking. Update comments on SMP.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Update defconfigs

    Enable HRT_TIMER, LC823450_MTM0_TICK, SPINLOCK_IRQ
    Enable NET_TCP_RWND_CONTROL, NXPLAYER_HTTP_STREAMING_SUPPORT (rndis only)

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-12-20 13:33:06 +00:00
Gregory Nutt
793c8b785a arch/arm/src/lpc54: Missed a change in the last commit 2017-12-19 15:11:22 -06:00
Gregory Nutt
321a7a64af arch/arm/src/lpc54xx and configs/lpcxpresso-lpc54628: Correct some SD/MMC clock divider logic. 2017-12-19 14:05:36 -06:00
Gregory Nutt
93b28017ab arch/arm/src/lpc54xx: Make the SPI driver selections EXPERIMENTAL since the SPI peripherals are not fully implemented. 2017-12-19 13:09:15 -06:00
Gregory Nutt
a8933f96bd configs/lpcxpresso-lpc54628: Fix SD/MMC clock divisor. 2017-12-19 12:43:44 -06:00
Gregory Nutt
ba1301a43a arch/arm/src/lpc54xx: Make the SDMCC driver selection EXPERIMENTAL since it has not yet been verified. 2017-12-19 12:23:37 -06:00
Gregory Nutt
5a66684293 Squashed commit of the following:
arch/arm/src/lpc54xx:  Adds the LPC54-specific clock configuration logic to the leveraged SD/MMC driver.
    arch/arm/src/lpc54xx:  Leveraged SD/MMC driver builds without error but is still missing clock configuration logic.
    arch/arm/src/lpc54xx:  Bring in LPC43xx SD/MMC driver from https://github.com/Smoothieware/smoothie-nuttx/tree/master/nuttx/arch/arm/src/lpc43xx
2017-12-19 12:09:22 -06:00
Gregory Nutt
c17651e26e arch/arm/include/lpc54xx: Add SD/MMC header file. 2017-12-19 09:12:42 -06:00
Gregory Nutt
a0004173d4 arch/arm/src/a1x: Fix a compile error introduce in recent commit. 2017-12-18 09:00:41 -06:00
Gregory Nutt
9dd5196741 arch/arm/src/a1x, kl, lpc11xx, lpc31xx, and nuc1xx: Fix some compile warnings that I introduced with a possibly overzealous recent change. 2017-12-17 18:12:19 -06:00
Gregory Nutt
b7391ec599 arch/arm/src/sama5 and samdl: Fix some compile warnings that I introduced with a possibly overzealous recent change. 2017-12-17 17:50:31 -06:00
Gregory Nutt
91f48701ae arch/arm/src/sam34: Fix some compile warnings that I introduced with a possibly overzealous recent change. 2017-12-17 17:43:20 -06:00
Gregory Nutt
7ca9e8c376 Eliminate another warning. 2017-12-17 16:51:20 -06:00
Gregory Nutt
0e6e05bf11 arch/arm/src/kinetis: Fix some compile warnings that I introduced with a possibly overzealous recent change. 2017-12-17 16:26:03 -06:00
Gregory Nutt
87252297d6 arch/arm/src/: Fix a error in last commit that was cloned in three places. 2017-12-17 14:38:20 -06:00
Gregory Nutt
b8ea9e9c64 arch/arm/src/lpc17xx, lpc43xx, and stm32: Fix some compile warnings that I introduced with a possibly overzealous recent change. 2017-12-17 14:29:55 -06:00
Gregory Nutt
664484bf5b configs/indium/include/board.h: Remove extra endif 2017-12-16 19:29:58 -06:00
Gregory Nutt
3dfe0f309c arch/arm/src/lpc54xx: Add WWDT header file. 2017-12-16 17:50:59 -06:00
Gregory Nutt
de4fc5864f arch/arm/src/lpc54xx: Fix some GPIO interrupt configuration errors. Add logic to acknowledge rising/falling edge events. config/lpcxpresso-lpc545628: Add an intermediate interrupt handler to support acknowledgement of rising and falling edge interrupts. 2017-12-16 15:34:41 -06:00
Gregory Nutt
5a12079e53 arch/arm/src/lpc54xx: Implement GPIO interrupt support. configs/lpcxpress-lpc54628: Add support for the USER button. Enable the apps/examples/button test in the NSH configuration. 2017-12-16 13:00:06 -06:00
Bob Feretich
83b382e906 arch/arm/src/stm32f7: Completes support for the STM32F72x/73x family. 2017-12-16 08:01:57 -06:00
Gregory Nutt
4c72f57273 arch/arm/src/lpc54xx: I2C now appears to be functional. Needs more testing. 2017-12-15 14:58:37 -06:00
Gregory Nutt
c8a8eb028f arch/arm/src/lpc54xx: Complete coding of the I2C driver. It is not yet functional and has not yet been seriously tested. config/lpcxpresso-lpc54628: Add support for I2C2 and for the I2C tool to the nsh configuration. 2017-12-15 11:38:55 -06:00
Gregory Nutt
9638f3f065 fs/fat: CONFIG_FAT_MAXFNAME may not exceed NAME_MAX (CONFIG_NAME_MAX) 2017-12-15 06:19:14 -06:00
Gregory Nutt
eed14e5eb1 arch/arm/src/lpc43xx: Add I2C stop logic. 2017-12-14 18:06:40 -06:00
Gregory Nutt
c50b4f5504 arch/arm/src/lpc43xx: Add helper macros to simplify peripheral configuration for new drivers; rename some other helper macros to make their operation clearer. Begin fleshing out the I2C driver. 2017-12-14 17:29:15 -06:00
Gregory Nutt
c53d88c75c Squashed commit of the following:
arch/arm/src/lpc54xx:  LCD.. Fix some miconceptions about how the video address lines are used.
    arch/arm/src/lpc54xx:  Fix some LCD BPP and BRG vs RGB settings.
2017-12-14 10:45:53 -06:00
Gintaras Drukteinis
1fbf788555 arch/arm/src/lpc43xx: Adapt LPC176x RTC driver for the LPC43xx. 2017-12-14 07:03:46 -06:00
Gregory Nutt
43a88c1428 arch/arm/src/lpc54xx: Fix some LCD clocking. This eliminates the hang problem. That is now recognizable albeit corrupted data on the display. 2017-12-13 19:07:10 -06:00
Gregory Nutt
d93a2d4f39 arch/arm/src/lpc54xx: Add reset logic. Some changes while debugging LDC. Does not yet work (hangs). 2017-12-13 14:36:58 -06:00
Gregory Nutt
f215660296 configs/lpcxpresso-lpc54628: Add the fb configuration testing the LCD. arch/arm/src/lpc54xx: Various fixes needed to get the fb configuration to build errorfree. The configuration is not functional as of this writing. 2017-12-13 09:18:16 -06:00
Gregory Nutt
48879933a9 arch/arm/src/lpc54xx: Correct some confusion about how the LCD data pins are configured. 2017-12-12 14:10:40 -06:00
Gregory Nutt
b33d7eb59f arch/arm/src/lpc54xx: Add the ported LPC1788 LCD driver to use the LPC54xx pin definitions and SYSCON. 2017-12-12 12:53:33 -06:00
Gregory Nutt
88834b6e50 arch/arm/src/lpc54xx: Add configuartion support and logic it all none, some, or all of the external RAM to the system heap. 2017-12-12 11:33:18 -06:00
Gregory Nutt
63415f9fb1 arch/arm/src/lpc54xx: Clone the LPC1788 LCD driver. The LPC54628 LCD interface is identical. The initial commit is a brute force clone. It still needs review to make sure the LDC is appropriately enabled in the SYSCON and that clocking is provided. Also, extend the SPI 'skeleton' file so that has a place to support for SPI DMA and the SPI exchange method. 2017-12-12 10:13:21 -06:00
Gregory Nutt
0cd87be495 arch/arm/src/lpc54xx: Correct the EMC divider register definition and one typo in the SDRAM setup. SDRAM is not fully functional on this board! 2017-12-12 08:24:57 -06:00
Gregory Nutt
d51554c101 arch/arm/src/lpc54xx: Costmetic. 2017-12-11 15:04:51 -06:00
Gregory Nutt
d74d9be429 arch/arm/src/lpc54xx: Add fragmenenty skeleon of SPI driver just as a starting point. 2017-12-11 14:50:54 -06:00
Gregory Nutt
11ca2c3847 arch/arm/src/lpc54xx: Rename I2C and SPI configurations to make room in the namespace for future slave support. Add fragmenenty skeleon of I2C driver just as a starting point. 2017-12-11 13:28:55 -06:00
Gregory Nutt
5854a1cd37 arch/arm/src/lpc54xx/chip: Add framework that will eventually support I2C and SPI. 2017-12-11 10:40:45 -06:00
Gregory Nutt
0508048291 configs/lpcxpresso-lp54629: Add logic to configure EMC pins. arch/arm/src/lpc54xx: Correct GPIO read/write logic. Update pin configuration for EMC pins. All should have the input file offset and fast slew rate. 2017-12-11 09:07:51 -06:00
Gregory Nutt
df3404da09 arch/arm/src/lpc54xx: Various fixes for initial build of SDRAM support. Still unverified (but at least appears to be nonfatal). 2017-12-10 17:20:16 -06:00
Gregory Nutt
1f6dfc6351 arch/arm/src/lpc54xx: Bring in NXP support for external SRAM. 2017-12-10 16:52:15 -06:00
Gregory Nutt
dab97de4ea arch/arm/src/lpc54xx: Bring in NXP support for external SDRAM. 2017-12-10 16:07:30 -06:00
Gregory Nutt
77728f49f1 arch/arm/src/lpc54xx: Add EMC register definitions. Add basic build support for EMC and SDRAM. 2017-12-10 12:40:01 -06:00
Gregory Nutt
66ee22f363 arch/arm/src/lpc54628: With these changes, the LPCXpresso-LPC54628 NSH configuration is fully functional. Also adds a README file for the board. 2017-12-10 08:54:24 -06:00
Gregory Nutt
187747d2e5 arch/arm/src/lpc54xx: Add DMA register definition header file. 2017-12-09 15:24:21 -06:00
Gregory Nutt
9bc3c04eaf /arch/arm/src/lpc54xx: Add input mux header files. 2017-12-09 11:15:44 -06:00
Gregory Nutt
4bc7b966f4 /arch/arm/src/lpc54xx: Add some GPIO pin interrupt header files (still missing one). Also add a file that was missing in previous commit. 2017-12-09 10:12:40 -06:00
Gregory Nutt
52f9128562 arch/arm/src/lpc54xx: Add USART pin configuration. Need enable IOCON and GPIO clocking. 2017-12-09 09:11:17 -06:00
Gregory Nutt
246a97008e arch/arm/src/lpc54xx: Minor updates from review of recent changes 2017-12-08 17:32:31 -06:00
Gregory Nutt
89c21dbf05 arch/arm/src/lpc54xx/chip: Add pin multiplexing definition head file. 2017-12-08 16:11:05 -06:00
Alan Carvalho de Assis
a2462b9b1a arch/arm/src/xmc4: Only setup USB clock when USB PLL is enabled 2017-12-08 13:16:55 -06:00
Gregory Nutt
da6c604ed1 Squashed commit of the following:
configs/lpcxpresso-lpc54628:  Add support for on-board LEDs.
    arch/arm/src/lpc54xx:  Add support for GPIO/Peripheral pin configuration.
    arch/arm/src/lpc54xx/chip:  Add IOCON register definition file.
    arch/arm/src/lpc54xx:  Add GPIO and (incomplete) PINT register definition header files.
2017-12-08 13:12:07 -06:00
Masayuki Ishikawa
ab96e3fdc7 Merged in masayuki2009/nuttx.nuttx/lc823450_smp_improvement (pull request #554)
lc823450 smp improvement

* arch/arm/src/common: Apply irq_spin APIs to modifyregXX

    Replace enter_critical_section with spin_lock_irqsave.
    Replace leave_critical_section with spin_unlock_irqrestore.

    Please see 6150299f54 as well.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Do not use modifyreg32() to enable Mutex.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Modify IRQ control for i2s

    Interrupt will be handled on CPU0 with this change.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Apply irq_spin APIs to dma/syscontrol/usbdev.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Assign CPU1 to lpwork

    This change will improve load balancing for networking with RNDIS.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* drivers/audio/wm8776.c: Improve stability in SMP mode

    Apply irq_spin APIs to improbe performance.
    Repeat to process a message to avoid deadlock.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Enable SPINLOCK_IRQ and NXPLAYER in rndis

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-12-08 12:31:34 +00:00
Gregory Nutt
8bc90a1899 This adds basic architectural support for the LPC546xx family and includes support for the LPCXpresso-LPC54628 board. The basic NSH port is almost complete... still lacking GPIO support and LED support. There are still no significant drivers available.
Squashed commit of the following:

    arch/arm/src/lpc54xx:  Finish off some missing logic.  Complete now execpt for GPIO and LED support.
    arch/arm/src/lpc54xx:  Add lpc54_clrpend.c
    arch/arm/src/lpc54xx:  Serial driver is complete and compiles.
    arch/arm/src/lpc54xx:  Add beginning of a serial driver (still missing some logic)
    arch/arm/src/lpc54xx:  Fleshes out low level USART intialization.
    arch/arm/src/lpc546xx/Kconfig: Add hooks to integrate with common seril upper half.
    arch/arm/src/lpc54xx:  Beginning of USART console support.
    arch/arm/src/lpc54xx: Completes very basic clock configuration.
    arch/arm/src/lpc54xx:  Add clocking logic (still not complete)
    arch/arm/src/lpc54xx:  Beginning of PLL configuration logic.
    arch/arm/src/lpc54xx:  Fix a few things from first compile attempt.  Compilation cannot work until I at least finish the clock configuration logic.
    arch/arm/src/lpc54xx: Addes some SysTick logic.
    arch/arm/src/lpc54xx:  Completes basic startup logic (sans clock configuration) and interrupt configuration.
     arch/arm/src/lpc54xx:  Add generic ARMv7-M start-up logic (needs LPC54628 customizations); add emtpy file that will eventually hold the clock configuration logic.
    arch/arm/src/lpc54xx:  Add (incomplete) SYSCON register definition header file.
    arch/arm/src/lpc54xx:  Add FLEXCOMM header file.
    arch/arm/src/lpc54xx:  Bring in tickless clock logic from LPC43; configs/lpcxpresso-lpc54628: mount procfs if enabled.
    arch/arm/src/lpc54xx: Add RIT clock definitions; add SysTick initialization (not finished)
    LPC54xx and LPCXpresso-LPC54628: add more boilerplate files and stubbed out files.
    arch/arm/src/lpc54xx:  Add (incomplete) USART header file.
    Add another condition to a Kconfig; refresh a defconfig.
    arch/arm/src/lpc54xx/chip: Add LPC54628 memory map header files.
    configs/lpcxpresso-lpc54628:  Add basic build files for the LPCXpresso-LPC54628
    arch/: Basic build directory structure for the LPC54628
2017-12-07 13:30:02 -06:00
Gregory Nutt
ba64499bc7 Triva fix of typos in comments. 2017-12-07 11:11:21 -06:00
Gregory Nutt
d540f3fd60 Costmetic update to comments and README. 2017-12-02 11:14:32 -06:00
Alan Carvalho de Assis
7311b132a1 arch/arm/src/xmc4/Kconfig: Define user friend SPI alias to follow other arch names
arch/arm/src/xmc4/Kconfig: Define user friend I2C alias to follow other arch names
arch/arm/src/xmc4/Kconfig: Define user friend LIN alias to follow other arch names
arch/arm/src/xmc4/Kconfig: Define user friend I2S alias to follow other arch names
2017-11-30 12:48:07 -06:00
Gregory Nutt
4eda9e92de arch/arm/src/lpc32xx: lpc32_adc.c was being selected by the build system wehn DAC was selected. 2017-11-27 10:12:03 -06:00
Masayuki Ishikawa
fb49472ec8 Merged in masayuki2009/nuttx.nuttx/lc823450_smp_audio (pull request #547)
lc823450 smp audio

* arch/arm/src/lc823450: Remove a workaround in up_cpu_paused()

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Introduce g_gpio_lock to improve write performance in SMP mode.

    NOTE: This is a tentative solution and should be replaced with more generic one.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Add a workaround in up_txready() to avoid data corruption.

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Enable CONFIG_SMP for audio

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Update README.txt regarding SMP audio

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-27 07:20:54 +00:00
Gregory Nutt
318dd06f8b arch/arm/src/stm32: Fix compile error when trace is enabled. I2CEVENT_ERROR was used but never defined. 2017-11-26 06:51:12 -06:00
Gregory Nutt
5328e3bafb configs/: CONFIG_QENCODER was renamed to CONFIG_SENSORS_QENCODER: update occurrences in several Kconfig files 2017-11-25 18:46:43 -06:00
Alan Carvalho de Assis
674b331f03 arm/src/xmc4: Include Alt. Interrupt Enable to RX_EVENTS and rename serial GPIO configurations. 2017-11-25 18:13:23 -06:00
Gregory Nutt
4404be23cb XMC4 Serial: The Alternative Receive Interrupt was not being configured. 2017-11-25 12:21:33 -06:00
Gregory Nutt
776b65bc90 Revert "arch/arm/src/xmc4: Serial fix... Cannot use SR1 for RXD. It will not work on this hardware. This means that no more than on UART can be configured per USIC."
This reverts commit 88982df09c.
2017-11-25 09:45:12 -06:00
Gregory Nutt
3160613db4 Revert "arch/arm/src/xmc4/xmc4_config.h: Add a check to doubly enforce the one UART per USIC rule."
This reverts commit 63026b789b.
2017-11-25 09:44:51 -06:00
Gregory Nutt
63026b789b arch/arm/src/xmc4/xmc4_config.h: Add a check to doubly enforce the one UART per USIC rule. 2017-11-25 08:41:47 -06:00
Gregory Nutt
88982df09c arch/arm/src/xmc4: Serial fix... Cannot use SR1 for RXD. It will not work on this hardware. This means that no more than on UART can be configured per USIC. 2017-11-25 08:19:43 -06:00
Alan Carvalho de Assis
639f77341a arch/arm/src/xmc4: Remove hard-coded values in clock configuration. USB will be fixed later. 2017-11-25 06:39:44 -06:00
Alan Carvalho de Assis
0ac8ac240a arch/arm/src/xmc4: Do not run at 144MHz unless BOARD_FCPU_144MHZ is selected in the board.h header file. 2017-11-24 12:47:47 -06:00
Gregory Nutt
37a9808dc9 Cosmetic fix to some alignment. 2017-11-24 08:34:39 -06:00
Gregory Nutt
a197676006 Fix typos in some comments. 2017-11-23 14:21:57 -06:00
Gregory Nutt
d1e234e179 STM32: Remove usb_dumpbuffer() macro from OTGFS device. It cannot be controlled via Kconfig and therefore will not be supported. 2017-11-23 06:37:21 -06:00
Gregory Nutt
cbfaca8a14 STM32 L4 USB OTGFS: Remove dumpbuffer feature added in the last commit. I don't want in features that cannot be controlled be via Kconfig files and I do not accept debug code in the upstream GIT. My mistake for merging it in the first place. 2017-11-22 13:26:15 -06:00
raiden00pl
83699beb10 stm32f33xxx_rcc: fix CAN clock enable 2017-11-22 09:26:07 +01:00
Gregory Nutt
c52fab653d Replicate Jussi Kivilinna's change for the newly added STM32F2xx and F3xx family members. This change allows selecting voltage output scale mode and enable over-drive only when needed. 2017-11-21 06:44:19 -06:00
Jussi Kivilinna
88cf9cf133 Two changes for STM32F7.
1) The first enables building with CONFIG_ARCH_IDLE_CUSTOM enabled.
2) The second allows changing voltage output scaling setting and prevents enabling over-drive mode for low frequencies (STM32 F74xx, 75xx, 76xx, 77xx)
2017-11-21 06:42:04 -06:00
Miha Vrhovnik
8bb54368c8 Various fixes for errors ound while debugging OTG on L496
STM32, STM32 L4, and STM32 M4: USB OTGFS DMA trace output fix
STM32: Add dump buffer feature to stm32 F4 series
STM32 and STM32 L4: Fix bad USB OTGFS register address
STM32 L4:  Fix typo in USB OTGFS register usage
STM32 L4:  Add check in USB OTGFS driver to assure that SYSCFG is enabled
Nucleo-L496ZG:  Make HSE on Nucleo-L496ZG default to enable USB
2017-11-21 06:32:53 -06:00
Alan Carvalho de Assis
41b89e1bb4 arch/arm/src/xmc4 UART: Enable RX/TX status and small fixes 2017-11-21 06:11:35 -06:00
Alan Carvalho de Assis
c117cdcf6b arch/arm/src/xmc4:xmc4_uart_configure() expects the channel# not uartbase as an input parameter. 2017-11-20 07:00:23 -06:00
Gregory Nutt
40b8cbb8dc Eliminate some warnings. 2017-11-18 12:29:34 -06:00
Bob Feretich
fab5faf097 STM32F7: Completes architecture support for the STM32 F72x and F73x families. Adds support for the Nucleo-144 boards with STM32F722. 2017-11-18 07:55:50 -06:00
Bob Feretich
d7bb824c69 stm32f7: Fix typos in two RCC register definition header files 2017-11-17 07:26:05 -06:00
Bob Feretich
13b52da3fa stm32 f72xx and f73xx: Add register definition header files and clocking logic 2017-11-17 07:18:02 -06:00
Alan Carvalho de Assis
fcb5129567 arch/arm/src/xmc4: Kconfig was not selecting XMC4_USIC for USIC1. 2017-11-16 13:51:17 -06:00
Alan Carvalho de Assis
ab7dfd75b5 arch/arm/src/xmc4: Fix XMC4xxx USIC UART sginal to be high level when in idle 2017-11-16 11:23:19 -06:00
Alexander Vasiljev
1fc3b47565 arch/arm/src/lpc43: Correct a typo in Kconfig. 2017-11-15 08:16:53 -06:00
Alexander Vasiljev
ac3884498f arch/arm/src/lpc43: UART_RX pins should be configured with input buffers enabled. Otherwise it cannot be read. 2017-11-15 07:54:09 -06:00
Alexander Vasiljev
485f0ebd40 arch/arm/src/lpc43: Add LPC43xx CAN driver 2017-11-15 07:54:09 -06:00
Gregory Nutt
62b8026976 Remove CONFIG_GRAN_SINGLE. It adds no technical benefit (other than some minor reduction in the number of interface arguments) but adds a lot of code complexity. Better without it. 2017-11-14 11:47:12 -06:00
Gregory Nutt
102f1ea33f Minor cleanup of some spacing. 2017-11-13 14:06:03 -06:00
Anthony Merlino
ea795c8cca SAMA5/SAMv7: It is necessary to disable pre-emption and interrupts around a loop that copies TX data into the hardware in order to avoid a TX data underrun condition. 2017-11-13 10:38:23 -06:00
Gregory Nutt
f3b37e5da3 fs/procfs/fs_procfsprogrem: Add /proc/progmem. This is an alternative way to get the information that was previoulsy available in apps/system/free. apps/system/free was removed beause it made illegal calls into the OS violating the portable interface. This new procfs entry provides the same information with no such violation. 2017-11-13 09:08:39 -06:00
Gregory Nutt
692ebdf9d4 arch/arm/src/stm32/stm32f33xx_adc.c: Eliminate warnings about cj_channels and j_chanlist being set but not used. 2017-11-12 10:17:10 -06:00
Jussi Kivilinna
585b04014f Merged in jussi_kivilinna/nuttx/stm32l4_serial_pm (pull request #534)
STM32L4 serial PM interface improvements

* stm32l4_serial: pm: check rx/tx buffers for pending data in pmprepare

* stm32l4: remove adhoc PM interfaces and move serial suspend functionality behind CONFIG_PM

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-10 13:05:00 +00:00
Masayuki Ishikawa
da78c18397 Merged in masayuki2009/nuttx.nuttx/lc823450_autoled (pull request #532)
lc823450 auto LED support

* arch/arm/src/lc823450: Add auto LED for CPU activity

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Add auto LED support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-09 11:36:33 +00:00
Jussi Kivilinna
c8797dbabc STM32 L4: Build stm32l4_idle.c only if CONFIG_ARCH_IDLE_CUSTOM is not enabled 2017-11-08 13:07:15 -06:00
Jussi Kivilinna
4ca07231ae stm32l4_rcc: restore backup-registers after backup-domain reset. 2017-11-08 13:05:56 -06:00
Gregory Nutt
349b513978 Very trivial changes from review of last PR 2017-11-08 06:34:23 -06:00
Masayuki Ishikawa
51b19d5f38 Merged in masayuki2009/nuttx.nuttx/lc823450 (pull request #531)
lc823450-xgevk audio support

* arch/arm/src/lc823450: Add IPL2 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Add IPL2 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* libc/audio: Fix compilation error in lib_buffer.c

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* drivers/audio: Add WM8774 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* arch/arm/src/lc823450: Add I2S support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Add WM8774 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-08 12:25:13 +00:00
Gregory Nutt
b076ff36cb Update NxWidgets version number 2017-11-07 13:20:03 -06:00
Masayuki Ishikawa
56eac96d2f Merged in masayuki2009/nuttx.nuttx/lc823450 (pull request #530)
Add IPL2 support for LC823450

* arch/arm/src/lc823450: Add IPL2 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

* configs/lc823450-xgevk: Add IPL2 support

    Signed-off-by: Masayuki Ishikawa <Masayuki.Ishikawa@jp.sony.com>

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-07 12:34:23 +00:00
Gregory Nutt
2a331b7f23 Fix some includes missed in the last commit. 2017-11-06 15:01:21 -06:00
Gregory Nutt
a14eb93ae7 lpc43xx Ethernet: Fix some backward logic setting full-duplex and 100mbps when autoconfiguration is disabled. Noted by Anonymous in Issue #76 2017-11-06 13:28:29 -06:00
Gregory Nutt
08fa834a6a arch/arm/include/stm32 and stm32f7: Remove ltdc.h and dma2d.h. Those header files in that location permitted inclusion into application space logic and, hence, facilitated and encouraged calling into the OS and violating the portable POSIX OS interface. The definitions in those header files were move the appropriate location in the counterpart, architecture specific files at arch/arm/src/stm32 and stm32f7 dma2d.h and ltdc.h.
configs/stm32f429i-disco/ltdc:  This configuration has been deleted because it violated the portable POSIX OS interface.  It used apps/examples/ltdc and include ltdc.h and dma2d.h which were also removed for the same reason.
2017-11-06 12:22:48 -06:00
Mateusz Szafoni
2fc5237854 Merged in raiden00/nuttx (pull request #529)
Master

* cosmetics

* stm32_hrtim: add helper macros

* smps: cosmetics

* stm32f33xxx_adc: injected channels support, fix some definitions, add interface to disable interrupts

* stm32f334-dsico: beginning of lower-half driver for SMPS (buck-boost onboard converter)

* nucleo-f334r8/highpri: missing ADC trigger configuration

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-11-05 14:15:04 +00:00
Gregory Nutt
6e9039bb08 Squashed commit of the following:
fs/userfs:  This completes coding of the UserFS client and of the UserFS feature in general.  This feature is being merged to main now because I believe it is innocuous.  It is, however, untesed.  The next step will be to develop a test case to verify the feature.
    fs/userfs:  Completes the request logic for the UserFS client.  Still need the logic that receives the responses.
    fs/userfs:  Completes coding for most of the server side of the user filesystem logic.
    fs/userfs:  Big design changes, simplications. Use Unix domain local sockets instead of message queues.  Easier to transfer big data in local sockets than message queues.  Remove character drvier 'factory' it is not necessary.
    fs/userfs:  Minor reparitioning; volume private info does not need to be held on the OS client side.
    libc/userfs:  Add some of the server side logic.
    fs/userfs:  Add some UserFS initialization logic.
    fs/userfs:  Add frame work for the UserFS proxy.  Remove all references to a block driver.  There is no block dricer... what was I thinking?
    fs/userfs: Add some initialization of the character driver, 'factory' device.
    fs/userfs:  Rename from fusefs to userfs to that we don't stomp on someone else's cool name.
    Add a header file describing the fusefs interface.
2017-10-30 18:07:42 -06:00
Dmitriy Linikov
ef1ca963a5 Merged in hardlulz/modem-3.0-nuttx/fix-stm32_dmacapable-on-f20xx (pull request #522)
Fix stm32 dmacapable on f20xx

* Fixed build for STM32F20XX platforms when CONFIG_STM32_DMACAPABLE is enabled

* Fixed build for STM32F20XX platforms when CONFIG_STM32_DMACAPABLE is enabled

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-30 19:20:52 +00:00
Dmitriy Linikov
73082f7513 STM32 ADC: Added support for ADC's IO_ENABLE_TEMPER_VOLT_CH ioctl on STM32F10XX and STM32F20XX 2017-10-30 06:21:48 -06:00
Mateusz Szafoni
e3bb78a881 Merged in raiden00/nuttx (pull request #520)
Master

* stm32: add ADC DMA support to STM32F33 configuration

* stm32f33xxx_adc.c: fix compilation if no DMA

* nucleo-f334r8: eliminate warning

* nucleo-f334r8: add highpri example configuration

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-28 14:29:07 +00:00
Jussi Kivilinna
bcf4a5d056 Merged in jussi_kivilinna/nuttx/stm32l4_i2c_rewrite (pull request #519)
Port STM32F7 I2C driver to STM32L4

* arch/stm32l4: port STM32F7 I2C driver to STM32L4

    STM32L4 I2C driver is in work-in-progress state (plentiful of
    TODOs and #warnings) and lags many features found in more
    up-to-date STM32 I2C drivers. The peripheral on STM32F7 and
    STM32L4 are identical except for L4's 'wakeup from stop mode'
    flag and STM32F7's I2C driver is in more 'ready to use' state.

    Patch ports the STM32F7 I2C driver to STM32L4. The I2C clock
    configuration is kept the same as before (I2CCLK = PCLK1 80 Mhz)
    instead of switching to STM32F7 arch default that is I2CCLK=HSI.
    Further work would be to add configuration option for choosing
    I2C clock source instead of current hard-coded default.

* arch/arm/stm32f7: i2c: restore bus frequency after I2C reset

    Copy frequency restoration fix from STM32L4 I2C driver to STM32F7 I2C driver.

* arch/arm/stm32f7: i2c: remove unused Kconfig option

* configs/nucleo-l496zg/nsh: enable I2C4 bus with i2ctool

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-26 13:59:20 +00:00
Jussi Kivilinna
45fdad5055 arch/arm/common/up_checkstack: fix assert panic when both TLS and interrupt stack are enable 2017-10-23 12:02:20 -06:00
Mateusz Szafoni
9105ac3e98 Merged in raiden00/nuttx (pull request #516)
Master

* stm32_hrtim: fix warnings related with RCC

* stm32f33xxx_adc: add some publicly visable interfaces and some code to support injected channels

* stm32f33xxx_dma: add public interface to handle with DMA interrupts

* stm32_hrtim: change some names and add some coments

* chip/stm32f33xxx_adc.h: cosmetics

* nucleo-f334r8: add logic for zero latency high priority interrupts example

* stm32: update some ADC-related configuration in Kconfig

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-22 15:46:13 +00:00
Mateusz Szafoni
704ad2faeb Merged in raiden00/nuttx (pull request #515)
stm32_adc.c: clear pending interrupts

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-20 17:15:48 +00:00
Juha Niskanen
9653255cff Merged in juniskane/nuttx_stm32l4/stm32l1_stm32l4_rtc_update_pr (pull request #514)
STM32L1, STM32L4 RTC: add periodic interrupts, update L1 RTC implementation

* STM32L4 RTC: add support experimental CONFIG_RTC_PERIODIC

* STM32 RTC: separate STM32L1 RTC into a separate file

    STM32L1 RTC is very close to F4 or L4 versions, with two alarms
    and periodic wakeup support so backported L4 peripheral to L1.

* RTC: add periodic alarms to upper and lower halves

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-20 17:15:17 +00:00
Jussi Kivilinna
b87739d174 arch/arm/src/stm32f7/i2c: fix I2C_M_NORESTART handling 2017-10-20 08:41:42 -06:00
Mateusz Szafoni
09f3e9ce5c Merged in raiden00/nuttx (pull request #513)
Master

* stm32f33xxx_adc.c: fix some warnings and compilation error when extsel not in use

* nucleo-f334r8/adc: change serial console to USART2 (STLINK COM)

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2017-10-19 20:07:04 +00:00
Gregory Nutt
ffca71b9bf Alexey T, Bitbuck Issue 73:
Lower part of STM32 CAN driver arch/arm/src/stm32/stm32_can.c uses all three hw tx mailboxes and clears TXFP bit in the CAN_MCR register (it means transmission order is defined by identifier and mailbox number).

This creates situation when order frames are put in upper part of CAN driver (via can_write) and order frames are sent on bus can be different (and I experience this in wild).

Since CAN driver API pretends to be "file like" I expect data to be read from fd the same order it is written. So I consider described behaviour to be a bug.

I propose either to set TXFP bit in the CAN_MCR register (FIFO transmit order) or to use only one mailbox.
2017-10-19 06:34:54 -06:00
Gregory Nutt
9b5f56ba5b BCM2708: The PiZero configuration now compiles and links cleanly. Still a few thngs missing internally. 2017-10-18 14:07:52 -06:00
Gregory Nutt
e18e8573d1 BCM2708: Allow pass parameters with AUX interrupts; Add mini-UART break capability. 2017-10-18 13:57:54 -06:00
Gregory Nutt
bcff0543f9 BCM2708: Add a little more Mini-UART logic. Still missing UART configuration logic. 2017-10-18 13:44:32 -06:00
Gregory Nutt
6235e72ce0 BCM2708: Add a little more Mini-UART logic. Still missing UART configuration logic. 2017-10-18 12:50:56 -06:00
Gregory Nutt
25079a9c93 BCM2708: Fleshes out GPIO interrupt logic. 2017-10-18 10:13:10 -06:00
Gregory Nutt
63b93a9fba BCM2708: Add framework for a Mini-UART driver (incomplete) 2017-10-18 09:17:08 -06:00
Gregory Nutt
3316103efd BCM2708: Add hooks to support both Mini- and PL011 UARTs. 2017-10-18 08:09:24 -06:00
Gregory Nutt
477a8d1aa7 BCM2708: Add support for AUX interrupts. 2017-10-17 17:08:54 -06:00