2015-05-19 19:03:24 +02:00
|
|
|
/****************************************************************************
|
2018-07-22 23:54:12 +02:00
|
|
|
* arch/arm/src/samd2l2/samd_periphclks.h
|
2015-05-19 19:03:24 +02:00
|
|
|
*
|
|
|
|
* Copyright (C) 2015 Gregory Nutt. All rights reserved.
|
|
|
|
* Author: Gregory Nutt <gnutt@nuttx.org>
|
|
|
|
*
|
|
|
|
* Redistribution and use in source and binary forms, with or without
|
|
|
|
* modification, are permitted provided that the following conditions
|
|
|
|
* are met:
|
|
|
|
*
|
|
|
|
* 1. Redistributions of source code must retain the above copyright
|
|
|
|
* notice, this list of conditions and the following disclaimer.
|
|
|
|
* 2. Redistributions in binary form must reproduce the above copyright
|
|
|
|
* notice, this list of conditions and the following disclaimer in
|
|
|
|
* the documentation and/or other materials provided with the
|
|
|
|
* distribution.
|
|
|
|
* 3. Neither the name NuttX nor the names of its contributors may be
|
|
|
|
* used to endorse or promote products derived from this software
|
|
|
|
* without specific prior written permission.
|
|
|
|
*
|
|
|
|
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
|
|
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
|
|
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
|
|
|
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
|
|
|
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
|
|
|
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
|
|
|
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
|
|
|
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
|
|
|
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
|
|
|
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
|
|
|
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
|
|
* POSSIBILITY OF SUCH DAMAGE.
|
|
|
|
*
|
|
|
|
****************************************************************************/
|
|
|
|
|
2018-07-22 23:54:12 +02:00
|
|
|
#ifndef __ARCH_ARM_SRC_SAMD2L2_SAMD_PERIPHCLKS_H
|
|
|
|
#define __ARCH_ARM_SRC_SAMD2L2_SAMD_PERIPHCLKS_H
|
2015-05-19 19:03:24 +02:00
|
|
|
|
|
|
|
/****************************************************************************
|
|
|
|
* Included Files
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#include <nuttx/config.h>
|
|
|
|
|
|
|
|
#include "chip/samd_pm.h"
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#if defined(CONFIG_ARCH_FAMILY_SAMD20) || defined(CONFIG_ARCH_FAMILY_SAMD21)
|
2015-05-19 19:03:24 +02:00
|
|
|
|
|
|
|
/****************************************************************************
|
|
|
|
* Pre-processor Definitions
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#define sam_apba_enableperiph(s) modifyreg32(SAM_PM_APBAMASK,0,s)
|
|
|
|
|
|
|
|
#define sam_pac0_enableperiph() sam_apba_enableperiph(PM_APBAMASK_PAC0)
|
|
|
|
#define sam_pm_enableperiph() sam_apba_enableperiph(PM_APBAMASK_PM)
|
|
|
|
#define sam_sysctrl_enableperiph() sam_apba_enableperiph(PM_APBAMASK_SYSCTRL)
|
|
|
|
#define sam_gclk_enableperiph() sam_apba_enableperiph(PM_APBAMASK_GCLK)
|
|
|
|
#define sam_wdt_enableperiph() sam_apba_enableperiph(PM_APBAMASK_WDT)
|
|
|
|
#define sam_rtc_enableperiph() sam_apba_enableperiph(PM_APBAMASK_RTC)
|
|
|
|
#define sam_eic_enableperiph() sam_apba_enableperiph(PM_APBAMASK_EIC)
|
|
|
|
|
|
|
|
#define sam_apbb_enableperiph(s) modifyreg32(SAM_PM_APBBMASK,0,s)
|
|
|
|
|
|
|
|
#define sam_pac1_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_PAC1)
|
|
|
|
#define sam_dsu_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_DSU)
|
|
|
|
#define sam_nvmctrl_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_NVMCTRL)
|
|
|
|
#define sam_port_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_PORT)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_dmac_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_DMAC)
|
|
|
|
# define sam_usb_enableperiph() sam_apbb_enableperiph(PM_APBBMASK_USB)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_apbc_enableperiph(s) modifyreg32(SAM_PM_APBCMASK,0,s)
|
|
|
|
|
|
|
|
#define sam_pac2_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_PAC2)
|
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 12:55:40 +01:00
|
|
|
#define sam_evsys_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_EVSYS)
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_sercom_enableperiph(n) sam_apbc_enableperiph(PM_APBCMASK_SERCOM(n))
|
|
|
|
#define sam_sercom0_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM0)
|
|
|
|
#define sam_sercom1_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM1)
|
|
|
|
#define sam_sercom2_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM2)
|
|
|
|
#define sam_sercom3_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM3)
|
|
|
|
#define sam_sercom4_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM4)
|
|
|
|
#define sam_sercom5_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_SERCOM5)
|
2015-06-20 23:32:57 +02:00
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD20
|
|
|
|
# define sam_tc0_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC0)
|
|
|
|
# define sam_tc1_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC1)
|
|
|
|
# define sam_tc2_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC2)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_tcc0_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TCC0)
|
|
|
|
# define sam_tcc1_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TCC1)
|
|
|
|
# define sam_tcc2_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TCC2)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_tc3_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC3)
|
|
|
|
#define sam_tc4_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC4)
|
|
|
|
#define sam_tc5_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC5)
|
|
|
|
#define sam_tc6_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC6)
|
|
|
|
#define sam_tc7_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_TC7)
|
|
|
|
#define sam_adc_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_ADC)
|
|
|
|
#define sam_ac_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_AC)
|
|
|
|
#define sam_dac_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_DAC)
|
|
|
|
#define sam_ptc_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_PTC)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
2018-01-31 14:29:23 +01:00
|
|
|
# define sam_i2s_enableperiph() sam_apbc_enableperiph(PM_APBCMASK_I2S)
|
2015-06-20 23:32:57 +02:00
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_apba_disableperiph(s) modifyreg32(SAM_PM_APBAMASK,s,0)
|
|
|
|
|
|
|
|
#define sam_pac0_disableperiph() sam_apba_disableperiph(PM_APBAMASK_PAC0)
|
|
|
|
#define sam_pm_disableperiph() sam_apba_disableperiph(PM_APBAMASK_PM)
|
|
|
|
#define sam_sysctrl_disableperiph() sam_apba_disableperiph(PM_APBAMASK_SYSCTRL)
|
|
|
|
#define sam_gclk_disableperiph() sam_apba_disableperiph(PM_APBAMASK_GCLK)
|
|
|
|
#define sam_wdt_disableperiph() sam_apba_disableperiph(PM_APBAMASK_WDT)
|
|
|
|
#define sam_rtc_disableperiph() sam_apba_disableperiph(PM_APBAMASK_RTC)
|
|
|
|
#define sam_eic_disableperiph() sam_apba_disableperiph(PM_APBAMASK_EIC)
|
|
|
|
|
|
|
|
#define sam_apbb_disableperiph(s) modifyreg32(SAM_PM_APBBMASK,s,0)
|
|
|
|
|
|
|
|
#define sam_pac1_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_PAC1)
|
|
|
|
#define sam_dsu_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_DSU)
|
|
|
|
#define sam_nvmctrl_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_NVMCTRL)
|
|
|
|
#define sam_port_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_PORT)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_dmac_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_DMAC)
|
|
|
|
# define sam_usb_disableperiph() sam_apbb_disableperiph(PM_APBBMASK_USB)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_apbc_disableperiph(s) modifyreg32(SAM_PM_APBCMASK,s,0)
|
|
|
|
|
|
|
|
#define sam_pac2_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_PAC2)
|
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 12:55:40 +01:00
|
|
|
#define sam_evsys_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_EVSYS)
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_sercom_disableperiph(n) sam_apbc_disableperiph(PM_APBCMASK_SERCOM(n))
|
|
|
|
#define sam_sercom0_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM0)
|
|
|
|
#define sam_sercom1_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM1)
|
|
|
|
#define sam_sercom2_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM2)
|
|
|
|
#define sam_sercom3_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM3)
|
|
|
|
#define sam_sercom4_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM4)
|
|
|
|
#define sam_sercom5_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_SERCOM5)
|
2015-06-20 23:32:57 +02:00
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD20
|
|
|
|
# define sam_tc0_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC0)
|
|
|
|
# define sam_tc1_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC1)
|
|
|
|
# define sam_tc2_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC2)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_tcc0_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TCC0)
|
|
|
|
# define sam_tcc1_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TCC1)
|
|
|
|
# define sam_tcc2_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TCC2)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_tc3_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC3)
|
|
|
|
#define sam_tc4_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC4)
|
|
|
|
#define sam_tc5_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC5)
|
|
|
|
#define sam_tc6_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC6)
|
|
|
|
#define sam_tc7_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_TC7)
|
|
|
|
#define sam_adc_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_ADC)
|
|
|
|
#define sam_ac_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_AC)
|
|
|
|
#define sam_dac_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_DAC)
|
|
|
|
#define sam_ptc_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_PTC)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
2018-01-31 14:29:23 +01:00
|
|
|
# define sam_i2s_disableperiph() sam_apbc_disableperiph(PM_APBCMASK_I2S)
|
2015-06-20 23:32:57 +02:00
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_apba_isenabled(s) (getreg32(SAM_PM_APBAMASK) & (s)) != 0)
|
|
|
|
|
|
|
|
#define sam_pac0_isenabled() sam_apba_isenabled(PM_APBAMASK_PAC0)
|
|
|
|
#define sam_pm_isenabled() sam_apba_isenabled(PM_APBAMASK_PM)
|
|
|
|
#define sam_sysctrl_isenabled() sam_apba_isenabled(PM_APBAMASK_SYSCTRL)
|
|
|
|
#define sam_gclk_isenabled() sam_apba_isenabled(PM_APBAMASK_GCLK)
|
|
|
|
#define sam_wdt_isenabled() sam_apba_isenabled(PM_APBAMASK_WDT)
|
|
|
|
#define sam_rtc_isenabled() sam_apba_isenabled(PM_APBAMASK_RTC)
|
|
|
|
#define sam_eic_isenabled() sam_apba_isenabled(PM_APBAMASK_EIC)
|
|
|
|
|
|
|
|
#define sam_apbb_isenabled(s) (getreg32(SAM_PM_APBBMASK) & (s)) != 0)
|
|
|
|
|
|
|
|
#define sam_pac1_isenabled() sam_apbb_isenabled(PM_APBBMASK_PAC1)
|
|
|
|
#define sam_dsu_isenabled() sam_apbb_isenabled(PM_APBBMASK_DSU)
|
|
|
|
#define sam_nvmctrl_isenabled() sam_apbb_isenabled(PM_APBBMASK_NVMCTRL)
|
|
|
|
#define sam_port_isenabled() sam_apbb_isenabled(PM_APBBMASK_PORT)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_dmac_isenabled() sam_apbb_isenabled(PM_APBBMASK_DMAC)
|
|
|
|
# define sam_usb_isenabled() sam_apbb_isenabled(PM_APBBMASK_USB)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_apbc_isenabled(s) (getreg32(SAM_PM_APBCMASK) & (s)) != 0)
|
|
|
|
|
|
|
|
#define sam_pac2_isenabled() sam_apbc_isenabled(PM_APBCMASK_PAC2)
|
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 12:55:40 +01:00
|
|
|
#define sam_evsys_isenabled() sam_apbc_isenabled(PM_APBCMASK_EVSYS)
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_sercom_isenabled(n) sam_apbc_isenabled(PM_APBCMASK_SERCOM(n))
|
|
|
|
#define sam_sercom0_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM0)
|
|
|
|
#define sam_sercom1_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM1)
|
|
|
|
#define sam_sercom2_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM2)
|
|
|
|
#define sam_sercom3_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM3)
|
|
|
|
#define sam_sercom4_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM4)
|
|
|
|
#define sam_sercom5_isenabled() sam_apbc_isenabled(PM_APBCMASK_SERCOM5)
|
2015-06-20 23:32:57 +02:00
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD20
|
|
|
|
# define sam_tc0_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC0)
|
|
|
|
# define sam_tc1_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC1)
|
|
|
|
# define sam_tc2_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC2)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
|
|
|
# define sam_tcc0_isenabled() sam_apbc_isenabled(PM_APBCMASK_TCC0)
|
|
|
|
# define sam_tcc1_isenabled() sam_apbc_isenabled(PM_APBCMASK_TCC1)
|
|
|
|
# define sam_tcc2_isenabled() sam_apbc_isenabled(PM_APBCMASK_TCC2)
|
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
#define sam_tc3_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC3)
|
|
|
|
#define sam_tc4_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC4)
|
|
|
|
#define sam_tc5_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC5)
|
|
|
|
#define sam_tc6_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC6)
|
|
|
|
#define sam_tc7_isenabled() sam_apbc_isenabled(PM_APBCMASK_TC7)
|
|
|
|
#define sam_adc_isenabled() sam_apbc_isenabled(PM_APBCMASK_ADC)
|
|
|
|
#define sam_ac_isenabled() sam_apbc_isenabled(PM_APBCMASK_AC)
|
|
|
|
#define sam_dac_isenabled() sam_apbc_isenabled(PM_APBCMASK_DAC)
|
|
|
|
#define sam_ptc_isenabled() sam_apbc_isenabled(PM_APBCMASK_PTC)
|
|
|
|
|
2015-06-20 23:32:57 +02:00
|
|
|
#ifdef CONFIG_ARCH_FAMILY_SAMD21
|
2018-01-31 14:29:23 +01:00
|
|
|
# define sam_i2s_isenabled() sam_apbc_isenabled(PM_APBCMASK_I2S)
|
2015-06-20 23:32:57 +02:00
|
|
|
#endif
|
|
|
|
|
2015-05-19 19:03:24 +02:00
|
|
|
/****************************************************************************
|
|
|
|
* Public Types
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
/****************************************************************************
|
|
|
|
* Inline Functions
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#ifndef __ASSEMBLY__
|
|
|
|
|
|
|
|
/****************************************************************************
|
|
|
|
* Public Data
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#undef EXTERN
|
|
|
|
#if defined(__cplusplus)
|
|
|
|
#define EXTERN extern "C"
|
|
|
|
extern "C"
|
|
|
|
{
|
|
|
|
#else
|
|
|
|
#define EXTERN extern
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/****************************************************************************
|
|
|
|
* Public Function Prototypes
|
|
|
|
****************************************************************************/
|
|
|
|
|
|
|
|
#undef EXTERN
|
|
|
|
#if defined(__cplusplus)
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
#endif /* __ASSEMBLY__ */
|
2015-06-20 23:32:57 +02:00
|
|
|
#endif /* CONFIG_ARCH_FAMILY_SAMD20 || CONFIG_ARCH_FAMILY_SAMD21 */
|
2018-07-22 23:54:12 +02:00
|
|
|
#endif /* __ARCH_ARM_SRC_SAMD2L2_SAMD_PERIPHCLKS_H */
|