Commit Graph

13876 Commits

Author SHA1 Message Date
Alan Carvalho de Assis 3b74f80981 arch/arm/src/xmc4: Add SPI support for Infineon XMC45xx microcontroller 2018-04-14 12:19:47 -06:00
Gregory Nutt 5d2c226675 wireless/bluetooth and drivers/wireless/bluetooth: Simply the driver registration/initialization interface. 2018-04-14 11:33:29 -06:00
Gregory Nutt a374c9daf8 arch/arm/src/stm32: In HCI UART driver, need to disable Tx interrupts after frame sent. Otherwise, we get infinite Tx interrupts. 2018-04-14 10:04:21 -06:00
Gregory Nutt fa287e8863 Various fixes/changes from intial testing of the HCI UART on the STM32F4-Discovery board. Re-organized how the Blutetooth network driver is initialized. Added lots of new debug output. Add a new STM32 F4 Discovery configuration for testing the HCI UART. Various fixes to get through initialization (still does not). 2018-04-14 09:23:08 -06:00
Gregory Nutt 0686989645 configs/stm32fdiscovery: Add support in bringup logic to initialize the HCI UART and register the HCI UART network device. 2018-04-13 14:53:11 -06:00
Gregory Nutt d25549ac54 This commit adds a Bluetooth HCI UART lower half driver for the STM32
Squashed commit of the following:

    arch/arm/src/stm32:  Add Kconfig options needed by the HCI UART.  Various fixes to finally get a clean error free compile with no unexpected warnings.
    arch/arm/src/stm32:  In HCI UART, use spin_lock_irqsave() instead of enter_critical_section() whenever possible.
    arch/arm/src/stm32:  In HCI UART, fix up naming of configurations so that they are unique.  Still needs Kconfig settings.  Modify logic so that there can be multiple HCI UARTs, some supporting DMA and some not.
    arch/arm/src/stm32:  Integrate watermarks and software Rx flow control into the HCI UART driver.
    arch/arm/src/stm32:  Eliminate some HCI UART UART configuration options.  Per the HCI UART spec, the link will b 8 data bits, no parity, 1 stop bit... Always.
    arch/arm/src/stm32:  Trivial cleanup
    arch/arm/src/stm32:  Fixes most initial compilation issues STM32 HCI UART driver.  Still need to set up USART configuration parmeters for HCI UART
    arch/arm/src/stm32:  Completes first cut at STM32 HCI UART driver.
    arch/arm/src/stm32:  Completes most of read logic for HCI UART.  Still needs to be able to block if no read data is available.  Still missing write and flush logic.
    drivers/wireless:    Remove txenable from HCI UART methods.  arch/arm/src/stm32:  Reorganize some structures in HCI UART.
    arch/arm/src/stm32:  Still messaging the HCI uart driver.
    arch/arm/src/stm32:  Some trivial renaming.
    arch/arm/src/stm32:  A little more HCI-UART logic.
    arch/arm/src/stm32:  Initial setup to support HCI-UART.  Little more than the serial driver with some name changes and a few things removed.
2018-04-13 10:36:23 -06:00
Ivan Ucherdzhiev cf8c25df64 This commit brings in basic support fo the i.MX RT 1050 'crossover' SoC. The basic support is complete and compiles without error, but is still untested.
This port was the joing effort of Janne Rosberg, Ivan Ucherdzhiev, and myself.  I give credit to Ivan for the kill because he is the one to held on to the end.

