numaker-ml51pc user manual - nuvoton · numaker-ml51pc jun 04, 2019 page 1 of 36 rev 1.01 r-m l l...

36
NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 NUMAKER-ML51PC USER MANUAL 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro ® 8051 Series The information described in this document is the exclusive intellectual property of Nuvoton Technology Corporation and shall not be reproduced without permission from Nuvoton. Nuvoton is providing this document only for reference purposes of NuMicro microcontroller based system design. Nuvoton assumes no responsibility for errors or omissions. All data and specifications are subject to change without notice. For additional information or questions, please contact: Nuvoton Technology Corporation. www.nuvoton.com

Upload: others

Post on 26-May-2020

6 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 1 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

1T 8051

8-bit Microcontroller

NuMaker-ML51PC

User Manual NuMicro® 8051 Series

The information described in this document is the exclusive intellectual property of Nuvoton Technology Corporation and shall not be reproduced without permission from Nuvoton.

Nuvoton is providing this document only for reference purposes of NuMicro microcontroller based system design. Nuvoton assumes no responsibility for errors or omissions.

All data and specifications are subject to change without notice.

For additional information or questions, please contact: Nuvoton Technology Corporation.

www.nuvoton.com

Page 2: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 2 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Table of Contents

1. OVERVIEW ...................................................................................................... 6

1.1. NuMaker-ML51PC Features ........................................................................................ 7

2. NUMAKER-ML51PC OVERVIEW .................................................................... 8

2.1. Front View ....................................................................................................................... 8

2.2. Rear View ....................................................................................................................... 9

2.3. Arduino UNO Compatible Extension Connectors ................................................... 10

2.4. Pin Assignment for Extension Connectors .............................................................. 12

2.5. System Configuration.................................................................................................. 14

VIN Power Source .......................................................................................................... 14

5 V Power Sources ........................................................................................................ 14

3.3 V Power Sources ..................................................................................................... 14

1.8V Power Sources ...................................................................................................... 14

Power Connectors .......................................................................................................... 15

USB Connectors ............................................................................................................. 15

Power Switches .............................................................................................................. 15

Power Supply Models .................................................................................................... 16

External Reference Voltage Connector ....................................................................... 19

..................................................................................... 19

.................................................................................. 19

............................................................................................... 19

........................................................................................................... 20

2.6. Nu-Link2-Me ................................................................................................................. 20

2.7. PCB Placement ........................................................................................................... 21

3. QUICK START ............................................................................................... 22

3.1. Toolchains Supporting ................................................................................................ 22

3.2. Nuvoton Nu-Link Driver Installation .......................................................................... 22

3.3. BSP Firmware Download ........................................................................................... 24

3.4. Hardware Setup ........................................................................................................... 24

3.5. Find the Example Project ........................................................................................... 26

3.6. Execute the Project under Toolchains ...................................................................... 27

Keil MDK .......................................................................................................................... 27

IAR EW8051 ................................................................................................................... 29

4. NUMAKER-ML51PC SCHEMATICS ............................................................. 32

4.1. Nu-Link2-Me ................................................................................................................. 32

4.2. ML51 Platform .............................................................................................................. 33

4.3. Extension Connector ................................................................................................... 34

Page 3: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 3 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

5. REVISION HISTORY ..................................................................................... 35

Page 4: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 4 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

List of Figures

Figure 1.1-1 NuMaker-ML51PC Board ............................................................................................ 6

Figure 2.1-1 Front View of NuMaker-ML51PC ................................................................................. 8

Figure 2.2-1 Rear View of NuMaker-ML51PC ................................................................................. 9

Figure 2.3-1 Arduino UNO Compatible Extension Connectors ...................................................... 10

Figure 2.4-1 ML51PC0AE Extension Connectors .......................................................................... 12

Figure 2.5-1 External Power Supply Sources on Nu-Link2-Me ..................................................... 16

Figure 2.5-2 External Power Supply Sources on ML51 Platform .................................................. 17

Figure 2.5-3 Separate the Nu-Link2-Me from NuMaker-ML51PC ................................................. 18

Figure 2.5-4 Wiring between Ammeter Connector and Ammeter .................................................. 19

Figure 2.7-1 Front Placement ........................................................................................................ 21

Figure 2.7-2 Rear Placement ......................................................................................................... 21

Figure 3.2-1 Nu-Link USB Driver Installation Setup....................................................................... 22

Figure 3.2-2 Nu-Link USB Driver Installation ................................................................................. 23

Figure 3.4-1 Open VCOM Function ............................................................................................... 24

Figure 3.4-2 ICE USB Connector ................................................................................................... 24

Figure 3.4-3 Device Manger ........................................................................................................... 25

Figure 3.4-4 PuTTY Session Setting ............................................................................................. 25

Figure 3-5 Template Project Folder Path ....................................................................................... 26

Figure 3.6-1 Project File Migrate to Version 5 Format ................................................................... 27

Figure 3.6-2 Debugger Setting in Options Window........................................................................ 27

Figure 3.6-3 Programming Setting in Options Window .................................................................. 28

Figure 3.6-4 Compile and Download the Project ........................................................................... 28

Figure 3.6-5 Keil MDK Debug Mode .............................................................................................. 29

Figure 3.6-6 Debug Message on Serial Port Terminal Windows ................................................... 29

Figure 3.6-7 IAR EW8051 Window ................................................................................................ 30

Figure 3.6-8 Compile and Download the Project ........................................................................... 30

Figure 3.6-9 IAR EW8051 Debug Mode ........................................................................................ 31

Figure 3.6-10 Debug Message on Serial Port Terminal Windows ................................................. 31

Figure 4.1-1 Nu-Link2-Me Circuit ................................................................................................... 32

Figure 4.2-1 ML51 Platform Circuit ................................................................................................ 33

Figure 4.3-1 Extension Connectors Circuit .................................................................................... 34

Page 5: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 5 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

List of Tables

Table 2.3-1 Arduino UNO Extension Connectors and ML51PC0AE Mapping GPIO List ............. 11

Table 2.4-1 ML51PC0AE Full-pin Extension Connectors and GPIO Function List ....................... 13

Table 2.5-1 Vin Power Source ....................................................................................................... 14

Table 2.5-2 5V Power Sources ...................................................................................................... 14

Table 2.5-3 3.3 V Power Sources .................................................................................................. 14

Table 2.5-4 1.8V Power Sources ................................................................................................... 15

Table 2.5-5 Power Connectors ...................................................................................................... 15

Table 2.5-6 USB Connectors ......................................................................................................... 15

Table 2.5-7 Power Switches .......................................................................................................... 15

Table 2.5-8 Supply External Power through Nu-Link2-Me ............................................................ 16

Table 2.5-9 Supply External Power for ML51 platform .................................................................. 18

Table 2.5-10 External Reference Voltage Connector .................................................................... 19

Table 2.5-11 Ammeter Connector .................................................................................................. 19

