mirror of
https://github.com/apache/nuttx.git
synced 2026-05-15 21:19:09 +08:00
configs/pjrc-8051: Configuration converted to use the kconfig-frontends tools
This commit is contained in:
@@ -6908,3 +6908,5 @@
|
||||
kconfig-frontends tools (2014-3-6)
|
||||
* configs/mx1ads/ostest: Configuration converted to use the
|
||||
kconfig-frontends tools (2014-3-6)
|
||||
* configs/pjrc-8051: Configuration converted to use the kconfig-frontends
|
||||
tools (2014-3-6)
|
||||
|
||||
@@ -2,3 +2,47 @@
|
||||
# For a description of the syntax of this configuration file,
|
||||
# see misc/tools/kconfig-language.txt.
|
||||
#
|
||||
|
||||
if ARCH_8051
|
||||
comment "ARM Options"
|
||||
|
||||
choice
|
||||
prompt "8051 Chip Selection"
|
||||
default ARCH_CHIP_8052
|
||||
|
||||
config ARCH_CHIP_8051
|
||||
bool "8051"
|
||||
|
||||
config ARCH_CHIP_8052
|
||||
bool "8052"
|
||||
|
||||
endchoice # 8051 Chip Selection
|
||||
|
||||
comment "Bring-up Debug Options"
|
||||
|
||||
config ARCH_8051_BRINGUP
|
||||
bool "Bring-up debug"
|
||||
default n
|
||||
---help---
|
||||
Enable bring-up debug instrumentation
|
||||
|
||||
config ARCH_8051_NOSYSTIMER
|
||||
bool "No system timer"
|
||||
---help---
|
||||
By default, Timer0 will be used as the system timer. Use of the
|
||||
system timer can be suppressed with the setting. This is useful
|
||||
during bring-up.
|
||||
|
||||
config ARCH_8051_BRINGUP
|
||||
bool "Bring-up debug"
|
||||
default n
|
||||
---help---
|
||||
Enable bring-up debug instrumentation
|
||||
|
||||
config ARCH_8051_SUPRESS_INTERRUPTS
|
||||
bool "Suppress interrupts"
|
||||
default n
|
||||
---help---
|
||||
It is useful during low-level bring-up to suppress all interrupts.
|
||||
|
||||
endif # ARCH_8051
|
||||
|
||||
@@ -64,7 +64,8 @@
|
||||
|
||||
#ifdef __cplusplus
|
||||
#define EXTERN extern "C"
|
||||
extern "C" {
|
||||
extern "C"
|
||||
{
|
||||
#else
|
||||
#define EXTERN extern
|
||||
#endif
|
||||
@@ -74,7 +75,7 @@ extern "C" {
|
||||
* code to dump the stack pointer at critical locations.
|
||||
*/
|
||||
|
||||
EXTERN void up_showsp(uint8_t ch) __naked;
|
||||
void up_showsp(uint8_t ch) __naked;
|
||||
|
||||
#undef EXTERN
|
||||
#ifdef __cplusplus
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_assert.c
|
||||
* arch/8051/src/up_debug.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -62,7 +62,7 @@
|
||||
* Private Functions
|
||||
************************************************************************/
|
||||
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
static void up_putspace(void) __naked
|
||||
{
|
||||
_asm
|
||||
@@ -103,7 +103,7 @@ static void _up_dump8(__code char *ptr, uint8_t b)
|
||||
* Name: up_puthex, up_puthex16, up_putnl, up_puts
|
||||
************************************************************************/
|
||||
|
||||
#if defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
void up_puthex(uint8_t hex) __naked
|
||||
{
|
||||
hex; /* To avoid unreferenced argument warning */
|
||||
@@ -141,7 +141,7 @@ void up_puts(__code char *ptr)
|
||||
* Name: up_dumpstack
|
||||
************************************************************************/
|
||||
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
void up_dumpstack(void)
|
||||
{
|
||||
NEAR uint8_t *start = (NEAR uint8_t *)(STACK_BASE & 0xf0);
|
||||
@@ -177,7 +177,7 @@ void up_dumpstack(void)
|
||||
* Name: up_dumpframe
|
||||
************************************************************************/
|
||||
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
void up_dumpframe(FAR struct xcptcontext *context)
|
||||
{
|
||||
#ifdef CONFIG_FRAME_DUMP_SHORT
|
||||
@@ -238,7 +238,7 @@ void up_dumpframe(FAR struct xcptcontext *context)
|
||||
* code to dump the stack pointer at critical locations.
|
||||
*/
|
||||
|
||||
#ifdef CONFIG_ARCH_PJRC
|
||||
#ifdef CONFIG_ARCH_8051_BRINGUP
|
||||
void up_showsp(uint8_t ch) __naked
|
||||
{
|
||||
ch;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************
|
||||
* up_head.S
|
||||
* arch/8051/src/up_head.S
|
||||
*
|
||||
* Copyright (C) 2007 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -51,7 +51,7 @@
|
||||
.area REG_BANK_0 (REL,OVR,DATA)
|
||||
.ds 8
|
||||
|
||||
#ifndef CONFIG_8052_TIMER2
|
||||
#ifndef CONFIG_ARCH_8051_NOSYSTIMER
|
||||
.area XSEG
|
||||
_g_timer0tick:
|
||||
.ds 1
|
||||
@@ -99,7 +99,7 @@ _g_timer0tick:
|
||||
|
||||
.org PM2_VECTOR_TIMER0
|
||||
push acc
|
||||
#ifdef CONFIG_8052_TIMER2
|
||||
#ifdef CONFIG_ARCH_8051_NOSYSTIMER
|
||||
mov a, #TIMER0_IRQ
|
||||
ljmp _up_interrupt
|
||||
#else
|
||||
@@ -162,7 +162,7 @@ start:
|
||||
*
|
||||
************************************************************/
|
||||
|
||||
#ifndef CONFIG_8052_TIMER2
|
||||
#ifndef CONFIG_ARCH_8051_NOSYSTIMER
|
||||
_up_timer0:
|
||||
ar2 = 0x02
|
||||
ar3 = 0x03
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_idle.c
|
||||
* arch/8051/src/up_idle.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -52,7 +52,7 @@
|
||||
* Private Data
|
||||
************************************************************************/
|
||||
|
||||
#if defined(CONFIG_ARCH_LEDS) && defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_ARCH_LEDS) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
static uint8_t g_ledtoggle = 0;
|
||||
#endif
|
||||
|
||||
@@ -81,7 +81,7 @@ static uint8_t g_ledtoggle = 0;
|
||||
|
||||
void up_idle(void)
|
||||
{
|
||||
#if defined(CONFIG_ARCH_LEDS) && defined(CONFIG_ARCH_BRINGUP)
|
||||
#if defined(CONFIG_ARCH_LEDS) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
g_ledtoggle++;
|
||||
if (g_ledtoggle == 0x80)
|
||||
{
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_initialize.c
|
||||
* arch/8051/src/up_initialize.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009, 2011 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2011, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -135,7 +135,7 @@ void up_initialize(void)
|
||||
|
||||
/* Initialize the system timer interrupt */
|
||||
|
||||
#ifndef CONFIG_SUPPRESS_INTERRUPTS
|
||||
#ifndef CONFIG_ARCH_8051_SUPRESS_INTERRUPTS
|
||||
up_timerinit();
|
||||
#endif
|
||||
|
||||
|
||||
+26
-25
@@ -1,7 +1,7 @@
|
||||
/**************************************************************************
|
||||
* up_internal.h
|
||||
* arch/8051/src/up_internal.h
|
||||
*
|
||||
* Copyright (C) 2007, 2009, 2011 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2011, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -33,8 +33,8 @@
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
#ifndef __ARCH_UP_INTERNAL_H
|
||||
#define __ARCH_UP_INTERNAL_H
|
||||
#ifndef __ARCH_8051_SRC_UP_INTERNAL_H
|
||||
#define __ARCH_8051_SRC_UP_INTERNAL_H
|
||||
|
||||
/**************************************************************************
|
||||
* Included Files
|
||||
@@ -108,29 +108,30 @@ extern const uint8_t g_ntobit[8];
|
||||
#ifndef __ASSEMBLY__
|
||||
|
||||
#if CONFIG_MM_REGIONS > 1
|
||||
extern void up_addregion(void);
|
||||
void up_addregion(void);
|
||||
#endif
|
||||
extern void up_delay(uint8_t milliseconds) __naked;
|
||||
extern void up_irqinitialize(void);
|
||||
extern void up_restorecontext(FAR struct xcptcontext *context) _naked;
|
||||
extern void up_restoreregisters(FAR uint8_t *regs) _naked;
|
||||
extern uint8_t up_savecontext(FAR struct xcptcontext *context) __naked;
|
||||
extern void up_saveregisters(FAR uint8_t *regs) _naked;
|
||||
extern void up_saveirqcontext(FAR struct xcptcontext *context);
|
||||
extern void up_timerinit(void);
|
||||
void up_delay(uint8_t milliseconds) __naked;
|
||||
void up_irqinitialize(void);
|
||||
void up_restorecontext(FAR struct xcptcontext *context) _naked;
|
||||
void up_restoreregisters(FAR uint8_t *regs) _naked;
|
||||
uint8_t up_savecontext(FAR struct xcptcontext *context) __naked;
|
||||
void up_saveregisters(FAR uint8_t *regs) _naked;
|
||||
void up_saveirqcontext(FAR struct xcptcontext *context);
|
||||
void up_timerinit(void);
|
||||
|
||||
/* Defined in up_debug.c */
|
||||
|
||||
#if defined(CONFIG_ARCH_BRINGUP)
|
||||
extern void up_puthex(uint8_t hex) __naked;
|
||||
extern void up_puthex16(int hex) __naked;
|
||||
extern void up_putnl(void) __naked;
|
||||
extern void up_puts(__code char *ptr);
|
||||
#if defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
void up_puthex(uint8_t hex) __naked;
|
||||
void up_puthex16(int hex) __naked;
|
||||
void up_putnl(void) __naked;
|
||||
void up_puts(__code char *ptr);
|
||||
void up_showsp(uint8_t ch) __naked;
|
||||
#endif
|
||||
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_BRINGUP)
|
||||
extern void up_dumpstack(void);
|
||||
extern void up_dumpframe(FAR struct xcptcontext *context);
|
||||
#if defined(CONFIG_FRAME_DUMP) && defined(CONFIG_ARCH_8051_BRINGUP)
|
||||
void up_dumpstack(void);
|
||||
void up_dumpframe(FAR struct xcptcontext *context);
|
||||
#else
|
||||
# define up_dumpstack()
|
||||
# define up_dumpframe(x)
|
||||
@@ -139,9 +140,9 @@ extern void up_dumpframe(FAR struct xcptcontext *context);
|
||||
/* Defined in board/up_leds.c */
|
||||
|
||||
#ifdef CONFIG_ARCH_LEDS
|
||||
extern void board_led_initialize(void);
|
||||
extern void board_led_on(uint8_t led);
|
||||
extern void board_led_off(uint8_t led);
|
||||
void board_led_initialize(void);
|
||||
void board_led_on(uint8_t led);
|
||||
void board_led_off(uint8_t led);
|
||||
#else
|
||||
# define board_led_initialize()
|
||||
# define board_led_on(led)
|
||||
@@ -149,4 +150,4 @@ extern void board_led_off(uint8_t led);
|
||||
#endif
|
||||
|
||||
#endif /* __ASSEMBLY */
|
||||
#endif /* __ARCH_UP_INTERNAL_H */
|
||||
#endif /* __ARCH_8051_SRC_UP_INTERNAL_H */
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_irq.c
|
||||
* arch/8051/src/up_irq.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -78,7 +78,7 @@ void up_irqinitialize(void)
|
||||
|
||||
IP = 0;
|
||||
|
||||
#ifdef CONFIG_SUPPRESS_INTERRUPTS
|
||||
#ifdef CONFIG_ARCH_8051_SUPRESS_INTERRUPTS
|
||||
/* Disable all interrupts */
|
||||
|
||||
IE = 0;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_irqtest.c
|
||||
* arch/8051/src/up_irqtest.c
|
||||
*
|
||||
* Copyright (C) 2007, 2011 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2011, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -160,13 +160,12 @@ void os_start(void)
|
||||
|
||||
IE = 0;
|
||||
|
||||
/* Then verify all of the interrupt */
|
||||
/* Then verify all of the interrupts */
|
||||
|
||||
g_irqtest = false;
|
||||
|
||||
up_extint0();
|
||||
up_timer0();
|
||||
#ifndef CONFIG_8052_TIMER2
|
||||
#ifdef CONFIG_ARCH_8051_NOSYSTIMER
|
||||
up_timer0();
|
||||
#endif
|
||||
up_extint1();
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/************************************************************************
|
||||
* up_timerisr.c
|
||||
* arch/8051/src/up_timerisr.c
|
||||
*
|
||||
* Copyright (C) 2007, 2009 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2007, 2009, 2014 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@@ -92,7 +92,7 @@ int up_timerisr(int irq, FAR uint8_t *frame)
|
||||
|
||||
void up_timerinit(void)
|
||||
{
|
||||
#ifdef CONFIG_8052_TIMER2
|
||||
#ifdef CONFIG_ARCH_8051_NOSYSTIMER
|
||||
up_disable_irq(TIMER2_IRQ);
|
||||
|
||||
/* Set up timer 2 -- See pjrc.h for details */
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ config ARCH_8051
|
||||
bool "8051"
|
||||
select CUSTOM_STACK
|
||||
---help---
|
||||
Intel 8051 architectures and derivaties
|
||||
Intel 8051 architectures and derivatives
|
||||
|
||||
config ARCH_ARM
|
||||
bool "ARM"
|
||||
|
||||
@@ -52,4 +52,3 @@ This configuration was last successfully built and tested with a ca.
|
||||
2.6.0 SDCC release. Support for that older toolchain was removed in
|
||||
NuttX revision -r5423. If you wanted to used those older toolchains,
|
||||
you would need to revert to a pre-r5423 revision.
|
||||
|
||||
|
||||
@@ -1,39 +0,0 @@
|
||||
############################################################################
|
||||
# configs/pjrc-8051/appconfig
|
||||
#
|
||||
# Copyright (C) 2011 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
#
|
||||
# Redistribution and use in source and binary forms, with or without
|
||||
# modification, are permitted provided that the following conditions
|
||||
# are met:
|
||||
#
|
||||
# 1. Redistributions of source code must retain the above copyright
|
||||
# notice, this list of conditions and the following disclaimer.
|
||||
# 2. Redistributions in binary form must reproduce the above copyright
|
||||
# notice, this list of conditions and the following disclaimer in
|
||||
# the documentation and/or other materials provided with the
|
||||
# distribution.
|
||||
# 3. Neither the name NuttX nor the names of its contributors may be
|
||||
# used to endorse or promote products derived from this software
|
||||
# without specific prior written permission.
|
||||
#
|
||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
# FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
# COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
# BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
# OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
# AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
# ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
# POSSIBILITY OF SUCH DAMAGE.
|
||||
#
|
||||
############################################################################
|
||||
|
||||
# Path to example in apps/examples containing the user_start entry point
|
||||
|
||||
CONFIGURED_APPS += examples/ostest
|
||||
|
||||
+529
-166
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user