Squashed commit of the following:

  Author: Gregory Nutt <gnutt@nuttx.org>
    configs/imxrt1050-evk/scripts:  Add section to linker script to handle the case where RAMFUNCs are enabled.  RAMFUNCs appear to be enabled in the default configuration ... they probably should not be enabled.

  Author: Ivan Ucherdzhiev <ivanucherdjiev@gmail.com>
    arch/arm/src/imxrt:  imxrt_lowputc.c is finished. Now everything needed for the initial port is done and ready for testing.
    arch/arm/src/imxrt:  Add logic to imxrt_lowputc.c.  Still incomplete.

  Author: Ivan Ucherdzhiev <ivanucherdjiev@gmail.com>
    arch/arm/src/imxrt:  Add serial support.  configs/imxrt1050-evk:  Add linker script.

  Author: Gregory Nutt <gnutt@nuttx.org>
    arch/arm/src/imxrt:  Add initial cut at imxrt_allocateheap.c

  Author: Ivan Ucherdzhiev <ivanucherdjiev@gmail.com>
    arm/arm/src/imxrt:  Completes all definitions for PADMUX, CTLMUX, and IOMUX_INPUT and mapping tables on imxrt_gpio.c and imxr_iomuxc.c.
    arch/arm/src/imxrt/chip:  Add definitions for IMXRT_PADCTL and IMXRT_PADMUX registers.  Only the IMXRT_INPUT definitions in this commit.
    arch/arm/src/imxrt/chip:  Add more IOMUXC register definitions.

  Author: Gregory Nutt <gnutt@nuttx.org>
    configs/imxrt1050-evk:  Add STRIP definition to Make.defs.
    arch/arm/src/imxrt:  Bring in i.MX6 memory configuration settings.
    arch/arm/src/imxrt:  Remove call to non-existent imxrt_gpioinit() from imxrt_start.c.
    arch/arm/src/imxrt:  Bring in incomplete imxrt_iomuxc.c file from i.mx6.
    arch/arm/src/imxrt:  Add first cut at GPIO interrupt logic.
    arch/arm/include:  Add definitions to support a second level of GPIO pin interrupts.

  Author: Janne Rosberg <janne.rosberg@offcode.fi>
    arch/arm/src/imxrt:  Add imxrt_wdog.c/.h

  Author: Gregory Nutt <gnutt@nuttx.org>
    arch/arm/src/imxrt:  Port SAMv7 interrupt logic to imxrt_irq.c.
    arch/arm/src/imxrt:  More clarification of the start-up memory map.
    arch/arm/src/imxrt:  Some mostly cosmetic clean-up to the imxrt_start.c file that was so rudely taken from the SAMv7.
    arch/arm/src/imxrt:  Add imxrt_start.c.  Initial commit is the the SAMv7 startup logic with name changes.

  Author: Ivan Ucherdzhiev <ivanucherdjiev@gmail.com>
    arch/arm/src/imxrt:  Adds a few IOMUXC register definitions.

  Author: Janne Rosberg <janne.rosberg@offcode.fi>
    arch/arm/src/imxrt:  Add imxrt_clockconfig.c/.h
    configs/imxrt1050-evk:  Add clock configuration definitions to board.h
    arch/arm/src/imxrt:  Fix CCM register name; Fix doubly defined in LPUART bit field.
    arch/arm/src/imxrt:  Add analog defines to CCM register definition header file.

  Author: Gregory Nutt <gnutt@nuttx.org>
    arch/arm/src/imxrt:  Bring in GPIO C files from i.MX6.  Things are in disarray now because that GPIO logic depends on IOMUXC logic which is not yet in place.
    arch/arm/src/imxrt:  Add a few more GPIO definitions to make the header file compatible with i.MX6
    arch/arm/src/imxrt/chip:  Add GPIO register definition file.

  Author: Janne Rosberg <janne.rosberg@offcode.fi>
    arch/arm/src/imxrt:  Add DCDC register definitions.
    arch/arm/srch/imxrt: Add CCM register bit definitions

  Author: Gregory Nutt <gnutt@nuttx.org>
    Purely cosmetic
    arch/arm/src/imxrt:  Add system reset controller register definition header file.
    Embarassingly trivial change left in compiler.
    arch/arm/src/imxrt:  Finishes i.MX RT1050 LPUART register definition header file.
    arch/arm/src/imxrt:  Beginning of an i.MX RT1050 LPUART register definition header file.
    Some trivial things

  Author: Janne Rosberg <janne.rosberg@offcode.fi>
    arch/arm/src/imxrt:  Add imxrt_wdog.h
    arch/arm/src/imxrt:  Add initial imxrt_ccm.h

  Author: Gregory Nutt <gnutt@nuttx.org>
    Trivial update to README.
    arch/arm/src/imxrt:  The i.MX Rt implements 4 bits of interrupt priority, not two.  Thanks, Janne.
    arch/arm/src/imxrt:  Fix some initial compile issues.  Still a long way from complete, but there is a buildable environment now for the imxrt1050-evk.
    configs/imxrt1050-evk:  Add an initial NSH configuration for testing.
    configs/Kconfig:  Hook the i.MX RT 1050 board configuration into the NuttX configuration system.
    configs/imxrt_evk:  Add the framework for i.MX RT 1050 board support.
    arch/arm/src/imxrt:  Bring in a few more files from LPC54xxx.
    arch/arm/src/imxrt:  Bring in imxrt_clrpend() from the LPC54xxx.
    arch/arm/src/imxrt:  Bring in Cortex-M7 SysTick setup from the SAMv7.
    arch/arm/src/imxrt:  Add a few easy files.
    arch/arm/src/imxrt/chip:  Add memory map header files.
    arch/arm/src/imxrt:  A few basic files to start the port to the i.MX RT 1050.
