Nuvoton NuMaker-MS51PC User Manual

Nuvoton NuMaker-MS51PC User Manual

8-bit microcontroller
Table of Contents

Advertisement

Quick Links

NuMaker-MS51PC
1T 8051
8-bit Microcontroller
NuMaker-MS51PC
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
Aug 30, 2019
Page 1 of 40
Rev 1.00

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the NuMaker-MS51PC and is the answer not in the manual?

Questions and answers

Summary of Contents for Nuvoton NuMaker-MS51PC

  • Page 1 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.
  • Page 2: Table Of Contents

    2.7 PCB Placement ......................23 3 QUICK START ....................24 3.1 Toolchains Supporting ....................24 3.2 Nuvoton Nu-Link Driver Installation ................25 3.3 BSP Firmware Download ................... 27 3.4 Hardware Setup ......................28 3.5 Find the Example Project ................... 30 3.6 Execute the Project under Toolchains ..............
  • Page 3 NuMaker-MS51PC 5 REVISION HISTORY ..................39 Aug 30, 2019 Page 3 of 40 Rev 1.00...
  • Page 4 Figure 2.5-1 External Power Supply Sources on Nu-Link2-Me ............. 17 Figure 2.5-2 External Power Supply Sources on MS51 Platform ..........18 Figure 2.5-3 Separate the Nu-Link2-Me from NuMaker-MS51PC ..........19 Figure 2.5-4 Wiring between Ammeter Connector and Ammeter ..........20 Figure 2.7-1 Front Placement ......................
  • Page 5 NuMaker-MS51PC List of Tables Table 2.3-1 Arduino UNO Extension Connectors and MS51PC0AE Mapping GPIO List ..... 11 Table 2.4-1 MS51PC0AE Full-pin Extension Connectors and GPIO Function List ....... 13 Table 2.5-1 Vin Power Source ....................... 15 Table 2.5-2 5V Power Sources ...................... 15 Table 2.5-3 3.3 V Power Sources ....................
  • Page 6: Overview

    NuMaker-MS51PC OVERVIEW This user manual is aimed to give users a fast introduction to the use of NuMaker-MS51PC board. The NuMaker-MS51PC consists of two parts, a MS51 platform and an on-board Nu-Link2-Me debugger and programmer. The NuMaker-MS51PC allows users to quickly develop and easily program and debug application.
  • Page 7: Numaker-Ms51Pc Features

    NuMaker-MS51PC NuMaker-MS51PC Features  ® NuMicro MS51PC0AE used as main microcontroller with function downward compatible with:  MS51EC0AE  MS51FC0AE  MS51TC0AE  ML51XC0AE  MS51PC0AE full pins extension connectors  Arduino UNO compatible extension connectors  Ammeter connector for measuring the microcontroller’s power consumption ...
  • Page 8: Numaker-Ms51Pc Overview

    NuMaker-MS51PC NUMAKER-MS51PC OVERVIEW Front View Figure 2.1-1 Front View of NuMaker-MS51PC Figure 2.1-1 shows the main components and connectors from the front side of NuMaker-MS51PC. The following lists components and connectors from the front view:  Target Chip: MS51PC0AE (U2) ...
  • Page 9: Rear View

    NuMaker-MS51PC Rear View Figure 2.2-1 shows the main components and connectors from the rear side of NuMaker-MS51PC. The following lists components and connectors from the rear view:  Nu-Link2-Me  MCUVCC Power Switch (ICEJPR1)  ICEVCC Power Switch (ICEJPR2) Figure 2.2-1 Rear View of NuMaker-MS51PC...
  • Page 10: Arduino Uno Compatible Extension Connectors

    NuMaker-MS51PC Arduino UNO Compatible Extension Connectors Figure 2.3-1 shows the Arduino UNO compatible extension connectors. UART3_RXD PWM3_CH1 P3.4 UART3_TXD PWM0_CH2 P0.5 CLKO PWM0_CH0 P3.3 SPI0_CLK P1.0 PWM3_CH0 P3.2 PWM2_CH1 P3.1 P3.6 P3.7 P1.1 P1.2 SPI0_SS PWM0_CH5 P1.5 SPI0_MOSI ADC_CH1 P3.0...
  • Page 11: Table 2.3-1 Arduino Uno Extension Connectors And Ms51Pc0Ae Mapping Gpio List

    NuMaker-MS51PC NuMaker-MS51PC NuMaker-MS51PC Header Header Compatible to Compatible to GPIO Pin of MS51 GPIO Pin of MS51 Arduino UNO Arduino UNO NU3.1 P3.4 NU2.6 P2.1 NU3.2 P0.5 NU2.5 P0.3 NU3.3 P3.3 NU2.4 P0.4 NU3.4 P1.0 NU2.3 P2.4 NU3.5 P3.2 NU2.2 P2.3...
  • Page 12: Pin Assignment For Extension Connectors

    NuMaker-MS51PC Pin Assignment for Extension Connectors The NuMaker-MS51PC provides the MS51PC0AE target chip onboard and full pins extension connectors (JP3, JP4, JP5 and JP6). The Figure 2.4-1 shows the MS51PC0AE extension connectors. Figure 2.4-1 MS51PC0AE Extension Connectors Aug 30, 2019 Page 12 of 40 Rev 1.00...
  • Page 13: Table 2.4-1 Ms51Pc0Ae Full-Pin Extension Connectors And Gpio Function List

    NuMaker-MS51PC MS51PC0AE Header Function Pin No. P2.0/RESET JP3.1 JP3.2 P3.0/OSCIN/INT0/UART2_TX/SPI0_MOSI/ADC_CH1 JP3.3 JP3.4 P1.7/INT1/UART2_RX/SPI0_CLK/ADC_CH0 JP3.5 JP3.6 JP3.7 JP3.8 P1.6/ICE_DAT/ICP_DAT/UART1_TX /I2C0_SDA JP3.9 JP3.10 JP3.11 JP3.12 P1.5/UART3_TX/SPI0_SS/ IC7/PWM3_CH1/PWM0_CH5 JP3.13 JP3.14 P2.5/UART3_RX/SPI0_MISO/ADC_CH15 JP3.15 JP3.16 P3.7/UART1_RX JP5.1 JP5.2 P3.6/UART1_TX JP5.3 JP5.4 P1.4/PWM0_CH1/I2C0_SDA/PWM0_BRAKE/ADC_CH14/ PWM1_CH1 JP5.5 JP5.6 P1.3/STADC/I2C0_SCL/ADC_CH13...
  • Page 14 NuMaker-MS51PC Aug 30, 2019 Page 14 of 40 Rev 1.00...
  • Page 15: System Configuration

    ICE USB connector supplies 5 V power from PC to ICEJ3 USB_HS_VBUS MS51 platform and Nu-Link2-Me. USB connector on NuMaker-MS51PC supplies 5 V USB_VBUS power from PC to MS51 platform and Nu-Link2-Me. ICEJ3, J2 or NU1 pin8 supplies 5 V power to NU1 pin5.
  • Page 16: Power Connectors

    Table 2.5-4 1.8V Power Sources 2.5.5 Power Connectors Table 2.5-5 presents the power connectors. Connector Comment (2.4 V ~ 5 V) connector on the NuMaker-MS51PC. connector on the NuMaker-MS51PC. Table 2.5-5 Power Connectors 2.5.6 USB Connectors Table 2.5-6 presents the USB connectors.
  • Page 17: Figure 2.5-1 External Power Supply Sources On Nu-Link2-Me

    NuMaker-MS51PC 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.
  • Page 18: Figure 2.5-2 External Power Supply Sources On Ms51 Platform

    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-MS51PC, please follow the below steps: 1. Switch the SW2 depends on the target chip operating voltage.
  • Page 19: Figure 2.5-3 Separate The Nu-Link2-Me From Numaker-Ms51Pc

    NuMaker-MS51PC Figure 2.5-3 Separate the Nu-Link2-Me from NuMaker-MS51PC Table 2.5-9 presents all power models when supplies external power through MS51 platform. The MS51 platform external power sources are highlighted in yellow. ICEJPR1 ICEJPR2 Target Chip ICE Chip (MCUVCC) (ICEVCC) Model...
  • Page 20: Ammeter Connector

    2.5.10 Extension Connectors Table 2.5-11 presents the extension connectors. Connector Comment JP3, JP4, JP5 and JP6 Full pins extension connectors on the NuMaker-MS51PC. NU1, NU2, NU3 and Arduino UNO compatible pins on the NuMaker-MS51PC. Table 2.5-11 Extension Connectors 2.5.11 Push-Buttons Table 2.5-12 presents the push-buttons.
  • Page 21: Table 2.5-13 Leds

    NuMaker-MS51PC Component Comment Power LED The power LED indicates that the NuMaker-MS51PC is powered. P3.5 LED The LED which is connected to the target chip P3.5. ICES0, ICES1, ICES2 Nu-Link2-Me status LED. and ICES3 Table 2.5-13 LEDs Aug 30, 2019 Page 21 of 40 Rev 1.00...
  • Page 22: Nu-Link2-Me

    NuMaker-MS51PC Nu-Link2-Me The Nu-Link2-Me is a debugger and programmer that supports on-line programming and debugging through OCD interface. 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.
  • Page 23: Pcb Placement

    NuMaker-MS51PC PCB Placement Figure 2.7-1 and Figure 2.7-2 show the front and rear placement of NuMaker-M51PC. Figure 2.7-1 Front Placement Figure 2.7-2 Rear Placement Aug 30, 2019 Page 23 of 40 Rev 1.00...
  • Page 24: Quick Start

    NuMaker-MS51PC QUICK START Toolchains Supporting Install the preferred toolchain. Please make sure at least one of the toolchains has been installed. KEIL C51 IAR EW8051 Aug 30, 2019 Page 24 of 40 Rev 1.00...
  • Page 25: Nuvoton Nu-Link Driver Installation

    NuMaker-MS51PC 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.
  • Page 26: Figure 3.2-2 Nu-Link Usb Driver Installation

    NuMaker-MS51PC Figure 3.2-2 Nu-Link USB Driver Installation Aug 30, 2019 Page 26 of 40 Rev 1.00...
  • Page 27: Bsp Firmware Download

    NuMaker-MS51PC BSP Firmware Download Download and unzip the Board Support Package (BSP).  Download and unzip MS51_Series_BSP_Keil when using Keil C51.  Download and unzip MS51_Series_BSP_IAR when using IAR EW8051. Aug 30, 2019 Page 27 of 40 Rev 1.00...
  • Page 28: Hardware Setup

    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. Aug 30, 2019 Page 28 of 40 Rev 1.00...
  • Page 29: Figure 3.4-3 Device Manger

    NuMaker-MS51PC 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 Aug 30, 2019 Page 29 of 40...
  • Page 30: Find The Example Project

    NuMaker-MS51PC Find the Example Project Use the “Template” project as an example. The project can be found under the BSP folder as shown:  MS51_Series_BSP_Keil_V1.XX.XXX  SampleCode  Template  Keil  Figure 3-5 Template Project Folder Path Aug 30, 2019 Page 30 of 40 Rev 1.00...
  • Page 31: Execute The Project Under Toolchains

    Figure 3.6-1 Project File Migrate to Version 5 Format 1. 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 3.6.1.
  • Page 32: Figure 3.6-3 Programming Setting In Options Window

    NuMaker-MS51PC Figure 3.6-3 Programming Setting in Options Window 2. 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. Rebuild 2. Successfully compile 3. Download 4.
  • Page 33: Iar Ew8051

    NuMaker-MS51PC source code, assembly language, peripherals’ registers, and setting breakpoint, step run, value monitor, etc. 3 1 2 1. Run 2. Stop 3. Reset Figure 3.6-5 Keil MDK Debug Mode Figure 3.6-6 Debug Message on Serial Port Terminal Windows 3.6.2 IAR EW8051 This section provides steps to beginners on how to run a project by using IAR EW8051.
  • Page 34: Figure 3.6-7 Iar Ew8051 Window

    NuMaker-MS51PC 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. Make 2. Successfully compile 3. Download and Debug Figure 3.6-8 Compile and Download the Project 4.
  • Page 35: Figure 3.6-9 Iar Ew8051 Debug Mode

    NuMaker-MS51PC 1 2 3 1. Go 2. Break 3. Reset Figure 3.6-9 IAR EW8051 Debug Mode Figure 3.6-10 Debug Message on Serial Port Terminal Windows Aug 30, 2019 Page 35 of 40 Rev 1.00...
  • Page 36: Numaker-Ms51Pc Schematics

    NuMaker-MS51PC NUMAKER-MS51PC SCHEMATICS 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 OCD interface. 3.3V ICER1 Off-page Connector 200 1% USB_HS_CAP R0603 ICE5V ICEC1 ICEC2 ICE5V 0.1u MCUVCC_DIODE...
  • Page 37: Ms51 Platform

    NuMaker-MS51PC MS51 Platform Figure 4.2-1 shows the MS51 platform circuit. P1 - P8 P17 - P24 P17_LED_R P17_P3.5 nRESET TICERST P3.1_NU3_D5 P3.0_NU4_D11 P3.2_NU3_D4 P1.7_NU4_D13 P1.2_NU4_D9 P1.1_NU4_D8 P5_ICE_DAT TICEDAT P1.0_NU3_D3 VDD_MCU P23_XT1_IN P23_P0.0 P24_XT1_OUT P1.5_NU4_D10 P24_P0.1 P2.5_NU4_D12 P9 - P16 P25 - P32 P3.3...
  • Page 38: Extension Connector

    NuMaker-MS51PC Extension Connector Figure 4.3-1 shows extension connectors of NuMaker-MS51PC. P1 - P8 P17 - P24 TICERST P17_P3.5 P3.0_NU4_D11 P3.1_NU3_D5 P1.3_NU4_SCL I2C_SCL P1.7_NU4_D13 P3.2_NU3_D4 P1.4_NU4_SDA I2C_SDA P1.2_NU4_D9 VREF TICEDAT P1.1_NU4_D8 P1.0_NU3_D3 TICERST P1.7_NU4_D13 MCU_RESET P1.5_NU4_D10 P23_P0.0 NU1_3VCC P2.5_NU4_D12 3VCC P2.5_NU4_D12 P24_P0.1...
  • Page 39 NuMaker-MS51PC REVISION HISTORY Date Revision Description 2019.08.30 1.00 Initial Release. Aug 30, 2019 Page 39 of 40 Rev 1.00...
  • Page 40 NuMaker-MS51PC 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”.

Table of Contents