Table 2.5-12 Extension Connectors ............................................................................................... 19

Table 2.5-13 Push-Buttons ............................................................................................................ 20

Table 2.5-14 LEDs ......................................................................................................................... 20

Table 2.6-1 VCOM Function of Nu-Link2-Me ................................................................................. 20

Page 6: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 6 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

1. OVERVIEW

This user manual is aimed to give users a fast introduction to the use of NuMaker-ML51PC board.

The NuMaker-ML51PC consists of two parts, a ML51 platform and an on-board Nu-Link2-Me debugger and programmer. The NuMaker-ML51PC allows users to quickly develop and easily program and debug application.

The NuMaker-ML51PC offers ML51PC0AE full pins extension connectors, Arduino UNO compatible extension connectors and diversified power supply option. It is an easy-to-develop platform for user to expand the functionality and build the applications. The NuMaker-ML51PC also provides an ammeter connector, allows user to monitor the microcontroller’s power consumption during development.

The Nu-Link2-Me is a debugger and programmer that support on-line programming and debugging through OCD interface. The on-board 16 Mbit SPI Flash allows it able to off-line programming the target microcontroller. Nu-Link2-Me provides virtual COM port (VCOM) function to print out messages on PC. Nu-Link2-Me can be separated from NuMaker-ML51PC, allowing user to use as a mass production programming tool.

Figure 1.1-1 NuMaker-ML51PC Board

Page 7: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 7 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

1.1. NuMaker-ML51PC Features

NuMicro® ML51PC0AE used as main microcontroller with function downward compatible with:

ML51EC0AE

ML51UC0AE

ML51TC0AE

ML51PC0AE full pins extension connectors

Arduino UNO compatible extension connectors

Ammeter connector for measuring the microcontroller’s power consumption

Fixable board power supply:

External VDD power connector

Arduino UNO compatible extension connector Vin

USB power connector on ML51 platform

ICE USB connector on Nu-Link2-Me

On-board Nu-Link2-Me debugger and programmer:

Debug through OCD interface

On-line/off-line programming

Virtual COM port function

Page 8: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 8 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2. NUMAKER-ML51PC OVERVIEW

2.1. Front View

ICE USB Connector

VCOM Switch

Reset Button

ICE Status LEDOff-line Program Button

USB Power Connector

Power LEDPB14 LED

VDD Switch

Target Chip: ML51PC0AE Target Chip Extension Connector

Arduino UNO Compatible Extension Connector

External VDD Connector

Nu-Link2-Me

Ammeter

ICE Chip: M48SSIDAE

External VSS Connector

ML51 Platform

Figure 2.1-1 Front View of NuMaker-ML51PC

Figure 2.1-1 shows the main components and connectors from the front side of NuMaker-ML51PC. The following lists components and connectors from the front view:

Target Chip: ML51PC0AE(U1)

USB Power Connector(J2)

Arduino UNO Compatible Extension Connectors (NU1, NU2, NU3, NU4)

ML51 Extension Connectors (JP3, JP4, JP5 and JP6)

External VDD Power Connector(JP1)

External VSS Power Connector(JP2)

VDD Switch(SW2)

Ammeter Connector(AMMETER)

Reset Button(SW1)

Power LED and PB14 LED(LEDG1 and LEDR1)

Nu-Link2-Me

VCOM Switch

ICE Chip: M48SSIDAE(ICEU2)

ICE USB Connector(ICEJ3)

ICE Status LED(ICES0,ICES1, ICES2, ICES3)

Off-line Program Button(ICESW1)

Page 9: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 9 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2.2. Rear View

Figure 2.2-1 shows the main components and connectors from the rear side of NuMaker-ML51PC.

The following lists components and connectors from the rear view:

Nu-Link2-Me

MCUVCC Power Switch (ICEJPR1)

ICEVCC Power Switch (ICEJPR2)

ICEVCC Power Switch

MCUVCC Power Switch

Figure 2.2-1 Rear View of NuMaker-ML51PC

Page 10: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 10 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2.3. Arduino UNO Compatible Extension Connectors

Figure 2.3-1 shows the Arduino UNO compatible extension connectors.

UART1_TXD PWM0_CH2 PB.2 D0UART1_RXD PWM0_CH3 PB.3 D1I2C1_SCL PA.12 D2I2C1_SDA PA.13 D3UART0_TXD PA.14 D4UART0_RXD PA.15 D5

NC D6NC D7

NC D8NC D9

SPI0_SS PWM0_CH2 PA.3 D10SPI0_MOSI PWM0_CH5 PA.0 D11SPI0_MISO PWM0_CH4 PA.1 D12

SPI0_CLK PWM0_CH3 PA.2 D13

VSS VSS

AVDD VREF

UART2_TXD I2C0_SCL PC.0 SDA

UART2_RXD I2C0_SDA PC.1 SCL

A5 PB.1 ADC0_CH1 I2C1_SCL UART2_TXDA4 PB.0 ADC0_CH0 I2C1_SDA UART2_RXDA3 PB.4 ADC0_CH4A2 PB.5 ADC0_CH5A1 PB.14 ADC0_CH14A0 PB.15 ADC0_CH15

VINVSSVSS5V3VRSTIOREF VDD

NC

Figure 2.3-1 Arduino UNO Compatible Extension Connectors

Page 11: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 11 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Header

NuMaker-ML51PC

Header

NuMaker-ML51PC

Compatible to Arduino UNO

GPIO Pin of ML51 Compatible to Arduino UNO

GPIO Pin of ML51

N

U

4

NU3.1 D0 P2.2

N

U

2

NU2.6 A5 P2.1

NU3.2 D1 P2.3 NU2.5 A4 P2.0

NU3.3 D2 P1.4 NU2.4 A3 P2.4

NU3.4 D3 P1.5 NU2.3 A2 P2.5

NU3.5 D4 P1.6 NU2.2 A1 P3.2

NU3.6 D5 P1.7 NU2.1 A0 P3.3

NU3.7 D6 NC

N

U

1

NU1.8 VIN

-

NU3.8 D7 NC NU1.7 VSS

N

U

3

NU4.1 D8 NC NU1.6 VSS

NU4.2 D9 NC NU1.5 5V

NU4.3 D10 P0.3 NU1.4 3V

NU4.4 D11 P0.0 NU1.3 RST nRESET

NU4.5 D12 P0.1 NU1.2 IOREF VDD

NU4.6 D13 P0.2 NU1.1 NC -

NU4.7 VSS VSS

NU4.8 VREF NC

NU4.9 SDA P4.0

NU4.10 SCL P4.1

Table 2.3-1 Arduino UNO Extension Connectors and ML51PC0AE Mapping GPIO List

Page 12: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 12 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2.4. Pin Assignment for Extension Connectors

