nubrick user manual - nuvoton...dali 2nd slave jul 11, 2019 page 3 of 18 rev 1.00 li 2 nd e us nual...
TRANSCRIPT
DALI 2nd Slave
Jul 11, 2019 Page 1 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
ARM® Cortex
®-M
32-bit Microcontroller
NuMicro® Family
DALI 2nd
Slave
User Manual
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
DALI 2nd Slave
Jul 11, 2019 Page 2 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
Table of Contents
1 General Description ...................................................................................................... 3
Feature .................................................................................................. 3 1.1
NuMicro® NDA102 Series Feature .................................................................. 4 1.2
2 Nuvoton DALI 2nd Slave Hardware Introduction ............................................................ 5
Jumper Description .................................................................................... 5 2.1
2.1.1 Power Interface ................................................................................................. 5
2.1.2 ICE interface for Nu-Link ...................................................................................... 5
2.1.3 DALI Bus Interface ............................................................................................. 6
2.1.4 DALI Interface and UART Interface .......................................................................... 6
2.1.5 Peripherial Interface ............................................................................................ 6
3 How to Start Nuvoton DALI 2nd Slave on the KEIL μVISION® IDE ................................ 7
Keil μVision® IDE Software Download and Install ................................................ 7 3.1
Nuvoton Nu-Link Driver Download and Install .................................................... 7 3.2
Hardware Setup ........................................................................................ 7 3.3
4 How to Start Nuvoton DALI 2nd Slave on the IAR Embedded Workbench .................... 8
IAR Embedded Workbench Software Download and Install .................................... 8 4.1
Nuvoton Nu-Link Driver Download and Install .................................................... 8 4.2
Hardware Setup ........................................................................................ 8 4.3
5 Nuvoton DALI 2nd Slave Quick Start ............................................................................. 9
Hardware Setup ........................................................................................ 9 5.1
Initialisation ............................................................................................ 10 5.2
DALI Commands ...................................................................................... 11 5.3
Monitoring Page ....................................................................................... 12 5.4
Button Function ....................................................................................... 12 5.5
6 Nuvoton DALI 2nd Slave Schematic ............................................................................ 13
NDA102EC1 Control Unit Schematic .............................................................. 13 6.1
DALI Bus Schematic ................................................................................. 14 6.2
LED Schematic ........................................................................................ 15 6.3
Power and Peripheral Schematic .................................................................. 16 6.4
7 REVISION HISTORY .................................................................................................. 17
DALI 2nd Slave
Jul 11, 2019 Page 3 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
1 GENERAL DESCRIPTION
The Nuvoton DALI 2nd
Slave is the specific development tool for DALI application. DALI is a protocol for digital addressable lighting device. The Arm
® Cortex
®-M0 core NuMicro
® NDA102 series
microcontroller is used as the main microcontroller in the demo board.
The NuMicro® NDA102 series 32-bit microcontrollers are embedded with ARM
® Cortex
®-M0 core for
industrial applications which need high performance, high integration, and low cost. It runs up to 48 MHz and offers 29.5 KB embedded program Flash, size configurable Data Flash (shared with program Flash), and 4 KB SRAM. The NDA102 series has many system level peripheral functions, such as I/O Port, Timer, UART, SPI, I
2C, PWM, ADC, Watchdog Timer, Analog Comparator, Hardware Divider and
Brown-out Detector. These useful functions make the demo board suitable for DALI standard implementations, and helps users to accelerate the development process. The NDA102’s fast computing ability allows faster device control and compound applications.
Feature 1.1 Compliance
IEC 62386-102:2014
IEC 62386-207:2009
IEC 62386-206:2009
IEC 62386-209:2011 (Colour Type Tc)
Future support: IEC 62386-103:2014, IEC 62384-2XX, IEC 62384-3XX
Color and dimming control for RGB LED
ADC, ECAP and UART interface for secondary development
Easily connect to Nuvoton DALI Master and software tool - DALI Controller on PC
Figure 1-1 DALI 2nd
Slave
DALI 2nd Slave
Jul 11, 2019 Page 4 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
NuMicro® NDA102 Series Feature 1.2
ARM® Cortex
®-M0 core running up to 48 MHz
Memory
29.5 KB Flash memory for program memory (APROM)
Configurable Flash memory for data memory (Data Flash)
2 KB Flash memory for loader (LDROM)
Three 0.5 KB Flash memory for security protection (SPROM)
4 KB SRAM for internal scratch-pad RAM (SRAM)
Up to 8-ch PWM output with 16-bit resolution
Fast computing ability by using hardware divider
Up to 8 single-end ADC input channel with 12-bit resolution and 10-bit accuracy guaranteed
The A/D converters can be started by software, external pin or PWM trigger
Operating temperature: -40℃~105℃
DALI 2nd Slave
Jul 11, 2019 Page 5 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
2 NUVOTON DALI 2nd SLAVE HARDWARE INTRODUCTION
The Nuvoton DALI 2nd
Slave uses NuMicro® NDA102 series NDA102EC1 as the main microcontroller.
The demo board can connect to a DALI system through the DALI bus. The demo board contains one RGB LED, one photoresistor, one potentiometer, one ICE interface and peripherial interfaces. It is suitable for DALI standards implementations.
Figure 2-1 Nuvoton DALI 2nd
Slave
Jumper Description 2.1
2.1.1 Power Interface
JP1 & JP2 Interface Signal Name MCU Pin Assignment
Pin 1, 2, 3, 4 5 V VDD
Pin 5, 6, 7, 8 GND VSS
2.1.2 ICE interface for Nu-Link
JP3 Interface Signal Name MCU Pin Assignment
Pin 2 VDD VDD
Pin 4 ICE_DAT ICE_DAT
Pin 6 ICE_CLK ICE_CLK
Pin 7 UART0_TX UART0_TX
Pin 8 ICE_RST nRESET
Pin 9 UART0_RX UART0_RX
Pin 10 GND VSS
5V Power Supply5V Power Supply
Reset SWD Interface
DALI Bus DALI Bus
RGB LED
NDA102EC1
Photoresistor
Potentiometer
ADC Interface
UART, DALI TX and RX Test Pin
DALI 2nd Slave
Jul 11, 2019 Page 6 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
2.1.3 DALI Bus Interface
JP4 & JP5 Interface Signal Name MCU Pin Assignment
Pin 1, 2, 7, 8 GND VSS
Pin 3, 4 DALI+ DALI+
Pin 5, 6 DALI- DALI-
2.1.4 DALI Interface and UART Interface
JP8 Interface Signal Name MCU Pin Assignment
Pin 1 DTX PC.2
Pin 2 TXD UART1_TX / PD.3
JP9 Interface Signal Name MCU Pin Assignment
Pin 1 DRX PB.0
Pin 2 RXD UART1_RX / PD.4
2.1.5 Peripherial Interface
JP10 Interface Signal Name MCU Pin Assignment
Pin 1 CAP0 ECAP_P0 / PC.4
Pin 2 CAP1 ECAP_P1 / PB.1
JP11 Interface Signal Name MCU Pin Assignment
Pin 1 ADC0_CH2 ADC0_CH2 / PB.2
Pin 2 ADC1_CH0 ADC1_CH0 / PB.4
Pin 3 ADC0_CH4 ADC0_CH4 / PC.1
Pin 4 ADC0_CH3 ADC0_CH3 / PC.0
DALI 2nd Slave
Jul 11, 2019 Page 7 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
3 HOW TO START NUVOTON DALI 2nd SLAVE ON THE KEIL μVISION® IDE
Keil μVision® IDE Software Download and Install 3.1
Please visit the Keil company website (http://www.keil.com) to download the Keil μVision® IDE and
install the RVMDK.
Nuvoton Nu-Link Driver Download and Install 3.2
Please visit the Nuvoton company NuMicro® website (http://www.nuvoton.com/NuMicro) to download
“NuMicro® Keil μVision
® IDE driver” file. When the Nu-Link driver has been well downloaded, please
unzip the file and execute the “Nu-Link_Keil_Driver.exe” to install the driver.
Hardware Setup 3.3
The hardware setup is shown as Figure 3-1.
Figure 3-1 Hardware Setup
DALI 2nd Slave
Jul 11, 2019 Page 8 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
4 HOW TO START NUVOTON DALI 2nd SLAVE ON THE IAR EMBEDDED WORKBENCH
IAR Embedded Workbench Software Download and Install 4.1
Please connect to IAR company website (http://www.iar.com) to download the IAR Embedded Workbench and install the EWARM.
Nuvoton Nu-Link Driver Download and Install 4.2
Please visit the Nuvoton company NuMicro® website (http://www.nuvoton.com/NuMicro ) to download
the “NuMicro® IAR EWARM Driver” file. When the Nu-Link driver has been well downloaded, please
unzip the file and execute the “Nu-Link_IAR_Driver.exe” to install the driver.
Hardware Setup 4.3
The hardware setup is shown as Figure 4-1.
Figure 4-1 Hardware Setup
DALI 2nd Slave
Jul 11, 2019 Page 9 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
5 NUVOTON DALI 2nd SLAVE QUICK START
Hardware Setup 5.1
Connect the Nuvoton DALI 2nd
Slave. DALI Bus interface JP4 or JP5 to the DALI control device as Figure 5-1. The DALI Bus can be connected at any position.
Connect the power supply 5 V to the Nuvoton DALI 2nd
Slave JP1 or JP2 as Figure 5-1.
It is recommanded to use Nuvoton DALI Master as the DALI control device as Figure 5-2.
Figure 5-1 Connections of DALI Bus and Power Supply
Figure 5-2 Nuvoton DALI Master with Nuvoton DALI 2nd
Slave
DALI 2nd Slave
Jul 11, 2019 Page 10 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
Initialisation 5.2Use the software tool - DALI Controller to do the initialisation. The DALI Controller can auto-detect the Nuvoton DALI Master through USB interface. Choose “New Initialization” to discover all control gear on the line. It will assign particular short address to each control gear as Figure 5-3.
Figure 5-3 Initialisation
DALI 2nd Slave
Jul 11, 2019 Page 11 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
DALI Commands 5.3Figure 5-4 shows the DALI command page in DALI Controller. Set up the DALI command and the destination, and then click “Send” button. Nuvoton DALI Master will send out the command to the DALI devices. The DALI command raw data will shown in the “Command send” text box. The DALI device’s answer will shown in the “Response” text box.
Figure 5-4 DALI Command Page
DALI 2nd Slave
Jul 11, 2019 Page 12 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
Monitoring Page 5.4Figure 5-5 shows the monitoring page in DALI Controller. Every frame on DALI bus is shown in the monitoring page in real time.
Figure 5-5 Monitoring Page
Button Function 5.5
The DALI 2nd
Slave is not a fully-featured DALI device. Press SW3 button to simulate the “Lamp Failure” condition.
Figure 5-6 Lamp Failure Simulation
DALI 2nd Slave
Jul 11, 2019 Page 13 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
6 NUVOTON DALI 2nd SLAVE SCHEMATIC
NDA102EC1 Control Unit Schematic 6.1
Figure 6-1 NDA102EC1 Control Unit
JP8
HEADER 2
12
DALI_TXTiny _TX
DALI_RXJP9
HEADER 2
12
Tiny _RX
JP10
HEADER 2
12
ECAP_P1ECAP_P0
JP11
HEADER 4
1234
ADC0_CH2ADC1_CH0ADC0_CH4ADC0_CH3
( O pt i on & Ext ernal Header)
VSS
LED2
VDD
LED1
TICERST
KEY2KEY1
KEY1LED2
VDD
GND
O f f - page Connect or
LED1
TICERST
KEY2
C81u
Tit le
Size Docum ent Num ber Rev
Dat e: Sheet of
2 1.0
MCU
A4
2 5Tuesday , March 13, 2018
LDO
PB3
TICECLKTICERST
TICEDAT
Tiny _RXTiny _TX
EPWM_CH0
VDD
EPWM_CH1
GND
ADC0_CH2
VDD
ADC0_CH4
GND
DALI_RX
VDD
DALI_TX
GND
ADC0_CH3
EPWM_CH3EPWM_CH2
JP3
1 23 45 67 89 10
TP1 NC
VDD
VCC_connect
GND
DALI_RX
VDD
DALI_TX
VDD
ADC0_CH4
GND
EPWM_CH1
GND
ADC0_CH2
EPWM_CH2
EPWM_CH0
VDD
Power Capacitance
Test Pin
Debug Interface & Off Page
ADC0_CH3
EPWM_CH3
( RG B LEDs)
O f f - page Connect or
( Phot oresi st or)
O f f - page Connect or
( DALI - Bus)
O f f - page Connect or
P6ADC1_CH0P5ADC0_CH2
P1VDDP2KEY1
P7ADC0_CH4P8TICERST
P10DALI_TXP9PB3
P14P13
P3DALI_RXP4ECAP_P1
P20 KEY2
P17 TICECLKP11TICEDAT
P16 Tiny _RX
P21 EPWM_CH4
P19 LED1P18 LED2
P28 GND
P25 EPWM_CH0P24 EPWM_CH1P23 EPWM_CH2P22 EPWM_CH3
P27 LDOP26 ECAP_P0
U5
NDA102EC1-TSSOP28
VDD1
PD6,UART0_RXD2
PB.0/ADC0_CH0/ACMP0_P0/ECAP_P03
PB.1/ADC0_CH1/ACMP0_P1/ECAP_P14
PB.2/ADC0_CH2/ACMP0_P2/ECAP_P2/BPWM_CH15
PB4/ADC1_CH0/ACMP0_N/TM16
PC.1/ADC0_CH4/STADC/ACMP0_P3/ACMP1_P1/SPI0_MOSI/SPI1_MISO7
nRESET8
PB.3/ACMP1_N/PGA_I/TM09
PC.2/ADC1_CH2/BRAKE/CCAP_P1/I2C1_SDA/SPI0_MISO/SPI1_MOSI/UART1_RXD10
PD.2/ICE_DAT/ADC1_CH1/CCAP_P0/I2C0_SDA/SPI0_MOSI/SPI1_MISO/UART0_RXD11
PD.3/BPWM_CH1/UART1_TXD12
NC13
NC14
ADC0_CH3/BPWM_CH0/ACMP1_P0/I2C1_SCL/SPI0_SS/SPI1_CLK/UART1_TXD/PC.015BPWM_CH0/UART1_RXD/PD416ACMP1_P2/I2C0_SCL/SPI0_CLK/SPI1_SS/UART0_TXD/ICE_CLK/PD.117ACMP1_O/PGA_O/SPI0_CLK/SPI1_SS/PC.318UART0_TXD/PD519EPWM_CH5/ACMP0_O/XT_OUT/PA.520EPWM_CH4/XT_IN/PA.421EPWM_CH3/I2C0_SCL/SPI0_CLK/SPI1_SS/UART0_TXD/PA.322EPWM_CH2/I2C0_SDA/SPI0_MOSI/SPI1_MISO/UART0_RXD/PA.223EPWM_CH1/I2C1_SDA/SPI0_MISO/SPI1_MOSI/UART1_RXD/PA.124CLKO/EPWM_CH0/I2C1_SCL/SPI0_SS/SPI1_CLK/UART1_TXD/PA.025PC426LDO_CAP27VSS28
P15 ADC0_CH3
P12Tiny _TX
EPWM_CH4EPWM_CH4
DALI 2nd Slave
Jul 11, 2019 Page 14 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
DALI Bus Schematic 6.2
Figure 6-2 DALI Bus Schematic
DALI+GND
GND
Off-page Connector
(DALI-Bus)
DALI_TX
VDD
DALI_RX
Q1
PZT2222A (NPN)
1
32 4
JP4
CONN FB 8-R
13578
642
JP5
CONN FB 8-R
13578
642
- +
D2
BGX 50A E6327
2
1
4
3
U2
TCLT1000
1
2
4
3
D3
MM5Z5V1
R112.2K
U3
TCLT1000
1
2
4
3
DALI_RX
VDD
R1310K
R121K
R10
120R
DALI_TXR9
330R
DALI_TX
VDD
DALI_RX
DALI-
DALI 2nd Slave
Jul 11, 2019 Page 15 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
LED Schematic 6.3
Figure 6-3 LED Schematic
R290
ADC0_CH3
VDD
EPWM_CH1
GNDGND
ADC0_CH3
EPWM_CH3EPWM_CH2
EPWM_CH0
EPWM_CH2
EPWM_CH0
VDD
EPWM_CH1
Off-page Connector
ADC0_CH3
EPWM_CH3
(RGB LEDs)
EPWM_CH4EPWM_CH4
12
D4
SS14A
12
D5
SS14A
R17 160
R18 160
U4
ALRGB5050C
1
2
3
4
5
6
R16 160
VDD
JP7
HEADER 2
1 2
PWM_G EPWM_CH1
PWM_B EPWM_CH3
PWM_R EPWM_CH2
R265.6K
R232K
Q2AO3401A(MOSFET P)
Q3
S8050 (NPN)
1
23
R21100
R19150/0.5W/2010
R20150/0.5W/2010
VDD
R2410K C9
10uF/10V
12
C100.1u
LED+
R251/0.5W/2010
LED- R2233K
EPWM_CH4
L3
INDUCTOR(150uH/1A)
Q6
PZT2222A (NPN)
1
324
R27
120
VDD
R28
1k
EPWM_CH0
CON3
USB A-TYPEUSB4P
VBUS1
D-2
D+3
GND4
DALI 2nd Slave
Jul 11, 2019 Page 16 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
Power and Peripheral Schematic 6.4
Figure 6-4 Power and Peripheral Schematic
TICERST
KEY2KEY1
VSS
LED2
VDD
GND
VDD
LED1
TICERST
KEY2KEY1LED2
Off-page Connector
LED1
12
D1
SS24A
C110uF/10V
12
R31K
12
GPIO1 YELLOWLED1
VDD
C20.1u
R110K
SW3
PUSH BUTTON
VDD
KEY1
SW1
PUSH BUTTON
R210K
KEY2
BUTTON
VSS
JP2
CONN FB 8-R
13578
642
JP1
CONN FB 8-R
13578
642
R610K
C710uF/10V
12
SW2
PUSH BOTTOM (B)
12
GPIO2 REDLED2 R5
1K VDD
12
POWER1GREENR71K
VDD
Power
VDD
VDD
LED
GND
Reset
TICERST
GND
ADC0_CH2
VDD
ADC0_CH4
GND
Off-page Connector
ADC0_CH2
VDD
ADC0_CH4
(Photoresistor)
R30
0
ADC0_CH2R31
0
ADC0_CH4
RV1GL5516GL55
R14
200R
VDD
PhotoresistorRT1
VDD
R15
1K
Variable Resistor
DALI 2nd Slave
Jul 11, 2019 Page 17 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
7 REVISION HISTORY
Date Revision Description
2019.07.11 1.00 1. Initially issued.
DALI 2nd Slave
Jul 11, 2019 Page 18 of 18 Rev 1.00
DA
LI 2
nd S
LA
VE
US
ER
MA
NU
AL
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.