Home

Code Generator Tutorial Manual

image

Contents

1. Return Value None PEELE EEL EEE EEE EE EA ESE EEE SESE EL RR EEE SEER SEES EEE EAE ER ARES EE EA TREE EE EE EEE EEE EEE EN ERA static uint32 t scale value const uint32 t value const uint32 t in max const uint32 t out max uint32 t output output out max 0 in max 0 output value 0 output output 1 output return output E RE RER AAE ELE ELE ERE EAL ERLE EEE Ee ES SERGE RAR TR RE RN GB RR LN a I RR EEESTIS AE EN RS CA E End of function scale value LE EELD ELA LEE ELA SLES EEE ELE TES LAST eS Se EUR Se Ee KI DI EON TINEO a ee EAE ERE R RRE End user code Do not edit comment generated here 5 2 5 r cg main c Code Insertion Insert the following in to the function void main void Start user code Do not edit comment generated here The rest of the code is executed in interrupt handlers while 1U asm nop End user code Do not edit comment generated here R20UT3281EG0100 Rev 1 00 LENESAS Page 25 of 37 Mar 21 2015 RSK RZT1 5 Adding Code to Generated Files Insert the following in to the function void R_MAIN UserInit void Start user code Do not edit comment generated here uint32 t delay Ox3FFFF Clear the switches interrupt flags before enabling the interrupts VIC PICO LONG 0x00000200UL VIC PICO LONG 0x00010000UL Enable the switch interrupts R ICU I ROQ12 Start Enabling interru
2. HEAP STACK SIZE heap_end gt ATCM Sys stack 0x807800 AT 0x807800 Sys stack start ALIGN 0x8 sys stack SYS STACK SIZE sys stack end Sys stack gt BTCM Svc stack 0x807A00 AT 0x807A00 svc stack start ALIGN 0x8 svc stack SVC STACK SIZE svc stack end R20UT3281EG0100 Rev 1 00 ENESAS Page 29 of 37 Mar 21 2015 RSK RZT1 6 External Linker File _svc_stack gt BTCM irq stack 0x807C00 AT 0x807C00 irg stack start ALIGN 0x8 irq stack IRO STACK SIZE irg stack end irg stack gt BTCM fiq stack 0x807D00 AT 0x807D00 fig stack start ALIGN 0x8 fiq stack FIQ STACK SIZE fig stack end fig stack gt BTCM und stack 0x807E00 AT 0x807E00 und stack start ALIGN 0x8 und stack UND STACK SIZE und stack end und stack gt BTCM abt stack 0x807F00 AT 0x807F00 abt stack start ALIGN 0x8 abt stack ABT STACK SIZE abt stack end abt stack BTCM Kolar ika i AAA ASAS TOO copying on the above MEA ne ate NUES UNDIS ee Click File gt Save Open Project properties gt C C Build gt Settings gt Linker Other Change the Command file overide option to External Linker script T Add the following to the File entry inclu
3. 4 2 Code Generator Tour This section presents a brief tour of Code Generator AP4 is the stand alone version of Code Generator and this manual is applicable to the Code Generator From the e studio menus select Window gt Open Perspective gt Other In the Open Perspective dialog shown in Figure 4 1 select Code Generator and click OK R20UT3281EG0100 Rev 1 00 RENESAS Page 14 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator Open Perspective He C C default Code Generator Es cvs Repository Exploring F Debug Gy sit CD Planning Resource Em SVN Repository Exploring E Team synchronizinq Figure 4 1 Changing Perspectives A Code Generator project file with extension cpg exists in the CG Tutorial project s settings CodeGenerator directory Code Generator also creates a folder named cg src in the src folder to store generated source and header files The user is encouraged to add non CodeGenerator files to the src folder The Code Generator s Peripheral View is displayed as illustrated in Figure 4 2 Project Explorer 52 SU 2 An outline is not available a 5 CG Tutorial gt Binaries ER Archives e 52 Co Generate Code 2 Y RI Includes B src z HardwareDebug CG Tutorial HardwareDebug o 16 bit 32 bit bus boot SPI boot CG Tutorial HardwareDebug CG Tutorial Release jlink CG Tutorial Release launch custom
4. 512AD0 S12AD1 Seting1 Seting2 Window function setting Disable Enable Reference data setting Initial reference data 0 for comparison Initial reference data 1 for comparison 0 Figure 4 9 A D Converter Setting tab 4 Interrupt setting Enable AD conversion compare interrupt 512CMPI0 Priority Level 0 highest Figure 4 10 A D Converter Setting tab 5 4 3 1 5 Interrupt Controller Unit ICU This peripheral is used to configure external interrupts input pins connected to user switches The CG_Tutorial only makes use of switch SW3 User switch connectivity on the schematic are shown in Table 4 2 ICU Connectivity MCU Pin VO Port NM SPH Notusd H3 IRQS IRQ12 Table 4 2 ICU Connectivity Please refer to the RSK schematic for full details of the connectivity Double click on the Interrupt Controller entry under the Project Tree gt Peripheral Functions list This is to configure switch SW3 to trigger IRQ12 interrupts IRQ12 setting J IRQ12 Detection type Falling edge Digital noise fitter PCLKB 64 1472 MHz Priority Level 3 Y Figure 4 11 ICU Setting tab 4 3 1 6 Multi Function Pin Controller MPC This peripheral is used to select and map port peripheral functionalities of the MCU pins By default mapping of functionalities to pins is done during peripheral configuration as shown in the setup of the l O Ports A D and ICU modules
5. SPI boot Main clock oscillator setting Main clock oscillation source Resonator Extemal clock Clock source Frequency 25 MHz Oscillation stop detection function Disabled 4 PLL circuit setting Frequency O00 PLL1 circuit setting Operation Frequency 1200 MHz Low speed on chip oscillator LOCO setting Operation Frequency 240 kHz Internal clock setting Clock source is PLLO or PLLT Clock source PLL1 CPU clock CPUCLK 8 amp 0 mw MH System clock ICLK 150 MHz High speed peripheral module clock PCLKA 150 MB High speed peripheral module clock PCLKB 75 MHz External bus clock CKIO 50 MHz Trace interface clock TCLK DR Internal clock setting Clock source is PLLO High speed peripheral module clock PCLKC 450 MHz Low speed peripheral module clock PCLKD 75 MHz Low speed peripheral module clock PCLKE 75 2 MHz Low speed peripheral module clock PCLKF 60 v MHz Low speed peripheral module clock PCLKG 60 MHz Low speed peripheral module clock PCLKH G0 MA High speed serial clock SERICLK 150 MHz IWDT clock setting IWDT clock IWDTCLK 120 kHz ECM clock setting n ECM clock ECMCLK 240 kHz Ethernet clock setting Ethernet clock D ETCLKD 125 MHz Ethernet clock E ETCLKE BIH Delta sigma clock setting Delta sigma interface clock 0 clock source PLOD Delta sigma interface cl
6. LENESAS jam T D TS o 3 u RZ T1 Group Renesas Starter Kit Code Generator Tutorial Manual For e studio RENESAS MCU RZ Family RZ T1 Series All information contained in these materials including products and product specifications represents information on the product at the time of publication and is subject to change by Renesas Electronics Corporation without notice Please review the latest information published by Renesas Electronics Corporation through various means including the Renesas Electronics Corporation website http www renesas com Renesas Electronics www renesas com Rev 1 00 Mar 2015 Notice 1 Descriptions of circuits software and other related information in this document are provided only to illustrate the operation of semiconductor products and application examples You are fully responsible for the incorporation of these circuits software and information in the design of your equipment Renesas Electronics assumes no responsibility for any losses incurred by you or third parties arising from the use of these circuits software or information 2 Henesas Electronics has used reasonable care in preparing the information included in this document but Renesas Electronics does not warrant that such information is error free Renesas Electronics assumes no liability whatsoever for any damages incurred by you resulting from errors in or omissions from the information included herein
7. The Multi Function Controller is used to re assign the default functionalities mapping if required Double click on the Device List View entry under the Project Tree gt Pin View Please ensure to verify the port pin functions for each configured peripheral by viewing the Pin Number and Pin Function tabs as shown in Figure 4 12 Pin Number Device List View tab and Figure 4 13 Pin Function Device List View tab R20UT3281EG0100 Rev 1 00 ENESAS Page 20 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator Pin Number Pin Name T Al VSS PC2 ETHO_TXC ETH1_RXD2 CATIZCDATA SDAO PJ3 IRG11 ETHO TXDO ADTRGO A2 A3 AA PJ1 ETHO TXD2 CATLEDSTER RSPCK3 A5 A6 PF7 IRQ7 A25 ETHO_TXER RTS3 SSL30 PB4 A24 ETH1 COL ETHO RXER CATSYNCO CATL PB0 ETH1_RXDV MTCLKB TCLKD TIC3 PCO WAITA ETH1 RXD2 GTETRG SCL1 MDAT3 PF6 ETH1_RXDO MTIOC3D GTIOCOB TOC2 P54 CLKOUT25M1 MOSI2 VREFH1 P17 CS54 ETH1 TXER PHYRESETOUT ADTRGO PJ5 ETHO_RXD1 TIOCDO RXD3 PJ4 ETHO RXDO TXD3 PC3 ETHO_RXC ETHO_RXDV CATI2CCLK RXD4 SC SPI Multi 1 0 Bus Controller Az Interface 12 Bit A D Converter Gigabit Ethemet MAC EtherCAT Slave Controller USB 2 0 H5 Host Function CAM Interface Serial Sound Interface ETHO_INT Wwe Mum In ETHIINT A Notesgned Mete mo ASES Figure 4 13 Pin Function Device List View tab
8. 2 2 r cg icu user c Code Insertion Open this file by double clicking on the file name in e studio s Project Tree window Insert the followings between the specific user code insertion delimiter comments as shown below Start user code for global Do not edit comment generated here volatile uint8 t g switch press 0 End user code Do not edit comment generated here Start user code Do not edit comment generated here Invert the flag g switch press g switch press End user code Do not edit comment generated here 5 2 3 r cg icu h Code Insertion Open this file by double clicking on the file name in e studio s Project Tree window Insert the following at the end of the file between the user code delimiter comments as shown below Start user code for function Do not edit comment generated here extern volatile uint8 t g switch press End user code Do not edit comment generated here 5 2 4 r cg cmt user c Code Insertion Open this file by double clicking on the file name in e studio s Project Tree window Insert the following between the user code delimiter comments as shown below in the file section designated Global variables and functions Start user code for include Do not edit comment generated here include r cg icu h include r cg cmt h include r cg s12ad h End user code Do not edit comment generated here R20UT3281EG0100 Rev 1 00 RENESAS Page 24 of
9. 3 Renesas 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 Renesas Electronics products or technical information described in this document No license express implied or otherwise is granted hereby under any patents copyrights or other intellectual property rights of Renesas Electronics or others 4 You should not alter modify copy or otherwise misappropriate any Renesas Electronics product whether in whole or in part Renesas Electronics assumes no responsibility for any losses incurred by you or third parties arising from such alteration modification copy or otherwise misappropriation of Renesas Electronics product 5 Renesas Electronics products are classified according to the following two quality grades Standard and High Quality The recommended applications for each Renesas Electronics product depends on the product s quality grade as indicated below 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 etc High Quality Transportation equipment automobiles trains ships etc traffic control systems anti disaster systems anticrime systems and safety equipment etc Renesas Electronics products are neither intended n
10. D Converter Setting tab Analog input channel setting Convert Group A Convert Group B Add Average AD value Dedicated sample and hold ANDOO ANOD MI ANDO2 al LI a ANOO3 FI d a al ANOOS FI LI al AN 0G FI LI ai ANDO E Conversion start tigger setting Conversion start trigger Group A Software trigger Conversion start trigger Group B Compare match with or input capture to MTUO TGRA Data registers setting AD converted value addition count 1 time conversion Data placement Right alignment Automatic clearing Disable automatic clearing Data accuracy 12 bit accuracy d Figure 4 7 A D Converter Setting tab 2 ANOU conversion time setting Input sampling time 0 3667 us Actual value 0 367 Temperature sensor output conversion time setting Input sampling time 0 3667 us Actual value 0 367 Conversion time setting Total conversion time Group A 0 717 us Total conversion time Group B us Interrupt setting Enable AD conversion end interrupt S12ADI0 Priority Level 0 highest 4 Enable AD conversion end interrupt for group B 512GBADIO Priority Level 0 highest Enable AD conversion overwrite error interrupt request 512ADED Please configure interrupt in ECM Figure 4 8 A D Converter Setting tab 3 R20UT3281EG0100 Rev 1 00 LENESAS Page 19 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator
11. Figure 4 13 shows IRQ12 Pin Name function assigned to MCU pin number V4 but on the RSK RZT1 schematic V4 is connected to l O port pin P44 The IRQ12 function needs to be re assigned to P44 MCU pin number W15 To assign re assign a pin click on the pin to reveal a drop down menu button Click on the button to reveal a list of available pins then select W15 as shown in Figure 4 14 R20UT3281EG0100 Rev 1 00 RENESAS Page 21 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator IRQ11 Mot assigned Not assigned In IRQ12 PN4 IRQ12 MTIOCEC TIOCCE SSL11 Vi x In IRQ13 Not assigned assigned In IRQ14 Not assigned Wi In IRQ15 Not assigned WIS In Figure 4 14 Pin Function Assignment Re assignement The MPC assigns pins in the order in which the peripherals were configured Once a pin has been assigned to a function configuring another peripheral that uses the same function will result in the assignment of that function to an alternate pin In addition the MPC does not automatically map functions to pins based on the connectivity on the RSK RZT1 This is why it is important to verify the pin functions in the Device List View A pin name will be shown in red if configuration clashes exist A remark will be shown on the Pin Remark column of the Device List View if a pin function is assigned without configuring the peripheral that uses the function 4 3 2 Generating the Code Peripheral function configuration is now comp
12. General Project References Run Debug Settings Task Repository 4 33 Other options 3 Miscellaneous a 3 Compiler Source 3 Object Q3 List 4 83 Warnings Standard 3 Advanced a Other 3 Miscellaneous 3 CPU 4 Assembler 8 Source 3 Object List Q3 Other 4 S Linker Mm Macro Defines x Figure 5 2 Adding additional search paths 24 NE S AS Page 26 of 37 RSK RZT1 5 Adding Code to Generated Files In the Add directory path dialog click the Workspace button and in the Folder selection dialog browse to the CG Tutorial src folder and click OK e studio formats the path as shown in Figure 5 3 below Add directory path Directory frworkspace loc ProjName src LIK Cancel File systern Figure 5 3 Adding workspace search path Repeat the above steps to add the workspace search paths and press OK to exit the Properties dialog Select Build Project from the Project menu or use the button e studio will build the project with no errors The project may now be run using the debugger as described in 87 5 4 Release Build Section Map Code Generator makes changes to Linker Section addresses while generating code These changes are only performed on the build configuration currently selected The steps followed above will create a working HardwareDebug build configuration Follow the steps be
13. ICIER BIT STILE QU RIICO ICIER BIT SPIE 1U Enable stop condition detection to prepare for the next receive Enable the TXIO interrupt VI C 1 EN3 LONG 0x08000000UL Enable the RXIO interrupt VI C 1EN3 LONG 0x04000000UL else if IIC MASTER RECEIVES RESTART g riicO state RII CO 1CSR2 BIT START QU RII CO ICIER BIT STIE QU g riic state IIC MASTER SENDS ADR 10A R else if IIC MASTER RECEIVES STOP g riic0 state RI ICO CMR3 BI T RDRFS RII CO CMR3 BI T ACKWP RII CO ICMR3 BIT ACKBT RIICO ICSR2 BI T NACKF RIICO ICSR2 BIT STOP RILCO ICI ER BIT SPIE QU RIICO ICIER BIT STIE 1U Enable start condition detection to prepare for the next receive N nmn n M c E Clear TXIO interrupt flag VIC PI C3 LONG 0x08000000UL Disable TXIO interrupt VIC IL EC3 LONG 0x08000000UL Clear RXIO interrupt flag VIC PI C3 LONG 0x04000000UL Disable RXIO interrupt VIC IL EC3 LONG 0x04000000UL r riic callback receiveend R20UT3281EG0100 Rev 1 00 RENESAS Page 32 of 37 Mar 21 2015 RSK RZT1 9 Additional Information 9 Additional Information Technical Support For details on how to use e studio refer to the help file by opening e studio then selecting Help gt Help Contents from the Window menu bar e GE Welcome Help Contents WP Search Dynamic Help For information about the RZ T1 group
14. bat Frequency 25 MHz makefile init a Code Generator JP PinView PLLO circuit setting Ee Peripheral Functions Frequency Main clock oscillator setting Main clock oscillation source Resonator Extemal clock Clock source is set based on the status of OSCTH Oscillation stop detection function Disabled J Code Preview PLL1 circuit setting Operation Frequency 200 MHz Low speed on chip oscillator LOCO setting Operation Frequency 240 Internal clock setting Clock source is PLLO or PLL1 Clock source PLLO CPU clock CPUCLK 150 System clock ICLK 150 High speed peripheral module clock PCLKA 150 High speed peripheral module clock PCLKB 75 External bus clock CKIO 50 Figure 4 2 Peripheral View Code Generator provides GUI features for configuration of MCU sub systems and peripherals Once the user has configured all required MCU sub systems and peripherals the user can click the Generate Code button resulting in the creation of a number of source and header files in the e studio project s src folder A few more steps will need to be carried out before the project is fully configured and ready for use Navigation to the MCU peripheral configuration screens may be performed by double clicking the required function in the Code Generator Peripheral Function under the Project View pane It is also possible to see a preview of the code that will be generated for the current peripheral function setti
15. microcontroller refer to the RZ T1 Group Hardware Manual For information about the RZ assembly language refer to the RZ Series Software Manual Technical Contact Details Please refer to the contact details listed in section 11 of the Quick Start Guide General information on Renesas microcontrollers can be found on the Renesas website at http www renesas com Trademarks All brand or product names used in this manual are trademarks or registered trademarks of their respective companies or organisations Copyright This document may be wholly or partially subject to change without notice All rights reserved Duplication of this document either in whole or part is prohibited without the written permission of Renesas Electronics Europe Limited O 2015 Renesas Electronics Europe Limited All rights reserved O 2015 Renesas Electronics Corporation All rights reserved O 2015 Renesas Solutions Corp All rights reserved R20UT3281EG0100 Rev 1 00 LENESAS Page 33 of 37 Mar 21 2015 REVISION HISTORY RSK RZT1 Code Generator Tutorial Manual e studio Rev Description Mar 21 2015 mE First Edition issued Renesas Starter Kit Manual Code Generator Tutorial Manual Publication Date Rev 1 00 Mar 21 2015 Published by Renesas Electronics Corporation LENESAS SALES OFFICES Renesas Electronics Corporation Refer to http www renesas com for the latest and detailed information http www renesas com Renesa
16. not focus on the functionality of the sample Use Build Project from the Project menu or the button to build the tutorial The project will build with no errors R20UT3281EG0100 Rev 1 00 ENESAS Page 13 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator 4 Using the Code Generator 4 1 Introduction Code Generator is a GUI tool for generating template C source code This tool comes in two versions either as an integrated plugin in e studio or as a standalone application The Code Generator tool distributed with the RSK RZT1 is the plugin version Code Generator enables the user is to configure various MCU features and operating parameters using intuitive GUI controls bypassing the need in most cases to refer to sections of the Hardware Manual By following the steps detailed in this tutorial the user will generate an e studio project called CG Tutorial A fully completed CG_Tutorial project is contained on the DVD and may be imported into e studio by following the steps in the Quick Start Guide This tutorial is intended as a learning exercise for users who wish to use the Code Generator to generate their own custom projects for e studio Once the user has configured the project the Generate Code function is used to generate three code modules for each specific MCU feature selected These code modules are named T cg xxx h r cg XXX C and r cg xxx user c where xxx is a three lette
17. 37 Mar 21 2015 RSK RZT1 5 Adding Code to Generated Files Start user code for global Do not edit comment generated here Function prototype for scaling a value static uint32 t scale value const uint32 t value const uint32 t in max const uint32 t out max End user code Do not edit comment generated here Insert the following in to the function voia r cmt cmil interrupt void Start user code Do not edit comment generated here Update the period based on the flag set in the switch handler interrupt if 0 g switch press scale the ADC value ADC range 0 4095 CMT range 0 65478 CMT1 CMCOR scale value uint32 t S12ADCO ADDR7 4095 65478 else Do not update the CMT period LEDO LEDO End user code Do not edit comment generated here Insert the following between the user code delimiter comments at the end of the file Start user code for adding Do not edit comment generated here uint32 t out max maximum range of desired scale J TOR ESEGEA ECEGEGEGE EEO LEE EA ELSES EL SLE ES EORR MEUS OP io Function Name scale val ue Description This function is CMI1 interrupt service routine The formula used output 1 value 0 out max 0 in max 0 i Note The actual and desired ranges minimum value is assumed to be 0 Arguments Uint32 t value value to scale uint32 t in max maximum range of value to scale
18. 8 JIn Persiaran Barat 46050 Petaling Jaya Selangor Darul Ehsan Malaysia Tel 60 3 7955 9390 Fax 60 3 7955 9510 Renesas Electronics India Pvt Ltd No 777C 100 Feet Road HALII Stage Indiranagar Bangalore India Tel 91 80 67208700 Fax 91 80 67208777 Renesas Electronics Korea Co Ltd 12F 234 Teheran ro Gangnam Gu Seoul 135 080 Korea Tel 82 2 558 3737 Fax 82 2 558 5141 O 2015 Renesas Electronics Corporation All rights reserved Colophon 4 0 RZT1 Group LENESAS Renesas Electronics Corporation R20UT3281EGO100
19. CK SIZE 0x100 IRQ mode stack Wi FIQ STACK SIZE 0x100 FRQ mode stack UND STACK SIZE 0x100 SVC mode stack ABT STACK SIZE 0x100 ABT mode stack ki HEAP STACK SIZE 0x1000 Heap stack size ATCM_BASE 0x00000000 User application located here d BTCM_BASE 0x00800000 BTCM base address I USER_EXEC_BASE 0x00000000 Application loads and runs from here USER_RAM 0x20000000 Application s RAM base STACK_BASE 0x00807800 Stacks located in BTCM I SECTIONS loader text USER EXEC BASE reset start loader text ALIGN 0x4 reset end gt ATCM R20UT3281EG0100 Rev 1 00 ENESAS Page 28 of 37 Mar 21 2015 RSK RZT1 6 External Linker File text text start text text startup text end gt ATCM rodata rodata start Start data ROM rodata rodata ALIGN 0x8 data data end data ROM got plt got ALIGN 0x8 rodata end PROVIDE end gt ATCM we a ram data size end data ROM start data ROM data USER RAM Start data RAM data start start data RAM ram data size data end j bss data end bss start PROVIDE bss start bss bss COMMON ALIGN 0x4 PROVIDE bss end ebss end _end PROVIDE end heap heap start ALIGN 0x8 heap stack
20. Port Pin Configuration 4 3 1 3 Compare Match Timer CMT This peripheral is configured to generate regular intervals used to flash LEDO Double click on the Compare Match Timer entry in Project Explorer gt CG_Tutorial gt Code Generator gt Peripheral Functions Configure the CMT channel as shown in Figure 4 5 eura EM cro cara cura enms Compare match timer operation setting 1 Unused Used Count clock setting PCLED 8 3 PCLED S32 PCLKD 128 PCLKD 512 Interval value setting Interval value 44 me Actual value 447 00330 Interrupt setting Enable compare match interrupt CMIT Priority Level 3 Figure 4 5 CMT Setting Tab 4 3 1 4 A D Converter This peripheral is configured to sample the analogue output value of the RV1 potentiometer The A D Converter is set to perform a sample when the user presses SW3 which is connected to the ANOO7 pin of the microcontroller Double click on the S12ADO entry in Project Tree gt Peripheral Functions gt 12 Bit A D Converter R20UT3281EG0100 Rev 1 00 ENESAS Page 18 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator Configure the Setting 1 sub tab as shown in the following figures 5124AD0 operation setting Unused Used Operation mode setting Single scan mode Group scan mode Continuous scan mode Double trigger mode setting Figure 4 6 A
21. The debugger will start up and the e studio will show the Code Generator function PowerOn_Reset Click the Resume E button The debugger will stop again at the beginning of the main function Press LI again to run the code The program will toggle LEDO at a rate set by the position of RV1 Slowly rotate RV1 fully clockwise then counter clockwise and observe the change in the rate at which the LED toggles Press SW3 to keep the rate at the position of RV1 when the SW3 was pressed Rotating RV1 will not change the toggling rate Press SW3 to re enable the variations to the toggling For more information on the e studio debugger refer to the Tutorial manual R20UT3281EG0100 Rev 1 00 RENESAS Page 31 of 37 Mar 21 2015 RSK RZT1 8 Usage Notes e Usage Notes 8 1 iodefine h File Location of the iodefine h file By default the r cg macrodriver h header file which includes the iodefine h file expects the iodefine h file to be located in the src folder 8 2 RIIC Module The RIIC peripheral contains an error in one of its interrupt handler functions In the r cg riic user c file in the function voiar riic0 error interrupt void replace the existing el se if condition and the encapsulated lines of code with the following else if IIC MASTER RECEIVE g riic0 mode flag if IIC MASTER SENDS ADR 7 R g riicO state IIC MASTER SENDS ADR 104 W g riic0 state RI1CO 1CSR2 BIT START QU RIICO
22. al Quick Start Guide Provides simple instructions to setup the RSK and RSK RZT1 Quick R20UT3244EG run the first sample Start Guide Code Generator Provides a guide to the standalone code generation RSK RZT1 Code R20UT3281EG Tutorial tool Generator Tutorial Manual Schematics Full detail circuit schematics of the RSK RSK RZT1 R20UT3241EG Schematics Hardware Manual Provides technical details of the RZ T1 RZT1 Group User s R0O1UHO483EJ microcontroller Manual Hardware NOR Boot Loader Describes operational details of the NOR Boot RZT1 NOR Boot R01AN2470EG Application Note Loader Program Loader Application Note QSPI Boot Loader Describes operational details of the QSPI Boot RZT1 QSPI Boot R01AN2471EG Application Note Loader Program Loader Application Note 2 List of Abbreviations and Acronyms Abbreviation 1 OV Central Processing Unit Dv Digital Versatile Disc 66677 OE Integrated Development Environment Ra hemmiRewesle 6677 lop guia Crystal Display S ED loEm npbios MU Meocowler h SSS PG PesoiGomur Digilent Pmod Compatible connector PmodIM is registered to Digilent Inc Digilent Pmod Interface Specification PL TT RSK Renesas StarterKit IO SOT Serial Communications Interface SP SerialPeripheral interface CPU DVD E1 UI IDE LCD LED MCU PC TM PLL RSK SCI SPI All trademarks and registered tradema
23. applications or use by the military including but not limited to the development of weapons of mass destruction When exporting the Renesas Electronics products or technology described in this document you should comply with the applicable export control laws and regulations and follow the procedures required by such laws and regulations 10 It is the responsibility of the buyer or distributor of Renesas Electronics products who distributes disposes of or otherwise places the product with a third party to notify such third party in advance of the contents and conditions set forth in this document Renesas Electronics assumes no responsibility for any losses incurred by you or third parties as a result of unauthorized use of Renesas Electronics products 11 This document may not be reproduced or duplicated in any form in whole or in part without prior written consent of Renesas Electronics 12 Please contact a Renesas Electronics sales office if you have any questions regarding the information contained in this document or Renesas Electronics products or if you have any other inquiries Note 1 Renesas Electronics as used in this document means Renesas Electronics Corporation and also includes its majority owned subsidiaries Note 2 Renesas Electronics product s means any product developed or manufactured by or for Renesas Electronics 2012 4 Disclaimer By using this Renesas Starter Kit RSK the user accepts the f
24. are not subject to radiation resistance design Please be sure to implement safety measures to guard them against the possibility of physical injury and injury or damage caused by fire in the event of the failure of a Renesas Electronics product such as safety design for hardware and software including but not limited to redundancy fire control and malfunction prevention appropriate treatment for aging degradation or any other appropriate measures Because the evaluation of microcomputer software alone is very difficult please evaluate the safety of the final products or systems manufactured by you 8 Please contact a Renesas Electronics sales office for details as to environmental matters such as the environmental compatibility of each Renesas Electronics product Please use Renesas Electronics products in compliance with all applicable laws and regulations that regulate the inclusion or use of controlled substances including without limitation the EU RoHS Directive Renesas Electronics assumes no liability for damages or losses occurring as a result of your noncompliance with applicable laws and regulations 9 Renesas Electronics products and technology may not be used for or incorporated into any products or systems whose manufacture use or sale is prohibited under any applicable domestic or foreign laws or regulations You should not use Renesas Electronics products or technology described in this document for any purpose relating to military
25. ding the speech marks workspace_loc ProjName src linker_file Id Click Apply Navigate to Project properties gt C C Build gt Settings gt Linker Other gt Miscellaneous Ensure to untick the Enable garbage collection of unused input sections gc sections if it is ticked Click Ok The above 7 steps needs to be done for the HardwareDebug and Release configurations 6 2 Building the Project The project template created by Code Generator can now be built In the Project Explorer pane expand the src folder Use Build Project from the Project menu or the A button to build the CG_Tutorial project The project will build with no errors R20UT3281EG0100 Rev 1 00 RENESAS Page 30 of 37 Mar 21 2015 RSK RZT1 7 Executing the Project 7 Executing the Project In the Project Explorer pane ensure that the CG Tutorial project is selected To debug the project click the button The dialog shown in Figure 7 1 will be displayed Confirm Perspective Switch E This kind of launch is configured to open the Debug perspective when it suspends This Debug perspective is designed to support application debugging It Incorporates views for displaying the debug stack variables and breakpoint management Do you want to open this perspective now Remember my decision Figure 7 1 Perspective Switch Dialog Click OK to confirm that the debug window perspective will be used
26. ect All to make change on all available build configurations Click OK Do Ie Exclude from build W HardwareDebug Select Al Deselect All C9 a Figure 5 1 Excluding files from the project Multiple files can be excluded in on step by selecting the desired files during step 1 Exclude the following files loader_param c r ecm c r ecm h r icu init c r icu init h r system h typdefine h To re include a file repeat the above steps and click on Deselect All then click OK R20UT3281EG0100 Rev 1 00 ENESAS Page 23 of 37 Mar 21 2015 RSK RZT1 5 Adding Code to Generated Files 5 2 Adding Code to Generated Files This section covers inserting code in to the newly created Code Generator files Each subsection is a Code Generator generated source file that needs to be opened by double clicking on the file name in e studio s Project Tree window under the src folder The code from each section should be copied from this document and pasted in to the relevant file at the location indicated 5 2 1 r cg userdefine h Code Insertion Open this file by double clicking on the file name in e studio s Project Tree window Insert the following at the end of the file between the user code delimiter comments as shown below Start user code for function Do not edit comment generated here define LEDO PORTF PODR BI T B7 End user code Do not edit comment generated here 5
27. enerating file was successful Figure 4 15 Code Generator s Output pane R20UT3281EG0100 Rev 1 00 RENESAS Page 22 of 37 Mar 21 2015 RSK RZT1 5 Adding Code to Generated Files 5 Adding Code to Generated Files At this stage of a typical project development the user would expand on the generated code to create the application required When inserting code in Code Generator created files it must be placed in the areas delimited by comments as follows Start user code for xxxxx Do not edit comment generated here End user code Do not edit comment generated here Where _xxxx_ depends on the particular area of code i e function for insertion of user functions and prototypes global for insertion of user global variable declarations or include for insertion of pre processor include directives User code inserted inside these comment delimiters is protected from being overwritten by Code Generator if the user regenerates the Code Generator code 5 1 Excluding Files All sample code can only have one main file The init main c file generated in Section 3 2 and the r cg main c file generated by Code Generator both include a main function The init main c file is automatically excluded following code generation To exclude a file from the project following these steps Locate the source file in the Project Explorer view Right click on the file and select Exclude from build Click on Sel
28. eripheral code generator automatically generates programs device drivers for MCU peripheral functions clocks timers serial interfaces A D converters DMA controllers etc based on settings entered via a graphical user interface GUI Functions are provided as application programming interfaces APIs and are not limited to initialization of peripheral functions Automatic ucc EE Y generation Application under of peripheral development function Software settings Middleware x gt E lt Microcontroller EA RZOZZEKZZEEGE R20UT3281EG0100 Rev 1 00 E 24 NE S AS Page 11 of 37 Mar 21 2015 RSK RZT1 3 Project Creation with e studio In Select Additional CPU Options leave everything at default values Click Next In the Library Generator Settings leave everything at default values Click Finish le C Project e2 studio Project Generation Select Additional CPU Options Select Additional CPU Options Instruction Set Inter Working Target FPU Floating Point ABI e2 studio Project Generation Select Library Generator Settings Select Library Source 9 Optimized Newlib Use these for further code size Optimization Select Header Files ctypeh Handles and checks characters math h Performs numerical calculations such as trigonometric funtions stdio h Performs input output handling stdlib h Perf
29. f the Electromagnetic Compatibility Directive and could lead to prosecution The product generates uses and can radiate radio frequency energy and may cause harmful interference to radio communications However there is no guarantee that interference will not occur in a particular installation If this equipment causes harmful interference to radio or television reception which can be determined by turning the equipment off or on you are encouraged to try to correct the interference by one or more of the following measures ensure attached cables do not lie across the equipment reorient the receiving antenna increase the distance between the equipment and the receiver connect the equipment into an outlet on a circuit different from that which the receiver is connected power down the equipment when not in use consult the dealer or an experienced radio TV technician for help NOTE It is recommended that wherever possible shielded interface cables are used The product is potentially susceptible to certain EMC phenomena To mitigate against them it is recommended that the following measures be undertaken The user is advised that mobile phones should not be used within 10m of the product when in use The user is advised to take ESD precautions when handling the equipment The Renesas Starter Kit does not represent an ideal reference design for an end product and does not fulfil the regulatory standards for an end product How to Use Th
30. is Manual 1 Purpose and Target Readers This manual is designed to provide the user with an understanding of how to use Code Generator for RZ together with the e studio IDE to create a working project for the RSK platform It is intended for users designing sample code on the RSK platform using the many different incorporated peripheral devices The manual comprises of step by step instructions to generate code and import it into e studio but does not intend to be a complete guide to software development on the RSK platform Further details regarding operating the RZT1 microcontroller may be found in the Hardware Manual and within the provided sample code Particular attention should be paid to the precautionary notes when using the manual These notes occur within the body of the text at the end of each section and in the Usage Notes section The revision history summarizes the locations of revisions and additions lt does not list all revisions Refer to the text of the manual for details The following documents apply to the RZT1 Group Make sure to refer to the latest versions of these documenis The newest versions of the documenis listed may be obtained from the Renesas Electronics Web site User s Manual Describes the technical details of the RSK hardware RSK RZT1 User s R20UT3242EG Manual Tutorial Provides a guide to setting up RSK environment RSK RZT1 Tutorial R20UT3243EG running sample code and debugging programs Manu
31. lete Click Generate Code button located at the top right of the Peripheral Function tab The Output pane should report The operation of generating file was successful as shown Figure 4 15 below Me489881 The following files were generated MO489 04 src ce src r cg main c was overwritten Me489884 srcVcg src r_ cg mpc c was overwritten M8489684 srckcg src r cg mpc h was overwritten MB84898684 srckcg src r cg interrupthandlers h was overwritten MB4B9BB4 srcicg srcXr cg intprg c was overwritten Me489884 s5rcVcg srcXr cg systeminit c was overwritten Me489884 srcVcg srcXr cg macrodriver h was overwritten Me489884 srcVcg srcXr cg userdefine h was overwritten Me489884 srcVcg src r cg cgc c was overwritten Me489884 srcVcg src r cg cgc user c was overwritten Me489884 srcVcg srcXr cg cgc h was overwritten Me489884 srcVcg srcXr cg icu c was overwritten Me489884 srcVcg srcXr cg icu user c was overwritten Me489884 srcVcg src r cg icu h was overwritten Me489884 srcVcg srcXr cg port c was overwritten Me4898084 s5rcVcg src r cg port user c was overwritten Me489884 srcVcg srcxXr cg port h was overwritten Me489884 srcVcg srcXr cg cmt c was overwritten Me489884 srcVcg src r cg cmt user c was overwritten Me489884 srcVcg srcXr cg cmt h was overwritten Me489884 srcVcg srcXr cg sl2ad c was overwritten Me489884 srcVcg srcXr cg sl2ad user c was overwritten MBABOBBA srckice src r cg sl2ad h was overwritten Me489883 The operation of g
32. low to create a working Release build configuration For details of the differences in these build configurations please see Section 2 Select the Release Build configuration by clicking Project gt Build Configurations gt Set Active gt Release Release No Debug In the Project Explorer tree right click the entry Code Generator and select Generate Code This will run an update for the generated code and make the required changes to Linker Section addresses Open the Release configuration from Debug Configurations gt Renesas GDB Hardware Debugging CG Tutorial Release Select the Startup tab Ensure the Set breakpoint at option is unticked Note Section 6 will need to be done for both R20UT3281EG0100 Rev 1 00 RENESAS Page 27 of 37 Mar 21 2015 RSK RZT1 6 External Linker File 6 External Linker File e studio allows specifying a different linker file to be used by the linker The default linker map declaration can be found in Project properties gt C C Build gt Settings gt Linker gt Sections The CG Tutorial code does not make use of the default linker mapping declaration The loader init asm file includes variables declared in the default linker map These variables are used for storing specific addresses in the linker file Open the loader init asm and change if 1 to if O 6 1 Linker File Over ride The following steps are used to create a new linker file define the li
33. n amp Sample Project 4 Static Library Renesas amp Sample Project gt Makefile project Show project types and toolchains only if they are supported on the platform lt Back Next gt Finish R20UT3281EG0100 Rev 1 00 LENESAS Page 10 of 37 Mar 21 2015 RSK RZT1 3 Project Creation with e studio In the Target Specific Settings dialog select the options as shown in the screenshot opposite The R7S910018 MCU is found under RZ T gt RZ T1 gt RZ T1 320 pin gt R7S910018 Click Next Select Use Peripheral code Generator Click Next e2 studio Project Generation Select Target Specific Settings Toolchain Version Debug Hardware J Link ARM No Image Endian Little endian Available y Select Target R7S910018 Select Configuration From List below Hardware Debug Debug using hardware Debug using Simulator Debug using simulator Release no debug Project without any debug information Build configurations will be created in the project only for the selected debug mode options however by default the project will be built for the active configuration i e first configuration selected from group Based on the device selection you made RZ T the debug hardware J Link ARM and debug target R75910018 debug configuration will be automatically created for you e2 studio Project Generation Code Generator Settings The e2 studio p
34. ngs by double clicking the required function in the Code Generator gt Code Preview on the left R20UT3281EG0100 Rev 1 00 ENESAS Page 15 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator 4 3 Code Generation In the following sections the reader is guided through the steps to configure the MCU peripherals required Note Configuration options that are not shown should be left with the default settings 4 3 1 Peripheral Function Configuration 4 3 1 1 Clock Generator Figure 4 3 shows a screenshot of Code Generator with the Clock Generator function open In this tutorial we are using the 25 MHz crystal resonator for the main clock source with the PLL circuit used as a multiplier Some peripherals can be configured to use the main clock or PLL circuitry sources to generate their clock Double click on the Clock Generation Circuit entry in Code Generator gt Peripheral Functions list in the Project Tree Configure the Clock Generation Circuit options under the Clock Settings tab as shown in Figure 4 3 A block diagram of the Clock Generation Circuit is provided under Block Diagram tab shown on the next page This helps to see the different clock configurations available for the system and peripheral clocks R20UT3281EG0100 Rev 1 00 ENESAS Page 16 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator Boot mode setting 3 16 bit 32 bit bus boot
35. nker sections of the RZ T1 device and set the GNU Linker to use the file created Create a new file in the project Right click on the src source folder oelect New File Specify the name as linker file ld Open the file by double clicking on it Copy and paste the following text Jer Em MUSEI ASSET EZ copying after this lij dedo OUTPUT FORMAT elf32 littlearm elf32 bigarm elf32 littlearm OUTPUT ARCH arm ENTRY PowerON Reset MEMORY Internal RAM address range H 2000_0000 to H 2001_FFFF is configured as data retention RAM Write access to this address range has to be enabled by writing to registers SYSCR1 and SYSCR2 ATCM rwx ORIGIN 0x00000000 LENGTH 0x00080000 512KB H 00000000 to H 0007FFFF BTCM rwx ORIGIN 0x00800000 LENGTH 0x00800000 32KB H 00800000 to H 00807FFF BUFFER RAM rwx ORIGIN 0x08000000 LENGTH 0x10000000 128MB H 08000000 to H 10000000 DATA RAM rwx ORIGIN 0x20000000 LENGTH 0x00080000 512KB H 20000000 to H 2007FFFF Mapped memory type SPI ROM rw ORIGIN 0x30000000 LENGTH 0x04000000 CS0 ROM rw ORIGIN 0x40000000 LENGTH 0x04000000 CS1 ROM rw ORIGIN 0x44000000 LENGTH 0x04000000 SDRAMO EXT rw ORIGIN 0x48000000 LENGTH 0x04000000 SDRAM1_EXT rw ORIGIN 0x4C000000 LENGTH 0x04000000 j SYS STACK SIZE 0x200 Application stack size E SVC STACK SIZE 0x200 SVC mode stack ml IRQ STA
36. ock 0 supply channel Clocks input to MCLKI 2 pins Delta sigma interface clock 0 DSCLKD 25 MHz DSCLKO output polarity Notinverted se Delta sigma interface clock 1 clock source PD e Delta sigma interface clock 1 DSCLKI BZ DSCLKI output polarity Notinverted e Figure 4 3 Clock setting tab R20UT3281EG0100 Rev 1 00 RENESAS Page 17 of 37 Mar 21 2015 RSK RZT1 4 Using the Code Generator 4 3 1 2 1 0 Ports This peripheral will be configured to assign output pins for user LEDs The CG_Tutorial only makes use of LEDO User LED connectivity port pins on the schematic are as shown in Table 4 1 I O Ports Connectivity MCU Pin VO Port LEDO ES AA LED1 LED2 LED3 Table 4 1 I O Ports Connectivity Please refer to the RSK schematic for full details of the connectivity Double click on the I O Ports entry in Project Tree gt Peripheral Functions gt I O Ports Expand the list Configuration is required for the port pins listed in Table 4 1 I O Ports Connectivity Configure the port as shown in Figure 4 4 LED Port Pin Configuration Porti Por Pona Pons Pomo Ports Port Pong Poto Porta Pond Pone For Poia Port Pons Pork Port Por Por PF5 Unused In Out Disables input pull up and pull down resistors PFG M med in J Out Disables input pull up and pull down resistors PFI Unused In Out Disables input pull up and pull down resistors Output 1 Figure 4 4 LED
37. ollowing terms The RSK is not guaranteed to be error free and the entire risk as to the results and performance of the RSK is assumed by the User The RSK is provided by Renesas on an as is basis without warranty of any kind whether express or implied including but not limited to the implied warranties of satisfactory quality fitness for a particular purpose title and non infringement of intellectual property rights with regard to the RSK Renesas expressly disclaims all such warranties Renesas or its affiliates shall in no event be liable for any loss of profit loss of data loss of contract loss of business damage to reputation or goodwill any economic loss any reprogramming or recall costs whether the foregoing losses are direct or indirect nor shall Renesas or its affiliates be liable for any other direct or indirect special incidental or consequential damages arising out of or in relation to the use of this RSK even if Renesas or its affiliates have been advised of the possibility of such damages Precautions The following precautions should be observed when operating any RSK product This Renesas Starter Kit is only intended for use in a laboratory environment under ambient temperature and humidity conditions A safe separation distance should be used between this and any sensitive equipment lts use outside the laboratory classroom study area or similar such area invalidates conformity with the protection requirements o
38. or authorized for use in products or systems that may pose a direct threat to human life or bodily injury artificial life support devices or systems surgical implantations etc or may cause serious property damages nuclear reactor control systems military equipment etc You must check the quality grade of each Renesas Electronics product before using it in a particular application You may not use any Renesas Electronics product for any application for which it is not intended Renesas Electronics shall not be in any way liable for any damages or losses incurred by you or third parties arising from the use of any Renesas Electronics product for which the product is not intended by Renesas Electronics 6 You should use the Renesas Electronics products described in this document within the range specified by Renesas Electronics especially with respect to the maximum rating operating supply voltage range movement power voltage range heat radiation characteristics installation and other product characteristics Renesas Electronics shall have no liability for malfunctions or damages arising out of the use of Renesas Electronics products beyond such specified ranges 7 Although Renesas Electronics endeavors to improve the quality and reliability of its products semiconductor products have specific characteristics such as the occurrence of failure at a certain rate and malfunctions under certain use conditions Further Renesas Electronics products
39. orms C program standard processing such as storage area management string h Performs string comparison copying Select Library Type 9 Project Built Pre Built Build the library with user specified options R20UT3281EG0100 Rev 1 00 Mar 21 2015 24 N S AS Page 12 of 37 RSK RZT1 3 Project Creation with e studio A summary dialog will appear click OK to complete the project generation Project Summary PROJECT GENERATOR PROJECT NAME CG Tutorial PROJECT DIRECTORY CA Workspace CG Tutoral CG CPU SERIES RZFT CPU TYPE RA TI TOOLCHAIN NAME KPIT GHUARM NONE EABI Too TOOLCHAIM VERSION v14 02 GENERATION FILES C Workspace CG Tutorial CG Tutorial src reset_program z Reset Program CAWorkspace LG TutoriatG Tutonal src CG_Tutorial c Main Program CAWorkspace CG Tutonal CG Tutorial sre amp khardware setup Hardware Initialization CA Workspace CG Tutonal CG Tutorialksrektypedefine h 4 nm I Click OK to generate the project or Cancel to abort The generated sample is a fully functional sample that can be built and executed however for the purpose of this tutorial the sample s functionality will not be tested Note the sample toggles LEDO on the RSK RZT1 board The toggling rate changes with variations of the potentiometer RV1 Pressing SW3 enables disables the LED toggling This manual does
40. pts can cause generation of an interrupt which should be ignored Allow some delay to catch the interrupt should it occur while 0 g switch press amp amp delay asm nop Ensure the switch pressed flag is cleared to enable timer period updates g switch press 0 Enable continuous A D conversions R 512AD0 Starti Enable the timer s count R CMT1 Start End user code Do not edit comment generated here 5 3 Before the project can be built the compiler needs some additional include paths added Additional include paths Select the CG Tutorial project in the Project Explorer pane Use the button in the toolbar to open the project settings Navigate to C C Build gt Settings gt Compiler gt Source and click the button as shown in below in Figure 5 2 le Properties for CG Tutorial R20UT3281EG0100 Rev 1 00 Mar 21 2015 type filter text Settings Resource Builders a C C Build Build Variables Change Toolchain Vers Dependency Scan Configuration HardwareDebug Active Y Manage Configurations Tool Settings F Build Steps gt Build Artifact Binary Parsers Error Parsers JD 3 v Y Device 4 8 Library Generator Environment Include file directories es 3 Settings Logging 3 Ee ERRAT AA Add Settings 32 Header files S TCINSTALL arm none eabi include Tool Chain Editor gt C C
41. r acronym for the relevant MCU feature for example scifa Within these code modules the user is free to add custom code to meet their specific requirement Custom code should be added between the following comment delimiters x Start user code for adding Do not edit comment generated here End user code Do not edit comment generated here Code Generator will locate these comment delimiters and preserve any custom code inside the delimiters on subsequent code generation operations Any code outside of these comment delimiters will be overwritten on subsequent code generation sessions The CG Tutorial project uses the ADC module with external trigger Interrupt Controller Unit ICU and Comapare Match Timer CMT and an LED I O Port As a demonstration this tutorial performs the following actions Configure an LED to be toggled Configure an A D channel for setting the toggling period Configure a timer channel to generate the toggling period Configure a switch used to enable or disable toggling of the LED Following a tour of the key user interface features of Code Generator in Section 4 2 the reader is guided through each of the peripheral function configuration dialogs in Section 4 3 1 ln Section 5 the reader is familiarised with the structure of the template code as well as how to add custom code in the areas provided by the Code Generator and any other changes required to be made in the project generated in Section 3 2
42. rks are the property of their respective owners Table of Contents ASI Wi IM RE MAMMA M 7 E PRU OSC naaa adas 7 MN EISE EN 7 2 NVO dU CUON sche TEO mom E OO 8 3 Project Creation with ef SIO etie te ict tete eti t tte td tet teta teta bam 9 3 1 IVONO uri a dba 9 e Creme RO E Tm T TERM 9 A SING ME Code GEI IU 14 4 1 daligerelULe Io ETT UTUNTUR 14 AD Gode Generator TOU uus ioca ime duc sedecim casetas c ndor 14 ES Code General Osee 16 4 3 1 Peripneral Funcion ONIQUFAU ONM sid sum sese r eee a eal on aka kuo 16 4 3 2 Generalnog the Cole ss nod 22 SAdding Gode to Generated Files tenido eni as lonio enda lea IRI danie TENN a 23 oy EXCUSA e a e Garo Gest ea stato una kata ka 23 5 2 Adding Code to Generated Files eesseseeecennnnnneeennnnnnnneennnnnnnennnnnnaretennnnnssssesnnnsssttoso 24 5 2 1 rg userdeline li Code seria l 24 5 2 2 r cg icu user c Code lnsertlON sssss cessssscessssscesssustcesquntcensansseruantsennantssnnnns 24 5 2 3 F260 einEEe 3n q m rcr 24 5 2 4 FCOQ CMIL USeCO Code INSEMION soi cession iii lacio ku SG usta 24 525 rcg Iain oc Code InsertlOlix unisce aa is tout abs DUE 25 5 3 X Additional include paths ssssssscesssessssssssssunsscerssnnasssessennstssennennstsrenqennssssrnsnnnnsstttt s 26 54 Release Build Section Map cccccccccsssscccccceeeeceeecseeesceeesseeeceeesseeseeeeesseueceee
43. s Electronics America Inc 2801 Scott Boulevard Santa Clara CA 95050 2549 U S A Tel 1 408 588 6000 Fax 1 408 588 6130 Renesas Electronics Canada Limited 9251 Yonge Street Suite 8309 Richmond Hill Ontario Canada L4C 9T3 Tel 1 905 237 2004 Renesas Electronics Europe Limited Dukes Meadow Millboard Road Bourne End Buckinghamshire SL8 5FH U K Tel 44 1628 585 100 Fax 44 1628 585 900 Renesas Electronics Europe GmbH Arcadiastrasse 10 40472 D sseldorf Germany Tel 49 211 6503 0 Fax 49 211 6503 1327 Renesas Electronics China Co Ltd Room 1709 Quantum Plaza No 27 ZhiChunLu Haidian District Beijing 100191 P R China Tel 86 10 8235 1155 Fax 86 10 8235 7679 Renesas Electronics Shanghai Co Ltd Unit 301 Tower A Central Towers 555 Langao Road Putuo District Shanghai P R China 200333 Tel 86 21 2226 0888 Fax 86 21 2226 0999 Renesas Electronics Hong Kong Limited Unit 1601 1611 16 F Tower 2 Grand Century Place 193 Prince Edward Road West Mongkok Kowloon Hong Kong Tel 852 2265 6688 Fax 852 2886 9022 Renesas Electronics Taiwan Co Ltd 13F No 363 Fu Shing North Road Taipei 10543 Taiwan Tel 886 2 8175 9600 Fax 886 2 8175 9670 Renesas Electronics Singapore Pte Ltd 80 Bendemeer Road Unit 06 02 Hyflux Innovation Centre Singapore 339949 Tel 65 6213 0200 Fax 65 6213 0300 Renesas Electronics Malaysia Sdn Bhd Unit 1207 Block B Menara Amcorp Amcorp Trade Centre No 1
44. sseaseceeessaaueeeessseaseeeesasaageeees 27 OE eine SINK lls ssussgs muss 0999190050294 059249019142009 4820899182 02990 09009 0 02094000990 095 28 6 1 LKINKEFFIIE OVE IMEEM a asada 28 62 O ducatu cba accetta dcn e E pa cdm atom MA a Pea du d 30 ToEXEGCUINO ME POEG sss m 31 S U Sade NOCO aranan TRE La Mta duda edat 32 NM eei Milan 32 32 RIE MOGU od 32 o o A 33 LENESAS RSK RZT 1 R20UT3281EG0100 Rev 1 00 RENESAS STARTER KIT Mar 21 2015 1 Overview 1 1 Purpose This RSK is an evaluation tool for Renesas microcontrollers This manual describes how to use the e studio IDE Code Generator plug in to create a working project for the RSK platform 1 2 Features This RSK tutorial guides the user through creating a project to evaluate the following features Project creation with e studio Code Generation using the Code Generator plug in User circuitry such as switches LEDs and a potentiometer The RSK board contains all the circuitry required for microcontroller operation R20UT3281EG0100 Rev 1 00 Page 7 of 37 Mar 21 2015 RENESAS RSK RZT1 2 Introduction 2 Introduction This manual is designed to answer in tutorial form how to use the Code Generator plug in for the RZ family together with the e studio IDE to create a working project for the RSK platform The tutorials help explain the following Project generation using the e studio Detailed use of the Code Generator plug in for e studio In
45. tegration with custom code Building and running the project e studio The project generator will create a tutorial project with two selectable build configurations HardwareDebug is a project built with the debugger support included Optimisation is set to zero Release is a project with optimised compile options producing code suitable for release in a product Some of the illustrative screenshots in this document will show text in the form RZxx These are general screenshots and are applicable across the whole RZ family In this case simply substitute RZxx for RZT1 These tutorials are designed to show you how to use the RSK and are not intended as a comprehensive introduction to the e studio debugger compiler toolchains or the J Link emulator Please refer to the relevant user manuals for more in depth information R20UT3281EG0100 Rev 1 00 Page 8 of 37 Mar 21 2015 RENESAS RSK RZT1 3 Project Creation with e studio 3 Project Creation with e studio 3 1 Introduction In this section the user will be guided through the steps required to create a new C project for the RZT1 microcontroller ready to generate and add peripheral driver code using Code Generator This project generation step is necessary to create the MCU specific source project and debug files 3 2 Creating the Project Start e studio and select a suitable location for the project workspace Start e studio and select a s
46. uitable location for the project workspace In the Welcome page click Go to the workbench R20UT3281EG0100 Rev 1 00 Mar 21 2015 LENESAS Workspace Launcher Select a workspace el studio stores your projects in a folder called a workspace Choose a workspace folder to use for this session Workspace SANI Browse C Use this as the default and do not ask again Cancel le C C e2 studio File Edit Source Refactor Navigate Search Project Run Window Help a 69 Welcome 2 A Ew Welcome e2studio cy Workbenct Go to the workbench 24 NE S AS Smart Manual Discovery Startup 33 s iar Page 9 of 37 RSK RZT1 3 Project Creation with e studio Create a new C project by right a project Explorer E Ege clicking in the Project Explorer pane and selecting New gt C Project as shown Alternatively use the menu New Proied item File gt New gt C Project a iia Import C Project Export a C Project Refresh 7j Other Ctrl N Enter the project name CG Tutorial In Project type choose Sample Project In Toolchains choose KPIT GNUARM NONE EABI Toolchain Click Next C Project Create C project of selected type Project name CG Tutorial Use default location Location CAWerkspaceC G Tuton Create Directory for Project Project type Toolchains 4 gt Executable Renesas KPIT GNUARM NONE EABI Toolchai

Download Pdf Manuals

image

Related Search

Related Contents

    Yamaha fzs6w Automobile User Manual  Pose 1clic2go  Leaflet CSS5235Y_12 Released France (French) High  1115503D FRONT COVER1.P65  Mode d`emploi  manual de instruções sobre lançamentos de nomes e  Karcher KMR 1250 D Vacuum Cleaner User Manual  DeLOCK 1m mini DVI/HDMI  

Copyright © All rights reserved.
Failed to retrieve file