The NuMaker-ML51PC provides the ML51PC0AE target chip onboard and full pins extension connectors (JP3, JP4, JP5 and JP6). The Figure 2.4-1 shows the ML51PC0AE extension connectors.

JP3Pin1 ~ Pin8

JP6Pin25 ~ Pin32

JP5 Pin9 ~ Pin18

JP4 Pin19 ~ Pin24

Figure 2.4-1 ML51PC0AE Extension Connectors

Page 13: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 13 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Header ML51PC0AE

Pin No. Function

JP3

JP3.1 JP3.2 1 P2.5/ADC_CH0/ACMP0_P0/ACMP1_P0/I2C0_SCL/PWM0_CH0/UART2_TXD/T0/INT0

JP3.3 JP3.4 2 P2.4/ADC_CH1/ACMP0_N0/I2C0_SDA/PWM0_CH1/UART2_RXD/T1/INT1

JP3.5 JP3.6 3 P2.3/ADC_CH2/ACMP0_P1/ACMP1_P1/I2C1_SCL/UART1_TXD/PWM0_CH2/PWM0_BRAKE

JP3.7 JP3.8 4 P2.2/ADC_CH3/ACMP1_N0/I2C1_SDA/UART1_RXD/PWM0_CH3

JP3.9 JP3.10 5 P2.1/ADC_CH4/ACMP0_P2/ACMP1_P2/UART2_TXD/I2C1_SCL/PWM0_CH4/PWM0_BRAKE

JP3.11 JP3.12 6 P2.0/ADC_CH5/ACMP0_N1/UART2_RXD/I2C1_SDA/PWM0_CH5/PWM0_BRAKE

JP3.13 JP3.14 7 P5.5/UART2_RXD/PWM0_CH0/X32_IN/STADC

JP3.15 JP3.16 8 P5.4/UART2_TXD/PWM0_CH1/X32_OUT

JP5

JP5.1 JP5.2 9 P5.3/UART0_TXD/I2C0_SCL/XT1_IN

JP5.3 JP5.4 10 P5.2/UART0_RXD/I2C0_SDA/XT1_OUT

JP5.5 JP5.6 11 P0.3/SPI0_SS/SPI1_SS/UART1_TXD/I2C1_SCL/STADC/PWM0_CH2

JP5.7 JP5.8 12 P0.2/SPI0_CLK/SPI1_CLK/UART1_RXD/I2C1_SDA/PWM0_CH3

JP5.9 JP5.10 13 P0.1/SPI0_MISO/SPI1_MISO/UART0_TXD/PWM0_CH4

JP5.11 JP5.12 14 P0.0/SPI0_MOSI/SPI1_MOSI/UART0_RXD/PWM0_CH5

JP5.13 JP5.14 15 P5.6/PWM0_BRAKE/PWM0_CH1/CLKO

JP5.15 JP5.16 16 RST

JP4

JP4.1 JP4.2 17 P5.0/UART1_TXD/I2C1_SCL/UART0_TXD/ICE_DAT

JP4.3 JP4.4 18 P5.1/UART1_RXD/I2C1_SDA/UART0_RXD/ICE_CLK

JP4.5 JP4.6 19 P4.1/UART2_TXD/I2C0_SCL/ACMP0_O

JP4.7 JP4.8 20 P4.0/UART2_RXD/I2C0_SDA/ACMP1_O/INT1

JP4.9 JP4.10 21 P1.4/I2C1_SCL

JP4.11 JP4.12 22 P1.5/I2C1_SDA

JP4.13 JP4.14 23 P1.6/UART0_TXD

JP4.15 JP4.16 24 P1.7/UART0_RXD

JP6

JP6.1 JP6.2 25 VSS

JP6.3 JP6.4 26 P4.6/PWM0_CH0/T0/CLKO/INT0

JP6.5 JP6.6 27 VDD

JP6.7 JP6.8 28 P3.3/SPI1_SS/IC0/PWM0_BRAKE

JP6.9 JP6.10 29 P3.2/ADC_CH7/ACMP1_N1/SPI1_CLK/IC1/CLKO

JP6.11 JP6.12 30 P3.1/ADC_CH6/ACMP0_P3/ACMP1_P3/SPI1_MISO/UART0_TXD/IC2

JP6.13 JP6.14 31 P3.0/SPI1_MOSI/UART0_RXD/IC0

JP6.15 JP6.16 32 VREF

Table 2.4-1 ML51PC0AE Full-pin Extension Connectors and GPIO Function List

Page 14: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 14 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2.5. System Configuration

VIN Power Source

Table 2.5-1 presents the Vin power source.

Connector Net Name in Schematic

Comment

NU1 pin8 NU1_VIN

Board external power source, with voltage range from 7 V to 12 V. The voltage regulator UP2 converts the NU1 pin8 input voltage to 5 V and supplies it to NuMaker-ML51PC.

Table 2.5-1 Vin Power Source

5 V Power Sources

Table 2.5-2 presents the 5 V power sources.

Connector Net Name in Schematic

Comment

ICEJ3 USB_HS_VBUS ICE USB connector supplies 5 V power from PC to ML51 platform and Nu-Link2-Me.

J2 USB_VBUS USB connector on NuMaker-ML51PC supplies 5 V power from PC to ML51 platform and Nu-Link2-Me.

NU1 pin5 NU1_5VCC ICEJ3, J2 or NU1 pin8 supplies 5 V power to NU1 pin5. NU1 pin5 supplies 5 V power to target chip or Arduino adapter board.

Table 2.5-2 5V Power Sources

3.3 V Power Sources

Table 2.5-3 presents the 3.3 V power sources.

Voltage Regulator 5V Source Comment

ICEUP1 USB_HS_VBUS ICEUP1 converts USB_HS_VBUS to 3.3 V and supplies 3.3V to ML51 platform or ICE chip.

UP1 USB_VBUS

UP1 converts USB_VBUS to 3.3 V and supplies 3.3 V to ML51 platform.

Note: SW2.2(NU1 3VCC) should be switched to ON.

UP1 NU1_5VCC

UP1 converts NU1_5VCC to 3.3 V and supplies 3.3 V to ML51 platform.

Note: SW2.2(NU1 3VCC) should be switched to ON.

Table 2.5-3 3.3 V Power Sources

1.8V Power Sources

Table 2.5-4 presents the 1.8 V power source.

Page 15: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 15 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Voltage Regular 5V Source Comment

ICEUP2 USB_HS_VBUS ICEUP2 converts USB_HS_VBUS to 1.8V and supplies 1.8V to ML51 platform or ICE chip.

Table 2.5-4 1.8V Power Sources

Power Connectors

Table 2.5-5 presents the power connectors.

Connector Comment

JP1 VDD (1.8 V ~ 3.6 V) connector on the NuMaker-ML51PC.

JP2 VSS connector on the NuMaker-ML51PC.

Table 2.5-5 Power Connectors

USB Connectors

Table 2.5-6 presents the USB connectors.

Connector Comment

