Skip to content

Commit 8256019

Browse files
committed
Merge remote-tracking branch 'rtt_gitee/gitee_master'
2 parents 0f65821 + 82f3a84 commit 8256019

File tree

283 files changed

+40970
-2706
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

283 files changed

+40970
-2706
lines changed

bsp/essemi/es32f0654/.config

Lines changed: 28 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ CONFIG_RT_USING_OVERFLOW_CHECK=y
1919
CONFIG_RT_USING_HOOK=y
2020
CONFIG_RT_USING_IDLE_HOOK=y
2121
CONFIG_RT_IDLE_HOOK_LIST_SIZE=4
22-
CONFIG_IDLE_THREAD_STACK_SIZE=256
22+
CONFIG_IDLE_THREAD_STACK_SIZE=512
2323
# CONFIG_RT_USING_TIMER_SOFT is not set
2424
CONFIG_RT_DEBUG=y
2525
CONFIG_RT_DEBUG_COLOR=y
@@ -114,26 +114,26 @@ CONFIG_RT_PIPE_BUFSZ=512
114114
CONFIG_RT_USING_SERIAL=y
115115
# CONFIG_RT_SERIAL_USING_DMA is not set
116116
CONFIG_RT_SERIAL_RB_BUFSZ=64
117-
CONFIG_RT_USING_CAN=y
117+
# CONFIG_RT_USING_CAN is not set
118118
# CONFIG_RT_CAN_USING_HDR is not set
119-
CONFIG_RT_USING_HWTIMER=y
119+
# CONFIG_RT_USING_HWTIMER is not set
120120
# CONFIG_RT_USING_CPUTIME is not set
121-
CONFIG_RT_USING_I2C=y
121+
# CONFIG_RT_USING_I2C is not set
122122
# CONFIG_RT_I2C_DEBUG is not set
123-
CONFIG_RT_USING_I2C_BITOPS=y
123+
# CONFIG_RT_USING_I2C_BITOPS is not set
124124
# CONFIG_RT_I2C_BITOPS_DEBUG is not set
125125
CONFIG_RT_USING_PIN=y
126-
CONFIG_RT_USING_ADC=y
126+
# CONFIG_RT_USING_ADC is not set
127127
# CONFIG_RT_USING_DAC is not set
128-
CONFIG_RT_USING_PWM=y
128+
# CONFIG_RT_USING_PWM is not set
129129
# CONFIG_RT_USING_MTD_NOR is not set
130130
# CONFIG_RT_USING_MTD_NAND is not set
131-
CONFIG_RT_USING_PM=y
132-
CONFIG_RT_USING_RTC=y
131+
# CONFIG_RT_USING_PM is not set
132+
# CONFIG_RT_USING_RTC is not set
133133
# CONFIG_RT_USING_ALARM is not set
134134
# CONFIG_RT_USING_SOFT_RTC is not set
135135
# CONFIG_RT_USING_SDIO is not set
136-
CONFIG_RT_USING_SPI=y
136+
# CONFIG_RT_USING_SPI is not set
137137
# CONFIG_RT_USING_QSPI is not set
138138
# CONFIG_RT_USING_SPI_MSD is not set
139139
# CONFIG_RT_USING_SFUD is not set
@@ -159,7 +159,8 @@ CONFIG_RT_USING_SPI=y
159159
#
160160
# CONFIG_RT_USING_LIBC is not set
161161
# CONFIG_RT_USING_PTHREADS is not set
162-
# CONFIG_RT_LIBC_USING_TIME is not set
162+
CONFIG_RT_LIBC_USING_TIME=y
163+
CONFIG_RT_LIBC_FIXED_TIMEZONE=8
163164

164165
#
165166
# Network
@@ -468,6 +469,8 @@ CONFIG_BSP_USING_GPIO=y
468469
# CONFIG_BSP_USING_UART1 is not set
469470
CONFIG_BSP_USING_UART2=y
470471
# CONFIG_BSP_USING_UART3 is not set
472+
# CONFIG_BSP_USING_USART0 is not set
473+
# CONFIG_BSP_USING_USART1 is not set
471474

472475
#
473476
# SPI Drivers
@@ -484,23 +487,26 @@ CONFIG_BSP_USING_UART2=y
484487
#
485488
# CAN Drivers
486489
#
487-
# CONFIG_BSP_USING_CAN is not set
490+
# CONFIG_BSP_USING_CAN0 is not set
488491