2018-04-12 09:31:09 -06:00
Gregory Nutt 7d7b8a243b arch/arm/src/stm32: Back out a small part of the previous commit ... my fault. 2018-04-11 18:25:35 -06:00
Michał Łyszczek da6dcb06b7 arch/arm/src/: Problem: stm32f30xx hangs waiting for LSE to initialize. Reason for hang is that operation of setting LSE_ON does not take effect because there is no clock on PWR peripheral. this is initialized later in the code 2018-04-11 16:02:12 -06:00
Gregory Nutt 730f7450b7 Remove all support for the CC3200 and CC3200-Launchpad. This was a port that was started but never completed. What good is partial CC3200-Launchpad board support with no wireless support?
Squashed commit of the following:

    Remove final references to CC3200 from the repository.
    arch/arm/include/tiva:  Remove all CC3200 support.
    arch/arm/src/tiva:  Remove all CC3200 support.
    configs/cc3200-launchpad:  Remove the board support directory.
2018-04-09 16:41:27 -06:00
Mateusz Szafoni 4de1378ceb Merged in raiden00/nuttx (pull request #625)
fix warnings found in stm32f334-disco/buckboost configuration

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-04-07 13:06:39 +00:00
Bob Feratich 7dc62b7483 arch/arm/src/stm32f7: Remove spurious space in pre-processor variable name. 2018-04-07 07:05:22 -06:00
Gregory Nutt 33d5325b09 STM32 F3: Fix a couple of new warnings noted in build testing. There are more new warnings, but I think these may be due to improper default values for some configuration settings. I have not looked into this in detail. 2018-04-04 17:32:25 -06:00
Juha Niskanen af5bcc0c13 arch/arm/src/stm32 and stm32l4: In 1wire driver, do not write useless WRITEBIT zero return value to const buffer 2018-04-04 11:09:20 -06:00
Mateusz Szafoni be5c20cdae Merged in raiden00/nuttx (pull request #616)
stm32/Kconfig: add some comments to HRTIM configuration, add ADC injected channels configuration; stm32f33xxx_hrtim.h: add some comments; stm32f334-disco: add buck/boost converter example configuration

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-04-04 17:03:48 +00:00
Masayuki Ishikawa 97ca4ef956 Merged in masayuki2009/nuttx.nuttx/change_copyright (pull request #621)
Change all Sony related copyright to conform with our company's internal rules.

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

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-04-04 12:35:47 +00:00
Vinicius Maciel 3ba6cc7921 arch/arm/src/tiva: Fix compilation errors on Tiva ADC code when ADC is enable. Please several cosmetic changes to files made during code review. 2018-04-01 17:52:37 -06:00
Gregory Nutt 8d5b225928 arch/arm/src/stm32: If Ethernet initialization failures (per previous commit), then do not register the uninitialized Ethernet device. Ths prevents any use of the badly initialized interface. 2018-03-27 15:33:59 -06:00
Sebastien Lorquet 7019d561b1 On STM32, in case of PHY failure, usually because of the lack of 25/50 MHz REFCLK input, the Ethernet block would lock up in a while loop waiting for readiness, which will never happened. This prevented the board from starting at all in the case of a PHY failure. This commit adds a retry loop to avoid bricking the board if the Ethernet block is unable to start. 2018-03-27 08:14:39 -06:00
Janne Rosberg 99e04a2d39 arch/arm/src/nrf52: Add nrf52_gpio_read 2018-03-27 07:41:46 -06:00
Janne Rosberg e4d43e8b87 arch/arm/src/nrf52: Better uart handling and some cleanup. 2018-03-26 12:50:06 -06:00
Janne Rosberg d608f6943b arch/arm/src/nrf52: Initial support for the NRF52 2018-03-26 10:37:32 -06:00
Gregory Nutt e35228ece9 arch/arm/src/imx6: Bring in a few i.MX6 fixes that were committed on the i.MX RT branch. 2018-03-23 16:55:12 -06:00
Juha Niskanen 0f03ffc745 STM32, STM32L4: add one bit read and write to 1-wire interface. This is needed for devices that require single bit timeslot generation and for 1-Wire search algorithm triplets. 2018-03-23 08:07:20 -06:00
Juha Niskanen 4e4229a8ef i2c/i2c_master.h: Change incorrect comment about I2C_TRANSFER return value to indicate that the method returns zero on success rather than the number of bytes transferred. 2018-03-22 06:51:09 -06:00
Juha Niskanen a36c7a779a |arch/arm/src/stm32l4: Add PM hooks to I2C, SPI and 1-wire 2018-03-21 07:26:33 -06:00
Juha Niskanen b9d0930761 arch/arm/src/stm32l4: Port 1wire driver from stm32. 2018-03-20 06:50:30 -06:00
Gregory Nutt 9c1efc7ab9 drivers/serial/Kconfig: Kconfig is too big, divide into Kconfig, Kconfig-uart, Kconfig-usart, Kconfig-sci, Kconfig-16550. More than one MCU supports LPUARTs. Add Kconfig-lpuart and remove MCU-specific LPUART definitions. Affects Kinetis and STM32L4. 2018-03-14 10:33:27 -06:00
Gregory Nutt 5f0af167df Trivial fix of two typos 2018-03-13 16:39:36 -06:00
Gregory Nutt b54ffe858a Standardization of some function headers. 2018-03-13 09:52:27 -06:00
Simon Piriou f62bfca94e Merged in spiriou/nuttx/stm32_lowputc (pull request #613)
arch/arm/src/stm32/lowputc: fix uart glitch when lowputc is enabled

Calling up_lowputc() when a character is in the shift register results
in corrupted character on stm32f1xx and stm32f205 cores.
TC status bit ensures that up_lowputc() waits for an on-going
transmission to complete before writing in TDR.

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-03-12 22:01:00 +00:00
Simon Piriou 1f52c13814 Merged in spiriou/nuttx/stm32_usbdev_hid (pull request #611)
arch/arm/src/stm32/usb: skip recipient check for descriptor related requests

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-03-12 20:08:55 +00:00
Juha Niskanen 8b57b7771f arch/srm/src/stm32f7: add PM hooks to ADC, I2C and SPI. 2018-03-06 08:10:50 -06:00
Juha Niskanen d8311b6493 drivers/power: add pm_unregister 2018-03-06 07:59:17 -06:00
Gregory Nutt 0b277da5fa arch/arm/src.stm32/Kconfig: Reduce redundancy in STM32F401 config settings. 2018-03-05 18:40:45 -06:00
Gregory Nutt ab5244e855 arch/arm/src/stm32: While we are at it and the differences are fresh in mind, add support for the rest of the STM32F401 family. 2018-03-05 17:36:08 -06:00
Gregory Nutt 33adf2c64d arch/arm/src/stm32: Add support for the STM32F401xB and STM32F401xC families. 2018-03-05 13:45:01 -06:00
Juha Niskanen 628821fdf4 arch/srm/src/stm32f7: Add CONFIG_RTC_PERIODIC support. Also makes the RTC lowerhalf more like in STM32L4. 2018-03-05 07:46:58 -06:00
Gregory Nutt de6b13b3ab Per OpenGroup.org, syslog -- and, hence, nonstandard vsyslog, and debug wrappers -- does not return a value. Rename _vsyslog to nx_vsyslog. Use internal nx_vsyslog in the few cases where a return value is required. 2018-03-04 08:07:07 -06:00
Gregory Nutt 6c729d6a7b Trivial, cosmetic change from review of last PR 2018-03-04 06:51:37 -06:00
raiden00pl 15dc86ddbb stm32_hrtim: fix capture_get function, add software capture trigger, add software reset trigger, add outputs polarisation configuration 2018-03-04 12:28:26 +01:00
Gregory Nutt 987a8298f2 Fix some errors found in build testing + clean-up some issues with last changes to remove use of printf() from within the OS. 2018-03-03 15:51:27 -06:00
Gregory Nutt b4f2b0dfc6 Remove all usage of printf() from the OS. That is not an acceptable context for the use of an application-oriented interface that depends on a task-specific file descriptor and C buffered I/O. 2018-03-03 15:20:21 -06:00
Mateusz Szafoni 160931ba72 Merged in raiden00/nuttx (pull request #607)
stm32f33xxx_adc.c: fix bug in RCC reset logic that resets ADC1 configuration when both ADC1 and ADC2 are in use

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-03-02 20:00:52 +00:00
Mateusz Szafoni 2e5bef89b8 Merged in raiden00/nuttx (pull request #606)
stm32_hrtim: add repetition support and fix enum overflow

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-27 18:53:08 +00:00
Juha Niskanen 05f056a770 arch/arm/src/stm32f7: Backport RTC alarm setting changes from STM32L4. Most notably this fixes RTC getting stuck issue when both alarms were used. Root cause was writing RTC ISR register contents to RTC CR register. 2018-02-27 06:50:04 -06:00
Masayuki Ishikawa 82e94a9948 Merged in masayuki2009/nuttx.nuttx/lc823450_dvfs_auto (pull request #604)
lc823450 dvfs auto

* arch/arm/src/lc823450: Fix up_enable_irq() timing for I2S.

    In previous commit, I2S IRQ might be sometimes assigned to CPU1
    when CONFIG_SMP=y. This change fixes this issue.

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

* arch/arm/src/lc823450: Refactor timer driver.

    Introduce lc823450_timer.h and move lc823450_timerisr.c to
    lc823450_timer.c Add MTM timer APIs for DVFS.  Introduce
    up_rtc_gettime() for CONFIG_RTC_HIRES.

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

* arch/arm/src/lc823450: Introduce idle time calculation in DVFS

    Also, DVFS autonomous mode based on CPU idle time is supported.
    NOTE: voltage control is still disabled.

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

* configs/lc823450-xgevk: Update defconfigs

    Enable RTC_HIRES instead of RTC_DATETIME (audio/rndis)
    Disable TCP_WRITE_BUFFERS and change SCHED_LPWORKPRIORITY (rndis)

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

* configs/lc823450-xgevk: Update README.txt

    Update SMP and DVFS related part

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

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-23 13:26:40 +00:00
Gregory Nutt 5f83631a97 arch/arm/src/sam34: Fix a typo resulting in duplicate names in DMAC bit definitions. 2018-02-22 13:57:20 -06:00
Dmitriy Linikov a8c58607e9 Merged in hardlulz/modem-3.0-nuttx/fix-sem-EINTR (pull request #603)
Added ECANCELED condition to DEBUGASSERT-s checking sem_wait result

Approved-by: Gregory Nutt <gnutt@nuttx.org>
2018-02-20 18:24:53 +00:00
Juha Niskanen 2fd9728a3a arch/arm/src/stm32: stm32_flash.c: add progmem support for STM32L15XX 2018-02-20 07:05:07 -06:00