ICEJ3 ICE USB connector on Nu-Link2-Me for power supply, debugging and programming from PC.

J2 USB power connector on NuMaker-ML51PC for power supply.

Table 2.5-6 USB Connectors

Power Switches

Table 2.5-7 presents the power switches.

Switch Comment

ICEJPR1 Configures the target chip operating voltage at 1.8 V / 3.3 V / 5 V.

ICEJPR2 Configures the ICE chip operating voltage at 1.8 V / 3.3 V.

SW2 Configures the target chip operating voltage at 3.3 V / 5 V.

Table 2.5-7 Power Switches

Page 16: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 16 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Power Supply Models

External Power Supply through Nu-Link2-Me to Target Chip

The external power supply source on Nu-Link2-Me is shown in Figure 2.5-1.

ICE USB Connector (ICEJ3)

Nu-Link2-Me

Figure 2.5-1 External Power Supply Sources on Nu-Link2-Me

To use ICEJ3 as external power supply source with Nu-Link2-Me, please follow the below steps:

1. Solder the resistor on ICEJPR1 (MCUVCC) depends on the target chip operating voltage.

2. Solder the resistor on ICEJPR2 (ICEVCC) depends on the ICE chip operating voltage.

3. Switch the SW2 to OFF.

4. Connect the external power supply to JP1.

Table 2.5-8 presents all power models when supplies external power through Nu-Link2-Me. The Nu-Link2-Me external power sources are highlighted in yellow.

Model Target Chip

Voltage ICEJ3

ICEJPR1 (MCUVCC) Selection [1]

ICEJPR2 (ICEVCC)

Selection [2]

ICE Chip

Voltage

SW2 Selection

J2 Vin JP1

1 1.8 V Connect

to PC 1.8 V 1.8 V 1.8 V Off Ignore Ignore

1.8 V output

2 3.3 V Connect

to PC 3.3 V (default)

3.3 V (default)

3.3 V Off Ignore Ignore 3.3 V output

3 5 V Connect

to PC 5V

3.3 V (default)

3.3 V Off Ignore Ignore 5 V

output

X: Unused.

Note:

1. 0 Ω should be soldered between ICEJPR1’s MCUVCC and 1.8 V / 3.3 V / 5 V.

2. 0 Ω should be soldered between ICEJPR2’s ICEVCC and 1.8 V / 3.3 V.

Table 2.5-8 Supply External Power through Nu-Link2-Me

Page 17: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 17 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

External Power Supply through ML51 platform to Target Chip

The external power supply sources on ML51 platform are shown in Figure 2.5-2.

USB Power Connector (J2)

NU1 pin8 (Vin)

External VDD Connector (JP1)

External VSS Connector (JP2)

Figure 2.5-2 External Power Supply Sources on ML51 Platform

To use Vin or J2 as external power supply source, please follow the below steps:

1. Switch the SW2 depends on the target chip operating voltage.

2. Remove the resistor on ICEJPR1 (MCUVCC).

3. Solder the resistor on ICEJPR2 (ICEVCC) depends on the ICE chip operating voltage.

4. Connect the external power supply to Vin or J2.

To use JP1 as external power supply source, please follow the below steps:

1. Switch the SW2 to OFF.

2. Remove the resistor on ICEJPR1 (MCUVCC).

3. Solder the resistor on ICEJPR2 (ICEVCC) depends on the ICE chip operating voltage.

4. Connect ICEJ3 to PC.

5. Connect the external power supply to JP1.

To use Vin or J2 as external power supply source with Nu-Link2-Me separated from NuMaker-ML51PC, please follow the below steps:

1. Switch the SW2 depends on the target chip operating voltage.

2. Separate the Nu-Link2-Me from NuMaker-ML51PC.

3. Connect the external power supply to Vin or J2.

To use JP1 as external power supply source with Nu-Link2-Me separated from NuMaker-ML51PC, please follow the below steps:

1. Switch the SW2 to OFF.

2. Separate the Nu-Link2-Me from NuMaker-ML51PC.

Page 18: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 18 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

3. Connect the external power supply to JP1.

USB Power Connector (J2)

NU1 pin8 (Vin)

External VDD Connector (JP1)

External VSS Connector (JP2)Separate Nu-Link2-Me

"

"

Figure 2.5-3 Separate the Nu-Link2-Me from NuMaker-ML51PC

Table 2.5-9 presents all power models when supplies external power through ML51 platform. The ML51 platform external power sources are highlighted in yellow.

Model Target Chip

Voltage Vin [1] J2 ICEJ3

SW2 Selection

JP1 ICEJPR1

(MCUVCC) Selection [2]

ICEJPR2 (ICEVCC)

Selection [3]

ICE Chip Voltage [4]

4 3.3 V 7 V ~ 12 V

Input X Ignore

NU1 3VCC

3.3 V output Remove resistor

3.3 V 3.3 V

5 3.3 V X Connect

to PC Ignore

NU1 3VCC

3.3 V output Remove resistor

3.3 V 3.3 V

6 5 V 7 V ~ 12 V

Input X Ignore

NU1 5VCC

5 V output Remove resistor

3.3 V 3.3 V

7 5 V X Connect

to PC

Ignore NU1 5VCC

5 V output Remove resistor

3.3 V 3.3 V

8 1.8 V ~ 3.6 V Ignore [5] Ignore [5] Connect to

PC OFF DC Input

1.8 V ~ 3.6 V Remove resistor

1.8 V / 3.3 V 1.8 V / 3.3 V

9 1.8 V ~ 3.6 V Ignore [5] Ignore [5] Nu-Link2-Me

removed OFF DC Input

1.8 V ~ 3.6 V X X X

X: Unused.

Note:

1. The Vin input voltage will be converted by voltage regulator UP2 to 5 V.

2. 0Ω should be removed from ICEJPR1’s MCUVCC and 1.8 V / 3.3 V / 5 V.

3. 0Ω should be soldered between ICEJPR2’s ICEVCC and 1.8 V / 3.3 V.

4. The ICE chip voltage should be close to the target chip voltage.

5. JP1 external power input only provides voltage to target chip. Supply external power to Vin or J2 can provide 5V to NU1 pin5 (5V) and 3.3V to NU1 pin4 (3VCC).

Table 2.5-9 Supply External Power for ML51 platform

Page 19: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 19 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

External Reference Voltage Connector

Table 2.5-11 presents the external reference voltage connector.

Connector Comment

VREF1 Connector for user to easily connect to the external reference voltage pin of the target chip. User needs to remove the L5 ferrite bead.

Table 2.5-10 External Reference Voltage Connector

Ammeter Connector

Table 2.5-11 presents the ammeter connector.

Connector Comment

AMMETER Connector for user to easily measure the target chip power consumption. User needs to remove the R16 resistor.

Table 2.5-11 Ammeter Connector

Remove the R16 Resistor

Figure 2.5-4 Wiring between Ammeter Connector and Ammeter