489492
#
490493
# PWM Drivers
491494
#
492-
# CONFIG_BSP_USING_PWM0 is not set
493-
# CONFIG_BSP_USING_PWM1 is not set
494-
# CONFIG_BSP_USING_PWM2 is not set
495-
# CONFIG_BSP_USING_PWM3 is not set
495+
# CONFIG_BSP_USING_AD16C4T0_PWM is not set
496+
# CONFIG_BSP_USING_GP16C4T0_PWM is not set
497+
# CONFIG_BSP_USING_GP16C2T0_PWM is not set
498+
# CONFIG_BSP_USING_GP16C2T1_PWM is not set
496499

497500
#
498501
# HWtimer Drivers
499502
#
500-
# CONFIG_BSP_USING_HWTIMER0 is not set
501-
# CONFIG_BSP_USING_HWTIMER1 is not set
502-
# CONFIG_BSP_USING_HWTIMER2 is not set
503-
# CONFIG_BSP_USING_HWTIMER3 is not set
503+
# CONFIG_BSP_USING_AD16C4T0_HWTIMER is not set
504+
# CONFIG_BSP_USING_GP16C4T0_HWTIMER is not set
505+
# CONFIG_BSP_USING_GP16C2T0_HWTIMER is not set
506+
# CONFIG_BSP_USING_GP16C2T1_HWTIMER is not set
507+
# CONFIG_BSP_USING_BS16T0_HWTIMER is not set
508+
# CONFIG_BSP_USING_BS16T2_HWTIMER is not set
509+
# CONFIG_BSP_USING_BS16T3_HWTIMER is not set
504510

505511
#
506512
# RTC Drivers
@@ -515,7 +521,7 @@ CONFIG_BSP_USING_UART2=y
515521
#
516522
# ADC Drivers
517523
#
518-
# CONFIG_BSP_USING_ADC is not set
524+
# CONFIG_BSP_USING_ADC0 is not set
519525

