Home
Manual - ICP DAS USA`s I
Contents
1. Add Files to Folder E MyDer Settings 3 StdAfx 7 Add to Source Contol 3 Header Fe 0 MyDe w Docking View E MyDe Hide a newre E Reso D Properties E StdAfx h C Resource Files SI ReadMe tet 5Class KE FileView I 87120 user manual ver 2 30 Jul 23 2008 50 Step10 In the popup dialog select Library Files lib in the Files of type filed Select the I87KCAN lib library files and then click OK button to add the library file into MyDemo project After finishing the Step the tree view of File View is shown below Insert Files into Project ied J al x Lookin E Dem GOARMY4Dbg me ICH ASA PAC SI BA e MyDema rc a rads cpp WE e inserted into folder titled Source Files in project A Bi MyDemo h A Si Ldiermefile h Step11 Click the Tools Options to set the include and library directory Visual C Source Browser Ak Flz A Remote Spy Fi Remote System Information A Remote Zoomin Step12 Click Directories tab and select Include files in the Show directories field Set the directories as follows Options KU Tabs Debug Compatibility Download Dat Directories D n Platform CPUs send Show directories SC Win32 WCE ARM WCE ARMVAI Inctude files omnee I 87120 user manual ver 2 30 Jul 23 2008 51 Step13 Select the Library files in the Show direc
2. i Category General N Output file name dbedded isual C ARMY 4IRel MyDemo exe Ey MyDemo Microsoft File Edit View Insert Objectilihrz saetete A z WinconSDK lib UartCe lib ei GG M Generate debug info Ignore all DT M Generate mapfile MyDemo PAC Set Active Proyect Add To Froject Source Control ifs Workspace My MyDemo file Project Options inologo base 0x00010000 stack 0x1f fentry wWinMainCRT Startup jincremer ipdb ARMY4lRel MyDemo pdb Pie ma v SS Step16 When finishing the program select the project configuration as Win32 WCE ARMV4I Release and click Build Rebuild All to build an execution file Evid iech Window Help ste Compie DEMO ALLDlecpp ChltF Build DEMO ALL exe F sm Ree build All Step17 Use ftp method to copy the execution file and necessary dll file into WinPAC series MCU First Open the IE internet explorer and key the ftp 192 168 0 115 and press Enter key in the Address filed The 192 168 0 115 is your WinPAC s IP address A ICPDAS Microsoft Internet Explorer File Edit wiew Favorites Tools Help ae Q sak zk x E A pP Search Sy Favorites Lea y E Go Links bre 7 Address CG ftp 192 169 0 115 a Certification Download Distributors i Home About Com pany Products e Step18 After connecting to the
3. 69 5 6 5 SetCANMask Description Use this function to set the I 87120 message filter Syntax int SetCANMask unsigned long AccCode unsigned long AccMask Parameters AccCode AccMask The AccCode is used for deciding what kind of ID the CAN controller will accept The AccMask is used for deciding which bit of ID will need to check with AccCode If the bit of AccMask is set to 0 it means that the bit in the same position of ID need to be checked and that ID bit value needs to match the bit of AccCode in the same position The following table shows each situation of AccCode and AccMask For 11 bit ID Message AccCode and AccMask high byte of the high word low byte of the high word low byte of the high word RTR high byte of the low word bit7 bitO bit7 bitO of 1st byte data low byte of the low word bit7 bitO bit7 Dm of 2nd byte data I 87120 user manual ver 2 30 Jul 23 2008 70 For 29 bit ID Message AccCode and AccMask high byte of the high word low byte of the high word low byte of the low word low byte of the low word RTR For example In 29 bit ID message AccCode OOh OOh OOh AOh AccMask FFh FFh FFh 1Fh ID bit bit28 bit21 bit20 bit13 bit12 bits bit4 bitO ID Value XXXX XXXX XXXX XXXX XXXX XXXX 101xx will be accepted Note The mark x means don t care And the mark h behind the value means hex format Return CAN_NoError CAN_ResetError CAN_SetACRError
4. 8 The following connection statuses are presented for the condition if the terminal resister is enabled or disabled Disable Enable Auto Run Initialize JP1 Jumper selection JP3 Jumper selection The pin assignment of l 87120 CAN bus connector is shown below N A Pin 1 CAN H Pin 2 CAN SHLD Pin 3 CAN L Pin 4 N A Pin 5 CAN_H CAN_H bus line dominant high CAN_SHLD Optional CAN Shield CAN_L CAN _L bus line dominant low I 87120 user manual ver 2 30 Jul 23 2008 9 2 5 Power LED l 87120 slot module needs 2W power consumption If the electric power is supplied normally the Power LED will be turn on always If any other situation please check the power supply or contact to your distributor 2 4 Tx Rx LED Each l 87120 slot module provides Tx Rx LED to check the CAN messages transmission and reception situation If the I 87120 is transmitting or receiving a CAN message the Tx Rx LED will blink If 67120 s loading is heavy the Tx Rx LED will always turn on 2 5 ERRLED The ERR LED indicates the error status of the CAN physical layer and indicates the errors due to missing CAN messages When the I 87120 ERR LED is turned on users can use the function GetStatus to obtain the error status and know what is happen If the ERR LED is turned on due to the software buffer overflow the buffer error flag can be clear by using the function ClearStatus For more detail about these functions please ref
5. A3 Download Tool Edit View Favorites Tools Help Zi v EI o o Search K Folders hl Ca7slO7 h Mi SlokModule tI ah File and Folder Tasks Sy 7168xw ini Configuration Setting MyDemo DSK MyDemo exe User ob Step14 Use Notepad to modify the first line of 7188xw ini in MyDemo folder This part of parameters is used to set the PC RS 232 com port parameters Words C1 means the PC COM port number B115200 indicates the baud of PC COM port PO is parity setting D8 is data bit setting S1 is stop bit setting For example if users use PC COM to connect with the COM1 of l 87120 slot module for program download the first line of 7188xw ini is C1 B115200 PO D8 1 If users use PC COM2 to connect with the COM1 of l 87120 the first line is set to C2 B115200 PO D8 1 E 7188xw ini Notepad EDR File Edit Format View Help demol exe showrom exe w29 I 87120 user manual ver 2 30 Jul 23 2008 85 Step15 If the COM1 of I 87120 has connected to the PC COM the hint sign C829 8KCAN gt will be shown in the 7188xw exe window after pressing the Enter key in the 7188xw exe program DIN L Ir Hegin Key Ihread ICurrent set Use CORI 115200 N 8 4 AutoRkun co_87k29 exe Autodownload Files Mone EE ware directory Gs SMyDemo C829 CBKCAND gt Step16 Key the command load in the 7188xw exe program Fol
6. ccccccccessceeeeeeesseeseessenseenseenseeaseessenseensesnsenasenas 18 3 8 GetCANMAaSKk E 20 39 ClearStalUsS srno a a aa EAA aAa 21 3 10 EH 22 WNWTTZOEH 4 el IV BE 23 3 12 IS CK CANIN istevecavesswecsvecsvecsvesavcnsvesnssasvenuwssevesewanursenseuuwansyecuncouswest 24 3 139 GEIGANMSG WEE 26 3 14 SONGGANMSG secie a EEEa 27 3 15 Function Return Error Code xekkkKKKKRKEKKR ENKER KREE R ENKEN EEN KENNEN 28 DEMO g lte tel lu E 29 4 1 TC 1 01 Demo For l 8000 Series MCU ee eeeeeeeeeeeeee 31 4 2 EVC Demo For WinCon Series MCU ceeeeeeseeeeeeeneeees 40 4 3 EVC Demo For WinPAC Series MCU ccseeeseeeneeeeeeees 48 4 4 GCC Demo For LinCon Series MCU ccccssesssseeeeeeeeeeeeeees 55 User defined Flexibility Firmware ccccsscceeseeseseeeeeeeeseeeeneeeeaeeeenees 60 St Mleetireuttzs sa eeuebsegoeutebeugehre ergeet deN eegene 61 G T dl e TI 62 5 3 UserDefCmdFunc eegene 63 54A USERDEIBINANY FUNG sses EE 64 I 87120 user manual ver 2 30 Jul 23 2008 2 59 Jee HEI eege 65 5 6 Others support functions for I 87120 firmware 0 s000 66 5 6 1 Ty er Tee Vu de BEE 66 5 6 2 CAN ROSCU eeeeeeiek uerge ege ege REN 67 IER 68 5 64 GEIC AN BAG ona AR 69 56 5 SeCtCANMAaSK EE 70 5 6 6 GetCANMask ccccccccsseceseecessecensecensecenseeensesensesenees 72 E GE ele e EE DE 73 56 8 GetCANMSO gees ege eege eege 74 387 WE e e E TT 75 5 6
7. For example if users use PC COM to connect with the COM1 of l 8000 series MCU for program download the first line of 7188xw ini is C1 B115200 PO D8 S1 If users use PC COM2 to connect with the COM1 of l 8000 series MCU the first line is set to C2 B115200 PO D8 1 E 7188xw ini Notepad Cep File Edit Format View Help CL 6115200 PO D 51 ECHO exe xgemol exe showroom exe w25 Step16 If the COM1 of l 8811 has connected to the PC COM1 the hint sign l 8000 gt will be shown in the 7188xw exe window after pressing the Enter key in the 7188xw exe program Note Different type of l 8000 series MCU or different OS version of l 8000 series MCU will have different hint sign T188XW 1 24 C0M1 115200 N 8 1 FC 0 CT5 1 DIR C MyDemo Jof x El ji 3 HHH I 87120 user manual ver 2 30 Jul 23 2008 38 Step17 Key the command load in the 7188xw exe program Follow the hint command to press AIt E and input the file name MyDemo exe to download the execution file Then press Enter to continue Current set Use COML 115268 4N 8 1 AutoRun c87h1AB exe Autodownload Files demol exe showronm exe Current work directory C MyDemo origin 1 848 load File will save to 8HHH 00i StartAaddr gt 7HH8 PEFFER Press LALT_E to doaweteed filet Input fFilenam MyDemo exe Step18 After finishing the download procedure
8. Library and demo for I 87120 gt 87120 default firmware gt 87120 library for user defined firmware gt All the demo of the user defined firmware gt demos and library for l 8000 series MCU gt 87120 library for l 8000 series MCU gt 8000 series MCU library gt 8000 series MCU program download tool gt 1 8000 series MCU OS image gt 87120 demo programs gt demos for Borland C 3 1 gt demos for Turbo C 1 01 gt demos for MSC 6 0 gt demos and library for WinCon series MCU gt 87120 demos for EVC 4 0 gt demos and library for WinCon series MCU gt 87120 library for WinCon series MCU gt 87120 send CAN messages demo gt 87120 receive CAN messages demo gt WinCon CAN Utility program source code gt demos and library for WinPAC series MCU gt 87120 library for WinPAC series MCU gt 87120 send CAN messages demo gt 87120 receive CAN messages demo gt WinPAC CAN Utility program source code gt demos and library for LinCon series MCU gt 87120 demos for GCC gt 87120 library for LinCon series MCU gt 87120 send CAN messages demo gt 87120 receive CAN messages demo I 87120 user manual ver 2 30 Jul 23 2008 29 Here we provide the demo programs about how to use the I 87120 library in l 8000 series MCU WinCon series MCU LinCon series MCU and WinPAC series MCU For l 8000 series MCU the demo program for BC 3 1 Borland C version 3 1 TC 1 01
9. Linde WCE ARMY4T CWin32 WCE MIDI ED Ca cme Step6 Select Dialog based item for this demo Choose the language which you want to see in your resources file Here English United States item is used Click Finish button to finish the project creation I 87120 user manual ver 2 30 Jul 23 2008 41 WCE MFC AppWizard exe Step 1 of 4 What type of application would you like to create Single document e Dialog based M DocumentView architecture support What language would you like your resources in English United States ceappwzenu dlihd Step7 Copy the I 87120 library files IB7KCAN h and I87KCAN Iib into the MyDemo folder in disk C File Edit view Favorit ZP pack k Ba Name lej Std Ars cpp h Std fx h UARTEE lib WW A3 Ele Edt View Fgvortes Took Hel Oa 8 Pp sexe gt gt Folders Adre E CAN SItModule I_S7 120 WinCEIEVCIS7CANIbIver_100 File and Folder Tasks KH Hake a met fodder K Publish this folder to the Web kad Share this folder Step8 Select the active configuration to SA_IA and Win32 Release mode Si MyDemo Microsoft eMbedded Visual C File Edit View Insert Project Build Tools Window Help I 87120 user manual ver 2 30 Jul 23 2008 42 Step9 Select File View tag and expand the tree view Right click the Source Files folder icon and click Add Files to Folde
10. frame DataLen The DataLen indicates how many data will be transmitted in the array Data see the parameter Data below The maximum value of DataLen is 8 Data This parameter needs a pointer to point an array This array include the date which will be transmitted to the CAN network Because the maximum data numbers of a CAN frame is 8 bytes more than 8 bytes data in the array Datal will be ignored Return CAN_NoError CAN_TransmitlIncomplete CAN DataOverrun I 87120 user manual ver 2 30 Jul 23 2008 73 5 6 8 GetCANMsg Description If a CAN message is received by I 87120 module use this function to read a CAN message from software buffer Syntax int GetCANMsg unsigned char Mode unsigned long MsgID unsigned char RTR unsigned char DataLen unsigned char Data Parameters Mode The parameter is used to point the CAN message specification If the CAN message is CAN 2 0A specification the Mode value is given to O If itis CAN 2 0B specification the value is 1 MsgID The parameter ID is used to point to the attribution ID of a CAN message If the l 87120 receive a CAN message with specification 2 0A the ID value range is from 0x0 to Ox3FF If CAN message is 2 0B the ID value range is from Ox0 to Ox1FFFFFFF RTR This parameter is used to get the RTR status of a CAN message The RTR value is 0 if the CAN message is normal CAN frame If itis 1 the CAN message Is remote transmit
11. 11898 2 spec each terminal resistance is 1200 or between 1080O 1320 The length related resistance should have 70 mQ m Users should check the resistances of the CAN bus before they install a new CAN network 120Q OO CAN_L Moreover to minimize the voltage drop over long distances the terminal resistance should be higher than the value defined in the ISO 11898 2 The following table can be used as a good reference Bus Cable Parameters Terminal Bus Length Length Related meter j Cross Section Resistance Resistance Q mO m Type 0 25 23AWG 124 0 1 0 34mm 22AWG 40 300 0 34 22AWG 127 0 1 0 6mm 20AWG 300 600 0 5 0 6mm 150 300 600 1K lt 0 75 0 8mm 150 300 I 87120 user manual ver 2 30 Jul 23 2008 7 70 lt 60 lt 40 20 In I 87120 the 1200 terminal resistance is supplied The JP1 of l 87120 is for the terminal resistance and the JP2 is RS232 COM port for download firmware of I 87120 Users can use special cable to download the firmware into 87120 This cable is named CA0904 and shown as follows The JP3 is the initial jumper of I 87120 If users want to stop the firmware uses need to turn off the 87120 and connect the JP3 jumper Then turn on the 87120 The locations of all jumpers are shown in the following figure eeeljps CAN Connector e e jp3 I 87120 Connector Hardware Profile I 87120 user manual ver 2 30 Jul 23 2008
12. AccCode and AccMask For 11 bit ID Message AccCode and AccMask high byte of the high word low byte of the high word low byte of the high word RTR high byte of the low word bit7 bitO bit7 bitO of 1st byte data low byte of the low word bit7 bitO bit7 bitO of 2nd byte data I 87120 user manual ver 2 30 Jul 23 2008 18 For 29 bit ID Message AccCode and AccMask Bit Position Filter Target high byte of the high word bit7 bitO bit28 bit21 of ID low byte of the high word bit7 bitO bit20 bit13 of ID high byte of the low word bit12 bit5 of ID low byte of the low word bit4 bitO of ID low byte of the low word RTR low byte of the low word For example In 29 bit ID message AccCode OOh OOh OOh AOh AccMask FFh FFh FFh 1Fh ID bit bit28 bit21 bit20 bit13 bit12 bits bit4 bitO ID Value XXXX XXXX XXXX XXXX XXXX XXXX 101xx will be accepted Note The mark x means don t care And the mark h behind the value means hex format Return CAN87K OK CAN87K CAN REG ERROR CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 19 3 8 GetCANMask Description Call this function to get the CAN message filter situation Syntax int GetCANMask unsigned long AccCode unsigned long AccMask Parameters AccCode AccMask These pointer for obtaining the AccCode and AccMask used by the I 8 7120 For more information about these two paramet
13. compiler will be used The procedure for all the other l 8000 MCUs will be the same with this demo Step1 Create a folder named MyDemo in the C disk Local Disk C Fie Edit wiew Favorites Tools Help pack Ki a PS Search gt Folders PE Address System Tasks Fey Hide the contents of Se hein CMY Installations T Add or remove _MS50Cache programs _MATLABEpS Al Search For files or MABRY Folders CH ISAW Th C Inetpub GON File and Folder Tasks x We Step2 Copy users s c file and l 87120 library files C87H103L lib and I87KCAN h into MyDemo folder Users can find them with version 1 03 in the path CAN SlotModule l 87120 l_ 8000 87CANLib ver_103 in CAN product CD ver 103 B Ek Fie Edit wiew Favorites 7 ae Fie Edt Yew Favorites Joos Help A3 pack Ki Si Oesch Ki LOG nH1UD3 LIE File and Folder Tasks Chc Inline File sf OB KH Make a re Poker Oh Publish this Fokker to ISKAN H the Weti CiC Header KI Share this folder 2 EB i HecC AN C Source 31 Step3 Copy l 8000 series MCU library files 8000 h and 8000E Ilib into MyDemo folder too Users can find them in the path CAN SlotModule l_87120 l_8000 MCU_Lib in CAN product CD Se MyDemo a leg File Edit view Favorites 7 Je Back e T CH Address E CiiMyDemo K Go w CBPHIOSL LIB Ci Inline File 6 EB ch IS7KCAN H Ci Header 2 KB RecCAN c C Source 3 KE AA WMCU Li
14. key in the command run to implement the execution file MyDemo exe Current set Use COML 115208 4N 8 1 AutoRun c87h1 48 exe Autodownload files demol exe shovwrom exe Current work directory GC MyDemo 2 1 860 load File will save to 8H HHA StartAddr gt 7HH0 FFFF Press ALT_E to download filet Input Filename MyDemo exe Load file MyDemo exe crc FF5A 6608 Send File info total 115 blocks Block 115 Transfer time is 5 831688 seconds LSD Cup e k run I 87120 user manual ver 2 30 Jul 23 2008 39 4 2 EVC Demo For WinCon Series MCU Step1 Download EVC 4 0 from Microsoft website Then install EVC 4 0 in your PC Note About the hardware and OS limitation of EVC please refer to the Microsoft website Step2 Double click WinConSDK_8X3X_EVC_20050617 msi file to install the WinConSDK in your PC users can find this file in the path WinCE SDK WinconSDK 8X3X EVC 20050617 msi in the WinCon product CD For more information about WinCon hardware and how to use WinConSDK please refer to the user manuals in the path WinCE User Manual in WinCon product CD User Manual L el E File Edit View Favorites Minimize bf File Edit View Favorites Tools Help Ki A3 A3 Back gt a O Back gt a ES Search Address EIWInCEISDK Go Address CD Ein Eeer Manual ke Go E readme txt Se hardware For wincons000 pdi a gt iPush Embedded For winCon 80
15. of transmission Syntax void ClearlxSoftBuffer void Parameters None Return None I 87120 user manual ver 2 30 Jul 23 2008 TT 5 6 12 ClearRxSoftBuffer Description Clear the software buffer of receipt Syntax void ClearRxSoftBuffer void Parameters None Return None I 87120 user manual ver 2 30 Jul 23 2008 78 6 TC 1 01 Firmware Demo For I 87120 Here it is considered that how to build an execution file with C87S10 7 lib and how to run this execution file on the I 87120 slot module Step1 Create a folder named MyDemo in the C disk Local Disk C a el x Edit File View Favorites Tools Help Q Bek k Sp E Search K Folders Address Ee cr System Tasks EH Hide the contents of this drive My Installations 4 Add or remove Mo ache programs MATLAB EpS c ior ral Caen minn Step2 Copy users s c file and l 87120 library files C878107 lib C87S107 h C829L lib and C829 h into MyDemo folder Users can find them in the path CAN SlotModule l_ 87120 FirmwareLib in CAN product CD Ses Sela S A3 A3 T MyDemo fi FirmwareLib Edit Tools Help search K Folders kl EI co A File Om O el Derma DW Eis Carsi07 h C Header File 2 KB File view Favorites Edit View Favorites Address Es CAN SlotModule _ 87120 FirrnvareLib Ce s107
16. one message stored in the reception buffer O for empty OverflowFlag CAN and host command buffer overflow flag information For the information about the OverflowFlag value meaning please refer to the following table 1 for host command buffer overflow O for normal O LSB 1 for CAN receive message buffer overflow O for normal Return CAN87K OK CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 22 3 11 ResetliB7KCAN Description This function is used to reset the 87120 module Calling this function will clear not only the CAN controller register error flag but also CAN and host command software buffer error flags When the CAN controller is bus off it may be called After applying this function the I 87120 configuration CAN baud and CAN message filter stored in the I 87120 EEPROM would be applied when the I 87120 reboots Syntax int ResetlB KCAN void Parameters None Return CAN87K OK CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 23 3 12 I87KCANInit Description When users want to use I 87120 module this function must be called first Afterwards The CAN baud CAN message filter and l 87120 configurations would be applied to the l 87120 Syntax int I87 KCANInit unsigned long CANBaud unsigned char BTO unsigned char BT1 unsigned long CAN_AccCode unsigned long CAN_ Mask unsigned char A
17. pi Kat Environment nelude Directories Directories g EKMKdAUSZVA ibrar Step12 After finishing the parameters setting click the Options save to save this project File Edit Search Run C ile Deh Project PR Window Help Full menus Compiler Transfer Make Linker Debugger Directories La Environment I 87120 user manual ver 2 30 Jul 23 2008 36 Step13 After finishing the parameters setting click the Compile build all to produce the execution file Users can find the execution file in the MyDemo folder Its name is MyDemo exe MME Debug Project Options Wi SE Compile to OBJ Seer ence erent EE S Make EXE file C M DEMO ERE SE Ss TL SS SE SEH MYDEMO Fi Help Rebuild all files Step14 Copy the file 7188xw exe and 188xw ini files into the MyDemo folder These two files can be found in CAN product CD Their path is CAN SlotModule l_87120 l_8000 Download_ Tool aai File and Folder Tasks 2 e KE Make a peu Folder I 87120 user manual ver 2 30 Jul 23 2008 37 Step15 Use Notepad to modify the first line of 7188xw ini in MyDemo folder This part of parameters is used to set the PC RS 232 com port parameters Words C1 means the PC COM port number B115200 indicates the baud of PC COM port PO is parity setting D8 is data bit setting S1 is stop bit setting
18. request CAN frame DataLen The DataLen is point to the value indicates how many data stored in the array Data see the parameter Data below The maximum value is 8 Data This parameter needs a pointer to point an array which is used to stored the CAN message data Because the maximum data numbers of one CAN message is 8 bytes it is recommend that the array Datal size is 8 bytes Return CAN_NoError CAN_SoftBufferlsEmpty CAN_DataLengthError I 87120 user manual ver 2 30 Jul 23 2008 74 5 6 9 GetCANStatus Description Obtain the status of the CAN controller of the specific 87120 slot module Syntax int GetCANStatus void Parameters None Return Bit Name Vawe Status Bit 7 Bus Status 1 o Buon Bit 6 Error Status Ls a 0 OK 1 Transmit Bit 5 Transmit Status 1 Receive Bit 4 Receive Status li 1 Complete Bit 3 Transmission Complete Status Ls S 0 7 Incomplete 1 Release Bit 2 Transmit Buffer Status S 1 Overrun Bit 1 Data Overrun Status WS 1 Not Emot Bit O Receive Buffer Status E pty I 87120 user manual ver 2 30 Jul 23 2008 75 5 6 10 RxMsgCount Description Obtain the message count of CAN message in software buffer Syntax int RxMsgCount void Parameters None Return CAN message count I 87120 user manual ver 2 30 Jul 23 2008 76 5 6 11 ClearTxSoftBuffer Description Clear the software buffer
19. ver 2 30 Jul 23 2008 34 Step9 Click the Options Compiler Code generation to set the compiler model to the large mode Afterwards click More to set the Floating point and Instruction Set parameters the Emulation and 80186 item will be used respectively Then click OK to save the configuration CA TE EZE jo x File Edit Search Run Compile Debug Fro lec P findow Help d Full menus Optimizations Source Messages Hames a Ce Large efines Gancely Help os Fl Help come Point Razi Convention Instruction bet E J Debug info in Ode gt a Waa Step10 Click the Option Debugger to set the Source Debugging parameter Here select None for this parameter setting amp TC EXE olx Pile Edit Search Run Compile Debug Project W SS Window Help Full menus On Compiler o Transfer Make IO OS Ge gees ram Heap Size ma i bytes ector options I 87120 user manual ver 2 30 Jul 23 2008 35 Step11 Click the Option Directories to set the Output Directory parameter Here set the C MyDemo for the Output Directory parameter cy TC _EZXE BE x File Edit Search Run Compile Debu Project 3 Window Help d EE SE Compiler H Transfer Make Linker A gt st Sek E
20. 00 System Overview pdr AE WinconSDe Bese EVO 20050617 msi gt Push Embedded Installation Guide for Winton pdf gt iPush Embedded Quick Start For WinCon 8000 pdr A Modbus_4PT_ 15 pdr AM Remote Admin Guide For iPush Embedded pdf Scankernel4Pr pdt A gt WXCOMD D og EICON EvH SEET A WinlOW Getting Started od gt WinlON 5 NET SDK pdf Step3 Execute the EVC ei See a Accessories u H DAGPro pS Search e Microsoft Office OR e Microsoft visual Studio 6 0 me 4 Help and Support Le Microsoft eMbedded Visual C 4 0 Ed eMbedded Visual C 4 0 E pun H IsaGRar 3 4 H Ki WON Messenger 7 0 Shut Down CH Hanaho I 87120 user manual ver 2 30 Jul 23 2008 40 Step4 Click File New to create a new project fey Microsoft eMbedded Visual C File Edit View Insert Project Build t Cila pen Open Workspace Step5 Select WCE MFC AppWizard exe for this project template The project name is MyDemo The location of this project is C MyDemo The CPU type in the CPUs field is set to Win32 WCE ARMV4 because the WinCon series MCU use the ARMV4 series CPU Then click OK to the next Files Projects Workspaces SlWCE Application Project name 2S WCE ATL COM AppWizard WCE Dynamic Link Library Ze WCE MFC Activex Control vizard SEET E SS Z U WCE MFC AppWizard Iesel CAMyDemo Ej EM Ke 5 x SL ZE D D
21. 10 RxMsgCount EE 76 560 11 Clear XSoOn Bummer sorset 77 56 12 Eeer rege ee EE 78 6 TC 1 01 Firmware Demo For 1 87120 cccccssessseseeeeeeseeeeeeeeeees 79 offe UL EE Le Le dl e RE 88 I 87120 user manual ver 2 30 Jul 23 2008 1 Introduction 1 1 Overview CAN Controller Area Network is a serial bus control protocol especially suited to structure intelligent industry devices networks and build smart automatic control systems It is popularly applied in the industrial automation building automation vehicle marine and embedded control network In order to expand the CAN functions of ICPDAS products I 87120 module is developed for this purpose It is a kind of slot module and need to be plugged into a host unit such as l 8000 series WinCon 8000 series LinCon 8000 series and WinPAC 8000 series PACs Programmable Automation Controller 87120 gives a way to connect to these ICPDAS host units with CAN network Owing to the features of PACs these host units can be arranged to be a CAN converter CAN slave device and CAN master device in a CAN network The following figure shows the application architecture for I 87120 modules A CANopen o Protocol a DeviceNet 8 Protocol LinCon 8000 J1939 se Protocol WinCon 8000 87120 Other CAN Protocol I 87120 user manual ver 2 30 Jul 23 2008 4 1 2 Specifications CPU 80186 80MHz Philip SJA1000 CAN controller with 16MHz cl
22. 7KCAN dIl is in CAN product CD Its path is as follows CAN SlotModule l_87120 WinCE EVC WinCon 87KCANLIib ver_110 enV 4Rel Sele o i wiew Favorites Tools E A3 File Edit View Favorites Tools Help o a a ES een Gs QB sen Ire D I Je BEE Be i a address L ftp 192 168 0 115 i T WEN L MyDemo exe MMyDemo WCE EC groltcation Other Places A MyDemo obj Object File i o KE amp ver 100 Sls Fie Edit View Favorites Tools Help MyDemoexe IOZKCAN d 8 Internet Explorer My Documents LC Shared Documents a My Network Places File and Folder Tasks User Anonymous S KH Make 5 mew Tokier a Publish thes folder Fe the Web kad Share thes Polder oor I 87120 user manual ver 2 30 Jul 23 2008 46 K Step19 Then users can find these two files in the WinCon default ftp folder Temp and execute the execution file MyDemo exe by double clicking the MyDemo exe icon in the WinCE platform of WinCon series MCU If users want to change the default ftp folder the WinCon Utility is needed For more detail information please refer to the WinCON Getting Started pdf in the following path in WinCon product CD WinCE User Manual WinCon Getting Started pdf I 87120 user manual ver 2 30 Jul 23 2008 47 4 3 EVC Demo For WinPAC Series MCU Step1 Download EVC 4 0 from Microsoft website Then inst
23. CAN_SetAMRError I 87120 user manual ver 2 30 Jul 23 2008 71 5 6 6 GetCANMask Description Call this function to get the CAN message filter situation Syntax void SetCANMask unsigned long AccCode unsigned long AccMask Parameters AccCode AccMask These pointer for obtain the AccCode and AccMask used by the I 8 120 For more information about these two parameters please refer to the section 5 5 5 Return None I 87120 user manual ver 2 30 Jul 23 2008 T2 5 6 7 SendCANMsg Description If uses want to send a CAN message by l 87120 module use this function to transmit the CAN message Syntax int SendCANMsg unsigned char Mode unsigned long MsgID unsigned char RTR unsigned char DataLen unsigned char Data Parameters Mode The parameter Mode is used set the transmitting CAN message specification If the CAN message is CAN 2 0A specification the Mode value is 0 If itis CAN 2 0B specification the value is 1 MsgID The parameter ID is used to set the attribution ID of a CAN message If the transmitting CAN message is for specification 2 0A the ID value range is from 0x0 to Ox3FF If the CAN message is for specification 2 0B the ID value range is from 0x0 to Ox1FFFFFFF RTR Use this parameter to set the RTR status of the transmitting CAN message The RTR value is 0 if the CAN message is normal CAN frame If it is 1 the CAN message is remote transmit request CAN
24. For LinCon Series MCU Step1 Download the GCC from web site and install it in the disk C of your PC Users can check the chapter 2 of the LinCon manual LinCon_Manual pdf to understand the installation procedure Step2 After finishing the installation double click the icon LinCon 8000 Build Environment on the desktop to enter the LinCon 8000 SDK environment e LinCon 8000 Build Environment LinGCon 8666 SDK Environment Configure ICPDAS LinCon HBH CArm based Mork Directory C Cyquin LinContk C scygquinsLinCon k gt m Step3 Create a folder named as MyDemo in your disk C Then copy the 8 7CANLib folder to the MyDemo folder and create a new folder named as Demo in the MyDemo folder Users can find the 87CANIib folder in following path of CAN CD CAN SlotModule l_87120 Linux GCC Bele Edit wiew Favorites Tools Help ae File I 87120 user manual ver 2 30 Jul 23 2008 55 Step4 Put users program into Demo folder Here the UserApp c is used Copy the compile bat file into the Demo1 folder Users can find the compile bat file in the each folder of LinCon I 87120 demos Seles File Edit View Favorites Tools Help ae A3 Dis Edt Yew Toots Help Q sack x bi F Search le Folders Favortes compile bat MS DOS Batch File 1 KE User ppc L Source 3 KE reccann Ge Step5 In order to build an execution file key the cd MyD
25. I 87120 User Manual Warranty All products manufactured by IPC DAS are warranted against defective materials for a period of one year from the date of delivery to the original purchaser Warning ICP DAS assume no liability for damages consequent to the use of this product ICP DAS reserves the right to change this manual at any time without notice The information furnished by ICP DAS is believed to be accurate and reliable However no responsibility is assumed by ICP DAS for its use nor for any infringements of patents or other rights of third parties resulting from its use Copyright Copyright 2005 by ICP DAS All rights are reserved Trademark The names used for identification only maybe registered trademarks of their respective companies I 87120 user manual ver 2 30 Jul 23 2008 1 Tables of Content 1 It de Le ei de 1 NEE 4 Ly WE e TT 4 UE NEE e le Ve E 5 BC Features ons a AAA aA a ERAAN 5 Hardware SDCCITICAUON E 6 2 1 Hardware Structure cccccsecssscsecsescsecceeceseneeceeeneenseceuenseceeeneeneseass 6 2 2 Wire Connection E 7 23 TOWER LED EE 10 24 XRX LED EE 10 29 E TR GE 10 l 87120 Host Function Library ccccceeeceeeeeeeeeeeseeeeeeeneeeneeeeeeseneeenees 11 Sel FUNCION BC GE 11 3 2 Programmable Flow Chart sseEKeREEKRREERREE RRE RR KEREN RRE RR En 12 3 3 LOIN GING Eeer ee 14 3 4 GEUS7TK GCANCONNG E 15 359 SCICANB AUG EE 16 36 GEIC ANB AUG RE 17 3 7 SetCANMask
26. Key cd root to enter the root folder and use Is to check all the files in the root folder Then key UserApp exe to execute the exe file um Telnet 192 168 0 100 installed installed installed installed UserApp exe I 87120 user manual ver 2 30 Jul 23 2008 59 5 User defined Flexibility Firmware There are four functions UserlrqFunc UserlnitFunc UserDefCmdFunc and UserLoopFunc for creating users flexibility firmware of I 87120 Users can design a I 8 7120 firmware with special features and communication commands by these functions Then download it into I 87120 and make the l 87120 more powerful and friendly Of cause if users don t want to code any programs just let these 4 functions empty and compile them with firmware library you will get a default firmware of 87120 1 87120 Power On I 8 7120 Initialize i UserlnitFunc Command Processer Check the first character of host gt commands UserCmd 0 is UserDefCmdFunc CAN information processer i UserLoopFunc C87s106 lib User c I 87120 user manual ver 2 30 Jul 23 2008 60 5 1 UserlrqFunc Description This function would be called when the CPU of I 87120 get an interrupt from CAN controller If users need the interrupt functionalities design their interrupt programs in this function Syntax void UserlrqFunc char INTT Parameter INTT The statu
27. LIB C C Inline File Cof5107 LIB 32 KB Cil Inline File 32 KB i caz9 h h C Header File Ca7si07 h C Header File 2 KB C 29L LIB C C Inline File c5 EB Leer C Source file 1 KB 16 KB CN GL 3290 LIB ZS Cic Inline File ao KB Cazo h C Header File 16 KB User c C Source File WEED I 87120 user manual ver 2 30 Jul 23 2008 79 Step3 Open your c file with Notepad Confirm the C87S107 h and C829 h path in the include syntax They are shown below include C829 h include C87S107 h In this demo these four functions UserlrqFunc UserlnitFunc UserDefcmdFunc and UserLoopFunc are kept empty But Users can write some c code in these functions as users wish E User c Notepad File Edit Format View Help GL ve I 87120 firmware for user desi gn d dd EE DEER incluge cB829 h e cB S107 inc lude Son include lt string h gt include lt stdlib h gt void UserIrgFunct char INTT f If CPU is interrupted by the Can controller the function will be excuted if CINTT void UserInitFunc void f f The function will be excuted first after I1 87120 is power on void UserDefCmdFunc Cunsigned int CmdLength char Usercmd yf Process user defined command the Usercmd 0 must be _ if cmdLength SEN Cusercmd 1 34 vo UserLoopFunc void ff The function will be excuted in while loop after the 1 87120 has be config
28. N baud rate for their application the user defined baud rate functionality may be needed The parameters BTO and BT1 are specially used for setting the user defined baud rate When users call the function SetCANBaud without using the Baud value listed above the Baud value is useless and the parameters BTO and BT1 will be applied for user defined CAN baud rate BTO BI1 These parameters are useful for user defined CAN baud rate The values of BTO and BI1 need to be calculated according the SJA1000 CAN controller datasheet For more information about the CAN baud please refer to the following web site http www semiconductors philips com Return CAN_NoError CAN_SetBaudRateError CAN_ResetError I 87120 user manual ver 2 30 Jul 23 2008 68 5 6 4 GetCANBaud Description Call this function to get the CAN baud used by the I 87120 Syntax void GetCANBaud unsigned long Baud unsigned char BTO unsigned char BT1 Parameters Baud The pointer for obtain the CAN baud rate If users use the predefine baud rate The function GetCANBaud would return the CAN baud rate used by I 87120 If the return value of Baud is 0 it means that the I 87120 use user defined CAN baud In this case the CAN baud rate will be indicated by using the parameters BTO and BI 1 BTO BT1 The pointer for obtain the user defined CAN baud used by I 87120 Return None I 87120 user manual ver 2 30 Jul 23 2008
29. Turbo C version 1 01 and MSC6 Microsoft C 6 0 compliers is given In WinCon and WinPAC series MCU the demos for EVC 4 0 Embedded Visual C is provided In LinCon series MCU we provide the GCC demo program The step by step demo procedure for TC 1 01 EVC and GCC will be given in the following section When users want to compile the demo program for l 8000 series MCU please copy the demo folder into a new folder named with max 8 letters because the compiler is 16 bit compiler and may have a trouble due to the long file name All of these demos may give a good model to show how to build an execution file with I87KCAN library Take a note that if users dont have any program development tools the TC 1 01 and EVC can be free download form the Borland and Microsoft web site They are shown below Download TC 1 01 http community borland com museum Download EVC 4 0 http www microsoft com downloads details aspx familyid 1DACDB3D 50D1 41B2 A107 FA 75AE960856 amp displaylang en The LinCon program development tool GCC can also free download on the ICPDAS web site Download GCC http ftp icodas com tw pub cd linconcd napdos linux sdk I 87120 user manual ver 2 30 Jul 23 2008 30 4 1 TC 1 01 Demo For I 8000 Series MCU Here it is considered that how to build an execution file with C87H103L lib and how to run this program on the l 8000 series MCU In this demo the l 8811 MCU with 40 MHz and TC 1 01
30. WinPAC series MCU drag and drop the I 87120 user manual ver 2 30 Jul 23 2008 53 ert Build Tools Window Help execution MyDemo exe and I87 KCAN_PAC dIl file into the IE window Users can find the MyDemo exe in the C MyDemo ARMV4IRel folder The I87KCAN_PAC dll is in CAN product CD Its path is as follows CAN SlotModule l_87120 WinCE EVC WinPAC 87KCANLIib ver_110 Swe MN Rel KI fm x wiew Favorites Tools D o M gt a ES Search Beem CET E 3 a MyDemo exe o gt MyDemo WCE MECgbplication Tage o MyDemo obij Object File Favorites Took Help ky po Search if Folders EBk A3 File Edit View Favorites Tools Help O O E pL search oriasi mi Address Bre ff192 168 0 115 WM Other Places S Internet Explorer CH My Documents CA Shared Documents DS ver 110 Ele Edt yw Adore ri e File and Folder Tasks User Anonymous CH Make a new folder gd Publish this folder to thet Web kal Share this Fokder Other Places Step19 Then users can find these two files in the WinPAC default ftp folder Temp and execute the execution file MyDemo exe by double clicking the MyDemo exe icon in the WinCE platform of WinPAC series MCU For more detail information please refer to the WinPAC Getting Started pdf in the WinPAC product CD I 87120 user manual ver 2 30 Jul 23 2008 54 4 4 GCC Demo
31. all EVC 4 0 in your PC Note About the hardware and OS limitation of EVC please refer to the Microsoft website Step2 Double click PAC2 70 SDK _20080512 msi file to install the WinPACSDK in your PC users can find this file in the WinPAC product CD or on the FIP of ICP DAS For more information about WinPAC hardware and how to use WinPACSDK please refer to the user manuals of WinPAC in the WinCon product CD Step3 Execute the EVC ea F m Accessories a H Settings m eg Gi DAQPro J Search Gel Microsoft Office 2 Microsoft visual Studio 6 0 GA Help ands t i E ees be ee H suppor Le Microsoft eMbedded Visual C 4 0 Ed eMbedded Visual C 4 0 wn d eg run H IsaGRar 3 4 H J MSN Messenger 7 0 Shut Down Gi SERGE Step4 Click File New to create a new project fey Microsoft eMbedded Visual C File Edit View nen Project Build LN Coho pen Open Workspace I 87120 user manual ver 2 30 Jul 23 2008 48 Step5 Select WCE MFC AppWizard exe for this project template The project name is MyDemo The location of this project is C MyDemo The CPU type in the CPUs field is set to Win32 WCE ARMV4Il because the WinPAC series MCU use the ARMV4I series CPU Then click OK to the next Files Projects Workspaces SlWCE Application Project name WCE ATL COM AppWizard C MyDemo la WCE Dynamic Link Library 82 WCE MFC Acti
32. ameters Ack This parameter is used for setting the host command acknowledge status If this parameter is set to 1 the I 87120 would not send the acknowledge message or error message after receiving a host command Therefore users function would not hang because of waiting the acknowledge message or error message In some application case it may reduce the communication time BufferSize Setting this parameter to 1 will disable the software buffer functionality This means that the I 87120 would have no buffer to store the CAN message In this case the I 87120 would recover the previous CAN data when the new CAN message is received Therefore users would lose the CAN data if they dont read back the data and the new one is coming The advantage is that users can always get the newest CAN message Return CAN87K OK CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 14 3 4 GetlI87KCANConfig Description Use this function to get the Ack and BufferSize parameters stored in the I 87120 Syntax int Getl87KCANConfig unsigned char Ack unsigned char BufferSize Parameters Ack The pointer for obtaining the Ack parameter stored in the l 87120 For more information about the Ack parameter please refer to the section 3 3 BufferSize The pointer for obtaining the BufferSize parameter stored in the 87120 About the information of BufferSize parameter please refer to the sect
33. annel is not connected CAN baud rate is different to the CAN network CAN network terminal resister is not equipped properly CAN network span distance is too long Host commands are too much to process CAN channel is not connected CAN network terminal resister is not equipped properly CAN baud rate is different to the CAN network CAN network terminal resister is not equipped properly CAN8 K_PARATERS_ERROR Check if any huge current or huge voltage Tess a0 ele CAN8 K_CAN REG ERROR Check if any huge current or huge voltage SS Mess he LETRO ma I 87120 user manual ver 2 30 Jul 23 2008 88 If the I 87120 Err LED is turned on uses can use function GetStatus to check what is happen on the I 87120 The troubleshooting methods and return value meanings of the function GetStatus is shown as follows Error Status Troubleshooting Bus off Reset the I 87120 module by using the function Resetl87KCAN At least one error These errors are occurred by different problems in the CAN network This kind of errors may disappear after receiving or transmit several CAN message successfully If users want to clean this error status immediately call the function ResetlIB7KCAN for the purpose Transmit This problem may due to the different CAN baud incomplete between I 87120 and CAN network Use functions GetCANBaud and SetCANBaud to fix this problem Transmit buffer is T
34. b Fie Edt few Favorites Back e F Toos Help File and Folder Tasks EN Make a neu Feller GD Publeh this folder to He Wei Ka Shara this Folder rrr rrr re eee eee 80006 lib Ci Inline File EE 128 KB Step4 Open your c file with Notepad Confirm the 8000 h and I87KCAN h path in the include syntax They are shown below include 8000 h include I87KCAN h E RecC AN ec Notepad E mfx d typedef struc unsigned char Mode unsigned char RTR unsigned char DataLen unsigned char Data 8 unsigned long ID rPacketsStruct void mainf void d unsigned Char CANRegS tatus OverFlowStatus O1LdCANRegSstatus 6 01d0verFlowstatus 6 int Ret SlotWo i PacketStruct Rxtisg ffInitiate host I 87120 user manual ver 2 30 Jul 23 2008 32 DICH 5 a Ue P o c os Fi Ke pru O O E Q pens a ZOE S x SC 5 A O e H p E Q F C O Cc Z Z S C b _ C Step7 Click Add function on the bottom of TC 1 01 window Search all c file by setting c MyDemo c in the Name field of popup window Then use the Add button to add the c file in to MyDemo project Then change the search command from c MyDemo c to c MyDemo lib in the Name field Add the library files C87H103L lib and 8000E lib into MyDemo project by the same way I 87120 user manual
35. ck unsigned char BufferSize Parameters CANBaud Set this parameter to configure the I 87120 CAN baud rate For example use the value 250000L to set the CAN baud rate to 250K bps The letter L means long integer format for the value 250000 BTO BT1 If the CANBaud parameter is set to 0 the BTO and BT1 will be used for configuring the I 87120 baud rate This case will be applied if users want to define a special CAN baud rate For more information about how to set the BTO and BT1 value please refer to the SJA1000 CAN controller datasheet Users can find it on the following website http www semiconductors philips com CAN AccCode CAN_Mask Set this parameter for CAN message filter The using method is the same with the AccCode and AccMask parameters of function SetCANMask Therefore please refer to the section 3 7 to know about the CAN message filter configuration I 87120 user manual ver 2 30 Jul 23 2008 24 Ack This parameter is used for setting the host command acknowledge Status If this parameter is set to 1 the I 87120 would not send the acknowledge message after receiving a host command Therefore users function would not hang because of waiting the acknowledge message In some application case it may reduce the communication time BufferSize Setting this parameter to 1 would disable the CAN software buffer functionality This means that the l 87120 would have no buffer to store the CAN message In th
36. dress WE Ftp root root 192 168 0 100 e El co Links gt VS Cer Bi VK E OFM services Il E Step8 Copy the file into the IE window of LinCon FTP site BEE Fie Edit wiew Favorites Tools Help ae e A3 O Back ey a i Search Keme 2 compile bet Fal I MS DOS Batch File 1 KB Fie Edit wiew Favorites Tools Help e Back e User4pp c Source 3 KB 5 0 A E E Ofmdeck illo OF riexck dFminfo ggcamrc FIP Properties General UserApp exe Type Application Location Fkp frook roob 192 166 0 100 User4pp exe Size 189 KB 194 026 bytes Modified 2005 F1i27A58 FF 02 59 Permissions Read Write Execute DNE Group All Users Step10 Key the telnet 192 168 0 100 in the path Start Run The 192 168 0 100 is LinCon IP address Type the name of a program folder document or Internet resource and Windows will open it For you NHNHN NHHHH_ NNNNN L JHHHHHH MMNP 4F MN MNL lt HHU 4HHH HH HHH 4F4F dl NN gt NN JN AHH HHH gt dk Bb HH CNN MN HH HN4H gt HHL NH NH_HHH gt MN HN NN NN MNNL du JMNNNNNF CNN JNF MNA MN 4NHH gt H gt lt NH NN dk JNN JNNNNNNN gt dE NNNL JNA CMN NNL_NNNN JNF HM HL_NNH gt H gt NNNNF lt NF NNNNN CNN NN NNNNF F LinGon 6668 series Linux embedded controller dincon 868HH login root SSWoOrRdd Step11
37. e files cnet Step13 Select the Library files in the Show directories field and set the library directory as follows After finishing the Step12 and Step13 click OK button to save the parameter settings Options Tabs Debug Compatibility Download Build Directories So Platform CPUs Show directories SA l Win32 WCE ARMY4 Cibrary files Library files Cancel I 87120 user manual ver 2 30 Jul 23 2008 44 Step14 Program users application and design the dialog screen in EVC environment When program the cpp program user need to include the uartce h WinconSDK h and I87KCAN h The include syntaxes are shown below ZZ MyDemoDlg cpp ff gt implement include lt WinconSDK h gt include lt UARTCE h gt include I87KCAN h Hinclude stdafx h fHinclude MyDemo h tT de Wb Hinclude lt WinconsDK bz Hinclude lt UARTCE h gt Hinclude I8 7KCAN h fifdef DEBUG fidefine new DEBUG HEN under THIS FILE Step15 For add WinconSDK lib and UartCe lib users must go to Project gt Settings gt Link and type WinconSDK lib and UartCe lib in Object library modules as follow Project Sethngs KE settings For General Debug uer Link Resources ke ya Win32 CE ARMY 4l Release E Category General N Output file name El MyDemo Microsoft eMbedded Vial C ARMY 4 RelfMyD
38. e parameter Data below The maximum value is 8 Data This parameter needs a pointer to point an array which is used to stored the CAN message data Because the maximum data numbers of one CAN message is 8 bytes it is recommend that the array Datal size is 8 bytes Return CAN87K_OK CAN87K_PARATERS_ ERROR CAN87K_FIFO_EMPTY CAN87K_TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 26 3 14 SendCANMsg Description If users want to send a CAN message by I 87120 module use this function to transmit the CAN message Syntax int SendCANMsg unsigned char Mode unsigned long MsgID unsigned char RTR unsigned char DataLen unsigned char Data Parameters Mode The parameter Mode is used set the transmitting CAN message specification If the CAN message is CAN 2 0A specification the Mode value is 0 If it is CAN 2 0B specification the value is 1 MsgID The parameter ID is used to set the attribution ID of a CAN message If the transmitting CAN message is for specification 2 0A the ID value range is from 0x0 to Ox3FF If the CAN message is for specification 2 0B the ID value range is from 0x0 to Ox1FFFFFFF RTR Use this parameter to set the RTR status of the transmitting CAN message The RTR value is 0 if the CAN message is normal CAN frame If it is 1 the CAN message is remote transmit request CAN frame DataLen The DataLen indicates how many data will be transmitted in the array Data see the
39. emo Demo 1 command in the LinCon 8000 Environment window to enter the folder path C MyDemo Demo 1 Then key the compile UserApp under the hint C MyDemo Demo1 gt The letters UserApp are user s program name without auxiliary file name If there is no error and warning during the compile procedure the Compile OK will be shown in the LinCon 8000 Environment window es LinCon 8000 Build Environment SS LinGon 8666 SDK Environment Configure ICPDAS LinCon HBH CArm based Mork Directory C Cyquin LinContk Coscyquin LinGondhecd AyDemo Demol C2 Aafoeno Nemol compile UserAapp ompile okt C2 iyveno Demol gt I 87120 user manual ver 2 30 Jul 23 2008 56 Step6 After finishing the compiling the execution file UserApp exe is produced in the Demo folder sit Fie Edit View Favorites Tools Help Ei A3 Fi Search compile bat MG DOS Batch File 1 KG User pp c Source 3 KE Step7 Open the IE window and input the URL ftp root root 192 168 0 100 to download the file into LinCon by using FTP The first root is the user name of LinCon FIP server and the second root is the password of LinCon FTP server The letters 192 168 0 100 are the LinCon IP address ICPDAS Microsoft Internet Explorer File Edit wiew Favorites Tools Help i 3 k k iy 7 j O Back B Le A Search Et Favorites Ad
40. emo exe emm File Edit View Insert Project Build Tq k Window Help Object Oe an e SS ff Wi SDK lib UartCe lib i GER ML gad To Pe Generate debug info l Ign M Generate mapfile MyDemo M PAC Workspace My SS MyDemo file Project Options fnologo fbase 0x00010000 star fentry w inMainCRTStartup fin Sy Source Fi ipdb ARMY4IRel MyDemo pdb ve Cancel Step16 When finishing the program select the project configuration to Win32 WCE ARMV4 Release and click Build Rebuild All to build an execution file Build Koos Window Help ste Compie DEMO ALLDecpp ChltF Build DEMO ALL exe F ml Rebuild All I 87120 user manual ver 2 30 Jul 23 2008 45 Step17 Use ftp method to copy the execution file and necessary dll file into WinCon series MCU First Open the IE internet explorer and key the ftp 192 168 0 115 and press Enter key in the Address filed The 192 168 0 115 is your WinCon s IP address Le ZA ICPDAS Microsoft Internet Explorer Sele File Edit View Favorites Tools Help ae CH Back nl E S e Search r Favorites 4 ge Address CH Ger e Ga SE el Go Links W Wm F gt Step18 After connecting to the WinCon series MCU drag and drop the execution MyDemo exe and I8 KCAN dll file into the IE window Users can find the MyDemo exe in the C MyDemo ARMV4Rel folder The I8
41. er to the section 3 I 87120 user manual ver 2 30 Jul 23 2008 10 3 l 87120 Host Function Library 3 1 Function List In order to use the I 87120 more easily the 87120 function library used in host side is provided There are several function libraries for different compiler such as BC TC MSC l 8000 series EVC WinCon 8000 and WinPAC 8000 and GCC LinCon 8000 Users can use these functions to control the I 87120 by the functions The following table shows the all functions provided by the I 87120 library ClearStatus Clear the 87120 software buffer overflow status GetStatus Get the I 87120 software buffer or CAN status Resetl87KCAN Reset the 87120 module Initiate the I 87120 module Users need to set the I8S7KCANInit proper CAN and I 87120 configuration to the I 87120 GetCANMsg Obtain the CAN message received by the I 87120 sendCANMsg send a CAN message to the CAN network I 87120 user manual ver 2 30 Jul 23 2008 11 3 2 Programmable Flow Chart If users want to develop the program with I 87120 module the following procedure may be a good reference InstallCom0 ChangeToSlotc I87KCANInit Send CAN message No GetCANMsg lt SendCANMsg Yes l Ex t Program No RestoreCom0C I 87120 user manual ver 2 30 Jul 23 2008 12 Note1 If the host side is l 8000 series main control unit the functi
42. erDefCmdFunc unsigned int CmdLength char eer md Parameter CmdLength The length of user defined command received from the UserDefCmdFunc function UserCmd The user defined command received from the UserDefCmdFunc function Example If the command AS defined by users had been received some CAN message will be sent void UserDefCmdFunc unsigned int CmdLength char eer md char data 8 if CmdLength lt 2 return switch UserCmd 1 case A switch UserCmd 2 case D d data 0 Oxff senCANdMsg 0 0x601 0 1 data break break I 87120 user manual ver 2 30 Jul 23 2008 63 5 4 UserDefBinaryFunc Description If users want to define some user defined binary commands in l 87120 this function would be useful Be attention that all user defined binary commands defined in this function must have a fixed header character and two bytes binary data length for example 10300112233 The is the binary header and the 0300 is means there are three bytes data to send 03 is LSB and 00 is HSB and the 112233 is the three bytes data Syntax void UserDefBinaryFunc unsigned int CmdLength char User md Parameter CmdLength The length of user defined binary command received from the UserDefBinaryFunc function The CmdLength includes to the least byte data User md The user defined command received from the from UserDefBinaryFunc function Example If
43. ers please refer to the section 3 7 Return CAN87K_OK CAN87K_PARATERS_ ERROR CAN87K_TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 20 3 9 ClearStatus Description This function is used for cleaning the CAN and host command software buffer overflow error flag When the CAN message software buffer or host command software buffer is full the CAN or host command buffer overflow error flag will be set to 1 In this case users need to use this function to clear the error flag to acknowledge the error information Syntax int ClearStatus void Parameters None Return CAN87K OK CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 21 3 10 GetStatus Description Read the I 87120 CAN controller status and software buffer error flag message Syntax int GetStatus unsigned char CANReg unsigned char OverflowFlag Parameters CANReg The pointer for obtain the I 87120 current CAN controller status For the information about the CANReg value meaning please refer to the following table Eror status 1 for atleast one error OforOK 5 Transmit status 1 for transmitting O forides 4 Receive status 1 for receiving Oforidies 38 Transmit complete status 1 for complete O for incomplete 2 Transmit buffer status 1 for released O for locked Data overrun status 1 for reception buffer overrun O for OK Receive buffer status 1 for at least
44. his problem may due to the different CAN baud locked between I 87120 and CAN network Use functions GetCANBaud and SetCANBaud to fix this problem Reception buffer When the CAN bus loading is heavy this problem mab overrun be happen In this case the received CAN messages will be lost Reducing the bus loading will improve this situation CAN message This problem is caused by that the host unit can t buffer overflow receive the CAN message in time Use functions ClearStatus to clean this error flag host command When the I 87120 is too busy to process the host buffer overflow commands this problem is happen Use functions ClearStatus to clean this error flag If users cant fix the problem after following the steps of the troubleshooting table please contact to your local distributor to fix the problem I 87120 user manual ver 2 30 Jul 23 2008 89
45. ion 3 3 Return CAN8 7K_OK CAN8 7K_PARATERS_ ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 15 3 5 SetCANBaud Description Call this function to set the I 87120 CAN baud rate Syntax int SetCANBaud unsigned long Baud unsigned char BTO unsigned char BT1 Parameters Baud I 87120 slot module has several predefine CAN baud rates Use this parameter to decide what kind of baud rate users want to use Here twelve kinds of baud rates are supported They are 5K 10K 20K 25K 50K 100K 125K 200K 250K 500K 800K and 1000K bps For example set the Baud value to 250000L to set I 87120 CAN baud to 250K bps The letter L means that the value 250000 is the long integer format If users can t find out the proper CAN baud rate for their application the user defined baud rate functionality may be needed The parameters BTO and BI1 are specially used for setting the user defined baud rate When users call the function SetCANBaud without using the Baud value listed above the Baud value is useless and the parameters BTO and BT1 would be applied for user defined CAN baud rate BTO BI1 These parameters are useful for user defined CAN baud rate The values of BTO and BT1 need to be calculated according to the SJA1000 CAN controller datasheet For more information about how to calculate the CAN baud please refer to the following web site http www semiconductors philips com Retu
46. is case the I 87120 would recover the previous CAN data when the new CAN message is received Therefore users would lose the CAN data if they dont read back the data and the new one is coming The advantage is that users can always get the newest CAN message Return CAN87K OK CAN87K PARATERS ERROR CAN87K CAN REG ERROR CAN87K_INIT_ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 25 3 13 GetCANMsg Description If the CAN message is received by I 87120 module use this function to read back the CAN messages Syntax int GetCANMsg unsigned char Mode unsigned long MsgID unsigned char RTR unsigned char DataLen unsigned char Data Parameters Mode The parameter Mode is used to point out the CAN message specification If the CAN message is CAN 2 0A specification the Mode value is given to 0 If it is CAN 2 0B specification the value is 1 MsgID The parameter ID is used to point to the attribution ID of a CAN message If the I 87120 receive a CAN message with specification 2 0A the ID value range is from Ox0 to Ox3FF If CAN message is 2 0B the ID value range is from 0x0 to Ox1FFFFFFF RTR This parameter is used to get the RTR status of a CAN message The RTR value is 0 if the CAN message is normal CAN frame If it is 1 the CAN message is remote transmit request CAN frame DataLen The DataLen is point to the value indicates how many data stored in the array Datal see th
47. l the parameters and function description of these functions are similar as those of the functions used in host side 5 6 1 IS7KCANConfig Description Use this function to configure CAN chip If users have called the CAN Reset function to reset CAN chip users must to use I87 KCANConfig function to configure CAN chip Syntax int I87 KCANConfig void Parameters None Return CAN_NoError CAN_ResetError CAN_ConfigError I 87120 user manual ver 2 30 Jul 23 2008 66 5 6 2 CAN Reset Description Use this function to reset CAN chip If users still want to use 87120 after calling CAN Reset function the function I87KCANConfig must be used Syntax void CAN _ Reset void Parameters None Return None I 87120 user manual ver 2 30 Jul 23 2008 67 5 6 3 SetCANBaud Description Call this function to set the I 87120 CAN baud rate Syntax int SsetCANBaud unsigned long Baud unsigned char BTO unsigned char BT 1 Parameters Baud I 87120 slot module has several predefine CAN baud rates Use this parameter to decide what kind of baud rate users want to use Here twelve kinds of baud rates are supported They are 5K 10K 20K 25K 50K 100K 125K 200K 250K 500K 800K and 1000K bps For example set the Baud value to 250000L to set I 87120 CAN baud to 250K bps The letter L means that the value 250000 is the long integer format If users can t find out the proper CA
48. low the hint command to press AIt E and input the file name MyDemo exe to download the execution file Then press Enter to continue Delt Hegin Key Thread ICurrent set Use COM NN KAZEN NI d AutoRun co_87k29 exe Autodown load tiles Hone C827 CS KCARS gt load File will save to 8HHH HE StartAddr 70HH0 FFFF Press ALT_E to download filet Input filename MyDemo exe I 87120 user manual ver 2 30 Jul 23 2008 86 Step17 After finishing the download procedure key in the command run to implement the execution file MyDemo exe 71884 W 1 26 COM1 115200 48 3 1 FC 0 C 15 1 DIRS AMyDemo Begin Key Thread 1 RR CB KCAND gt load File will save to 8000 0006 StartAddr gt 7HH0 FFFF Press ALT_E to download filet Input filename NyDemo exe Load file AyDemo exe cre 945D 6668 Send file info total 581 blocks Block 5S 1 Transfer time is 18 763000 seconds C627 C8 KCAAD gt run ee I 87120 user manual ver 2 30 Jul 23 2008 87 7 Troubleshooting When users call the I87KCAN library functions the error code may return if some occurs This section will give some basic diagnostic methods for reference CAN8 K_TIMEOUT CAN87K_ FIFO EMPTY CAN8 K_FIFO_FULL CAN87K_INIT ERROR Check if any huge current or huge voltage bypasses the I 87120 module Reset the 87120 module and try it again No CAN message is received CAN ch
49. ock Philip 82C250 CAN transceiver Power LED Tx Rx LED Error LED 120 terminal resister selected by jumper CAN bus interface ISO 11898 2 5 pin screw terminal with on board optical isolator protection 2500 Vrms isolation on CAN side Power Consumption 2W Operating Temperature 25 C to 75 C Storage Temperature 30 C to 85 C Humidity 5 95 1 3 Features Common Features One CAN port expansion for l 8000 series WinCon 8000 LinCon 8000 and WinPAC 8000 PACs 4096 records CAN message receive buffer size 4096 records buffer size for the command from 8000 WinCon 8000 LinCon 8000 WinPAC 8000 to I 87120 Provide C C function libraries to send and receive CAN messages Demos and utility are provided 3 indication LEDs Rx Tx and Err LEDs CAN Port Features Support user defined baud 2500 Vrms isolation Baud 5Kbps 10Kbps 20Kbps 25Kbps 50Kbps 100Kbps 125Kbps 200Kbps 250Kbps 500Kbps 800Kbps 1Mbps I 87120 user manual ver 2 30 Jul 23 2008 5 2 Hardware Specification 2 1 Hardware Structure Tx Rx LED Err LED PWR Tx Rx ERF i 87120 NA t CAN H CAN_SHLD CAN L NA I 87120 user manual ver 2 30 Jul 23 2008 6 2 2 Wire Connection In order to minimize the reflection effects on the CAN bus line the CAN bus line has to be terminated at both ends by two terminal resistances as in the following figure According to the ISO
50. on InstallCom0 is used here If the host side is WinCon 8000 LinCon 8000 or WinPAC 8000 the function Open Com is used Note2 If the host side is l 8000 series main control unit the function ChangeToSlot is used here If the host side is WinCon 8000 or WinPAC 8000 the function ChangeSlotlo8 K is used In LinCon 8000 host side the function Open Gott is needed Note3 If the host side is l 8000 series main control unit the function RestoreCom0O is used here If the host side is WinCon 8000 LinCon 8000 or WinPAC 8000 the function Close Com is used Take the l 8000 series main control unit for example Before users use the l 87120 functions the function InstallCom0 and ChangeToSlot must be used first The function Change ToSlot is used to define which l 87K series slot module users want to operate now For example if users want to use the l 87120 module plugged in the slot 0 the code is shown as follows Change ToSlot 0 Afterwards users need to initiate the 87120 module by using the function IS7KCANInit Then users can use I87KCAN Ilib arbitrarily Before users close their application program don t forget to use the function RestoreCom0 to recover the COM port setting I 87120 user manual ver 2 30 Jul 23 2008 13 3 3 I87KCANConfig Description Use this function to set the I 87120 configuration Syntax int I87 KCANConfig unsigned char Ack unsigned char BufferSize Par
51. parameter Data below The maximum value of DataLen is 8 Data This parameter needs a pointer to point an array This array include the date which would be transmitted to the CAN network Because the maximum data numbers of a CAN frame is 8 bytes more than 8 bytes data in the array Daaf will be ignored Return CAN8 7K_OK CAN87K_PARATERS_ ERROR CAN87K FIFO FULL CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 27 3 15 Function Return Error Code The following table displays the function return error codes which may return from the functions provided by I87KCAN library CAN8 K_TIMEOUT 21 No message response before TTT ewe e CAN8 K_FIFO_EMPTY 22 The software buffer which stores Wee eeng CAN8 K_FIFO_ FULL 23 The software buffer which stores TT Teen CAN87K CAN REG ERROR Set CAN controller register failure I 87120 user manual ver 2 30 Jul 23 2008 28 4 Demo Programs The following architecture is the demos and libraries positions in the path CAN SlotModule _ 87120 in CAN CD manual FirmwareLib DefFirm Library Demos l 8000 87CANLib MCU_Lib Download_ Tool MCU_OS Demos BCPP31 TCPP101 MSC6 WinCE EVC WinCon 87CANLib SendMsg RecMsg Demo_ALL WinPAC 87CANLib SendMsg RecMsg Demo_ALL Linux GCC 87CANLib SendMsg RecMsg gt Users manual gt
52. r item MyDemo SA_IA Win32 WCE iis Workspace MyDemo 1 project s id Demo files SH Files to Folder A Settings My iH Ste 3 Head SI My jy Docking View E My Hide Sing B De E Sr Properties E Std fx h Resource Files 2 ReadMe tt av Add to Source Control 5 ResourceViev4 FileView 1 ClassView Step10 In the popup dialog select Library Files lib in the Files of type filed Select the I87KCAN lib library files and then click OK button to add the library file into MyDemo project After finishing the Step the tree view of File View is shown below Insert Files into Project EK ajx Lookin E MyDemo EQ 4RMYV4IDbz Ba an ee AT E a rata EQ ARMV4lRel KS ST E SSES cpp 4 MyDemo rc Ea oi cpp IB dree h BA MwNemoalla h Files will be inserted into folder titled Source Files in project h Step11 Click the Tools Options to set the include and library directory Visual C Source Browser Ak F1 fs Remote Spy Fi Remote System Information A Remote Zoomin 43 Step12 Click Directories tab and select Include files in the Show directories field Set the directories as follows Options Tabs Debug Compatibility Download Build Directories So CPUs Show directories Platform CISA IA EC Wwin32 WCE ARMY4 includ
53. respectively Then click OK to save the configuration IC EXE Sg 5 Window elp Optimizations Source Messages Hames EEN a Ce Large ga Point cou Convention Instruction Set DFT Help Help E Debug info in OBJs I 87120 user manual ver 2 30 Jul 23 2008 82 Step9 Click the Option Debugger to set the Source Debugging parameter Here select None for this parameter setting o TC EXE Ej x File Edit Search Run Compile Debu HD Window Help Full menus Compiler Transfer e ram ae Size bytes OS Ge ector options Step10 Click the Option Directories to set the Output Directory parameter Here set the C MyDemo for the Output Directory parameter c TC _EZE BE x File Edit Search Run Compile P Window Help EE Full menus On S EE SS E k SE Transfer Hake SS Linker Sees ey L SS WOO E SS Environment 8 SE nelude Directories oN Directories C2 SAY DEMO ibrar I 87120 user manual ver 2 30 Jul 23 2008 83 Step13 Copy the file 7188xw exe and 188xw ini files into the MyDemo folder These two files can be found in CAN product CD Their path is CAN SlotModule l_ 87120 FirmwareLib Download_ Tool Se MyDemo KL el x File Edit View Favorites Ir ae Bak J i m i MOO wc
54. rn CAN87K OK CAN87K CAN REG ERROR CAN87K PARATERS ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 16 3 6 GetCANBaud Description Call this function to get the CAN baud used by the I 87120 Syntax int GetCANBaud unsigned long Baud unsigned char BIO unsigned char BT1 Parameters Baud The pointer for obtaining the CAN baud rate If users use the predefine baud rate the function GetCANBaud would return the CAN baud rate used by I 87120 If the return value of Baud is 0 it means that the I 87120 use user defined CAN baud In this case the CAN baud rate would be indicated by using the parameters BTO and BT 1 BTO BT1 The pointer for obtaining the user defined CAN baud used by 87120 Return CAN8 7K_OK CAN8 7K_PARATERS_ ERROR CAN87K TIMEOUT I 87120 user manual ver 2 30 Jul 23 2008 17 3 7 SetCANMask Description Use this function to set the I 87120 parameters Syntax int SetCANMask unsigned long AccCode unsigned long AccMask Parameters AccCode AccMask The AccCode is used for deciding what kind of ID the CAN controller would accept The AccMask is used for deciding which bit of ID would need to check with AccCode If the bit of AccMask is set to 0 it means that the bit in the same position of ID needs to be checked and that ID bit value needs to match the bit of AccCode in the same position The following table shows each situation of
55. s of interrupt register of CAN bus Bite Arbitration Lost interrupt mz Error Passive Interrupt Bita Wake Up interrupt Bit Data Overrun eng az Error Warning Interupt a Transmit interupt Bito Receive interrupt Example When 87120 receive transmit a CAN message the screen would show Receive Transmit a CAN message information void UserlrqFunc char INTT if INTT amp 0x01 Print Receive a CAN message r n If INTT amp 0x02 Print Transmit a CAN message nl I 87120 user manual ver 2 30 Jul 23 2008 61 5 2 UserlnitFunc Description If some functionalities or parameters of users programs need to be initialized during the system boot up users can initialize these functionalities or parameters in this function Be attention that this function will be only called once after the I 87120 is turned on Syntax void UserlInitFunc void Parameter None Example Two parameters TxCount and RxCount are global variables Users need to initialize them after the I 87120 is turned on void UserlnitFunc void TxCount 0 RxCount 0 I 87120 user manual ver 2 30 Jul 23 2008 62 5 3 UserDefCmdFunc Description If users want to define some user defined commands in l 87120 this function would be useful Be attention that all user defined commands defined in this function must have a fixed header character _ for example AO Syntax void Us
56. the command 02000100 defined by users has been received then some thing would be do void UserDefBinaryFunc unsigned int CmdLength char UserCmd unsigned int length comm if CmdLength lt 3 return length UserCmd 2 256 UserCmd 1 if length 2 comm UserCmd 4 256 UserCmd 3 switch comm case 1 II do something break I 87120 user manual ver 2 30 Jul 23 2008 64 5 5 UserLoopFunc Description This function will be called in a loop after the I 87120 had been configured If there are some functionalities or parameters of users programs need to be executed in the loop this function will be used Please note that insert the function RefreshnWDT in UserLoopFunc if the content of UserLoopFunc is too large Syntax void UserLoopFunc void Parameter None Example This loop function is always called to check if a CAN message is received or not When a CAN message have been received the CAN message data will be printed on the screen void UserLoopFunc void int Ret unsigned char Mode RTR DataLen Data 8 unsigned long ID Ret GetCANMsg amp Mode amp ID amp RTR amp DataLen Data if Ret for i 0 i lt DataLen i Print Y x Datali Print r n I 87120 user manual ver 2 30 Jul 23 2008 65 5 6 Others support functions for I 87120 firmware The following functions are used for user defined firmware of I 87120 Al
57. tories field and set the library directory as follows After finishing the Step12 and Step13 click OK button to save the parameter settings Options KE Tabs Debug Compatibility Download Bui 7 Directories oo Plattorm CPUs Show directories Win32 WCE AHMVAU _ A Library files l AE T CAProgram Files Windows CE Tools wce500 PAC2 7 Ob ARMY AI CAProgram Files Windows CE Tools wce500 PAC2 O0 micilibARMyY4l C Program Files rindows CE Toolstwce500 PAC2 D atlhlibARMYA4l l Step14 Program users application and design the dialog screen in EVC environment When program the cpp program user need to include the uartce h WinconSDK h and I8ZKCAN h The include syntaxes are shown below ZZ MyDemoDlg cpp ff gt implement include lt WinconSDK h gt include lt UARTCE h gt include I87KCAN h Hinclude stdafx h Hinclude MyDemo h LLsgtfde Wen Hinclude ZCHinconsbk bz Hinclude lt UARTCE h gt Hinclude I87KCAN h fifdef DEBUG fidefine new DEBUG HEN under THIS FILE I 87120 user manual ver 2 30 Jul 23 2008 52 Step15 For adding WinconSDK lib and UartCe lib users must type WinconSDK lib and UartCe lib in Object library modules item of Project Settings Link tab as follows Project Settings R oe Settings For General Debug C C C ink 7 De NES M NI Win32 CE ARMY4I Release
58. ured Step4 Run the TC 1 01 development environment Click the Options Full menus to expand the all functions list in the menus Compiler Tr ansfer 5 a i b See E qger Environment I 87120 user manual ver 2 30 Jul 23 2008 80 Step5 Click the Project Open project to create a new project Input the project name MyDemo PRuJ and click OK button to continue TC EXE File Edit Search Run Compile Options Window Hel eg TT eege E al Ip Ta RES Ee E Beginn a Add item Delete item Local options Include files Step6 Click Add function on the bottom of TC 1 01 window Search all c file by setting c MyDemo c in the Name field of popup window Then use the Add button to add the users c file in to MyDemo project Then change the search command from c MyDemo c to c MyDemo lib in the Name field Add the library files C87S10 7 lib and C829L lib into MyDemo project by the same way Step After finishing the Step6 the TC 1 01 window will look like as follows Search Run Compile Deh ES Project MYDEMO Fi Help Ins Add Del Delete Oo Options Space Includes 4 Edit Fifi Menu Step8 Click the Options Compiler Code generation to set the compiler model to the large mode Afterwards click More to set the Floating point and Instruction Set parameters the Emulation and 80186 item will be used
59. vex Control Vvizard Location CE MFC AppWizard exe Ower El OWin32 WCE ARMYAT OWin32 WCE MIPS16 CWin32 WCE MIPSII OWin32 WCE MIPSII_FP Con cen Step6 Select Dialog based item for this demo Choose the language which you want to see in your resources file Here English United States item is used Click Finish button to finish the project creation WCE MFC AppWizard exe Step 1 of 4 What type of application would you like to create C Single document Dialog based e What language would you like your resources in English United States ceappwzenu dlihd I 87120 user manual ver 2 30 Jul 23 2008 49 Step7 Copy the I 87120 library files IB7KCAN h and I87KCAN_PAC lib into the MyDemo folder in disk C Ei Fo 3 AUS Oh Se ver 110 File and Folder Tasks KH Make a new Polder z Publish this folder to In D IBTKCANH the Wab h Chil Hasta ihj Resource h ISTEICAM PAC Eb wal SM ALx cpp W Ch Inine Fis h Sd fxh Other Places J 4 KB LF Edit View Insert Project Build Tools Window Help ashla 2 nae Dh ep EK L Mal ie emoApl Siwe Myc emos Api i Step9 Select File View tag and expand the tree view Right click the Source Files folder icon and click Add Files to Folder item MyDemo _ PAC270 Win32 WC EE iG Workspace SEET 1 project s
Download Pdf Manuals
Related Search
Related Contents
Sony XS-R1343 Operating Instructions User Guide 5.1 2013 Final Fiche Technique V.A.C. Freedom PDF scan to USB stick Copyright © All rights reserved.
Failed to retrieve file