Extension Connectors

Table 2.5-12 presents the extension connectors.

Connector Comment

JP3, JP4, JP5 and JP6 Full pins extension connectors on the NuMaker-ML51PC.

NU1, NU2, NU3 and NU4 Arduino UNO compatible pins on the NuMaker-ML51PC.

Table 2.5-12 Extension Connectors

Push-Buttons

Table 2.5-13 presents the push-buttons.

Page 20: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 20 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Component Comment

ICESW1 Off-line program button to start off-line programming the target chip.

SW1 Reset button to reset the target chip.

Table 2.5-13 Push-Buttons

LEDs

Table 2.5-14 presents the LEDs.

Component Comment

Power LED The power LED indicates that the NuMaker-ML51PC is powered.

PB14 LED The LED which is connected to the target chip PB.14.

ICES0, ICES1, ICES2 and ICES3

Nu-Link2-Me status LED.

Table 2.5-14 LEDs

2.6. Nu-Link2-Me

The Nu-Link2-Me is a debugger and programmer that supports on-line programming and debugging through OCDinterface. The on-board 16 Mbit SPI Flash allows it to off-line program the target microcontroller. Additionally, the Nu-Link2-Me provides virtual COM port (VCOM) function to print out messages on PC. Table 2.6-1 presents how to set the VCOM function by ICESW2.

ICESW2

Pin Function Comment

1 TXD On: Connect target chip PB.13 (UART0_TXD) to Nu-Link2-Me.

Off: Disconnect target chip PB.13 (UART0_TXD) to Nu-Link2-Me.

2 RXD On: Connect target chip PB.12 (UART0_RXD) to Nu-Link2-Me.

Off: Disconnect target chip PB.12 (UART0_RXD) to Nu-Link2-Me.

Note: Pin 3 and 4 is unused.

Table 2.6-1 VCOM Function of Nu-Link2-Me

Page 21: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 21 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

2.7. PCB Placement

Figure 2.7-1 and Figure 2.7-2 show the front and rear placement of NuMaker-ML51PC.

Figure 2.7-1 Front Placement

Figure 2.7-2 Rear Placement

Page 22: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 22 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

3. QUICK START

3.1. Toolchains Supporting

Install the preferred toolchain. Please make sure at least one of the toolchains has been installed.

KEIL C51 IAR EW8051

3.2. Nuvoton Nu-Link Driver Installation

Download and install the latest Nuvoton Nu-Link Driver. Please install the Nu-Link USB Driver as well at the end of the installation.

Download and install Nu-Link_Keil_Driver when using Keil C51. Download and install Nu-Link_IAR_Driver when using IAR EW8051.

Please install the Nu-Link USB Driver as well at the end of the installation. The installation is presented in Figure 3.2-1 and Figure 3.2-2.

Figure 3.2-1 Nu-Link USB Driver Installation Setup

Page 23: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 23 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Figure 3.2-2 Nu-Link USB Driver Installation

Page 24: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 24 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

3.3. BSP Firmware Download

Download and unzip the Board Support Package (BSP).

Download and unzip ML51_Series_BSP_Keil when using Keil C51. Download and unzip ML51_Series_BSP_IAR when using IAR EW8051.

3.4. Hardware Setup

1. Open the virtual COM (VCOM) function by changing Nu-Link2-Me VCOM Switch No. 1 and 2 to ON.

Figure 3.4-1 Open VCOM Function

2. Connect the ICE USB connector shown in Figure 3.4-2 to the PC USB port through USB cable.

Figure 3.4-2 ICE USB Connector

3. Find the “Nuvoton Virtual COM Port” on the Device Manger as Figure 3.4-3.

Page 25: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 25 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Figure 3.4-3 Device Manger

4. Open a serial port terminal, PuTTY for example, to print out debug message. Set the speed to 115200. Figure 3.4-4 presents the PuTTY session setting.

Figure 3.4-4 PuTTY Session Setting

Page 26: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 26 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

3.5. Find the Example Project

Use the “Template” project as an example. The project can be found under the BSP folder as shown:

ML51_Series_BSP_Keil_V1.XX.XXX

SampleCode

Template

Keil

IAR

Figure 3-5 Template Project Folder Path

Page 27: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 27 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

3.6. Execute the Project under Toolchains

Open and execute the project under the toolchain. The section 3.2, 3.7.2 describe the steps of executing project in Keil PK51, IAR EW8051 respectively.

Keil MDK

This section provides steps to beginners on how to run a project by using Keil PK51.

1. Double click the “Template.uvproj” to open the project.

1

2

3

Figure 3.6-1 Project File Migrate to Version 5 Format

2. Make sure the debugger is “Nuvoton Nu-Link Debugger” as shown in Figure 3.6-2 and Figure 3.6-3.

Note: If the dropdown menu in Figure 3.6-2 does not contain “Nuvoton Nu-Link Debugger” item, please rework section 0.

Figure 3.6-2 Debugger Setting in Options Window

Page 28: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 28 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Figure 3.6-3 Programming Setting in Options Window

3. Rebuild all target files. After successfully compile the project, download code to the flash memory. Click “Start/Stop Debug Section” button can enter debug mode.

1 3

2

4

1. Rebuild

3. Download

4. Start/Stop Debug

2. Successfully compile

Figure 3.6-4 Compile and Download the Project

4. Figure 3.6-5 shows the debug mode under Keil MDK. Click “Run” and the debug message will be printed out as shown in Figure 3.6-6. User can debug the project under debug mode by checking

Page 29: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 29 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

source code, assembly language, peripherals’ registers, and setting breakpoint, step run, value monitor, etc.

2. Stop

3 1 21. Run

3. Reset

Figure 3.6-5 Keil MDK Debug Mode

Figure 3.6-6 Debug Message on Serial Port Terminal Windows

IAR EW8051

This section provides steps to beginners on how to run a project by using IAR EW8051.

1. Double click the “Template.eww” to open the project.

2. Make sure the toolbar contain “Nu-Link” item as shown in Figure 3.6-7.

Note: If the toolbar does not contain “Nu-Link” item, please rework section 0.

Page 30: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 30 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Figure 3.6-7 IAR EW8051 Window

3. Make target file as presented in Figure 3.6-8. After successfully compile the project, download code to the flash memory and enter debug mode.

1 3

2

1. Make

3. Download and Debug

2. Successfully compile

Figure 3.6-8 Compile and Download the Project

4. Figure 3.6-9 shows the debug mode under IAR EW8051. Click “Go” and the debug message will be printed out as shown in Figure 3.6-10. User can debug the project under debug mode by checking source code, assembly language, peripherals’ registers, and setting breakpoint, step run, value monitor, etc.

Page 31: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 31 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

1 2 3

1. Go

3. Reset

2. Break

Figure 3.6-9 IAR EW8051 Debug Mode

Figure 3.6-10 Debug Message on Serial Port Terminal Windows

