Home

User`s Manual TK

image

Contents

1. eese terere tette te trt totos tette tata tss tattoos sa sss 33 I 35 241 TaD dta rcd leet EE 35 252 OUD 37 Ve Hey oi el E ed 38 251 Extend EORR 38 2 5 2 Startup Routine 0 2 2 0 39 2 0 Creare Load Module FING S 40 DJ Gheck Debisger orbs aah ed in ideas 42 2 Board SGINE S ell beat bie Able 44 2 9 Start Debugger ID78KOR QBJ seen tette tette te tette te teretes teen sts 45 2 PO 48 otop 50 2 12 Close Debugger 078 51 2 19 Quit P MIS opt oO ______ 52 CHAPTER S HARDWARE SPESIEIGA TIONS
2. 53 34 eon 54 9 2 Layout ot solder SHOFt Dada decur N ___________ 54 Olah OW FUNGCUORNG senate 55 PT 55 55 A N a 55 56 ___ ____6 ___ ___ ___ 56 5505 i MR UN 56 TK 78KOR KG3 User 5 Manual ood AL ______ ______ 57 94 Universal PA Sacha ata eet 57 3 9 Solder short pad 2 59 With using the solder short pad to cut the circuit users can customize the circuit 58 3 6 Operation by external power 2 0 59 CHAPTER 4 TROUBLESHOOTING 60 4 1 If you cannot find USB driver when you connect to the 60 4 2 Error when you start the 60 4 2 1 not communicate with Emulator F0100 or 0109 61 4 2 2
3. F8KOR_ oice prw File Edit Find Layer View Project Build Tool Window Help _______ Load the workspace file SAMPLE_KG3 prw 78K0R_Voice 78KOR_Voice Debug Build amp gt BI xl EOF Project group Project 4 E For Help press F1 feed fea The workspace file SAMPLE KG3 prw contains one project called SAMPLE You will use this project SAMPLE CAUTION Please ignore when you get a prompt saying could not be found This may occurred when the installation directory is not a default 34 TK 78KOR KG3 User 5 Manual 2 4 Set Linker Options The linker options have been set by the project file However some option settings will be covered in this section because the linker option settings are important for debugging Following three settings are covered specifically Outputs from debugging On chip debug Desable Enable security ID Watchdog timer Select Tools on menu bar then Linker options 2 4 1 Output Tab Select Outputl tab on Linker Options window and see following settings Linker Options X Output Library Others Load Module File a Output File M ame Em Browse Output Symbol Informatian put Sy g Create Error List File e Output File Hame Browse 7 0
4. Output Directive File Image kd Output Public Symbol List kp Output Local Symbol List kI Farm Feed at End of List File If Lines per 0 Select mirror area User Option Bytes ab 0 mil DOFFFF H C MAA 1 Emil p Command Line Options goe5h 3FC00h 1 024 adFFFFFFFFFFFFFFFFFFFFh pa map gb00FFFFR lib belbrm lib bel rmf lib SPregram Files Electronics Tools s Cancel Apply Help User Option Byte Check User Option Byte and then enter OOFFFF Here you can do the setting of watchdog timer low voltage detector and system reserved memory area The 3 bytes you entered are stored at COH C2H on flash memory COH setting for watchdog timer setting for low voltage detector setting for system reserved memory area must be set as FFH This time you disabled the watchdog timer and the default start function of low voltage detector For details refer to the user s manual 78KOR KG3 U17847E 37 TK 78KOR KG3 User 5 Manual 2 5 Set Compiler Options The compiler options have been set by project file However because some compiler options are useful following two settings are covered specifically in this section Enable C comments Use multiplier and divider Select Tools on menu bar then Compiler options
5. v Security ID qi v Or Chip Debug Option Bytes 3a Control Value 85 H ID FFFFFFFFFFFFFFFFFFFF Start Address H 1 024 bytes Allow 64K bytes Size Command Line Options 0985 1024 adFFFFFFFFFFFFFFFFFFFFh pa map gb00FFFFR lib belbrm lib bel rmf lib C Program Files HEL Electronics Tool t CC fo OR Sw 2 3 Cancel Apply Help 35 TK 78KOR KG3 User 5 Manual Load Module File settings Check Output Symbol Information This enables to do source level debugging setting break points monitoring variables in watch window etc Also you can specify the load module file name On Chip Debug Option Byte Check On Chip Debug Option Byte Enter 85 in Control value This setting enables the on chip debugging function of the microcontroller For details of Control value refer to the user s manual of 78KOR KG3 0178476 See Start address is set to 00 and Size is set to 1024 These settings reserve the memory address area for the monitor program the flash memory area that the debugger uses for on chip debugging In this case the Control value is allocated to the address of C3H in flash memory is set to the next address Because of this the following areas could not be set the segm
6. 12 TK 78KOR KG3 User 5 Manual 5 Read software license agreement and click for continuing the installation To stop the installation click Software License Agreement Please read the following license agreement Scroll down to see the rest of the agreement USER LICENSE AGREEMENT IMPORTANT READ CAREFULLY This User License Agreement is legal agreement between you either a natural person an entity and Electronics Corporation NEC for the SOFTWARE PRODUCT As used herein SOFTWARE PRODUCT means the NEC s computer software products provided with this ULA which includes computer software and may include associated media printed materials and online files or data By installing and using the SOFTWARE you agree to be bound by the terms of this ULA IF do nat agree to the terms of this ULA nat install or use the SOFTWARE PRODUCT you accept all the terms of the preceding License Agreement install this product you must click to accept If choose Setup will exit lt Back Enter the product ID and click product ID is available on the other sheet X InstallShield Wizard Please enter the product ID of the product 4 Enter Product ID Product ID ig written an the case ar in the accompanying documents Product InstallShield
7. Files Memo B 78K R Voice 1 Project s 5 8 78 Voice 1 Source Files g Include Files H Project Related Files Other Files Build process is executed For Help press F1 1 h PM SAMPLE_KG3 prw OutPut loj x File Edit Find Layer View Project Build Tool Window Help 26 t amp B Whee e Files Memo C Program Files NEC Electronics Tools CC78KOR U1 20 bin Compilation complete 0 error s and 0 warning s for i fig SAMPLE_KG3 1 Project s C Program Files NEC Electronics Tools CC78KOR W1 20 bin c H 3 SAMPLE KG3 Compilation complete 0 error s and 0 warning s foi H E Source Files C Program Files NEC Electronics Tools CC78KOR W1 20 bin c a Include Files Compilation complete 0 erroris and 0 warning s c Project Related Files C Program Files NEC Electronics Tools CC78KOR W1 20 bin c Other Files PM error s 0 warning s ronics Tools RA7S8KOR W1 10 bin and 0 warning s found ronics Tools RA78KOR W1 10 bin c 0 error s and 0 warn 13500 Build completed normally Lx otal warning s 0 EOF Build has been completed successfully 40 TK 78KOR KG3 User 5 Manual 41 TK 78KOR KG3 User 5 Manual 2 7 Check Debugger Settings After the build you should configure the debugger settings The debugger settings have been
8. J AH XXR Insert File Save As Ghange Source File Save A Source Files Print Preview Print Ctrl P Recent File Recent Workspace Exit New WorkSpace dialog opens Create a new workspace 2 lt Description of items gt Workspace File Name New WorkSpace Step 1 9 Workspace Information gt Specify the of the workspace file that manages woke Fis Nate th pro j ect fil es gt gt 1 Workspace Information 2 Select Tools is automatically suffixed as the file type TN 3 Select Real Time 05 A project file prj of the same name is Browse didus Project Group Name simultaneously created Clin Directive Fiel Microcontrollers Name Device Name Folder 78K0R o 42 v 42 64 8 Select Debugger 3 Confirmation Device Install gt Specify the folder for saving the workspace file by evioe Install Meco 4 writing its absolute path This item can be selected from a reference dialog box by pressing the button Project Group Name This will set up the basic information about the workspace and the project gt Specify this item if wishing to manage multiple TN projects together in function units If nothing is specified this item is the same as the workspace file
9. 2 5 1 Extend Tab Select Extend tab and check Enable C Comment This setting allow you to use the C comment using It is useful feature when developing code Compiler Options E X Preprocessor Menor Model Data Assign Optimize Debug Output Extend Others Startup Routine Change Source Regulation Disable Extensions ANSI Standard Only za A Enable C Comment Ignore from Till End of Line zp Comment Can Mest zc Code of Source S5JIS zs Not Expand Argument and Return V alue zb ELC ze C Mone zn Command Line Options Cancel Apply Help 38 TK 78KOR KG3 User s Manual 2 5 2 Startup Routine Tab Select Startup Routine tab and check Using Library and Using Multiplier The 78KOR KG3 has feature of multiplier to increase those calculation speed 39 TK 78KOR KG3 User 5 Manual 2 6 Create Load Module Files After developing the source code you have to create load module files by compiling assembling and linking This process 15 called build Click the build button or select Build on menu bar then Build n 78KOR_ oice prw OutPut File Edit Find Layer View Project Build Tool Window Help S MAC ADDR PeKoR_Voice 78KOR_Voice Debug Build 6
10. Incorrect ID Code Ff603 62 4 2 3 The on chip debug function had been disabled in the device F0c79 62 4 2 4 Disabling the on chip debug function is prohibited 0 33 62 CHAP TER OS OTHER INFORMA TION RUE EATER Fa 63 ___ ____ 64 9 2 SOURCE ceo 69 Jo Debusger Re LE E D Sen MOTE 71 5 3 1 Change display of 5 2 0 71 5 23 2 Display source list arid function listes 71 5 3 3 Set delete breakpoints eerte 12 5 3 4 Display global variables ierit tnter ettet 73 5 3 5 Display global variables while programs 74 9 2 0 IDIsplaydocal Vakllablesu seca D 75 5 3 1 Display memory and SFR contents esent nennen treni 75 5 3 8 Erase microcontroller built in flash memory ene 76 SAONA T ELA ELA XL AE LIE LI E I E Et 78 TK 78KOR KG3 User s Manual TK 78KOR KG3 is the evaluation kit for d
11. LED brink INTP mask RTC int mask RTCI int clr RTCI int 31 25ms unmask INTP1 int F clr INTP1 unmask g_start 154 start amp spining INTP1 mask RTCI int 31 25ms mask TM int TM unmask slowly amp stop When programs running the status bar will be red 48 TK 78KOR KG3 User s Manual If you push SW1 the 7 seg LED segments rotates You push the SW2 and confirm the display of number after a while U1 U2 7segLED SWI 0 SS i mle ola ER ORT USB 2 2 MADE ope 05 TK 78KOR K63 RESET 5EI 244A 2 2 Y NW ET E ge J o L 7 ka 871 2 gt 4 RoHS WTA A COMPLIANT O 2O000 0 0 2 000000000000009 Y You could confirm the sample program is working 49 7 O O O 4 TK 78KOR KG3 User s Manual 2 11 Stop Programs Now you are going to stop the program Click the stop button or select on menu bar then Stop 2 ID78KO0R QB SAMPLE KG3 prj Edit View Option Run Event Browse Jump Window Help 21 aea 243 mj Source main c Search _ Watch Quick Refresh Close Count down start value TMMKGG TMB mask PIF
12. TK 78KOR KG3 User 5 Manual 5 3 5 Display global variables while programs are running Global variable could be referred even when the programs are running Select Option menu gt Extended Option Follow below settings Use MINIGUBE Extended Function RAM Monitor Break When Readout f RRM Setting Redraw Interval 500 Right click the variable in watch window while programs are running then select RRM Setting Adi Delete up SU break when Access to this Variable Break when this Variable Break when Read From this Variable Clear RRM Setting RRM Setting dialog opens Click button to complete the setting then button to close the dialog RRM Setting Address oy mbal Cel 1 Bytes 2 Bytes Restore d Bytes Clear 4 Bytes Delete 2 Bytes Jump Bytes He Bytes 2 Bytes Size Total 1 16 Bytes This completes the settings CAUTION The maximum size of variable area is as total of 16byte when programs are running The maximum number of variable area is 8 locations The user program momentarily breaks upon a read 74 TK 78KOR KG3 User 5 Manual 5 3 6 Display local variables Local variable window is used to display local variables By clicking the button below you can open the local variable window Unlike g
13. mw 7 Goto 1 3 3 Completion of USB Driver Installation 22 TK 78KOR KG3 User 5 Manual 1 3 3 Completion of USB Driver Installation Confirm the USB driver is installed on PC Start Device Manager and find NEC Electronics Starter Kit Virtual UART without mark under the Ports COM amp LPT Device Manager L Computer Management Action View Window Help mm a Computer Disk drives Display adapters 2 DYD CD ROM drives ta Human Interface Devices ic ATA ATAPI controllers cw Keyboards Mice and other pointing devices Find NEC Electronics Starter Kit 3 Monitors Virtual UART COMx Network adapters Ports amp LPT Pork COMI Computer Local ih System Tools Event viewer iJ Shared Folders Performance Logs and Alerts ri Device Manager Storage Removable Storage Disk Defragmenter Disk Management as Services and Applications eee Je ee doe E IIS IA Sound video and game controllers M System devices Universal Serial Bus controllers The screen above shows that the COM port number is 8 If ID78KOR QB is not in use you use this port number for connecting TK 78KOR KG3 When you change the USB port connection the COM port number will be changed as well
14. 54 TK 78KOR KG3 User 5 Manual 3 3 Hardware Functions 3 3 1 SW1 SW1 is the push switch connected to P120 INTPO EXLVTI in CPU When the switch is pushed down it sends the signal of Low When it is released it becomes Open Therefore when you need to use this you need to set the microcontroller built in pull up resistor option registers PU12 to ON For details about settings of microcontroller built in pull up resistor option registers refer to 78BKOR KG3 User s Manual U17894E 3 3 2 SW2 SW2 is the push switch connected to P46 INTP1 TI05 TOO5 pin in microcontroller When the switch is pushed down it sends the signal of Low When it is released it becomes Open Therefore when you need to use this you need to set the microcontroller built in pull up resistor option registers PU4 to ON For details about settings of microcontroller built in pull up resistor option registers refer to 78KOR KG3 User s Manual U17894E 3 3 3 SW3 The bit 1 5 SW3 are for mode settings and bit 6 8 switches connected to P50 P52 pins microcontroller Q For the use of ID78KOR QB use following settings SW3 Bt2 LON 04 0 1 The microcontroller stays being reset until ID78KOR GB is started OFF The microcontroller runs the programs stored in the flash memory as soon as it gets power supply 55 TK 78KOR KG3 User 5 Manual To run programs stored
15. 8 INTPB int 8 INTP unmask RTCIF RTC int RTC int unmask LED brink INTP mask 1 RTC int mask RICIIF 8 Ll int F 8 RTCI int 31 25ms unmask PIF1 8 int F 0 INTP1 unmask vhile amp gy start 154 start amp spining Stop the program while lt gy start 2 gt lt if led s gt 32 1 2 ID78KOR QB SAMPLE_KG3 prj File Edit View Option Run Event Browse Jump Window Help ir m er 246 Source main c initial 10 while 12 Count down start value TM mask INTPB int INTP unmask RTC int F clr RTC int unmask INTP mask RTC int mask RTCI int clr RTCI int 31 25ms unmask int F clr INTP1 unmask 054 start amp spining INTP1 mask int 31 25ms mask TM int clr TM unmask while lt gy start 2 gt lt slowly amp stop if lt gy led s gt 32 36 main 00439 2h 31m 23 06 Manual Break When the program stops the status bar changes back to the original color 50 TK 78KOR KG3 User 5 Manual 2 12 Close Debugger ID78KOR QB Select File on menu bar then Exit 29 ID78KOR QB SAMPLE_KG3 prj x File Edit view Option
16. lt Back Next gt Cancel 7 It starts copying the files 13 TK 78KOR KG3 User 5 Manual Click when Select Files installation wizard dialog opened 44444 9 When the installation is completed the following dialog opens Click NEC Electronics Starter Virtual UART USB driver must be installed on PC before you connect to TK 78KOR KG3 Install the USB driver by referring 1 3 Installation of USB Driver 14 TK 78KOR KG3 User s Manual Notes on the installation authority To install this tool in Windows 2000 or XP the authority of an administrator is necessary Therefore please login as an administrator Notes on install directory Please do not use 2 byte characters such as umlaut in the directory name where the product is to be installed Note on the version of Windows If the language of the Windows is not English a file transfer error during installation might be observed In this case please abort the installation in the language and re install it in an English version of Windows The identical problem may be observed if a language other than English is specified as the system language in the Regional Settings Properties tab Assembler RA78KOR and C compiler CC78KOR limit the object size to 64 Kbyte 15 TK 78KOR KG3 User 5 Manual 1 3 Installation of USB Driver NEC Electronics Starter Kit Virtual UART USB d
17. 2 ID78KOR QB SAMPLE KG3 prj File View Option Run Event Browse Jump Window Help Search Beal Watch Quick Refresh Close Suurce main c EI while 1 gt g_start 8 g_led_s 8 Count down start value 1 TM mask 5 INTP int 3 INTP unmas RTC int F RTC int philos yg start B gt lt 77 LED brink Run the sample program 1 INTP RICMK 1 RTC RICIIF 8 7 RICI i RICIMK RTCI i PIF1 8 8 INTP1 un while g_start 1 54 start amp spining 1 mask 1 RICI int 31 25ms mask 8 TMB int TMMKOB TM unmask while lt g start gt lt slowly 8 stop if Sten eS H PA TMB mask 22 main 00008 Ous 2 i ID78KOR QB SAMPLE_KG3 prj File Edit View Option Run Event Browse Jump Window Help 1 gt 244 Source main c Search RG gt gt Watch Quick Refresh gt 1 lt 5 while 1 gt g_start Count down start value TM mask INTP int clr INTP unmask RTC int F clr RTC int unmask nates g_start B gt lt
18. 558 Sxa S8d 389 gg LH INV ESId gt 55 S Ld 22 1 64 26 ved 28 sg ZS Fe ES 289 ES 1X3 440 1 ANZL WVY d IZ 08d 92d 991148 dn 1nowo sod 202 gsn 140 5 29 49 9 61 504 anto ASZ JhL v LIYM 90d St bed 15 1 OWM 91XS 0Ld 95 Od 3B 9 m Ezd 25 1 ZINY ZZd E 074 501 4 i NROW LON INNON LON OINV 0Zd i 19 vL d INNON LON 29 0fld t dade T 0 Ld 900L 901L L Ld GdLNI SHM LOX3 84d d 99 L109S 01432S v0d OLdLNI 9UM 22X3 94d zl d 99 v9 on 12 5 TE d LOXL OLOS Z0d 81Sv 9d d 20d 22 0001109 LHM 99d 8 299 X7HWOc SUSO 104 4 001 004 0HM S9d 99d 00d te LOOLILOLL S Ld 5 999 Sid 4 2aXL 0zOS rr Ld PdLNI EOOL EOIL LEd 799 vv Ld 94 3 Led Evid m zios 0eMOS evld v 2 294 9d 2 5 2 E 0v 5 194 298 id 8 S F p 0198 09 2 INnON LON Old 08 5 8 094 39159 dp3 05525 SisapesesS 99 so 20 gNLOE v1 PS S IRIS eS EIS Ee SI
19. TK 78KOR KG3 User 5 Manual 4 2 1 not communicate with Emulator 0100 0109 Check Point 1 If you use USB hub do not use it USB hub is not supported Check Point 2 Check if the settings of switches on the kit are correct with referring 2 8 Check Board Settings Check Point 3 Confirm the USB driver installation with referring to 1 3 3 Completion of USB Driver Installation Check Point 4 If above 3 check points are confirmed close the debugger and disconnect the USB cable from PC Re connect USB cable properly to both the PC and the kit and then re start the debugger 61 TK 78KOR KG3 User 5 Manual 4 2 2 Incorrect ID Code Ff603 This error occurs when the security ID stored on microcontroller built in flash memory is different from the ID code you entered at the start of debugger Security ID entry area at the start of debugger ID Cade Check Point 1 Enter correct security ID and click OK on the configuration window Check Point 2 If you forgot the security ID you have to erase the microcontroller built in flash memory Before erasing check if you actually set the security ID with referring to 2 4 Set Linker Options Also remember the code you set for the security ID After this erase the flash memory with referring to 6 3 8 Erase microcontroller built in flash memory 4 2 3 The on chip debug function had been disabled in the device F0c79 This error occurs when th
20. Manual 5 4 Circuit diagram From following page it shows the circuit diagram of the demonstration kit 78 TK 78KOR KG3 User 5 Manual 9000 40 AON 816 SION 691 COT d3MOd A INNOW LON 139 82 ML INNOW LON 2x s LdaWv2 044 219 LJ3HAV AS2 JhL n LJ3HAV LJ3HAV ose 0 4 LNNOW LON 9 029 10 02700 3 NZL 2 0d3HAV 0d3HAV cu vv 70 0 9 14 a als Of POC Ni Ny Op gt 09 5 5 6 BESS SSS F9 8 LCUUDCUTUUUUUUUUUUUUUUU 2 Sr ae Seer 5 O 222 mzemmmmmmmmmmmmmmmmm i gt B 8 2S53u3992o020v o 7 i m dol SSAV 98 559033333 en n SHNv ZSLd ZHLOLY EdLNI OEd E Oum i CN pc 8 9599034 eae lar OV 089 2 90 ON d a TX zoo 9X3 98d 55 9314
21. Run Event Browse Jump Window Help Open m zc T m alaale Eal Close 0 Download ich Quick Refresh Load Module Gun A Upload 1 lt 2 Project r fhile 19 Environment gt g_start Debugger Reset g_led_s TDROO 8x8820 gt Count down start value TMMK8B 1 TM mask 8 int INTPB unmask RTC int F clr RICMK A int unmask gt 1 INTP mask 1 7 RTC int mask RICIIF int 8 int 31 25ms unmask PIFi int INTP1 unmask Bl start amp spining INIP EE 7 E The exit confirmation dialog is displayed while lt 4 start 2 2 if lt g_led_s gt 32 1 main c 36 main 00439 2h 31m 23 05 Manual Break A ID F8EOR 0O6 x This will end your Debugger session Do you want to save the settings in the project File 7 Y Cancel If you click it saves the settings in the project file and then closes the ID 8KOR QB It is recommended to save the settings as it saves the window you used window size layout etc If you click it does not save the settings and closes the ID 8KOR QB 51 TK 78KOR KG3 User 5 Manual 2 13 Quit PM Select File on menu bar the
22. aa asn 4 z Nomo N magaxy dieo L L VOOA 899A 94 0640384 endi 8NdL 5 INNOW LON 2091 SSA3 aa asn INNOW LON 0L 9r 0SOL 0OSIL Z Ld OSIL 9 OlOSld INNOW LON C OLMOS OLd Gl GOO Ed LNI ZEd 8 501 18 9 HIN Ol 9 aa asn Vd aa asn X90S2LOLOATPZNS anyo E 89 ondasn a wasn 001 5 gg YMS MS 19534 gt Mb aoa MS 410 esodundi3 nW 29 094 NO 477118 440 2 2318 340 9 119 2318 90 MS OdlNI E SL ZY E 37127 0 ISS dW vosxn 2 1861 GLO SO0SZDd AS2 JhL v 4nzv0 7 FH v0320 IX LZLd Eum L A passos bise 13538 niasau B INTKX OdLNI OZL d OdLNI HN YOL 0001L 00d 584 dante OOOL OLOLL LOd x INNON LON Ld LNI OEd GN EET 80
23. in built in flash memory without using 78 use following settings and re supply power SW3 Bit2 ___ ____ OFF Bit 4 OFF ON 2 OFF ON 2 ON Serial connection can be made with using UART3 P13 TXD3 P14 RXD3 on microcontroller The bit 6 8 are connected to P50 P57 pins in microcontroller ON means Low and OFF means Open When you need to use this you need to set the microcontroller built in pull up resistor option registers PU5 to ON For details about settings of microcontroller built in pull up resistor option registers refer to 78KOR KG3 User s Manual U17894E SW3 3 3 4 SW4 RESET SW This is the reset switch You can reset the microcontroller by pressing this switch 3 3 5 LED1 POWER This is the POWER LED It is lighted when it gets power supply 3 3 6 JP 1 JP1 is the jumper switch pin to select power supply JP1 Use power supply from USB power connected to USB1 Use power supply from other expect USB 56 TK 78KOR KG3 User 5 Manual 3 3 7 01 02 7seg LED U1 02 are general purpose 7SegLED LED is lighted when each port outputs Low 7SegLED segment connection U1 ae U2 right P65 5 64 P84 P82 9 3 9 7 m A The figure of 0 9 can be displayed by writing the following values in P6 or P8 register Example of displayed figure and set data 3 4 Universal Area The kit has the universal area Users
24. name Microcontroller Name gt Specify the name of the microcontroller to be used Device Name The concrete information set here 15 gt Specify the name of the device to be used described on the following pages 64 TK 78KOR KG3 User 5 Manual New WorkSpace Step 1 9 Workspace Information 4 x Workspace File Name as follows mat gt gt 1 Workspace Information 2 Select Tools Create Blank Workspace 3 Select RealTime 05 Input the workspace information setting Workspace file name Folder 4 Startup 8 E t test Browse 5 Register Project Group Name E Link Directive 8 Folder Microcontrollers Name Device QCXtest 78 NN uPD78F1166 A0 7 8 Select Debugger 3 Confirmation Device Install 8 850 Microcontrollers Project Group Name Only 4 6 no input Microcontroller Name This will set up the basic information about the workspace and the project 78 Device Name 78 1166 Cancel Help Click button PM 02011 D test This Falder cannot found you wish to create Click button New WorkSpace Step 2 9 Select Tools Tool Set 1 Workspace Information gt gt 2 Select Tools Series Software Package V1 00 English veria Select Real Ti
25. set by the project file as well However because those settings are important for debugging some settings are covered in this section Select Tools on menu bar then Debugger ig SAMPLE KG3 prw DutPut 6 x File Edit Find Layer View Project Build Tool Window Help n Semple eens Jj e Assembler Options SaMPLE_KG3 SAMPLE_KG3 Linker Option m Object Converter Options ject Window List Option Fies TENUES Electronics ToolsiCC7BEDRVWI Z0Vbinsc ete erroris and 0 warningis SAMPLE 1 Project s Register Extent RSANEC Electronics Tools CC78KOR W1 20 bin Start up Ex tool gt error s and warning s H E Source Files ksi Electronics Tools CC7SKOR W1 Z0 binic E Include Files File Compare nlete error s and warningi s H E Project Related Files Device File Installer RSANEC Electronics Tools CC78KOR W1 20 bin 1 Other Files PM Settings alerte error s and 0 warningis B 5 Electronics ToolsiBATSEORAWI 10Nbin E Ee erroris and 0 warning s found Electronics Tools RATSEOR WU1 10 bin c Record the Key Operations Complete error s and O warn Play Back Saye the Key Operations or 21 Total O EOF Lo
26. the device driver fram list Windows does on m the driver you choose will be the best match for your hardware Click Next 4 If the following dialog is opened click Hardware Installation The software are installing for this hardware Electronics Starter Kit Virtual UART has not passed Windows Logo testing to verify its compatibility with Windows Tell me why this testing is important Continuing your installation of this software may impair or destabilize the correct operation o zuztem either immediately ar in the future 1 Click Continue Anyway recommends that you stop this inst contact the hardware vendor for so passed Windows Logo testing Continue Anyway STOP Installation 18 TK 78KOR KG3 User 5 Manual 6 installation of NEC Electronics Starter Kit Virtual UART driver is completed Click Found New Hardware Wizard Completing the Found New Hardware Wizard The wizard has finished installing the software Far E MEL Electronics Starter Kt Click Finish Click Finish ta close the wizard 7 Goto 1 3 3 Completion of USB Driver Installation 19 TK 78KOR KG3 User 5 Manual 1 3 2 Installation on Windows 2000 1 2 Once the TK 78KOR KG3 is connected with USB the Found New Hardware Wizard will be started Select No not this time and click Found New Hardwar
27. CAUTION not do Hardware Modification Scan when you communicate with the target device 23 TK 78KOR KG3 User 5 Manual 1 4 Sample Programs This section explains the overview and preparation of sample programs 1 4 1 Preparation of Sample Programs 1 Insert the CD ROM disk in the CD ROM drive of your PC The NEC Electronics Microprocessor Development Tools Setup screen automatically appears if this screen does not appear automatically start setup exe from Explorer etc Electronics Microcomputer Development Too s St tu Welcome to the NEC Electronics Microcomputer development tools setup program Before vau execute this installer please exit all windows programs Install Documents Sample Frogram 2 Press the Sample Program button to start the WWW browser 24 TK 78KOR KG3 User 5 Manual E Sample Programs Microsoft Internet Explorer File Edit View Favorites Tools Help 4m Back mp fat 5 Favorites Media x Eh E Address EADOCISAMPLE E HTML Links gt Sample Programs Welcome to T SEUE K GS world The purpose of sample programs 15 to 8 53 Sample programs consist of the following ttems e TE GEOR SAMPLE Ets3 SAMPLE Sample program described in the T 78K EJ K G3 evaluation kit tutorial guide Click the lnk of TE 7SEQR E 33 sample progra
28. Development Environment IDE PM V6 30 The IDE works on Windows operation system Users can develop a system efficiently by using the editor with idea processor function compiler and debugger C Compiler CC78KOR W1 20 code size limited version C compiler for the 78KOR microcontrollers The object code size is limited to 64 Kbyte This compiles C code for 78KOR and ANSI C code program into assembler code This produces object code and linker Assembler RA78KOR W1 10 code size limited version Assembler for the 78KOR microcontrollers The object code size is limited to 64 Kbyte This convert the assembler code for 78KOR into object program The object program will be used for debugger 78KOR Integrated Debugger ID78KOR QB V3 40 This is the tool for debugging the object program generated by C compiler and assembler The debugger enables to do C source level debugging With the debugger you can debug the code easily and efficiently by refering and changing variables using step in debuging function and 50 on Starter Kit USB Driver USB driver for the USB connection with TK 78KOR KG3 and Sample program Demonstration program using the 7 and push switch TK 78KOR KG3 User 5 Manual 1 2 Installation of Development Tools 1 2 1 Installation Package The attached CD ROM includes the development tools and documentations Users can use the installer to install those development tools and doc
29. FFFFFFFFF F x 20 in ID code on the configuration window of the debugger Cade If you start the debugger with using PM debug button the below error dialog may displayed because the debugger remember the ID Code from previous use In this case click to close the dialog open the configuration dialog to enter FFFFFFFFFFFFFFFFFFFF F x 20 in ID code and then re start the debugger again ID78K R QB X A Incorrect ID Code 76 TK 78KOR KG3 User s Manual When you could confirm the debugger is working open exkOr32ocfg exe again This time select KEEP flash memory at debugger start up then click Setting Because there is a limit of erasing times for flash memory it is recommended to try not to erase flash memory many times b After the debugger is started and programs are downloaded the security ID on microcontroller changes to the code that you set at 2 4 Set Linker Options On the other hand the debugger stores the security ID FFFFFFFFFFFFFFFFFFFF F x 20 Therefore when you close and start the debugger again you may get below error ID78K R QB X A FF603 Incorrect ID Code In this case click to close the dialog then enter the code you entered at 2 4 Set Linker Options to ID Code on the configuration dialog For other information refer to the user s manual ID78KOR QB Integrated Debugger Operation 71 TK 78KOR KG3 User 5
30. FFFFFFFFFFFF x 20 in ID Code then click OK 1 large Connect Hot Connect Click when the confirmation dialog for downloading load module file is opened ID78KOR OB EE xj TK 78KOR KG3 User 5 Manual Download ID78KOR GB starts and downloading the program to flash memory CATRZBK PASAMPLE KG3ya Imf object loading Cancel When the download is completed the source code will be displayed 4 ID78KOR QB SAMPLE_KG3 prj x File Edit view Option Run Event Browse Jump Window Help ir m m t 1 Source main c Search lt lt gt gt Watch Quick Refresh Close ____ 21 EIQ while lt 1 g_start g_led_s 8 TDRB8B 8x8820 Count doun 1 PIF 8 PMK 8 RICIF g_start B gt lt PMKi 8 ad 4 start 154 main c 22 00008 Completion of the download does not mean running the programs Therefore even though you press switch on the board it does not make anything happened To run the sample program demonstration see 2 10 Run Programs 47 TK 78KOR KG3 User 5 Manual 2 10 Run Programs Now you are ready to run the program Click the restart button gt or select Run on menu bar then Restart The sample program runs
31. Optional search locations Floppy disk drives CD ROM drives Specify a location Microsoft Windows Update Cancel 4 Select the driver directory path The path should be C Program Files NEC Electronics ToolsYTK driver as default installation If the installation directory is not default then select under the installation directory Click Found Mew Hardware Wizard Insert the manufacturer s installation disk into the drive selected and then click Cancel Select the driver directory Click manufacturer s files from JC Prograrn NEC Electronics Taalz TK drreer 21 TK 78KOR KG3 User 5 Manual 5 Click Driver Files Search Results The wizard has finished searching Far driver files for your hardware device The wizard found driver for the following device y USB Device Windows found a driver for this device To install the driver Windows found click Next files nec electronics taols tk drreersmabzsall inf Click Next lt Back Ce Cancel 6 The installation of NEC Electronics Starter Kit Virtual UART driver is completed Found New Hardware Wizard Completing the Found New Hardware Wizard lt gt MEL Electronics Starter Kit Virtual LAAT Windows has finished installing the software for this device Click Finish To close this wizard click Finish
32. S 2 5 261 8 anyo anro Od1NI LAA B FES S S S s S S sa a 29 18d NINIS ES SES RES Phu 98d 9 INAOW LON INNOW LON o E dg z ete 2 age Z V Q0 H 4IH VSQvS 2 VQ09 H 4IH Pe 9 899 Bigg ET 18452 LMS ASIE 0847 084 9919 9919 254 88Noxs 2919 054 0514 19 98d a 2919 224 E Ji 9d 9 3o 0d bed 5 zd lt Ged 92 24 jus Ord Led Lid gNLOE v1 289 261 8 Led oawi4 0219 DEIN re AA eee vr 92 94 209 999 Zld NAAN TE Sd 94 290 o 990 193 224 594 Gd 3 sg qi LH m dui 20452 Old Eld 19538 1 its OL 194 thd Gld ana 09d osa 094 28 00d 229 LJ3HAV 043HAV 79 TK 78KOR KG3 User 5 Manual 9000 40 AON 39 JequinN LOZONTIVZNS 4 899A 220
33. Users Manual TK 78KOR KG3 Date published June 2008 Rev 1 1 TESSERA TECHNOLOGY INC 2007 2008 Printed in Japan TK 78KOR KG3 User 5 Manual Windows and Windows XP are registered trademarks or trademarks of Microsoft Corporation in the United States and or other countries information in this document is current as of February 2007 The information is subject to change without notice For actual design in refer to the latest publications of the product data sheets No part of this document may be copied or reproduced in any form or by any means without prior written consent of NEC Electronics NEC Electronics assumes no responsibility for any errors that may appear in this document 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 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 resp
34. ad the Macra File Play Back the Macro File Register the Macro Files Play Back the Register Macra 4 k x Change debugger settings fra 42 TK 78KOR KG3 User s Manual Check if ID78KOR QB V3 40 78KOR Integrated Debugger is selected on Debugger Debugger Settings L STEZSK RSSAMPLE Execute 5 Pio reset ater Downoad Wownload the Debug Target Files the same Project Group Debug Target File List 43 TK 78KOR KG3 User 5 Manual 2 8 Check Board Settings Before connecting the PC and the TK 78KOR KG3 with USB you should check the setting of SW3 and JP1 on the board Set the SW3 and JP1 of the TK 78KOR KG3 as follows MADE IN JAPAN usa 2 6 00 e Fuso eZ gt TK TBKOR KG3 J E s OM 4 2 x M 2 1 o et EE pim f E CT ot 1 3 LI s JPE 4 55 pnm 3 ye fe COMPLIANT le 0 010101010 SW3 After the switch settings are completed connect the PC to USB1 TK 78KOR KG3 with USB cable If the Found New Hardware Wizard is started install USB driver with referring 1 3 Installation of USB Driver 44 TK 78KOR KG3 User 5 Manual 2 9 Start Debu
35. can use this to develop custom circuit 57 TK 78KOR KG3 User 5 Manual 3 5 Solder short pad label With using the solder short pad to cut the circuit users can customize the circuit The solder short pad looks like the picture below To open use cutter to cut the dent part To short put solder on the pad Solder short pad Solder short pad Open Short Before Solder short pad name Connection Shipment 7 seg LED 1 5k ohm resister 60 67 Short You can use port6 for multipurpose I O 7 seg LED 1 5k ohm resister P80 P8 7 Short You can use port8 for multipurpose I O VDD AVREFO AVREF1 AVREFO AVREF1 Short You can Supply different voltage than VDD VDD EVDDO EVDD1 EVDD1 Short You can Supply different voltage than VDD DCVDD1 DCVD D2 O Short EERE JI is connected to VDD CN3 J1 is separated from VDD Note All ground signal are each connected Attention If you supply VDD 5V from or J1 disconnect jumper pin 58 TK 78KOR KG3 User 5 Manual 3 6 Operation by external power supply The power supply of the AC adaptor connected with CN3 is connected only with the power supply terminal of the connector of the board in the surrounding 10 12 and 16pin of CN1 However not to tie to USB this board and to operate with the unit the AC adaptor can be made a power supply by the connection of the AC adaptor of 5V to CN3 a
36. cations Explain the hardware of TK 78KOR KG3 Troubleshooting Describe how to solve troubles you may face such as errors when starting the integrated debugger ID78KOR QB Other Information Introduce other information such as how to create a new workspace project on integrated development environment PM how to register additional source file and some useful tips of the integrated debugger The circuit diagrams of demonstration kit are included in this chapter This manual is intended for development engineers who wish to become familiar with the development tools for the 78KOR It is assumed that the readers have been familiar with basics of microcontrollers C and Assembler languages and the Windows operating system This manual is intended to give users an understanding of the features hardware configurations development tools for the 78KOR TK 78KOR KG3 User 5 Manual This chapter describes following topics Overview and installation of development tools Installation of development tools Overview and preparation of sample programs Users can experience the development flow such as coding build debugging and test by using the development tools bundled with TK 78KOR KG3 TK 78KOR KG3 User 5 Manual 1 1 Development Tools Software Device file DF781188 V3 00 A device file contains device specific information So users need a device file to use the development tools Integrated
37. ct group What is a workspace workspace is the unit used to manage all the projects and project group required for one application system A workspace file contains one or more project files The file name format is xxxxx prw 32 TK 78KOR KG3 User 5 Manual 2 3 Load Workspace project In this section you will use the workspace that you created in 1 4 Sample Programs For creating a new workspace refer to Chapter 5 Other Information The workspace has information about the build environment for the sample programs Select File on menu bar and Open Workspace Then select SAMPLE KG3 prw under the directory XTK78KORXSAMPLE File Edit Find Layer Project Build Tool Window Help New h Mac ADDR v Open Ctrl O pe MAL AODA 9 1 Insert i di x d Close Glose Workspace Save 5 Save Ghange Source File Mame Save All Source Files Print Preview Print Ctrl P Recent File Recent Workspace Exit Open an existing workspace E 2 Open Workspace Look in SAMPLE KG3 amp t Filename SAMPLE Files of type Workspace Filej pre L ancel Help Select SAMPLE KG3 prw then click 2 33 TK 78KOR KG3 User 5 Manual Workspace name SAMPLE KG3 prw
38. e Wizard Welcome to the Found New Hardware Wizard This wizard helps you install a device driver Far 4 hardware device Click Next To continue click Next lt Back Cancel Select Search for a suitable driver for my device Click Install Hardware Device Drivers device driver i software program that enables hardware device to work with an operating system This wizard will complete the installation for this device 2 USB Device device driver is software needs driver files for your nev device installation click Nest Select Search for a suitable driver for my Click Next Cancel What want to do Search for a suitable driver for my device recommended Display a list of the known drivers for this device so that can chod driver 20 TK 78KOR KG3 User 5 Manual 3 Select Specify a location Click Found New Hardware Wizard Locate Driver Files Where you want Windows to search for driver files Search for driver files Far the following hardware device y USB Device for suitable drivers its driver database on your computer and in optional search locations that you specify Select Specify a location lick M ext IF vau are searching an floppy disk or drive before clicking Click Next
39. e value at address C3H On chip debug option byte in microcontroller built in flash memory is incorrect You need to erase the flash memory Check Point 1 Check if you actually set the correct on chip debug option byte with referring to 2 4 Set Linker Options If it is not correct then set correctly Check Point 2 Erase the flash memory with referring to 5 3 8 Erase microcontroller built in flash memory 4 2 4 Disabling the on chip debug function is prohibited F0c33 Basically this error occurs when you start download the debugger without doing the settings described at 2 4 Set Linker Options Do the same checking processes as 4 2 3 The on chip debug function had been disabled in the device 0 79 62 TK 78KOR KG3 User 5 Manual This chapter explains some useful operation techniques of development tools and circuit diagram of the kit for developing of user programs 6 1 Create a new workspace project 6 2 Register additional source file 6 3 Debugger tips 6 4 Circuit diagram 63 TK 78KOR KG3 User 5 Manual 5 1 Create a new workspace Now create a new workspace and project PM allows you to create a new workspace with following New WorkSpace dialog Select File on PM menu bar then New Workspace Eem No workspace touepue File Edit Find Layer View Project Build Tool Window Help New Mac ADR 54 i ries es Open
40. elopment tool and information about other useful features in Chapter 5 Other Information 52 TK 78KOR KG3 User 5 Manual In this chapter the hardware of TK 78KOR KG3 will be explained PD78F1166GF 78KOR KG3 Clock External main system clock 20MHz Subsystem clock 32 768KHz Internal high speed oscillation clock 8MHz Internal low speed oscillation clock 240 kHz Expansion connector 5 socket x2 only pad Power supply voltage Input output for 7 Seg LED 01 02 operation check use Push switch SW1 SW2 Reset switch SW4 Other parts Operating mode setting switch SW3 Power supply selecting jumper pin JP1 Power LED LED1 solder short pad The name with bracket is the name printed on the board 53 TK 78KOR KG3 User 5 Manual 3 1 Layout of hardware functions J1 LED1 SWA P CN3 T ae 2 26 USB1 oi MADE IN J PAN UK T8KOR KG3 2444 2 CN2 ol ryojolooQooooQs U1 7segLED U2 7segLED SW3 SW1 SW 3 2 Layout of solder short pad DCVDD2 AVREFO AVREF1 EVDD1 IN JAPAN OPEN 0 0 cid CPP 78KOR KG3 S A 7 19 USBI i gt lt M pene w m Ds EI Ld c o Bg pnm de ea 60 67 80 87
41. ents Address area that reserved by on chip debugging 2H 3H CEH D7H From the address set in Start address to the byte set in Size Security ID Check Security ID and enter the security ID which is a unique ID code 10 bytes to authenticate when the debugger is launched The security ID is stored in the flash memory 4 and checked if it is the same the code entered in Linker options dialog when the debugger is launched The debugger will not be launched when the security ID is unmatched By using this function you can secure the programs from leaks If you do not need to set the security it is recommended to set the security ID FFFFFFFFFFFFFFFFFFFF this is the initial code If you forget about the security ID stored in the address of 4 or if you set wrong on chip debug option byte you will not be able to use the debugger ID78KOR QB To solve this you can use the 78KOR Starter Kit Setting for changing the setting to initialize the flash memory at the time debugger launched For details refer to 5 3 8 Erase microcontroller built in flash memory 36 TK 78KOR KG3 User 5 Manual 2 4 2 Output2 Tab Select Output2 tab on Linker Options window and see following settings Linker Options X Output Library Others Create Link Map File p Output File Browse M Output
42. evelopment using 78 NEC Electronics 16bit all flash microcontroller The user only needs to install the development tools and USB driver and connect the host machine with the target board to start the code development build monitoring the output and debugging code This demonstration kit uses the on chip debug feature from the microcontroller itself without emulator connection Configuration for Debugging RTV 42735 RID NN 25940 WHYPIW a 87 2 76 Start adding user code Do not edit comment generated her 11 End user code adding Do not edit comment generated here Am OS By loading the sample programs you can confirm running the board Input output for operation check use LED Push switch TK 78KOR KG3 User 5 Manual Overview Reader Purpose This manual consists of the following contents Read chapter 1 and 2 first for installing the development tools and using the sample programs Read chapter 3 5 for customizing the sample programs and the hardware Chapter 1 Chapter 2 Chapter 3 Chapter 4 Chapter 5 Preparations Install the development tools Experiences Experience the basic operations of integrated development environment PM and integrated debugger ID78KOR QB with using sample programs Hardware Specifi
43. folder in addition is made 26 TK 78KOR KG3 User 5 Manual 1 4 2 Overview of Sample Programs The sample programs consist of following directories SAMPLE SAMPLE KG3 prw Work space file Main c Source file 27 TK 78KOR KG3 User s Manual In this chapter you will experience how to use the development tools with using the sample programs The development tools are Integrated Development Environment IDE PM Integrated Debugger ID78KOR QB You will use the programs that you prepared 1 4 Sample Programs as the sample programs for TK 78KOR KC3 You will be able to understand how to use the development tools and the concept of project files which you need for producing application programs 28 TK 78KOR KG3 User s Manual The overall steps are as follows 2 1 Start PM 2 3 Load Workspace 2 4 Set Linker Options 2 9 Set Compiler Options 2 6 Greate Load Module Files un Programs 2 9 Start Debugger 29 TK 78KOR KG3 User 5 Manual Let s start using the development tools First start the PM Select Windows Start Menu gt Program gt NEC Electronics Tools gt 6 30 Em No Workspace OutPut 30 TK 78KOR KG3 User 5 Manual 2 2 What is PM In PM application programs and environment setting are handled as a single project and series of actions such as program creati
44. gger ID78KOR QB Click the debug button or select Build on menu bar then Debug If you do not see the debug button go to 2 7 Check Debugger Settings for changing the settings The steps to start the debugger will be explained below ho SAMPLE KG3 prw OutPut loj x File Edit Find Layer View Project Build Tool Window Help 268 le gt C Program Files NEC Electronics Tools CC78KOR W1 20 bin Compilation complete 0 error s and 0 warning s SAMPLE KG3 1 Project s C Program Files NEC Electronics Tools CC78KOR W1 20 bin c 3 SAMPLE KG3 Compilation complete 0 error s and 0 warning s foi H E Source Files C Program Files NEC Electronics Tools CC78KOR W1 20 bin c E 22 Include Files Compilation complete 0 error s and 0 warning s foi 9 08 Project Related Files C Program Files NEC Electronics Tools CC78KOR W1 20 bin c Other Files Compilation complete 0 error s and 0 warning s fo C Program Files NEC Electronics Toolsi RA78KOR U1 10 bin Link complete 0 error s and D warning s found C Program Files NEC Electronics Tools RA7S8KOR W1 10 bin c Object Conversion Complete 0 error s and times Buila Total error s 0 Total warning s ID78KOR QB is launched For Help press F1 ml 11 14 z 45 TK 78KOR KG3 User s Manual Configuration dialog is opened Enter FFFFFFFF
45. lobal variables local variables cannot be displayed when programs are running Local Variable iL 5 3 7 Display memory SFR contents By clicking the button below you can open the memory window Memory Search E Refresh 3 4 45 6 Close T2 9 3 B 0017 p co eo 75 TK 78KOR KG3 User s Manual 5 3 8 Erase microcontroller built in flash memory If you forgot the security ID or if you set On Chip Debug Option Byte to disable the on chip debug function you cannot start debugger For the case like this there is the function to erase the flash memory First check if you actually set the correct On Chip Debug Option byte with referring to 2 4 Set Linker Options If it is not correct then set correctly Remember the security ID you set 2 Use Windows Explorer to go to the path C XProgram Files NEC Electronics ToolsYTK driver then open exkOr32ocfg exe the directory path is for the default installation directory The 78 Starter Kit Setting starts Select Erase flash memory at debugger start at Flash Memory then click 78KOR Starter Kit Setting E x Flash Memory ERASE flash memory at debugger start up Cancel start the debugger As you erased the flash memory with above processes you need to enter FFFFFFFFFFF
46. m and install the sample programs e TE TREOR E GS sample prferam e TE REORJE G3 gvaluation kit User s manual Reter to the User s manual about ubage Done NM m BR Local intranet 7 3 Click the TK 78KOR KG3 Sample Programs link the following download confimation window appears File Download E E X Some files can harm your computer IF the file information below looks suspicious you do not Fully trust the source do nat open save this file File name type Application From E SAMPLE E This type of file could harm your computer if iE contains malicious cade file or save it ta pour computer Cancel Info Sivas ask before opening thie type ar File Would vau like ta open Click the butten 25 TK 78KOR KG3 User 5 Manual Save ir Local Disk 4m o Documents and Settings i Program Files History WIMMT 50 wLITemp kto biy Documents Computer i File name TK SKOR EXE QD My Network LEE Save as type Application Cancel 5 After specifying the download destination folder click the button 6 The self extraction sample program set TK78KOR exe is copied to the specified folder The folder that the TK78KOR folder is made when this file is executed and the sample program is stored under the
47. me 25 4 Startup 5 Register Model Link Directive 7 Setup Source Files Tool Versions Version 8 Select Debugger 3 Confirmation 8 850 Microcontrollers Only 4 5 Select only Installed Tools Please select the Tools from NEC Electronics to be used The following tools have been excluded from selection because they are not installed 8 8 SM for 8 Click Detail Setting button 65 TK 78KOR KG3 User 5 Manual Tool ersion Detail Setting e ___________ Unused Unused 1 20 1 10 Select tools as above screenshot then click New WorkSpace Step 2 9 Select Tools Changed Selected 1 78K0R Series Software Package 1 Select WS 5 Link Directive ID78KOR QB Select any Installed 11005 Click New WorkSpace Step 7 9 Setup Source Files Select WS 4 Startup Fil 5 Register Model 5 Directive Fre HT Jp LJ WEIT Click 66 TK 78KOR KG3 User 5 Manual New WorkSpace Step 8 9 Select Debugger fib 7SKUR W B v3 40 78KOR Integrated Debugger Click 67 New WorkSpace Step 9 9 Confirmation Select Real Time WS 4 Startu
48. n Exit 5 SAMPLE KG3 prw OutPut File Edit Find Layer View Project Build Tool Window Help Mew Ctrl N yx Open cho A ec E Insert Debug Build Close New Workspace Open Workspace C Program Files NEC Electronics Tools CC78KOR W1 20 bin Compilation complete 0 error s and warning s Save Workspace i C Program Files NEC Electronics Tools CC78KOR W1 20 bin c Close Workspace Compilation complete error s and warning s fo Save Ctrl 5 C Program Files NEC Electronics Tools CC78KOR W1 20 bin c Save As Compilation complete D error s and 0 warning s foi C Program Files NEC Electronics Tools CC78KOR U1 20 bin c Change Source File Mame Compilation complete 0 error s and 0 warning s fo Save All Source Files C Program Files NEC Electronics Tools RA7SKOR W1 10 bin DRE PVSUMM Link complete error s and 0 warning s found 4 E C Program Files NEC Electronics Toolsi RA7SKOR W1 10 bin c us Object Conversion Complete 0 error s and 0 warn Recent File s Build Total error s 0 Total warning s O 4 Recent Warkspace Download C TK78KOR SAMPLE KG3 a to the debugger EOF Exit and prompt to save the files is closed The experiences section ends now You can find more information how to use the dev
49. nd the short circuit of solder short pad DCVDD1 2 Moreover it is also possible to connect the stabilizing supply etc in the lead line instead of the AC adaptor because CN3 is connected with J1 of a through hall Acceptable jack CN3 0470 01 630 by Hosiden Corp not mounted Acceptable plug 2 1mm DC jack center plus Current capacity 100mA or more Attention Please make JP1 Open when operating in an external power supply 59 TK 78KOR KG3 User 5 Manual This chapter describes how to solve troubles you may face 4 1 If you cannot find USB driver when you connect PC to the kit Check Point 1 If you use USB hub do not use it USB hub is not supported Check Point 2 Check if you installed Starter Kit USB Driver in 1 2 Installation of Development Tools If not install the driver Check Point 3 If above 2 check points are confirmed disconnect the USB cable from PC and re connect again It should show the Found New Hardware Wizard wizard Operate the installation with referring to 1 3 Installation of USB Driver After the installation make sure you go through 1 3 3 Completion of USB Driver Installation to confirm the USB driver installation 4 2 Error when you start the debugger There could be several reasons to make errors happen The solving processes differ depending on errors Please check the error message first The solving processes for each error are as follows 60
50. nue 2 Select Install from a list or specific location and click Found New Hardware Wizard This wizard helps vou install software Far USB Device Select Install from a list or specific fe If your hardware came with an installation CD location E or floppy disk insert it now What vou want the wizard to do CQ Install the software automatically Install from list or specific location Adva Click Next Click Next to continue 17 TK 78KOR KG3 User 5 Manual 3 Select Search for the best driver in these locations check Include this location in the search and then click Browse to select the driver directory path The path should be C XProgram Files NEC Electronics ToolsYTK driver as default installation If the installation directory is not default then select TK driver under the installation directory Click Found New Hardware Wizard Please choose your search and installation options Search for the best driver in these locations Use the check boxes below to limit or expand the deta paths and removable media The best driver Found will Select the driver directory Search removable media floppy CD ROM Include this location in the search C Program Files WEC Electronics T aalss T K drive Don t search will choose the driver to install Choose this option to select
51. on using the editor source management build and debugging are managed Also one of more project files is managed together as a workspace Menu bar Tool bar s No Workspace OutPut File Edit Find Layer Project Build Tool Window Help Project Window Files Memo Workspace For Help press 1 Project Window Output Window Project window A window in which project names source files and include file are displayed using a tree structure Output window A window in which the build execution status is displayed For details regarding menu bars and tool bars refer to Help menu in Help on menu bar then PM Help 31 TK 78KOR KG3 User s Manual What is a project A project is the unit that is managed by A project refers to an application system and environment development based saves project information in a project file What is a project file A project file contains project information that includes the source files device name tool options for compiling editor and debugger information The file name format is xxxxx prj Project files are created in the directory you specifies when you create a new workspace What is a project group project group is a group comprised of a number of projects an application system The target device of each project must be the same within a proje
52. onsibility 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 While NEC Electronics endeavors to enhance the quality reliability 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 Electronics products are classified into the following three quality grades Standard Special and Specific The recommended applications of NEC Electronics products depend on its quality grade as indicated below Customers must check the quality grade of each NEC Electronics product before using it 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 eq
53. p Hegister 5 Link Directive Click TK 78KOR KG3 User 5 Manual pM test prw DutPut inl File Edit Find Layer View Project Build Tool Window Help 2 8 Es S Sh vac gt test Source Files 21 Include Files Project Related Files Other Files Project test was registered 4 4 2 Make File created successfully m E gt This completes workspace and project creation Additional source files can be registered at any time thereafter For details refer to Register additional source file Also you need to do the settings for on chip debug Please refer to 2 4 Set Linker Options 2 5 Set Compiler Options and 2 7 Check Debugger Settings 68 TK 78KOR KG3 User 5 Manual 5 2 Register additional source file Now register additional source files The following example shows the additional registration of source files b c and with source file already registered Place the cursor on the source file in the Project window of PM and select Add Source Files displayed in the right click menu PM test prw Project Window File Edit Find Layer View Project Build Tool Window Help S X SM vac gt Add the source file to the project z A Add Sou
54. r must be grounded using the wrist strap The connectors and or device pins should not be touched with bare hands TK 78KOR KG3 User 5 Manual Contents IL PREPARA TON 8 1 1 Development Tools SOFUWAFCe 3 ete deco es etes ee ees bes eet 9 1 2 lInstallauonmot Development a ere e noe hc UH OE EG 10 2 Installatioti PAC Ka teile ttd tenes ens 10 1 2 2 Installation of Development tento tette dab pore eee pde ende 10 1 9 Installatiori otr USB DVEF v ota MO Or OO 16 T93sl Installation orn Wiridows P 17 132 Installation on Windows 2000 student b oti d tenuti t ot ot i bot de 20 i 3 6 Gompletion of USB Driver 23 Sample Progi AIS 24 141 Breparation of Sample Programs sescent iaiaaeaia aA a 24 1 4 2 Overview of Sample Profas assessed Gnd odit dedu 27 CGHAPTERZEXPERIENOES shots mta aces od cad cada data sede deut 28 30 22 UAE VSP M MT _ __ __ ____________ 31 2 3 Load Workspace
55. rce Files test 3 xl Look in test b e ce Files af type Source Files c asm Cancel Help Add Files fram Folder File name Multiple source files can be selected by clicking them with pressing key 69 TK 78KOR KG3 User 5 Manual rg test prw Project Window T 70 TK 78KOR KG3 User s Manual 5 3 Debugger tips This section describes some useful techniques for the debugger ID78KOR QB 5 3 1 Change display of buttons Execution controls run stop step in debugging reset etc and opening functional window made by below buttons However it could be difficult to know which button does what ipm E In this case select Options on menu bar then Debugger Options Check Pictures Text on setting area With this setting the buttons display the text as well so that it is easier to know what they are E E Al dn Open Load Proj Sro Asm Weh Ret Step Ower Res 5 3 2 Display source list and function list When you wish to see source file list or function list select Browse on menu bar then Other gt List to open the list window The information in the windows is synchronized Therefore it is not just for referring to the list but it is useful when you
56. river must be installed on PC before you start using the TK 78KOR KG3 Please follow the instruction below to install the driver Starter Kit USB Driver must be installed on the PC If not please refer to 1 2 Installation of Development Tools to install the driver first CAUTION Do not use a USB hub for connecting TK 78KOR KG3 First connect the TK 78KOR KG3 to PC with USB Depending on the version of Windows OS the installation will be differed Please check your Windows version and follow the instructions Windows XP gt 1 3 1 Installation on Windows Windows 2000 gt 1 32 Installation on Windows 2000 After the installation go to 1 3 3 Completion of USB Driver Installation 16 TK 78KOR KG3 User 5 Manual 1 3 1 Installation on Windows XP 1 Once the TK 78KOR KG3 is connected with USB the Found New Hardware Wizard will be started Select No not this time and click Found New Hardware Wizard Welcome to the Found New Hardware Wizard Windows will search for current and updated software by looking on Your computer on the hardware installation or on the Windows Update Web site with your permission Head our privacy policy TET an Windows connect to Windows Update ta search for Select No not this time software Yes this time only Ces now and every time connect a device gt No not this time Click Next Click Next to conti
57. rmation and FAQs lt 6 gt Exit Terminate the setup 2 Click the Install 11 TK 78KOR KG3 User 5 Manual 3 Tool Installer dialog box is opened Select products that you need to install as default all the products that you need to use the TK 78KOR KG3 are selected Explain area displays an explanation of the selected product To change the installation destination click When all the settings are completed click Install In this document it is assumed that users install the programs under NEC Electronics Tools directory default installation directory Users can find the tools by selecting Start Menu gt Programs gt NEC Electronics Tools 3 Tool Installer i x DeviceFile Install D eviceFile DF 81188 v3 00 Search Tool Install Tools Product 1 20 11251 1 20 Documents 14 400 HATSK OR 1 10 1 10 Documents 11 432KB 30 1 Documents 12 8 8 Integrated Debugger 3 40 3 384 IDF8K0R GB 363 40 Documents 11 552KB E plain Drive Available Space Ea 63 405 132KE Destination Required Space JC AProgram NEC Electronics Tools Browse 125 553KB 4 Click when Install comfirmation dialog box is opened DINEM gt 22 Install the Tools and Cancel
58. uipment submersible repeaters nuclear reactor control systems life support 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 need 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 CAUTION not give any physical damage to this equipment such as dropping Do not superimpose voltage to this equipment not use this equipment with the temperature below 0 C or over 40 C sure the USB cables are properly connected Do not bend or stretch the USB cables Keep this equipment away from water TK 78KOR KG3 User 5 Manual extra care to electric shock This equipment should be handled like a CMOS semiconductor device The user must take all precautions to avoid build up of static electricity while working with this equipment All test and measurement tool including the workbench must be grounded The user operato
59. umentations 1 2 2 Installation of Development Tools 1 Please insert the CD ROM in the drive The installer will show up automatically If it does not start automatically please initiate it by double clicking the SETUP EXE NEC Electronics Microcomputer Development Tools Welcome to the NEC Electronics Microcomputer development tools setup program Before vau execute this installer please exit all windows programs TK 78KOR KG3 11 02 Sep 28 2007 Readme First Documents Sample Prograrn Link to NEC Electronics Microcomputer E sit 1 Readme First The contents of the CD ROM and some notes are available Please read it at first lt 2 gt Install Click Install to start installation of development tools For details please refer to the next section 10 TK 78KOR KG3 User 5 Manual lt 3 gt Documents Manuals of development tools and the evaluation kit are available in PDF files When this button is clicked the WWW browser will start Adobe Acrobat Reader is available in the CD ROM lt 4 gt Sample Program Click this button to start the WWW browser for the sample program and the tutorial lt 5 gt Link to NEC Electronics Microcontrollers Click this button to start the WWW browser display the link to the NEC Electronics Microcontroller web site http www necel com micro index_e html The NEC Electronics Microcontroller web page provides with the latest product tool info
60. wish to update files or functions e x interrupt Hy main c 71 TK 78KOR KG3 User 5 Manual 5 3 3 Set delete breakpoints Breakpoints are executed by clicking lines in which is displayed is displayed in the line where a breakpoint is set Breakpoints are deleted by clicking Search 44 gt gt Watch Quick R 20 maintvoid feo While 13 ml 4 EI amp 4 72 TK 78KOR KG3 User 5 Manual 5 3 4 Display global variables With using Watch Window you can display global variables There are several ways to register global variables to watch window In this section how to register from source window is described Right click the variable on source window then select Add Watch Source TGK R Vnice c ucPlaySts ug stop Led Mis ug a utput count tatic lUi amp autput 2 1 TEE tatic 8 PlayMode u32 Symbol u32 uilntCoun U16 usKeyStsC Break when Access Us Break when Write 4 mi Break when Read fr 2 Add Watch dialog opens Click CI MH ame Add Rade Proper Dec Oct Bin String C Byte C Word Double Word Number 3Adding a variable to watch window is completed 73

Download Pdf Manuals

image

Related Search

Related Contents

SIMATIC HMI HMI device MP 377 (WinCC flexible)  PAD Setup Guide v1.3 - Greensboro Day School  TS-AVE3/B USER`S MANUAL IntelSocket 370 Celeron/ Pentium III  FP-AI-100 and cFP-AI-100 Operating Instructions  Manual U-nik MICRO SOL    Manuel d`Utilisation du variateur de fréquence L200  Base des expériences éducatives  Fortbildung 21    

Copyright © All rights reserved.
Failed to retrieve file