Home
Manual: Ethernet CAN Interface
Contents
1. p see above on products where more than one CAN chan should then also be used nel is available k keep alive The connection will be running using a keep EMS Dr Thomas W nsche 5 6 EMS Dr Thomas W nsche User Manual EtherCAN Cl User Manual alive mechanism that reestablishes broken connections Please notice In order for the keep alive me chanism to run properly both applications server and client have to be started with the K option For debugging purposes the following options can be used For performance reasons it is not recommended to use them in production sys tems t show tcp frames Show TCP frames on the serial terminal c show cpc frames Show CPC messages on the serial terminal Server mode If option i is not given EtherCAN will start in servermode and listen on lt PORT gt for inco ming connections If options b or f are given a baudrate set ting via TCP IP will be ignored Client mode back to back operation only If option i is given the CAN server will start in client mode It will try to open a connection to lt IPADDRESS gt and lt PORT gt of the server A baudrate option with b or f is mandatory If option f is given and there is a baudrate configured within this file it will not override lt BAUDRATE gt given by the b option If option k is set a keep alive mechanism will reestablish a broken connection
2. Ethernet CAN Interface EtherCAN Cl User Manual Sonnenhang 3 E D 85304 llmm nster Tel 49 8441 490260 THOMAS WUNSCHE Fax 49 8441 81860 EtherCAN Cl User Manual Documentation for Ethernet CAN interface EtherCAN Cl version 2 1 Document version V3 0 Documentation date June 16th 2007 This documentation is not valid for EtherCAN Cl version 2 0 and earlier versions No part of this document or the software described herein may be reproduced in any form without prior written agreement from EMS Dr Thomas W nsche For technical assistance please contact EMS Dr Thomas Wunsche Sonnenhang 3 D 85304 Ilmmunster Tel 49 8441 490260 Fax 49 8441 81860 Email support ems wuensche com Our products are continuously improved Due to this fact specifications may be changed at any time and without announcement WARNING EtherCAN Cl hardware and software may not be used in applications where damage to life health or private property may result from failures in or caused by these compo nents ii EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual Content 5 3 2 Device Configuration 23 5 3 3 CAN Server Startup Configuration 24 1 Overview 2 eee ooo 1 5 3 4 Default Configuration upon Delivery 24 1 1 Attributes 2 0 2 000084 1 5 3 5 Sample cansrv cansrv_udp Configuration File 1 2 General Description ii ete hn Bm AAA 25 1
3. The cansrv program uses the status LEDs as described here On means cansrv program is started Off means cansrv is not started or has cor rectly terminated Blinking means cansrv ethernet communica tion is in state of connecting or listening On means ethernet communication link is established On means CAN controller state is bus on Off means CAN controller state is bus off Examples cansrv p 1500 This will start cansrv as a server listening on port 1500 This is the default setting As no baudrate is specified at the command line the server will initialize its CAN controller with the parameters sent by the client cansrv p 1500 i 192 168 0 176 k b 500 This will start cansrv as a client which will try to connect to the host with IP address 192 168 0 176 on port 1500 The client will use a baudrate of 500 kBaud and will use the keep alive mechanism It will also advertise this baudrate to the client The client takes it if no b or f option is set 3 2 2 cansrv_udp The application cansrv_udp is intended to pro vide a point to point communication link with another EtherCAN Cl device It uses a UDP based protocol which offers better latency timing than TCP does The reliability of the messages is handled completely by the appli cation EMS Dr Thomas W nsche 7 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual Once it is started it li
4. 3 Sample Applications 2 1 4 Ordering Information 2 2 Hardware o core saosaoa e eee eee ee es 3 3 Software i o ce kee eee ee ee RHE RE 4 3 1 Built in Capabilities 4 3 2 Communication and General Software 4 3271 CANSIVS asker Bk ce cd eR Ye ae 4 3 2 2 cansrv_udp 8 3 2 3 Client Application 12 JLA MAd cee we ae a Re we RE 12 3 2 5 User Accessible Flash 12 LO WdOG i fo a he eh A ee OA a 14 327 AA 14 IL TOQUE o oz e AR ee 16 3 2 9 A 16 4 Electrical Characteristics 19 4 1 Absolute Limiting Values 19 4 2 Nominal Values 19 5 Operating Instructions 20 5 1 Connection Scheme 20 5 2 Installatioms sss e ap aea a a HB 21 5 3 Configuration s s se ma ses a dow aaa 22 5 3 1 General Configuration 22 EMS Dr Thomas W nsche iii iv EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual 1 Overview 1 1 Attributes EtherCAN Cl offers a range of features which make it valuable for many CAN based applica tions e Connection of CAN systems to Ethernet networks e Coupling of CAN networks over Ethernet e CAN interface for industrial applications e CiA DS 102 and ISO 11898 compatible physical layer e Microcontroller Winbond W90N740 32 Bit ARM7 80MHz with additional CAN controller NXP SJA1000 NXP PCA82C25
5. 1 10 entries Please use this with This deletes the USER_1 entry Please note extreme care because a foreground pro the quotation marks indicating an empty cess occupies the console input until it ter string minates 3 2 8 route The following command line options are avai lable If a default gateway is needed the route com mand can be used A USER_x entry is used r lt specifier gt for that purpose This reads out an entry detailed by lt speci fier gt Example w lt specifier gt lt value gt fltool w USER_2 route add default gw This sets an entry detailed by lt specifier gt to 192 168 1 1 lt value gt This will set the IP address 192 168 1 1 as the address for the default gateway e This erases all entries 3 2 9 led l The led application can be used to explicitly This lists all entries which have a value set the status LED on and off from the com mand line The command line options are Examples r lt register gt fltool w IP 192 168 1 94 This reads out the value of a LED register This will set the entry IP to 192 168 1 94 This Currently only register 0 is supported EMS Dr Thomas W nsche 15 16 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual w lt register gt lt value gt lt mask gt This sets the bit positions of lt register gt to lt va lue gt at which the bits of lt mask gt are 1 This scheme allows to modify a single LED without the need to know the s
6. 1 CAN transceiver e Galvanic decoupling between Ethernet and CAN bus Filtering and buffering of CAN traffic e Supports CAN protocols 2 0A and 2 0B e Serial interface for configuration Embedded Linux operating system 1 2 General Description The rail mountable Ethernet CAN interface EtherCAN Cl transmits signals between a CAN system and an Ethernet network Utilizing the Ethernet standard EtherCAN is usable in a wide range of applications It can be used as a standard CAN interface in a LAN environment Or two EtherCAN devices wor king back to back can bridge two CAN net works over an Ethernet connection 1 3 Sample Applications The field of application for EtherCAN Cl is wide Some sample applications are detailed in the following and supported by correspon ding software e Online configuration of CAN networks e Network setup and analysis e Visualisation of process parameters in CAN based systems 1 4 Ordering Information 12 20 302 20 EtherCAN Cl ARM7 RMD Ethernet CAN interface with 32 bit microcontroller ARM7 core and CAN controller NXP SJA1000 12 20 305 20 EtherCAN CI ARM7 RMD M4D Ethernet CAN interface with 32 bit microcontroller ARM7 core CAN controller NXP SJA1000 and CANopen software M4D EMS Dr Thomas W nsche 1 2 EMS Dr Thomas W nsche EtherCAN Cl EtherCAN Cl User Manual Hardware EtherCAN Cl includes a Winbond W90N740 ARM core with 80MHz clo
7. Dr Thomas W nsche 11 12 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual Step 2 Step 3 Step 4 If the gzip utility is available it may now be compressed the file name changes to canconf gz The file is transferred with ftp to EtherCAN Cl using the binary trans fer mode If it is not yet compressed it must be done now gzip canconf The file is flashed using the flashw command flashw f canconf gz dev rom5 The cansrv or cansrv_udp may now use this file As both programs are able to read a gziped file they may be started with the option f dev rom5 Example 2 Store html file Step 1 Step 2 Step 3 Step 4 Some html files in one or more direc tories are assumed which shall be used on EtherCAN Cl On the host PC a cramfs image using the mkcramfs tool is created mkcramfs lt your_directory gt lt out put_filename gt The file is transferred with ftp to the EtherCAN Cl using the binary trans fer mode The file is flashed using the flashw command flashw f lt output_filena me gt dev rom5 3 2 6 wdog 3 2 7 fltool Step 5 This cramfs image can be mounted at boot time using a fltool USER_x en try fitool w USER_x mount t cramfs Idev rom5 mnt EtherCAN Cl incorporates a hardware watch dog It has to be triggered periodically by an application The most common applications cansrv and cansrv_udp
8. a tion link is established Status 3 On means CAN controller state is bus on Off means CAN controller state is bus off Example EtherCAN A with IP address 192 168 1 94 cansrv_udp i 192 168 1 95 b 500 EtherCAN B with IP address 192 168 1 95 cansrv_udp i 192 168 1 94 b 500 This will establish a connection between two EtherCAN Cl where unit A has the IP address 192 168 1 94 and unit B has the IP address 192 168 1 95 A baudrate of 500 kbaud is used on both sides 3 2 3 Client Application 3 2 4 m4d The client application monitor exe currently only runs on a PC with Windows OS Please refer to the manual for the monitor application which is available separately This client needs the cansrv program to be run on EtherCAN Cl The documentation for the CANopen software m4d is not included in this manual it can be obtained separately 3 2 5 User Accessible Flash There are 128kByte of flash memory reserved dev rom5 for the user to store application specific data It can be used to hold a configu ration file for the cansrv and cansrv_udp program It can also be used to be filled with html files if EtherCAN Cl is run as a CAN ba sed web server The usage of dev rom5 is very versatile To explain the usage two exam ples are given Example 1 cansrv configuration file Step 1 On a host PC a cansrv configuration file is created e canconf EMS
9. a PC or any other device supporting IP networking Server and client use an ASCII protocol when communicating via TCP or UDP This protocol is not included in this document but can be obtained on demand EtherCAN Cl is delivered with a monitor pro gram running under Windows OS as client ap plication The CAN server application cansrv is intended to provide a point to point communication link with a client over a TCP connection While the main purpose is the connection with a PC based client application cansrv can also be used in a back to back configuration with another EtherCAN CI device In this configura EMS Dr Thomas Wunsche 3 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual tion one device acts as a server and the other f config file CONFIGFILE as a client they form a transparent link for the Allows the use of a configuration file for CAN networks connected baudrate settings and identifier filtering A sample configuration file can be found in Once it is started as server it listens on a port 5 3 5 A baudrate given within CONFIGFILE for incoming connections After the connection cannot be changed dynamically by a connec is established the client is able to send and re ted client ceive CAN messages and to configure the CAN parameters of the remote CAN controller p port PORT The port to listen at for incoming connections The use of a configuration file allows to specify d
10. ck In addition the device has 16MB SDRAM and 2MB Flash The connection to the CAN bus is provided by a CAN controller of type NXP SJA1000 and supports the CAN protocols 2 0A and 2 0B EtherCAN Cl includes a CAN segment with two connectors of type D Sub 9 the pin as signment complies to CiA DS 102 standard Besides the CAN signals the connectors also carry the power supply for EtherCAN Cl EtherCAN Cl includes an Ethernet connector Twisted Pair 10 100MBit s and a serial con nector D Sub LED s Explanation of the different LED s on Ether CAN CAN Active this LED flickers in case of traffic on the CAN bus Eth Active this LED flickers in case of traffic on the Ethernet network Eth Link this LED is lit if another device was detected within the network There are three status LEDs on EtherCAN Cl usable by application software Currently cansrv cansrv_udp and led are using them Please refer to the related program documen tation for details 3 Software 3 1 Built in Capabilities an Embedded Linux operating system e a powerful TCP IP stack e a CAN server application e Watchdog functionality 3 2 Communication and General Software 3 2 1 cansrv The communication software normally consists of two parts One part is executed by the pro cessor inside EtherCAN Cl server applica tion The other part client application runs on a device connected to EtherCAN Cl via the Ethernet This device can be
11. de2 x00 accCode3 x00 accMask0 xff accMask1 xff accMask2 xff accMask3 xff mode 0 FARAH FILTER All Identifiers in this list are filtered Filter on CAN received messages both start and end value are included FIL x000 x7e5 EMS Dr Thomas W nsche 25 26 EMS Dr Thomas W nsche
12. ect connection using the PC s COM port See the communication parameters to use in the following image eN E Baud rate 57600 v Data fabi y Cancel Parity none y Stop fbit y Help Flow control none v Transmit delay jo msecjchar 0 msecjline EMS Dr Thomas W nsche 21 22 EMS Dr Thomas W nsche User Manual EtherCAN Cl User Manual Notice that the flow control parameter within the serial monitor running on the PC has to be turned off If this parameter can not be chan ged supplemental bridges between pins 4 6 and pins 7 8 have to be inserted in the PCs side connector of the serial cable described above Power on EtherCAN Cl On the terminal window the output from the startup procedure is displayed If the procedu re was successful a prompt that enables you to input commands is shown 5 3 2 Device Configuration EtherCAN Cl needs some parameters set cor rectly to take part in the Ethernet communica tion This parameters are the IP address the netmask and optional the hostname To set this parameters the fltool command is used fltool w IP 192 168 0 93 fltool w NETMASK 255 255 255 0 fltool w HOSTNAME ethcan1 To inquire this parameters the following may be used fltool r IP fltool r NETMASK fltool r HOSTNAME or fltool l 5 3 3 CAN Server Startup Configuration EtherCAN can be configured to start the CAN server application automatically at boot time T
13. efault is 1500 more detailed CAN controller register values and to configure a software filter for standard w trigger watchdog identifier CAN messages This option triggers the watchdog cyclicly If this option is not set an other application The following command line options are avai must trigger the watchdog lable for the CAN server application both short and long options are supported o busoff recovery time TIMEOUT This time specifies the period which is waited h help after a bus off event before the CAN controller Show the available options is reinitialized The time value is given in ms 0 indicates to immediately go bus on again As v version default the option is not set and this means ac Show the version information tually do not go bus on again b baudrate BAUDRATE To form a bridge for two independent CAN The CAN baudrate used networks two EtherCAN devices connected 1000 800 500 250 125 100 50 25 20 10 kBaud over their Ethernet interfaces can be used can be set with this option Please notice that one running as server the other as client In a baudrate specified with this option can not this case the following parameters can be be changed dynamically by a connected client used d device file DEVICE i ip address IPADDRESS The device default is dev can0 This option is IP address of the server the client wants to documented for completeness only It is used connect to The parameter
14. er supply EMS Dr Thomas Wunsche 19 20 EMS Dr Thomas W nsche EtherCAN Cl EtherCAN Cl User Manual The following table shows the assignment of the RS232 connector Pin Name Function 2 RxD Receiving data line 3 TxD Sending data line Data Set Ready line i Beh not supported at this time 5 GND Ground line 6 DTR Data Terminal Ready line not supported at this time Installation To setup and use EtherCAN Cl within a net work the following is needed APC running Windows 95 98 NT 2k XP or Linux connected to the Ethernet net work An Ethernet network with a free twisted pair connection for EtherCAN Cl e ADC power supply see chapter elec trical characteristics fed over the CAN connectors A terminal program connected to the RS232 port of EtherCAN Cl Since EtherCAN Cl supports Auto MDIX it is able to detect the cable type whether it is a cross over or a regular twisted pair Ethernet cable 5 3 Configuration 5 3 1 General Configuration To review or change the IP configuration EtherCAN Cl can be accessed by using a ter minal program connected to its RS232 port Connect a serial cable to the RS232 port of EtherCAN Cl Connect the other end to a free COM port of your PC Note The serial cable should have the pins 2 and 3 crossed and pins 5 connected directly Start the terminal software Configure the software for a dir
15. he different command line options are alrea dy detailed on page 4 and following Simply paste the command line into to the option command of the fltool Example fltool w USER_2 cansrv p 1500 b 500 This will start the CAN server application as server at boot time listening on port 1500 and using a fixed baudrate of 500 kBaud 5 3 4 Default Configuration upon Delivery In the default delivery of EtherCAN CI the fol lowing parameters are used IP 192 168 1 94 Netmask 255 255 255 0 Gateway none The above parameters can be changed through serial access to the console of Ether CAN The following user commands are also enab led USER_1 cansrv p 1500 w EMS Dr Thomas W nsche 23 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual 5 3 5 Sample cansrv cansrv_udp Configuration File FABRA EMS Dr Thomas Wuensche 2006 Configuration file for EtherCAN Cl FARAH RARA ARRRARAA4Aa CAN SJA1000 controller initialisation CAN controller runs with 16MHz 1000kBaud btrO x00 btr1 x14 500kBaud btrO x00 btr1 x1c 250kBaud btrO x01 btr1 x1c 125kBaud btrO x03 btr1 x1c 100kBaud btrO x04 btr1 x1c 50kBaud btrO x09 btr1 x1c 25kBaud btrO x18 btr1 x1c 10kBaud btrO x31 btr1 x1c accCode0 x00 accCode1 x00 accCo
16. o listen for incoming datagrams sample configuration file can be found in 5 3 5 If this option is not given the default value is The baudrate parameters btrO and btr1 given 1500 within this file are treated like it is described with option b e dest port PORT The port where the destination udpsrv has to x btr0 BTRO be listening at Set BTRO register explicitly If this option is not given the default value is 1500 y btr1 BTR1 Set BTR1 register explicitly i dest ip The IP address for outgoing datagrams e g r accept remote baudrate 172 0 1 2 If this option is set a baudrate given from the EMS Dr Thomas W nsche 9 10 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual remote side is always accepted As default this option is not set o busoff recovery time TIMEOUT This time specifies the period which is waited after a bus off event before the CAN controller is reinitialized The time value is given in ms 0 indicates to immediately go bus on again As default the option is not set and this means ac tually do not go bus on again The cansrv_udp program uses the status LEDs as described here Status 1 On means cansrv_udp program is started Off means cansrv_udp is not started or has correctly termina ted Status 2 Blinking means cansrv_udp ethernet communication is in state of connecting or listening On means ethernet communic
17. offer a command line option to do so There is a standalone program called wdog which may also be used lt is started without any command line options If triggering stops EtherCAN Cl will reboot after 180s Device parameters like IP address or netmask are stored in a part of the flash memory The task to read and write this parameters is done by the fltool application Although entries are stored immediately in the flash when they are modified it needs a reboot for the changes to take effect The fltool program knows a list of predefined specifiers IP Used for setting the IP address NETMASK Used for setting the netmask parameter EMS Dr Thomas W nsche 13 14 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual HOSTNAME value is used at boot time to set the IP ad Used for setting the hostname of the device dress of the device USER_ 1 10 fltool r HOSTNAME The list of USER_1 to USER_10 entries can This reads out the entry HOSTNAME and be used to start applications at boot time If prints it on the terminal an entry is set to i e wdog wdog is started at the end of the boot process as a back fltool w USER_1 cansrv p 1500 ground process This will set the USER_1 entry to cansrv p 1500 At boot time this will start the cansrv USER_FG 1 10 with the given parameter USER_FG1 to USER_FG10 entries are started as foreground processes after the fltool w USER_1 USER_
18. stens on a port for inco a ack timeout TIMEOUT ming connections After the connection is This option changes the acknowledge timeout established the client is able to send and re given in us ceive CAN messages and to configure the The acknowledge timeout is the time within CAN parameters of the CAN controller which a transmitted UDP datagram packet has to be acknowledged by the receiver The use of a configuration file allows to specify If this option is not given the default value detailed CAN controller register values and to 10000 is applied configure a filter for standard identifier CAN messages d device DEVICE The device default is dev can0 This option is The command line parameters are described documented for completeness only It is used in the following on products where more than one CAN chan nel is available h help Show the available options b baudrate BAUDRATE The CAN baudrate used on this segment v version 1000 800 500 250 125 100 50 25 20 10 kBaud Show the version information can be set with this option A baudrate given will be advertised to the op w trigger watchdog posite side where it is used if option r is set This option triggers the watchdog cyclicly If there this option is not set an other application must trigger the watchdog f configfile CONFIGFILE Allows the use of a configuration file for p listen port PORT baudrate settings and identifier filtering A The port t
19. tatus of the others Cur rently only register O is supported V This reads out the version information of the program Example led w017 This activates only status LED 1 THIS PAGE INTENTIONALLY LEFT BLANK EMS Dr Thomas W nsche 17 18 EMS Dr Thomas W nsche User Manual EtherCAN Cl EtherCAN Cl User Manual 4 Electrical Characteristics 4 1 Absolute Limiting Values Any also temporary stress in excess of the limiting values may cause permanent damage on EtherCAN Cl Exposure to limiting condi tions for extended periods may affect the relia bility and shorten the life time of the device Parameter Min Max Unit Storage temperature 25 70 C Operating 0 60 C temperature Supply voltage 100 35 V Voltage on bus 30 30 V connections 4 2 Nominal Values Parameter Min Typ Max Unit Current 70 150 mA consumption Supply voltage 10 24 30 V at nominal supply voltage of 24V 5 Operating Instructions 5 1 Connection Scheme The pin usage of the CAN connectors is de tailed in the following table Pin Name Function 1 Reserved by CiA 2 CAN_L CAN_L bus line dominant low 3 GND Ground 4 Reserved by CiA 5 Reserved by CiA 6 GND Optional ground internally connected to Pin 3 7 CAN_H_ CAN_H bus line dominant high 8 Reserved by CiA error line 9 V Positive pow
Download Pdf Manuals
Related Search
Related Contents
Manual de instalação, operação e configuração. Blue Cat`s Phaser User Manual 第23回定時株主総会招集通知(2010年6月8日 取扱 説 明 書 - Sega Retro Manual - Pioneer Specifications - Procurement & Strategic Sourcing Tyan GT20B7002 Dürr Regeneration Unit - Frank`s Hospital Workshop SSRRR---JJJVVV888000-- Copyright © All rights reserved.
Failed to retrieve file