Page 32: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 32 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

4. NUMAKER-ML51PC SCHEMATICS

4.1. Nu-Link2-Me

Figure 4.1-1 shows the Nu-Link2-Me circuit. The Nu-Link2-Me is a debugger and programmer that supports on-line programming and debugging through OCDinterface.

Figure 4.1-1 Nu-Link2-Me Circuit

GND

REDGREEN

NU

LIN

K_ID

1N

ULIN

K_ID

0

SW

DH

_C

LK

ICEU1

<M48SSIDAE>

PB

.61

PB

.52

PB

.43

PB

.34

PB

.25

PB

.16

PB

.07

PA

.11

8

PA

.10

9

PA

.910

PA

.811

PF

.612

VB

AT

13

PF

.514

PF

.415

PF

.316

PF.217PC.718PC.619PA.720PA.621VSS22VDD23LDO_CAP24PA.525PA.426PA.327PA.228PA.129PA.030VDDIO31nRESET32

PF

.033

PF

.134

PC

.535

PC

.436

PC

.337

PC

.238

PC

.139

PC

.040

HS

US

B_V

RE

S41

HS

US

B_V

DD

33

42

HS

US

B_V

BU

S43

HS

US

B_D

-44

HS

US

B_V

SS

45

HS

US

B_D

+46

HS

US

B_V

DD

12_C

AP

47

HS

US

B_ID

48

VSS49

LDO_CAP50

VDD51

PC.1452

PB.1553

PB.1454

PB.1355

PB.1256

AVDD57

VREF58

AVSS59

PB.1160

PB.1061

PB.962

PB.863

PB.764

SW

DH

_D

AT

ICE

LE

D

ICE

VD

DS

WD

H_R

ST

#

HX

T_I

ICE_RSTICEVDD

HXT_O

SWO

ICEC6

1u

C0603ISPLEDKEY1

GNDICEVDD

US

B_H

S_V

BU

S

US

B_H

S_C

AP

US

B_H

S_R

EX

T

GN

DU

SB

_H

S_D

+

US

B_H

S_D

-

USB_HS_CAP

ICEC2

1u

C0603

ICE

_D

AT

ICE

_C

LK

SP

IM_D

3

SP

IM_M

ISO

0

SP

IM_C

S

SP

IM_M

OS

I0

SP

IM_C

LK

SP

IM_D

2

GND

ICEVDD

USB_HS_VBUS

ICED30.1u

C0603

DEBUG RESET

ICEVDD

ICER310KR0603

ICE_RST

ICEC9

1uC0603

ICE_DATICE_CLKICE_RST

ICE_DAT

ICEVDD

ICE_CLK

ICEJ1

HEADER_5(NC)

12345

ICEVDDICER210K

R0603

ICER410K

R0603

ETMD1

ETMCK_MOSIETMD0_MISO

ETMD2_CKETMD3_SS

ICE_RXICE_RX_S

ICESW2

SMD HPS604-E

ICE_TXICE_TX_S

VCOM SWITCH

ETMD2_CKETMD3_SS

ETMCK_MOSIETMD0_MISO

NULINK_ID0 NULINK_ID1

Nu-Trace, ID0 = 1, ID1 = 1Nu-Link2, ID0 = 0, ID1 = 1Nu-LInk2-Me, ID0 = 0, ID1 = 0

NULINK ID

SWDH_DATSWDH_CLKSWDH_RST#

GND

TICEDAT

TICERST

MCUVCC_DIODE

MCU_RXMCU_TX

TICECLK

ICE_TX_SICE_RX_S

MCUVCC

1 2

ICED4

SS24A

ICER1200 1%

R0603

HS

US

B_V

DD

33

HXT_O

HXT_I

ICEC10 20p

C0603

ICEC11 20p

C0603

12M Crystal

ICEX1

12MHz SMD X3225B1

XIN

2

GND

4GND

3XOUT

3.3V

SPIM_MISO0

ICEU2

W25Q16JVSSIQ

SOP8\5.23/1.27MM

CS#1

DO2

WP#3

GND4

DI5CLK6HOLD#7VCC8

3.3V

SPI FLASH

ICEC12

0.1u

C0603

SN74LV2T45DCUR

ICEU4

SOP8/3.1/0.5

GND4 A23

VCCA1

DIR5

A12

B26B17VCCB8

SPIM_CLK_LV

SN74LV2T45DCUR

ICEU3

SOP8/3.1/0.5

GND4 A23

VCCA1

DIR5

A12

B26B17VCCB8

SPIM_MOSI0_LV

SPIM_CS_LV

SPIM_CS

ICEVDD3.3V

SPIM_CS_LV SPIM_CLKSPIM_MOSI0

SPIM_CLK_LVSPIM_MOSI0_LV

ICEVDD3.3V

ICER1810KR0603

3.3V

ICER1910KR0603

3.3V

ICE INTERFACE

ICEJ4

HEADER 2.54 5X2 (NC)

1 23 45 67 89 10

Title

Size File Name : Rev

Date: Sheet of

Author :

Nu-Link2-Me 1.0

Nu-Link2-Me

CMHuangA3

1 3Thursday, January 24, 2019

SWDH_DATSWDH_CLKSWDH_RST#

SWO

ICE_RX_S

ICE_TX_S

ICEC7

4.7u

C0603

ICEC1

0.1u

C0603

ICEVDD

ICEC8470p

C0603

MSG_EN

MS

G_E

N

ETMD3_SS I2C1_SCL QSPI_SS BUSY

5V

ETMD2_CK I2C1_SDA QSPI_CLK START

ETMCK_MOSI UART0_RX QSPI_MOSIPASSICE_RX

ETMD0_MISO UART0_TX QSPI_MISOFAILICE_TX

USB_HS_VBUS ICEJ3

micro USB 5pin

MICRO_USB_AB

VBUS1

D-2

D+3

GND5

ID4

Shield6

Shield7

Shield8

Shield9

Shield10

Shield11

DM

DP

ICEL2

FERRITE BEAD

L0603

ICER60

ICER70

USB_HS_D-

USB_HS_D+

USB 2.0 HIGH SPEED DEVICES

ISPLED

RED

ICELED

GREEN1 2

ICES3

0805 LED G (綠光 ) 普亮KP-2012

DPDM

ICERP1

8P4R-330

8P4RA

1 23 45 67 8

ICEJ2

HEADER04(NC)

1234

ICEVDD

USB_HS_VBUS

1 2

ICES20805 LED R (紅光 ) 高亮KP-2012

1 2

ICES10805 LED Y (黃光 )高亮

KP-2012

1 2

ICES0

0805 LED R (紅光 ) 高亮KP-2012

LED

KEY1

ICEVDD

KEY

ICER510KR0603ICESW1

3x6x5 2PIN SMD

SW-2P-SMD

MCUVCC_DIODE

MCUVCC_DIODE

