DOC35_WT51F108S-104S Starter Kit Board Operation Manual V1.0

WT51F108S/104S Starter Kit Board
Operation Manual
WT51F108S/104S
Starter Kit Board
Operation Manual
REV. 1.0
May 26, 2016
This document is Weltrend confidential information. Do not copy.
WT51F108S/104S Starter Kit Board
Operation Manual
Ver.
1.0
Date
Applicant
2016/05/26
Louis 1st version
This document is Weltrend confidential information. Do not copy.
2
Description
WT51F108S/104S Starter Kit Board
Operation Manual
Table of contents
CHAPTER 1
WT51F108S/104S STARTER KIT BOARD HARDWARE DESCRIPTION ............................................4
1.1 SYSTEM BLOCK DIAGRAM ..................................................................................................................................... 4
1.2 STARTER KIT BOARD COMPONENTS LOCATION ...................................................................................................... 5
CHAPTER 2
2.1
2.2
2.3
2.4
DC INPUT CONNECTOR (J1) .................................................................................................................................. 6
SWUT (SINGLE-WIRE UART) PROGRAMMING INTERFACE PORT (J2)...................................................................... 6
2
WT51F108S/104S I C INTERFACE PORT .............................................................................................................. 7
TEST PINS (J6/J7) ................................................................................................................................................ 8
CHAPTER 3
3.1
3.2
3.3
3.4
3.5
WT51F108S/104S STARTER KIT BOARD I/O PORT DESCRIPTION ..................................................6
WT51F108S/104S STARTER KIT BOARD CIRCUIT DESCRIPTION ...................................................9
VDD POWER SELECTION ....................................................................................................................................... 9
POWER CIRCUIT .................................................................................................................................................... 9
RESET CIRCUIT ................................................................................................................................................. 10
OSCILLATE CIRCUIT............................................................................................................................................. 10
LDO 18 FILTER CIRCUIT...................................................................................................................................... 11
CHAPTER 4
WT51F108S/104S STARTER KIT BOARD OPERATION MANUAL....................................................12
4.1 WT51F108S/104S TESTING AND DEMO PLATFORM .............................................................................................. 12
4.2 LED DISPLAY ...................................................................................................................................................... 13
CHAPTER 5
DRIVER MODULE.......................................................................................................................................14
5.1 DRIVER MODULE SUMMARY ................................................................................................................................. 14
5.2 LED DRIVER MODULE <LED.C> ......................................................................................................................... 15
5.3 ADC DRIVER <DRV_ADC.C> .............................................................................................................................. 15
CHAPTER 6
APPENDIX.....................................................................................................................................................16
6.1 CIRCUIT .............................................................................................................................................................. 16
6.2 BOM .................................................................................................................................................................. 18
6.3 ORDERING INFORMATION ..................................................................................................................................... 19
This document is Weltrend confidential information. Do not copy.
3
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 1
1.1
WT51F108S/104S Starter Kit Board Hardware Description
System Block Diagram
WT51F108S/104S is an enhanced 8052 Micro Controller with a variety of peripheral functions, and the Starter
Kit Board is designed for 32-pin QFN type IC to demonstrate its functions. System structure is as the figure
below.
VDD
VDD
47uF
SCL
I2C
SDA
0.1uF
WT51F108S/104S
20pF
OSCI
12MHz
5V
OSCO
20pF
LED
GPIOC0
GPIOC1
VDD
GPIOC2
10K
RST / SWUT
GPIOC3
GPIOC4
4.7uF
GPIOC5
SWUT
AD_ADJ
ADC 2
LDO_18
10uF
0.1uF
This document is Weltrend confidential information. Do not copy.
4
5V
VR
WT51F108S/104S Starter Kit Board
Operation Manual
1.2
Starter Kit Board Components Location
This document is Weltrend confidential information. Do not copy.
5
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 2
2.1
WT51F108S/104S Starter Kit Board I/O Port Description
DC Input Connector (J1)
This is DC input connector for Starter Kit Board (supporting voltage: DC 5V).
2.2
Pad Number
Description
1
Positive Input Pin
2
--
3
Negative Input Pin
SWUT (Single-wire UART) Programming Interface Port (J2)
WT51F108S/104S Single-wire programming port as below:
Pitch (1.25 mm)
This document is Weltrend confidential information. Do not copy.
6
WT51F108S/104S Starter Kit Board
Operation Manual
2.3
Pad Number
Description
1
VDD
2
SWUT
3
GND
WT51F108S/104S I2C Interface Port
2
Components Location (J5): Slave I C Interface Port.
Pitch (1.25 mm)
Pad Number
Description
1
VDD
2
Slave_SCL
3
Slave_SDA
4
GND
This document is Weltrend confidential information. Do not copy.
7
WT51F108S/104S Starter Kit Board
Operation Manual
2.4
Test Pins (J6/J7)
These are testing signal pins.
J6
J7
P1
P2
P3
P4
P5
P6
P17
P18
P19
P20
P21
P22
P23
P24
P25
P26
P27
P28
P29
P30
P31
P32
P7
P8
P9
P10
P11
P12
P13
P14
P15
P16
Pitch (2.54 mm)
J6
Pad
Number
1-2
J7
GPIOA5DH/IRQ15/ADC15/OSCI/PWM1B/P00
Pad
Number
1-2
GPIOC2D/ PWM2C/P06
3-4
GPIOA4DH/IRQ14/ADC14/OSCO/PWM0B/P01
3-4
GPIOC1D/IRQ7/ADC7/P05
5-6
GPIOB5D/IRQ12/ADC12/RXA/PWM1A/P02
5-6
GPIOC0D/IRQ6/ADC6/PWM3B/P04
7-8
GPIOB4D/IRQ11/ADC11/TXA/PWM1D/P03
7-8
GPIOB2D/IRQ5/ADC5/STB/PWM0D
9-10
GPIOB3D/IRQ10/ADC10/PWM0A
9-10
GPIOB1D/IRQ4/ADC4/MOSI/PWM3A
11-12
GPIOC5D/IRQ9/ADC9
11-12
LDO18
13-14
GPIOC4D/IRQ8/ADC8
13-14
GPIOA2DH/IRQ2/ADC2/CMPO/PWM1C
15-16
GPIOC3D/PWM3C/P07
15-16
GPIOA1DHIRQ1/ADC1/VREF/
CMPN/SCKA/MISOB/RXA/SCL/PWM2B
17-18
GPIOA7DH
17-18
GPIOD5
19-20
GPIOA6DH
19-20
GPIOD4
Description
Description
21-22
GPIOB7D
21-22
GPIOA0DH//IRQ0/ADC0/CMPP/MISOA/
SCKB/TXA/SDA/PWM0D
23-24
GPIOB6D
23-24
VSS
25-26
GPIOC7D
25-26
VDD
27-28
GPIOC6D
27-28
GPIA3D/IRQ13/ADC13/NRST/SWUT
29-30
GPIOD1
29-30
GPIOD3
31-32
GPIOD0
31-32
GPIOD2
This document is Weltrend confidential information. Do not copy.
8
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 3
3.1
WT51F108S/104S Starter Kit Board Circuit Description
VDD Power Selection
There are three main power options for WT51F108S/104S Starter Kit Board.
(External power input cannot exceed Max. 5.5V as spec. definition).
1. 5V adapter (Select input is 5V by J1), J1 DC Jack (VDD)
2. External VDD: PO1 positive input, PO2 negative power, external VDD cannot exceed Max 5.5V as spec.
definition.
3. WLINK-SWUT VDD: Using WLINK-SWUT MCU_ VDD as WT51F108S/104S VDD power.
If power works normally, DB1 LED will light up.
3.2
Power circuit
VDD power input should be with filter capacitance, this is best that the layout is close to the pin.
This document is Weltrend confidential information. Do not copy.
9
WT51F108S/104S Starter Kit Board
Operation Manual
3.3
RESET Circuit
WT51F108S/104S RESET circuit and SWUT (Single-wire programming) use the same pin, the related circuit
description as below. When SWUT on programming, J3 JUMP should be removed, and disconnect from the
external RC RESET. After programming finished, J3 JUMP should be plugged in again, if the REST function
had been used.
3.4
Oscillate Circuit
WT51F108S/104S oscillates circuit as bellow:
This document is Weltrend confidential information. Do not copy.
10
WT51F108S/104S Starter Kit Board
Operation Manual
3.5
LDO 18 Filter Circuit
WT51F108S/104S LDO18 filter circuit as below illustrated:
This document is Weltrend confidential information. Do not copy.
11
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 4
4.1
WT51F108S/104S Starter Kit Board Operation Manual
WT51F108S/104S testing and demo platform
WT51F108S/104S Starter Kit Board built-in a single and easy LED flash to display functions, and reserved
some pins for testing usage.
This document is Weltrend confidential information. Do not copy.
12
WT51F108S/104S Starter Kit Board
Operation Manual
4.2
LED display
After Power on, LED will alternately blink on the Starter Kit Board. Meanwhile, adjusting VR1 can change
LED blinking speed.
This document is Weltrend confidential information. Do not copy.
13
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 5
5.1
Driver Module
Driver Module Summary
Please refer to the Driver module display, as below:
This document is Weltrend confidential information. Do not copy.
14
WT51F108S/104S Starter Kit Board
Operation Manual
5.2
LED Driver Module <LED.C>
Function
void DelayWhile(WORD
5.3
ms)
Description
NOP Delay Sub-Program
Void DRV_InitialXTAL(vold)
Initialize oscillator parameters
void DRV_InitPowerOn(void)
Call Timer 0 and ADC to initialize the functions
void SelectSourceClock(void)
MCU Source clock select internal IRC 12 MHZ and
enable external oscillator 32.768 kHz
void INIT_LED (void)
Initialize LED counter and initialize LED pins as
output ports
void Init_OS_Timer0(void)
Initialize Timer 0 count 10ms generate an interrupt
void LED_SHIFT (void)
Led shift light program
void SYS_InitialPort(void)
Initialize all GPIO as input ports and enable internal
pull-up resistors
void SYS_LoadCalibrationData(void)
Load Default IRC 12 MHZ correction value to register
void SYS_RoscCalibration(BYTE retry_cnt)
Auto calibration internal IRC 12 MHZ ±2%
void Timer0 (void) interrupt 1
Timer 0 interrupts sub-Program
void Timer0Service(void)
Timer 0 service program
ADC Driver <DRV_Adc.c>
Function
Description
WORD API_AverageADCData(BYTE ADC_Channel)
Sampling analog to digital average (16 times)
void DRV_AnalogKeyInitial(void)
Initialized Analog to Digital convert
WORD DRV_ReadAnalogChannel(BYTE
AD_Channel)
Assigned channel executing Analog to Digital
This document is Weltrend confidential information. Do not copy.
15
WT51F108S/104S Starter Kit Board
Operation Manual
Chapter 6
6.1
Appendix
Circuit
1. Power
This document is Weltrend confidential information. Do not copy.
16
WT51F108S/104S Starter Kit Board
Operation Manual
2. WT51F108S/104S (MCU)
This document is Weltrend confidential information. Do not copy.
17
WT51F108S/104S Starter Kit Board
Operation Manual
6.2
BOM
This document is Weltrend confidential information. Do not copy.
18
WT51F108S/104S Starter Kit Board
Operation Manual
6.3
Ordering Information
1. WT51F108S/104S Starter Kit
Kit
WT51F108S/104S
Starter Kit
Product Name
Number
Single-wire Programming Board PL-2303 (WLINK-SWUT) x 1
WA001
Simple Version (WT51F108S/104S Starter Kit Board) x 1
WB012
SWUT Programming Wire x 1
2. WT51F108S/104S Starter Kit Board
Kit
Product Name
Number
WT51F108S/104S Starter Kit Board
WB012
EVB Operation Manual
DOC35
WT51F108S/104S
3.
Single-wire Programming Board (WLINK-SWUT)
Kit
Single-wire
Programming
Board
WLINK-SWUT
Product Name
Number
Single-wire Programming Board PL-2303 (WLINK-SWUT)
WA001
WLINK-SWUT Operation Manual
DOC2
This document is Weltrend confidential information. Do not copy.
19