Home

V850E/IF3, V850E/IG3 32-bit Single

image

Contents

1. NEC Electronics China Co Ltd 7th Floor Quantum Plaza No 27 ZhiChunLu Haidian District Beijing 100083 P R China Tel 010 8235 1155 http www cn necel com Shanghai Branch Room 2509 2510 Bank of China Tower 200 Yincheng Road Central Pudong New Area Shanghai P R China P C 200120 Tel 021 5888 5400 http www cn necel com Shenzhen Branch Unit 01 39 F Excellence Times Square Building No 4068 Yi Tian Road Futian District Shenzhen P R China P C 518048 Tel 0755 8282 9800 http www cn necel com NEC Electronics Hong Kong Ltd Unit 1601 1613 16 F Tower 2 Grand Century Place 193 Prince Edward Road West Mongkok Kowloon Hong Kong Tel 2886 9318 http www hk necel com NEC Electronics Taiwan Ltd 7F No 363 Fu Shing North Road Taipei Taiwan R O C Tel 02 8175 9600 http www tw necel com NEC Electronics Singapore Pte Lid 238A Thomson Road 12 08 Novena Square Singapore 307684 Tel 6253 8311 http www sg necel com NEC Electronics Korea Ltd 11F Samik Lavied or Bldg 720 2 Yeoksam Dong Kangnam ku Seoul 135 080 Korea Tel 02 558 3737 http www kr necel com G0706
2. Transmit data register None unsigned char buf tx Transmit data storing buffer volatile unsigned char count tx Transmission count variable uarta c None Preliminary Application Note U18723EJ1VO0AN 11 Function name Processing content SFR used call function Variables File name Caution Function name Processing content SFRs used call function Variable File name Caution 12 CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION uarta int receive Writes receive data to receive data register Stops and disables reception operation if number of receptions and the count value match UAORX Receive data register None unsigned char buf rx Receive data storing buffer volatile unsigned char count rx Reception count variable uarta c To stop reception operation set UAOPWR bit to O after setting UAORXE and UAOTXE bits to 0 uarta_error Clears error flag when reception error occurs UAOSTR UAOPE 0 Clears parity error flag UAOSTR UAOFE 0 Clears framing error flag UAOSTR UAOOVE O Clears overrun error flag None None uarta c None Preliminary Application Note U18723EJ1VOAN CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION Figure 1 1 Continuous Transmission Reception 1 4 uarta_main Disables maskable interrupt request count_tx 0 Initializes transmission count count_rx 0 Initializes reception count uarta_port_set Alternate function pin sett
3. to priority level 7 uarta port set uarta set uarta start uarta send end uarta receive end uarta end unsigned char buf tx Transmit data storing buffer unsigned char buf rx Receive data storing buffer volatile unsigned char count tx Transmission count variable volatile unsigned char count rx Reception count variable unsigned char count Transfer data generating variable uarta int send uarta int receive uarta error INTUAOT INTUAOR INTUAORE uarta c None uarta port set Sets alternate function pin to UARTAO I O pin PFC4 0x03 Sets TXDAO output and RXDAO input PFCE4 0x00 Sets TXDAO output and RXDAO input PMC4 0x03 Sets TXDAO output and RXDAO input None None uarta c None Preliminary Application Note U18723EJ1VOAN Function name Processing content SFRs used call function Variable File name Caution Function name Processing content SFRs used call function Variables File name Caution Function name Processing content SFR used call function Variable File name Caution 10 CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION uarta set Sets UARTAO control register Sets baud rate to 9 600 bps UAOCTL1 0x03 Sets baud rate to 9 600 bps UAOCTL2 OxDO Sets baud rate to 9 600 bps UAOOPTO 0x14 Sets to ordinary output of transfer data ordinary input of transfer data UAOCTLO Ox8A Enables UARTAO operation s
4. 03 PFCE4 0x00 to TXDAO output and RXDAO input PMC4 0x03 Pee Sets baud rate to 9 600 bps UAOCTL2 0xDO Outputs transfer data normally UARTAO operation start function PALO Ieee Inputs transfer data normally uarta_start Enables UARTAO operation Sets transfer direction to MSB first UAOCTLO Ox8A Sets parity selection to odd parity Sets data length to 8 bits UAOTXE 1 Enapiestransmission Sets stop bit to 1 bit operation UAORXE 1 Enables reception operation UARTAO transmission operation disable function over 2 x fucik UAOTXE 0 Disables transmission operation UAOTX buf tx 0 Writes to UAOTX register UARTAO reception operation disable function UARTAO operation disable function uarta receive end uarta end UAORXE 0 UAOPWR 0 Disables UARTAO operation Disables reception operation Preliminary Application Note U18723EJ1VOAN 15 CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION Figure 1 1 Continuous Transmission Reception 4 4 INTUAOT interrupt INTUAOT interrupt function No Checks transmission count Yes UAOTX buf fx count tx count bc Writes to UAOTX register Increments transmission count Increments transmission count INTUAOR interrupt INTUAORE interrupt INTUAOR interrupt function INTUAORE error interrupt function buf rx count rx UAORX Clears parity error flag Stores reception result Clears f
5. NEC Preliminary Application Note V850E IF3 V850E IG3 32 bit Single Chip Microcontrollers Sample Programs for Serial Communication UARTA V850E IF3 UPD70F3451 UPD70F3452 V850E IG3 LPD70F3453 UPD70F3454 Document No U18723EJ1VOANOO 1st edition Date Published August 2007 N NEC Electronics Corporation 2007 Printed in Japan MEMO 2 Preliminary Application Note U18723EJ1VOAN NOTES FOR CMOS DEVICES VOLTAGE APPLICATION WAVEFORM AT INPUT PIN Waveform distortion due to input noise or a reflected wave may cause malfunction If the input of the CMOS device stays in the area between Vi MAX and Vin MIN due to noise etc the device may malfunction Take care to prevent chattering noise from entering the device when the input level is fixed and also in the transition period when the input level passes through the area between Vit MAX and Vin MIN HANDLING OF UNUSED INPUT PINS Unconnected CMOS device inputs can be cause of malfunction If an input pin is unconnected it is possible that an internal input level may be generated due to noise etc causing malfunction CMOS devices behave differently than Bipolar or NMOS devices Input levels of CMOS devices must be fixed high or low by using pull up or pull down circuitry Each unused pin should be connected to Voo or GND via a resistor if there is a possibility that it will be an output pin All handling related to unused pins must be judged separately for each dev
6. ets to MSB first and sets odd parity to output data character length of 8 bits and stop bit length of 1 bit uarta start Enables transmission reception and writes data to UAOTX register UAOCTLO UAOTXE 1 Enables transmission operation UAOCTLO UAORXE 1 Enables reception operation UAOTX Transmit data register None unsigned char buf tx Transmit data storing buffer uarta c Set UAORXE and UAOTXE bits to 1 after setting UAOCTL UAOPWR bit to 1 uarta send end Disables transmission operation UAOCTLO UAOTXE 0 Disables transmission operation None None uarta c None Preliminary Application Note U18723EJ1VOAN Function name Processing content SFR used call function Variable File name Caution Function name Processing content SFR used call function Variable File name Caution Interrupt function Function name Processing content SFR used call function Variables File name Caution CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION uarta_receive_end Disables reception operation UAOCTLO UAORXE 0 Disables reception operation None None uarta c None uarta_ end Disables operation of UARTAO UAOCTLO UAOPWR 0 Disables operation of UARTAO None None uarta c None uarta_int_send Writes transmit data to transmit data register Stops transmission operation if number of transmissions and the count value match UAOTX
7. ice and according to related specifications governing the device PRECAUTION AGAINST ESD A strong electric field when exposed to a MOS device can cause destruction of the gate oxide and ultimately degrade the device operation Steps must be taken to stop generation of static electricity as much as possible and quickly dissipate it when it has occurred Environmental control must be adequate When it is dry a humidifier should be used It is recommended to avoid using insulators that easily build up static electricity Semiconductor devices must be stored and transported in an anti static container static shielding bag or conductive material All test and measurement tools including work benches and floors should be grounded The operator should be grounded using a wrist strap Semiconductor devices must not be touched with bare hands Similar precautions need to be taken for PW boards with mounted semiconductor devices STATUS BEFORE INITIALIZATION Power on does not necessarily define the initial status of a MOS device Immediately after the power Source is turned ON devices with reset functions have not yet been initialized Hence power on does not guarantee output pin levels I O settings or contents of registers A device is not initialized until the reset signal is received A reset operation must be executed immediately after power on for devices with reset functions POWER ON OFF SEQUENCE In the case of a device that uses different powe
8. ing function uarta_set UARTAO control register setting function Initializes count for transmission data generated Checks count for transmission data generated buf tx count count 1 Substitutes value in buf_tx count Increments count for transmission data generated Clears INTUAORE interrupt request signal releases mask sets to priority level 7 Clears INTUAOT interrupt request signal UAOTIC 0x07 eer releases mask sets to priority level 7 UAORIC 0x07 Clears INTUAOR interrupt request signal releases mask sets to priority level 7 Enables maskable interrupt request UAOREIC 0x07 uarta_start UARTAO operation start function Preliminary Application Note U18723EJ1VOAN 13 CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION 14 Figure 1 1 Continuous Transmission Reception 2 4 uarta receive end uarta send end count rx gt RX SIZE amp amp count tx gt TX SIZE uarta end No Checks reception count UARTAO reception operation disable function Checks transmission count UARTAO transmission operation disable function Checks reception and transmission count UARTAO operation disable function Preliminary Application Note U18723EJ1VOAN CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION Figure 1 1 Continuous Transmission Reception 3 4 Alternate function pin setting function UARTAO control register setting function PFC4 0x03 Sets alternate function pin UAOCTL1 0x
9. ing sample programs reference the following startup routine and link directive file and adjust them if necessary e Startup routine ig3 start s e Link directive file ig3 link dir Target Readers This Application Note is intended for users who understand the functions of the Purpose V850E IF3 uPD70F3451 70F3452 and V850E IG3 uPD70F3453 70F3454 and who design application systems that use these microcontrollers This manual is intended to give users an understanding of the basic functions of the V850E IF3 and V850E IG3 using the application programs How to Use This Manual It is assumed that the reader of this Application Note has general knowledge in the Conventions fields of electrical engineering logic circuits and microcontrollers For details of hardware functions especially register functions setting methods etc and electrical specifications See the V850E IF3 V850E IG3 Hardware User s Manual For details of instruction functions See the V850E1 Architecture User s Manual Data significance Higher digits on the left and lower digits on the right Active low representation XXX overscore over pin or signal name Memory map address Higher addresses on the top and lower addresses on the bottom Note Footnote for item marked with Note in the text Caution Information requiring particular attention Remark Supplementary information Numeric representation Binary xxxx or xxxxB Decimal
10. onverters 0 and 1 To be prepared Application Note V850E IF3 V850E IG3 Sample Programs for A D Converter 2 Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for Low Voltage Detector LVI To be prepared Function Application Note V850E IF3 V850E IG3 6 Phase PWM Output Control by Timer AB Timer Q U18717E Option Timer AA A D Converters 0 and 1 Application Note Preliminary Application Note U18723EJ1VOAN 7 CONTENTS CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION eee 8 Preliminary Application Note U18723EJ1VOAN Function Function name Argument Processing content SFRs used call functions Variables Interrupts Interrupt sources File name Caution Function name Processing content SFRs used call function Variable File name Caution CHAPTER 1 CONTINUOUS TRANSMISSION RECEPTION Performs continuous UARTAO transmission reception uarta_main None Performs transmission reception for ten times using UARTAO Stores received data in buf rx and transmitted data in buf tx UAOREIC 0x07 Clears UARTAO reception error interrupt request signal INTUAORE releases mask sets to priority level 7 UAOTIC 0x07 Clears UARTAO transmission enable interrupt request signal INTUAOT releases mask sets to priority level 7 UAORIC 0x07 Clears UARTAO reception end interrupt request signal INTUAOR releases mask sets
11. r supplies for the internal operation and external interface as a rule switch on the external power supply after switching on the internal power supply When switching the power supply off as a rule switch off the external power supply and then the internal power supply Use of the reverse power on off sequences may result in the application of an overvoltage to the internal elements of the device causing malfunction and degradation of internal elements due to the passage of an abnormal current The correct power on off sequence must be judged separately for each device and according to related specifications governing the device INPUT OF SIGNAL DURING POWER OFF STATE Do not input signals or an I O pull up power supply while the device is not powered The current injection that results from input of such a signal or I O pull up power supply may cause malfunction and the abnormal current that passes in the device at this time may cause degradation of internal elements Input of signals during the power off state must be judged separately for each device and according to related specifications governing the device Preliminary Application Note U18723EJ1VOAN Caution This product uses SuperFlash technology licensed from Silicon Storage Technology Inc SuperFlash is a registered trademark of Silicon Storage Technology Inc in several countries including the United States and Japan The information contained in this documen
12. raming error flag Increments reception count Clears overrun error flag UAOOVE 0 16 Preliminary Application Note U18723EJ1VOAN For further information please contact NEC Electronics Corporation 1753 Shimonumabe Nakahara ku Kawasaki Kanagawa 211 8668 Japan Tel 044 435 5111 http www necel com America NEC Electronics America Inc 2880 Scott Blvd Santa Clara CA 95050 2554 U S A Tel 408 588 6000 800 366 9782 http www am necel com Europe NEC Electronics Europe GmbH Arcadiastrasse 10 40472 Dusseldorf Germany Tel 0211 65030 http www eu necel com Hanover Office Podbielskistrasse 166 B 30177 Hannover Tel 0 511 33 40 2 0 Munich Office Werner Eckert Strasse 9 81829 Munchen Tel 0 89 92 10 03 0 Stuttgart Office Industriestrasse 3 70565 Stuttgart Tel 0 711 99 01 0 0 United Kingdom Branch Cygnus House Sunrise Parkway Linford Wood Milton Keynes MK14 6NP U K Tel 01908 691 133 Succursale Francaise 9 rue Paul Dautier B P 52 78142 Velizy Villacoublay C dex France Tel 01 3067 5800 Sucursal en Espana Juan Esplandiu 15 28007 Madrid Spain Tel 091 504 2787 Tyskland Filial Taby Centrum Entrance S 7th floor 18322 Taby Sweden Tel 08 638 72 00 Filiale Italiana Via Fabio Filzi 25 A 20124 Milano Italy Tel 02 667541 Branch The Netherlands Steijgerweg 6 5616 HS Eindhoven The Netherlands Tel 040 265 40 10 Asia amp Oceania
13. rchitecture User s Manual U14559E V850E IF3 V850E IG3 Hardware User s Manual U18279E V850E IF3 V850E IG3 Sample Programs for Serial Communication This manual UARTA Application Note V850E IF3 V850E IG3 Sample Programs for Serial Communication To be prepared UARTB Application Note V850E IF3 V850E IG3 Sample Programs for Serial Communication CSIB To be prepared Application Note V850E IF3 V850E IG3 Sample Programs for Serial Communication FC To be prepared Application Note V850E IF3 V850E IG3 Sample Programs for DMA Function Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for Timer M Application Note To be prepared V850E IF3 V850E IG3 Sample Programs for Watchdog Timer Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for Timer AA Application Note To be prepared V850E IF3 V850E IG3 Sample Programs for Timer AB Application Note To be prepared V850E IF3 V850E IG3 Sample Programs for Timer T Application Note To be prepared V850E IF3 V850E IG3 Sample Programs for Port Function Application Note To be prepared V850E IF3 V850E IG3 Sample Programs for Clock Generator Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for Standby Function Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for Interrupt Function Application To be prepared Note V850E IF3 V850E IG3 Sample Programs for A D C
14. rt systems and medical equipment for life support etc The quality grade of NEC Electronics products is Standard unless otherwise expressly specified in NEC Electronics data sheets or data books etc If customers wish to use NEC Electronics products in applications not intended by NEC Electronics they must contact an NEC Electronics sales representative in advance to determine NEC Electronics willingness to support a given application Note 1 NEC Electronics as used in this statement means NEC Electronics Corporation and also includes its majority owned subsidiaries 2 NEC Electronics products means any product developed or manufactured by or for NEC Electronics as defined above M5 02 11 1 4 Preliminary Application Note U18723EJ1VOAN Cautions 1 INTRODUCTION This Application Note explains a case where the V850E IG3 is used as a representative microcontroller Use this Application Note for your reference when using the V850E IF3 Download the program used in this manual from the page of Programming Examples http www necel com micro en designsupports sampleprogram index html in the NEC Electronics Website http www necel com This sample program is provided for reference purposes only and operations are therefore not subject to guarantee by NEC Electronics Corporation When using sample programs customers are advised to sufficiently evaluate this product based on their systems before use When us
15. t is being issued in advance of the production cycle for the product The parameters for the product may change before final production or NEC Electronics Corporation at its own discretion may withdraw the product prior to its production No part of this document may be copied or reproduced in any form or by any means without the prior written consent of NEC Electronics NEC Electronics assumes no responsibility for any errors that may appear in this document e NEC Electronics does not assume any liability for infringement of patents copyrights or other intellectual property rights of third parties by or arising from the use of NEC Electronics products listed in this document or any other liability arising from the use of such products No license express implied or otherwise is granted under any patents copyrights or other intellectual property rights of NEC Electronics or others e Descriptions of circuits software and other related information in this document are provided for illustrative purposes in semiconductor product operation and application examples The incorporation of these circuits software and information in the design of a customer s equipment shall be done under the full responsibility of the customer NEC Electronics assumes no responsibility for any losses incurred by customers or third parties arising from the use of these circuits software and information e While NEC Electronics endeavors to enhance the quality reliabilit
16. xxxx Hexadecimal xxxxH Prefix indicating the power of 2 address space memory capacity K kilo 2 1 024 M mega 2 1 024 G giga 2 1 024 Preliminary Application Note U18723EJ1VOAN 5 The function lists are structured as follows Hardware name symbol Function Function name Argument s Processing content SFR s used call function s Variable s Interrupt s Interrupt source s File name Caution s Interrupt function Function name Servicing content SFR s used call function s Variable s File name Caution s Function description Name of sample function Type and overview of argument s Processing content of sample function Register name and setting content Name and function of call function s Type name and overview of variable s used in sample function Name of function Name Name of corresponding sample program file Caution s upon function usage Name of interrupt function Servicing content of interrupt function Name of interrupt and conditions for occurrence None Name of variable function Name of corresponding sample program file None Preliminary Application Note U18723EJ1VOAN Related Documents The related documents indicated in this publication may include preliminary versions However preliminary versions are not marked as such Documents related to V850E IF3 and V850E IG3 Document Name Document No V850E1 A
17. y and safety of NEC Electronics products customers agree and acknowledge that the possibility of defects thereof cannot be eliminated entirely To minimize risks of damage to property or injury including death to persons arising from defects in NEC Electronics products customers must incorporate sufficient safety measures in their design such as redundancy fire containment and anti failure features e NEC Electronics products are classified into the following three quality grades Standard Special and Specific The Specific quality grade applies only to NEC Electronics products developed based on a customer designated quality assurance program for a specific application The recommended applications of an NEC Electronics product depend on its quality grade as indicated below Customers must check the quality grade of each NEC Electronics products before using it in a particular application Standard Computers office equipment communications equipment test and measurement equipment audio and visual equipment home electronic appliances machine tools personal electronic equipment and industrial robots Special Transportation equipment automobiles trains ships etc traffic control systems anti disaster systems anti crime systems safety equipment and medical equipment not specifically designed for life support Specific Aircraft aerospace equipment submersible repeaters nuclear reactor control systems life suppo

Download Pdf Manuals

image

Related Search

Related Contents

Indoor Cycle Cycle De L`Intérieur Bicicleta estacionaria  Regione Lombardia, d.d.u.o. 11 giugno 2009, n  HQ W7-54910- N  MS International TTBEIG-PAT-HUFC Instructions / Assembly  Tour Hydraulique préparateur d`eau chaude  Nokia 6360 Cell Phone User Manual  Apple iPod nano 4Gb White    Air Cut-Off Tool - Air Compressors Direct  User Manual - TLC Direct  

Copyright © All rights reserved.
Failed to retrieve file