3.3V

ICE5V

ICE5V

ICEVDD

5V

ICE5VUSB_HS_VBUS

Power Switch

1 2

ICED1

SS24A

ICEUP2ACE1117_ADJ

IN3

AD

J1

OU

T2

OU

T4

ICEUP1AMS1117_3.3v

IN3

GN

D1

OU

T2

OU

T4

ICER8120,1%R0603

ICER982, 1%

R0603

3.3V

ICEVCC

ICEJPR2

1&2 (0 ohm)

123

1.8V 3.3V 3.3VICECT110uF/10VTANT-A

12 1.8V

MCUVCC

ICEJPR1

1&2 (0 ohm)

1234

1.8V

ICECT310uF/10V

12

ICEC5

0.1u

C0603

ICEVCC ICEVDD

ICEL1

FERRITE BEAD

ICECT210uF/10VTANT-A

12

Off-page Connector

ICEC3

1u

C0603

ICEC4

0.1u

C0603

Page 33: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 33 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

4.2. ML51 Platform

Figure 4.2-1 shows the ML51 platform circuit.

Figure 4.2-1 ML51 Platform Circuit

PC0_NU4_SDAPC1_NU4_SCL

VDD

J1

HEADER 2.54 5X2 (NC)

1 23 45 67 89 10

PA12_NU3_D2

TICEDATTICECLK

PA13_NU3_D3

PB12_RXD0PB13_TXD0

ICE

PA14_NU3_D4PA15_NU3_D5

P19P20

SW13x6x5 2PIN SMD

SW-2P-SMD

P21

C910uC0603

R310KR

R0603

P24

P22P23

RESET

VDD

nRESET

PF0_ICE_DATP17PF1_ICE_CLKP18

VDD_MCU

PB14_NU2_A1

VDD_MCULDO_CAPGND

VREF

MCU_TXMCU_RX

PB15_NU2_A0

LDO_CAPP26P25

PB14_LED_RP29P28

P32

VDD_2P27

PB12_RXD0P31PB13_TXD0P30

12

LEDG1GreenLED0805

PB2_NU3_D0/RXPB3_NU3_D1/TXPB4_NU2_A3PB5_NU2_A2

PB0_NU2_A4/SDA/RXPB1_NU2_A5/SCL/TX

PF4_X32_OUTPF5_X32_IN

SW2

SMD HPS602-E

PF2_XT1_OUT

PA2_NU3_D13/CLK

PA0_NU3_D11/MOSIPF15

PA1_NU3_D12/MISO

PA3_NU3_D10/SS

TICERST

nRESETPF1_ICE_CLKPF0_ICE_DAT

R14100KR

R0603

R13100KR

R0603

UP2AMS1117_5v

IN3

GN

D1

OU

T2

OU

T4

Title

Size Document Number Rev

Date: Sheet of

NuMaker-ML51PC

v1.0Ml51PC0AECustom

2 3Thursday , April 25, 2019

Bypass Cap

P17 - P24

P9 - P16

P1 - P8

P25 - P32

NU1_VIN

R7330R

R0603

1 2

D2

SS24A

C30.1uC0603

R6330R

R0603

CT510uF/10VTANT-A

12

12

LEDR1RedLED0805

VDDVDD_MCU

VDD

VDD_MCU

PF2_XT1_OUTP10

P14P13P12P11

nRESETP16P15

P1

P5P4P3P2

P6PF5_X32_INP7PF4_X32_OUTP8

1 2

D1

SS24A

USB Device

UP1AMS1117_3.3v

IN3

GN

D1

OU

T2

OU

T4

NU1_3VCC

CT410uF/10VTANT-A

12

NU1_5VCC

PF2_XT1_OUT

PF3_XT1_IN

R16 0

R2 0

AMMETERNC

1 2

R5 0

MCUVCC_DIODE

C8 20p

X1

32MHz 49S SMDXTAL\LP\SMD

C2 20p

HXT & LXT Crystal

X2

SMD 32.768K X3215

9HT9

PF4_X32_OUT

PF5_X32_INR1 0

R4 0

C1 20p

C7 20p

JP2

NC

1234

JP1

NC

1234

C151u

VDD VREF

C110.1u

CT210uF/10V

12

L5

FERRITE BEAD

Power

LED

L1

FERRITE BEAD

U2

ML51PC0AE

P2

.5/A

DC

_C

H0

/AC

MP

0_

P0

/AC

MP

1_

P0

/I2

C0

_S

CL

/PW

M0

_C

H0

/UA

RT

2_

TX

D/T

0_

INT

01

P2

.4/A

DC

_C

H1

/AC

MP

0_

N0

/I2

C0

_S

DA

/PW

M0

_C

H1

/UA

RT

2_

RX

D/T

1/I

NT

12

P2

.3/A

DC

_C

H2

/AC

MP

0_

P1

/AC

MP

1_

P1

/I2

C1

_S

CL

/UA

RT

1_

TX

D/P

WM

0_

CH

2/P

WM

0_

BR

AK

E3

P2

.2/A

DC

_C

H3

/AC

MP

1_

N0

/I2

C1

_S

DA

/UA

RT

1_

rXD

/PW

M0

_C

H3

4

P2

.1/A

DC

_C

H4

/AC

MP

0_

P2

/AC

MP

1_

P2

/UA

RT

2_

TX

D/I

2C

1+S

CL

/PW

M0

_C

H4

/PW

M1

_C

H4

/PW

M0

_B

RA

KE

5

P2

.0/A

DC

_C

H5

/AC

MP

0_

N1

/UA

RT

2_

RX

D/I

2C

1_

SD

A/P

WM

0_

CH

5/P

WM

1_

CH

5/P

WM

0_

BR

AK

E6

P5

.5/U

AR

T2

_R

XD

/PW

M0

_C

H0

/X3

2_

IN/E

AD

C0

_S

T7

P5

.4/U

AR

T2

_T

XD

/PW

M0

_C

H1

/X3

2_

OU

T8

nRESET16

ICE

_D

AT

/UA

RT

0_

TX

D/I

2C

1_

SC

L/U

AR

T1

_T

XD

/P5

.017

ICE

_C

LK

/UA

RT

0_

RX

D/I

2C

1_

SD

A/U

AR

T1

_R

XD

/P5

.118

VSS25

P4.6/PWM1_BRAKE/PWM0_CH0/TM0_CLKO/INT026

VDD27

P3.3/SPI1_SS/PWM1_CH0/TM2_EXT0/PWM0_BRAKE28

P3.2/ADC_CH7/ACMP1_N1/CPI1_CLK/UART3_RXD/PWM1_CH1/TM2_EXT1/CLK029

CLKO/PWM0_CH1/PWM0_BRAKE/P5.615

PWM0_CH5/UART0_RXD/SPI1_MOSI/SPI0_MOSI/P0.014

PWM0_CH4/UART0_TXD/SPI1_MISO/SPI0_MISO/P0.113