520526
#
521527
# Onboard Peripheral Drivers
@@ -532,6 +538,7 @@ CONFIG_BSP_USING_UART2=y
532538
# CONFIG_BSP_USING_EXAMPLE_ADC_VOL is not set
533539
# CONFIG_BSP_USING_EXAMPLE_HWTIMER is not set
534540
# CONFIG_BSP_USING_EXAMPLE_I2C is not set
541+
# CONFIG_BSP_USING_EXAMPLE_I2C_E2PROM is not set
535542
# CONFIG_BSP_USING_EXAMPLE_LED_BLINK is not set
536543
# CONFIG_BSP_USING_EXAMPLE_PIN_BEEP is not set
537544
# CONFIG_BSP_USING_EXAMPLE_PWM_LED is not set
Lines changed: 160 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,160 @@
1+
menu "UART Drivers"
2+
3+
config BSP_USING_UART0
4+
bool "Register UART0"
5+
select RT_USING_SERIAL
6+
default n
7+
8+
config BSP_USING_UART1
9+
bool "Register UART1"
10+
select RT_USING_SERIAL
11+
default n
12+
13+
config BSP_USING_UART2
14+
bool "Register UART2"
15+
select RT_USING_SERIAL
16+
default y
17+
18+
config BSP_USING_UART3
19+
bool "Register UART3"
20+
select RT_USING_SERIAL
21+
default n
22+
23+
config BSP_USING_USART0
24+
bool "Register USART0"
25+
select RT_USING_SERIAL
26+
default n
27+
28+
config BSP_USING_USART1
29+
bool "Register USART1"
30+
select RT_USING_SERIAL
31+
default n
32+
endmenu
33+
34+
menu "SPI Drivers"
35+
36+
config BSP_USING_SPI0
37+
bool "Register SPI0"
38+
select RT_USING_SPI
39+
select RT_USING_PIN
40+
default n
41+
42+
config BSP_USING_SPI1
43+
bool "Register SPI1"
44+
select RT_USING_SPI
45+
select RT_USING_PIN
46+
default n
47+
endmenu
48+
49+
menu "I2C Drivers"
50+
config BSP_USING_I2C0
51+
bool "Register I2C0"
52+
select RT_USING_I2C
53+
default n
54+
55+
config BSP_USING_I2C1
56+
bool "Register I2C1"
57+
select RT_USING_I2C
58+
default n
59+
endmenu
60+
61+
menu "CAN Drivers"
62+
config BSP_USING_CAN0
63+
bool "Register CAN0"
64+
select RT_USING_CAN
65+
select RT_CAN_USING_HDR
66+
default n
67+
endmenu
68+
69+
menu "PWM Drivers"
70+
config BSP_USING_AD16C4T0_PWM
71+
bool "Register pwm0"
72+
select RT_USING_PWM
73+
default n
74+
75+
config BSP_USING_GP16C4T0_PWM
76+
bool "Register pwm1"
77+
select RT_USING_PWM
78+
default n
79+
80+
config BSP_USING_GP16C2T0_PWM
81+
bool "Register pwm2"
82+
select RT_USING_PWM
83+
default n
84+
85+
config BSP_USING_GP16C2T1_PWM
86+
bool "Register pwm3"
87+
select RT_USING_PWM
88+
default n
89+
endmenu
90+
91+
menu "HWtimer Drivers"
92+
config BSP_USING_AD16C4T0_HWTIMER
93+
bool "Register timer0"
94+
select RT_USING_HWTIMER
95+
default n
96+
depends on !BSP_USING_AD16C4T0_PWM
97+
98+
config BSP_USING_GP16C4T0_HWTIMER
99+
bool "Register timer1"
100+
select RT_USING_HWTIMER
101+
default n
102+
depends on !BSP_USING_GP16C4T0_PWM
103+
104+
config BSP_USING_GP16C2T0_HWTIMER
105+
bool "Register timer2"
106+
select RT_USING_HWTIMER
107+
default n
108+
depends on !BSP_USING_GP16C2T0_PWM
109+
110+
config BSP_USING_GP16C2T1_HWTIMER
111+
bool "Register timer3"
112+
select RT_USING_HWTIMER
113+
default n
114+
depends on !BSP_USING_GP16C2T1_PWM
115+
116+
config BSP_USING_BS16T0_HWTIMER
117+
bool "Register timer4"
118+
select RT_USING_HWTIMER
119+
default n
120+
121+
config BSP_USING_BS16T1_HWTIMER
122+
bool "Register timer5"
123+
select RT_USING_HWTIMER
124+
default n
125+
depends on !BSP_USING_UART2
126+
127+
config BSP_USING_BS16T2_HWTIMER
128+
bool "Register timer6"
129+
select RT_USING_HWTIMER
130+
default n
131+
depends on !BSP_USING_UART3
132+
133+
config BSP_USING_BS16T3_HWTIMER
134+
bool "Register timer7"
135+
select RT_USING_HWTIMER
136+
default n
137+
endmenu
138+
139+
menu "RTC Drivers"
140+
config BSP_USING_RTC
141+
bool "Register RTC"
142+
select RT_USING_RTC
143+
default n
144+
endmenu
145+
146+
menu "PM Drivers"
147+
config BSP_USING_PM
148+
bool "Using PM"
149+
select RT_USING_PM
150+
default n
151+
endmenu
152+
153+
menu "ADC Drivers"
154+
config BSP_USING_ADC0
155+
bool "Using ADC"
156+
select RT_USING_ADC
157+
select BSP_USING_ADC
158+
default n
159+
endmenu
160+
Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
/*
2+
* Change Logs:
3+
* Date Author Notes
4+
* 2021-04-20 liuhy the first version
5+
*
6+
* Copyright (C) 2021 Shanghai Eastsoft Microelectronics Co., Ltd. All rights reserved.
7+
*
8+
* SPDX-License-Identifier: Apache-2.0
9+
*
10+
* Licensed under the Apache License, Version 2.0 (the License); you may
11+
* not use this file except in compliance with the License.
12+
* You may obtain a copy of the License at
13+
*
14+
* www.apache.org/licenses/LICENSE-2.0
15+
*
16+
* Unless required by applicable law or agreed to in writing, software
17+
* distributed under the License is distributed on an AS IS BASIS, WITHOUT
18+
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19+
* See the License for the specific language governing permissions and
20+
* limitations under the License.
21+
*
22+
*/
23+
24+
#ifndef __ES_CONF_INFO_ADC_H__
25+
#define __ES_CONF_INFO_ADC_H__
26+
27+
#include "es_conf_info_map.h"
28+
29+
#include <ald_adc.h>
30+
31+
32+
#define ES_C_ADC_CLK_DIV_1 ADC_CKDIV_1
33+
#define ES_C_ADC_CLK_DIV_2 ADC_CKDIV_2
34+
#define ES_C_ADC_CLK_DIV_4 ADC_CKDIV_4
35+
#define ES_C_ADC_CLK_DIV_8 ADC_CKDIV_8
36+
#define ES_C_ADC_CLK_DIV_16 ADC_CKDIV_16
37+
#define ES_C_ADC_CLK_DIV_32 ADC_CKDIV_32
38+
#define ES_C_ADC_CLK_DIV_64 ADC_CKDIV_64
39+
#define ES_C_ADC_CLK_DIV_128 ADC_CKDIV_128
40+
41+
#define ES_C_ADC_ALIGN_RIGHT ADC_DATAALIGN_RIGHT
42+
#define ES_C_ADC_ALIGN_LEFT ADC_DATAALIGN_LEFT
43+
44+
#define ES_C_ADC_CONV_BIT_6 ADC_CONV_BIT_6
45+
#define ES_C_ADC_CONV_BIT_8 ADC_CONV_BIT_8
46+
#define ES_C_ADC_CONV_BIT_10 ADC_CONV_BIT_10
47+
#define ES_C_ADC_CONV_BIT_12 ADC_CONV_BIT_12
48+
49+
#define ES_C_ADC_SAMPLE_TIME_1 ADC_SAMPLETIME_1
50+
#define ES_C_ADC_SAMPLE_TIME_2 ADC_SAMPLETIME_2
51+
#define ES_C_ADC_SAMPLE_TIME_4 ADC_SAMPLETIME_4
52+
#define ES_C_ADC_SAMPLE_TIME_15 ADC_SAMPLETIME_15
53+
54+
/* ADC 配置 */
55+
56+
/* codes_main */
57+
58+
59+
#define ES_ADC0_ALIGN ES_C_ADC_ALIGN_RIGHT
60+
#define ES_ADC1_ALIGN ES_C_ADC_ALIGN_RIGHT
61+
#define ES_ADC1_DATA_BIT ES_C_ADC_CONV_BIT_12
62+
#define ES_ADC0_DATA_BIT ES_C_ADC_CONV_BIT_12
63+
64+
#ifndef ES_DEVICE_NAME_ADC0
65+
#define ES_DEVICE_NAME_ADC0 "adc0"
66+
#endif
67+
#ifndef ES_DEVICE_NAME_ADC1
68+
#define ES_DEVICE_NAME_ADC1 "adc1"
69+
#endif
70+
71+
#ifndef ES_ADC0_CLK_DIV
72+
#define ES_ADC0_CLK_DIV ES_C_ADC_CLK_DIV_128
73+
#endif
74+
#ifndef ES_ADC0_ALIGN
75+
#define ES_ADC0_ALIGN ES_C_ADC_ALIGN_RIGHT
76+
#endif
77+
#ifndef ES_ADC0_DATA_BIT
78+
#define ES_ADC0_DATA_BIT ES_C_ADC_CONV_BIT_12
79+
#endif
80+
#ifndef ES_ADC0_NCH_SAMPLETIME
81+
#define ES_ADC0_NCH_SAMPLETIME ES_C_ADC_SAMPLE_TIME_4
82+
#endif
83+
84+
#ifndef ES_ADC1_CLK_DIV
85+
#define ES_ADC1_CLK_DIV ES_C_ADC_CLK_DIV_128
86+
#endif
87+
#ifndef ES_ADC1_ALIGN
88+
#define ES_ADC1_ALIGN ES_C_ADC_ALIGN_RIGHT
89+
#endif
90+
#ifndef ES_ADC1_DATA_BIT
91+
#define ES_ADC1_DATA_BIT ES_C_ADC_CONV_BIT_12
92+
#endif
93+
#ifndef ES_ADC1_NCH_SAMPLETIME
94+
#define ES_ADC1_NCH_SAMPLETIME ES_C_ADC_SAMPLE_TIME_4
95+
#endif
96+
97+
#endif

0 commit comments

Comments
 (0)