PWM0_CH3/I2C1_SDA/UART1_RXD/SPI1_CLK/SPI0_CLK/P0.212

PWM1_BRAKE/CLKO/PWM0_CH2/I2C1_SCL/UART1_TXD/SPI1_SS/SPI0_SS/P0.311

XT1_OUT/I2C0_SDA/UART0_RXD/P5.210

XT1_IN/I2C0_SCL/UART0_TXD/P5.39

AC

MP

0_

O/P

WM

1_

CH

4/I

2C

0_

SC

L/U

AR

T2

_T

XD

/P4

.119

AC

MP

1_

O/P

WM

1_

CH

5/I

2C

0_

SD

A/U

AR

T2

_R

XD

/P4

.020

I2C

1_

SC

L/P

1.4

21

I2C

1_

SD

A/P

1.5

22

UA

RT

0_

TX

D/P

1.6

23

UA

RT

0_

RX

D/P

1.7

24

P3.1/ADC_CH6/ACMP0_P3/ACMP1_P3/SPI1_MISO/UART3_TXD/UART0_TXD/PWM1_CH2/TM2_EXT230

P3.0/SPI1_MOSI/UART0_RXD/PWM1_CH3/TM2_EXT031

AVDD/VREF32

P10

P12P13P14P15

P9

P16

P11

P29P28P27P26P25

P32P31P30

P7

P2

P4

P8

P5

P6

P1

P3

ICE5V

P20

P19

P18

P17

P24

P23

P22

P21

PB14_LED_RC100.1u

CT11uF/16V

12

USB_VBUS

L3

FERRITE BEADL0603

J2

micro USB 5pin

MICRO_USB_AB

VBUS1

D-2

D+3

GND5

ID4

Shield6

Shield7

Shield8

Shield9

Shield10

Shield11

USB_VBUS

H1

H-3.4X6

1

H2

H-3.4X6

1

H4

H-3.4X6

1

H3

H-3.4X6

1

Mounting Hole

VREF NC

12

VDD_2

PF3_XT1_INPF3_XT1_INP9

VDD

NU1_3VCC

NU1_5VCC

R12 0(NC)

Page 34: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 34 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

4.3. Extension Connector

Figure 4.3-1 shows extension connectors of NuMaker-ML51PC.

Figure 4.3-1 Extension Connectors Circuit

PF4_X32_OUTPF5_X32_IN

PF3_XT1_IN

P1

P6P5P4P3P2

P8P7

JP3

HEADER8x2/2.54 (NC)

2468

10121416

13579111315

JP4

HEADER8x2/2.54 (NC)

2468

10121416

13579111315

JP5

HEADER8x2/2.54 (NC)

2468

10121416

13579111315

JP6

HEADER8x2/2.54 (NC)

2468

10121416

13579111315

PF2_XT1_OUTPA3_NU3_D10/SSPA2_NU3_D13/CLK

TICERST

PA0_NU3_D11/MOSIPF15

PA1_NU3_D12/MISO

P20P21P22

P17P18

P24P23

P19

VDDP22

P17P18

P24P23

P19P20P21

P29P28

P26P27

P25

P32P31P30

P29P28

P26P27

P25

P32P31P30

P13

P9P10

P12P11

P17 - P24

P16P15P14

P13P12

P10P11

P9

P16P15P14

PB3_NU3_D1/TXPB4_NU2_A3PB5_NU2_A2

PB0_NU2_A4/SDA/RXPB1_NU2_A5/SCL/TXPB2_NU3_D0/RX

P24 - P32

LDO_CAPGND

VREF

VDD_MCU

MCU_TXMCU_RX

PB15_NU2_A0PB14_NU2_A1

External Connector

UNO Interface

P1 - P8

P9 - P18

P2

P4P3

P1

P8P7P6P5

Title

Size Document Number Rev

Date: Sheet of

NuMaker-ML51PC

v1.2Ext. ConnectorCustom

3 3Monday , March 04, 2019

PC0_NU4_SDAPC1_NU4_SCL NU1

HEADER 2.54 8X1 f emale

NC1

VDD2

MCU_RESET3

3VCC4

5VCC5

VSS6

VSS7

VIN8

TICECLK

PA13_NU3_D3PA12_NU3_D2

NU3

HEADER 2.54 8X1 f emale

D01D12D23D34D45D56D67D78

PA14_NU3_D4PA15_NU3_D5

TICEDAT

NU2

HEADER 2.54 6X1 f emale

A01

A12

A23

A34

A4/SDA5

A5/SCL6

NU4

HEADER 2.54 10X1 f emale

D81D92D103D114D125D136VSS7VREF8I2C_SDA9I2C_SCL10

GNDGND

TICERST

PB4_NU2_A3

PB14_NU2_A1PB5_NU2_A2

PB15_NU2_A0

PC0_NU4_SDAPC1_NU4_SCL

PB0_NU2_A4/SDA/RXPB1_NU2_A5/SCL/TX

PA3_NU3_D10/SS

PA2_NU3_D13/CLK

VREFGND

NU3_D8_NCNU3_D9_NC

PA0_NU3_D11/MOSIPA1_NU3_D12/MISO

PA15_NU3_D5PA14_NU3_D4

NU3_D6_NCNU3_D7_NC

PB2_NU3_D0/RXPB3_NU3_D1/TXPA12_NU3_D2PA13_NU3_D3

NU1_VIN

NU1_5VCCNU1_3VCC

Page 35: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 35 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

5. REVISION HISTORY

Date Revision Description

2019.03.13 1.00 Initial Release.

2019.07.04 1.01 Modified Section 2.7 PCB placement picture.

Page 36: NuMaker-ML51PC User Manual - Nuvoton · NuMaker-ML51PC Jun 04, 2019 Page 1 of 36 Rev 1.01 R-M L l er Nu-2 1T 8051 8-bit Microcontroller NuMaker-ML51PC User Manual NuMicro® 8051 Series

NuMaker-ML51PC

Jun 04, 2019 Page 36 of 36 Rev 1.01

NU

MA

KE

R-M

L51

PC

US

ER

MA

NU

AL

Maker N

u-m

bed

NU

C472 U

ser M

an

ual

Important Notice

Nuvoton Products are neither intended nor warranted for usage in systems or equipment, any malfunction or failure of which may cause loss of human life, bodily injury or severe property damage. Such applications are deemed, “Insecure Usage”.

Insecure usage includes, but is not limited to: equipment for surgical implementation, atomic energy control instruments, airplane or spaceship instruments, the control or operation of dynamic, brake or safety systems designed for vehicular use, traffic signal instruments, all types of safety devices, and other applications intended to support or sustain life.

All Insecure Usage shall be made at customer’s risk, and in the event that third parties lay claims to Nuvoton as a result of customer’s Insecure Usage, customer shall indemnify the damages and liabilities thus incurred by Nuvoton.