Home

CANopen Device Monitor User Manual

image

Contents

1. Figure 31 Octet strings If an octet string is read from the device it s displayed twice The upper entry shows the value in x00 notation and below it is displayed as ASCII values Page 46 of 125 CANopen Device Monitor Version 3 2 7 pert 18 2 Octet strings in scripts There are two ways to send or receive octet strings from scripts The first one is to use the normal r or w commands In this case the data must be specified as base64 EXAMPLE w 0x2000 0 os SSBsaWtlIENBTm9wZW4gRGV2aWNIIE1 vbml10b3I To decode or encode base64 data the built in tcl commands e base64 encode lt raw_data gt e and base64 decode lt base64_data gt can be used EXAMPLE w 0x2000 0 os base64 encode any data The other way is to use the 2 special commands e m4d ro lt index gt lt sub gt lt timeout in ms gt to read octet strings e and m4d wo lt index gt lt sub gt lt timeout in ms gt lt data gt to send octet strings EXAMPLE m d wo 0x2000 0 1000 start engine Version 3 2 7 CANopen Device Monitor Page 47 of 125 pert 19 User Specified Tabs In addition to the predefined tabbed fields or tabs at the right side it is possible that you add your own tabbed fields to CANopen Device Monitor There are 2 kinds of tabs available e User specified tabs with support of tests e User specified tabs without contents 19 1 User specified tabs with su
2. tkcon save lt filePath gt lt spec gt Description This command saves the content of the CDM console to a file Parameters filePath path to writeable file spec content specifier use all for all content Results Version 3 2 7 CANopen Device Monitor Page 109 of 125 pert 33 8 DSP402 commands DSP402 Extension 402 ret Description List of possible return values Parameters Results 0 OK 1 Drive in wrong state 2 Transition not possible 3 SDO abort occured 4 No setpoint acknowledge p402 ppHandleNewSetpoint lt delayTime gt Description This function handles a new setpoint in the Profile Position mode The function initiates an absolute movement in the single setpoint mode If this function returns with an error it is possible that the mode specific bits in object 0x6041 controlword and object 0x6041 statusword are not cleared Each drive needs a specific time for the transfer of a new setpoint This time can be specified by the argument delayTime The communication is done via SDO This function can only be used for single drive devices This function is used by other functions of this namespace Parameters delayTime time for transfer in ms Results ret see variable p402 ret Page 110 of 125 CANopen Device Monitor Version 3 2 7 pert p402 getState Description This function gets the actual CIA 402 state of the drive The actual Ci
3. 24 4 Reception of PDOs To receive a PDO it must be configured pdo set_tpdo and an asynchronous indication function must be present The following indication function simply writes the data to the console putPDO puts PDO data to the console proc putPDO num len dataList puts PDO SdataList Any indication function must have the 3 parameters num len dataList Each PDO needs an indication function This can be configured with the command pdo setPDOIndication EXAMPLE ipdo setPDOIndication 1 putPDO The first parameter is the number of the PDO and the second one is the name of the indication function If the indication function is not tailored for a specific PDO more than one PDO can be assigned to it 24 5 Waiting for PDOs The function pdo waitForPDO lt num gt lt expr gt can wait for PDOs lt num gt specifies the number of the PDO It must be configured before it can be used With the Version 3 2 7 CANopen Device Monitor Page 61 of 125 pert optional parameter expr a numeric expression can be specified that must be 1 to return Within the expression the variables val 1 to val 8 can be used to access the objects in the PDO expr is evalutated by the tcl function expr The following script shows an example wait until the bit TargetReached is set set script val 1 amp 0x40 gt 1 waltForPDO 1 script Page 62 of 125 CANopen De
4. port GmbH Halle 11 01 2013 CANopen Device Monitor Version 3 2 7 pert Disclaimer All rights reserved The programs boards and documentations supplied by port GmbH are created with due diligence checked carefully and tested on several applications Nevertheless port GmbH can not take over no guarantee and no assume del credere lia bility that the program the hardware board and the documentation are error free respec tive are suitable to serve the special purpose In particular performance characteristics and technical data given in this document may not be constituted to be guaranteed product features in any legal sense For consequential damages which are emerged on the strength of use the program and the hardware boards therefore every legal responsibility or liability is excluded port has the right to modify the products described or their documentation at any time without prior warning as long as these changes are made for reasons of reliability or technical improvement All rights of this documentation lie with port The transfer of rights to third parties or duplication of this document in any form whole or in part is subject to written approval by port Copies of this document may however be made exclusively for the use of the user and his engineers The user is thereby responsible that third parties do not obtain access to these copies The soft and hardware designations used are mostly registered and are su
5. Because of the restrictions of the old EDS format according to DSP 306 it is not possi ble to add object descriptions to an EDS file Therefore this additional information is stored in a separated object description file See file structure below indexl object name 1 description line 1 description line 2 description line n index2 Version 3 2 7 CANopen Device Monitor Page 33 of 125 pert object name 2 description line 1 description line 2 description line n The data format for the indices is hexadecimal without leading Ox An example object description file is Lib ds301 txt with descriptions for the objects from the commu nication profile When an EDS file is loaded the CANopen Device Monitor looks for a file with the same name as the EDS but with the extension t xt If such a file is found it is loaded as object description file for this EDS Otherwise only the data type or the object code is displayed The CANopen DesignTool by port creates object description files automatically Page 34 of 125 CANopen Device Monitor Version 3 2 7 pert 12 Overview Tab 12 1 Index Overview With the object overview tab all sub indices of an array or record an be read or written at once PDO Image Overview Process Chart Object overview 1018 Sub Name 000 number of entries 002 Product Code 004 Serial number kd Read values Send values Figure 19 Index over
6. The first lines contain some header information for maintaining the data like CANopen Device Monitor version time and date The device configuration file contains commands for the CANopen Device Monitor for writing values to a device Additionally the config uration of bit boxes and sliders is saved in the OCF file EXAMPLE OCF file for SPC Operating Interface created by CANopen Device Monitor V3 2 7 Wed Mar 30 14 48 40 CEST 2005 w 0x100C 0 ul6 100 w 0x2000 0 u8 67 cdm setSlider 100D 000 0 255 1 Version 3 2 7 CANopen Device Monitor Page 57 of 125 pert 23 Console The Console can be activated via View gt Console In the console Tcl commands can be executed as well as user scripts and procedures tkcon 2 4 Main mE File Console Edit Prefs History AO Help softuare 3 0 102 2 Al software 3 0 102 2 a little proc that writes data from one node to anothe r software 3 0 102 2 proc readllrite read input value of node 64 set val 64 r 0x6000 1 u8 send it to node 1 w 0x6200 1 u8 val software 3 0 102 2 try it software 3 0 102 2 readWrite OK software 3 0 103 do this forever t software 3 0 103 while 1 readllrite cdmttpause 100 Figure 35 Console 23 1 Tel Commands A description of the Tcl script language exceeds the scope of this manual To illustrate some special features and basics some simple exa
7. data buffer internal data buffer SDO read online 3 SDO read offline gt internal data buffer Figure 34 SDO communication depending on the options offline online Page 56 of 125 CANopen Device Monitor Version 3 2 7 pert 22 Object Data Management with OCF File 22 1 Saving of OCF files The values of configured objects of CANopen devices and additionally settings of bit boxes slides and object specific commands can be stored in a file for restoring them auto matically in another session The objects to be stored are selected by an active check box labeled with used for saving configuration at the tabbed field Action The configuration can be stored by the menu File gt Save device configuration gt Save OCF Each value is obtained from the CANopen device in the moment it is stored The command to save object values results in CAN traffic with SDO transfers The CANopen Device Monitor does not automatically set the file extension In difference to the DCF file the OCF file needs less memory because the OCF file only contains the selected parameter values 22 2 Loading Saved object values stored in a configuration file can be reloaded to the CANopen device with the menu File gt Load device configuration gt Load OCF The values are transfered from of the configuration file to the CANopen device which result in CAN traffic by SDO transfers 22 3 File Format
8. E Be OS A A ee D 59 24 Scripting with PDOs 0 2 as es oi a AR E e cg Sees 60 24 1 Configuration of PDOs in scripts 2 040 60 24 2 Transmission of PDOs 20 0000000 61 24 3 Request of PDOs using RTR 0 2 00 61 24 4 Reception of PDOs e 61 24 5 Waiting for PDOs cis 1 Ass asc A 61 25 CAN Message Logging add A HEL a 63 25 1 Scriptins Interfac s o s s ds ch aE oe eee ee we Se 64 26 SDO Program Download 2 2 20202 02 00202048 66 27 Network overview window 2 2 68 28 Project Files 4 4474 ow i naeg bee p map bw Oe bee ee RG 69 Version 3 2 7 CANopen Device Monitor Page 5 of 125 pert 28 1 Import Export of CCM project files 2 0 0 0 69 29 DRDO TAD 00 Gre a Ge ere ee OE De Be e A eS ee 70 30 ESS Tb as a e ae ee Bee et ee Ake 72 30 1 LSS MaSK oce 244 eb wd a e ow ee des 72 30 2 LSS Commands bo aoe ds Ya RH De a ee a Ba 73 31 DSP 402 extension 4 4 gah oe oe we PR a ad Se BS 75 31 1 State machine tab edi oe Rw OR ee ee a 75 31 2 Profile velocity modetab a a a a 00020000040 76 31 3 Profile position mode tab a a 0020200002000 000 76 31 4 Object extensions o oo a A Re ee Leh 77 32 About amp Release Info Dialog 2 a a 0040 79 32 1 About Dialog oaa e A i we Oe 79 32 2 Latest Release Info Dialog 0 0 a a a a a a 79 33 CDM Command syntax a a 80 33 1 S
9. ID Node ID of the CANopen Server m4d Send PREOP at exit automatic transmission of the NMT command ENTER PREOPERATIONAL to all devices when the CANopen Server is shut down Keep server running at exit the CANopen Server will not be closed when the CDM is closed Depending on the hardware interface some additional options like device channel board or unit can be present These options distinguish the connected device or the desired communication channel The CANopen Device Monitor searches for all installed drivers and CANopen Server and offers only the installed drivers at the option CAN Interface Mostly it s only one driver plus TCP as default option Version 3 2 7 CANopen Device Monitor Page 19 of 125 pert 6 Object Dictionary Accesses The object dictionary is the data interface between the CANopen Device Monitor and the CANopen device The CANopen Device Monitor can access every object in the object dictionary for reading or writing by index subindex CANopen subdivides the objects into various groups Index Objects 0000h OFFFh common types 1000h 1FFFh communication objects 2000h SFFFh manufacturer specific objects 6000h 9FFFh profile objects A000h AFFFh objects for network variables The CANopen Device Monitor shows the object dictionary loaded from the Electronic Data Sheet EDS file of the device in a tree structure An EDS can be loaded for each device in the network After the selection of
10. X or Ox x Results Returns objectType VARIABLE ARRAY RECORD DOMAIN throws an error if the index does not exist cdm getDataType lt node gt lt index gt lt sub gt Description Returns the data type of a sub index Parameters node node ID means current node ID as d or 0x x index index as X or Ox x sub subindex opt as 03d 0x or 0x x Results Returns DataType uSlu16lu321181116lu321r32lvs throws an error if the index does not exist cdm getName lt node gt lt index gt lt sub gt Description Returns the parameter name of an object from the EDS Parameters node node ID index index sub sub index opt as 03d 0x or 0x x Version 3 2 7 CANopen Device Monitor Page 103 of 125 pert Results returns the parameter name or throws an error if the object does not exist cdm getDefaultValue lt node gt lt index gt lt sub gt Description Returns the default value of an object from the EDS Parameters node node ID index index sub sub index opt as 03d 0x or 0x x Results returns the default value throws an error if the object does not exist cdm existObject lt node gt lt index gt lt sub gt Description Checks if an object exists in the EDS file Parameters node node ID means current node ID as d or 0x x index index as X or Ox x sub subindex opt as d Ox x Results 1 object exists 0 object does not exist cdm getRemote
11. are written into a buffer and after a certain amount of time the values of the buffer are displayed in the chart If the update interval is O the chart is updated at every arriving PDO It it s an asynchronous PDO the information about the time of the arrival of the data is lost At Color the color of a signal can be configured Every color that is supported by Tcl Tk can be used Otherwise the colors can be specified in hexadecimal notation like ffaal 1 Page 38 of 125 CANopen Device Monitor Version 3 2 7 pert 14 Process Tab The process image Tab serves the observation of process quantities of different nodes The values of the individual objects are queried and updated cyclically by SDO every 1000 ms per default Normally the values are read only if the tab is active To update the values in every cycle activate Update even in background e CANopen Device Monitor Node 28 IclA D065 Process y Node Index sub Name Value 64 6o00 f Read Input 1h to 8h hex Oxe0 3 64 6o00 f2 Read Input 9h to 10h hexw Oxid 64 6401 f Analog Input 1h hex w 0x7b80 3 64 6401 2 Analog Input 2h hex w 0x2c60 28 6040 0 control word hex we 0x0 26 6041 0 status word hex w Ox40 8 28 6064 0 position actual value hex Ox68fc 28 606c fo velocity actual value hex w 0x0 QQ 26 607a 0 target position hex w 0x0 _ Update even in background Figure 23 Pro
12. dialog appears when loading an EDS file via File Load EDS Version 3 2 7 CANopen Device Monitor Page 15 of 125 pert e CANopen Device Monitor EDS Selection x Vendor ProductName e le Description Fi FileName SYSTE CANopen Chip EDS for CANopen COP164_0 EDS SYS TE CANopen Chip a EDS for SYS TEC C CHIP_C505 EDS Contem CANopen Engine 401 CANopen I O Devic engine eds port Gm CANopen Librar 0 Example for CANop design eds port Gm CANopen Librar 402 Example for CANop 1 eds port Gm CANopen Librar 0 Example for CANop s2 eds port Gm CANopen Librar 0 Example for CANop s6 eds Danfoss CANopen module 0 CANopen module mass201 eds Danfoss CANopen module 0 CANopen module danfoss eds PESTO G62 401 EDS for FESTO Val CPY COZ EDS Frenzel CO401140 401 EDS file for CO4011 CO401140 eds Frenzel CO401141 401 EDS file for CO4011 CO401141 eds Frenzel CO401142 401 EDS file for CO4011 CO401146 eds Frenzel CO401142 401 EDS file for CO4011 CO401142 eds Frenzel CO401144 401 EDS file for CO4011 CO401144 eds A sn y Open selected file Cancel Select another file Figure 13 EDS choice box 4 3 Device Specific Settings If the Device Monitor loads a new EDS file at start up or if selected by File gt Load EDS 1t looks also if
13. dynamic OD entries Exports a scanned object dictionary as EDS file Transmits the values of all objects with DCF compo nent flag to the device Reads the values of all objects with DCF compo nent flag from the device Store or restores the configuration of the device in its non volatile memory Converts DCF files into the concise format Menu to load plug ins Opens the option dialog The exported file can be read again by the CANopen Device Monitor but it is no complete EDS file according to the standard Version 3 2 7 CANopen Device Monitor Page 25 of 125 pert 7 6 Windows Cascade Tile vertical Tile horizontal Clear All Clears the console and the log window except of Cascade Cascades all open windows the main Tile vertical Tiles all open windows vertically window Tile horizontal Tiles all open windows horizontally 7 7 Help About Latest Release Info Help Shows the on line help CDM Wiki Opens the CDM wiki in a web browser About Shows version and licence information Latest Release Info Fetch information about updates from the internet Page 26 of 125 CANopen Device Monitor Version 3 2 7 pert 8 Toolbar The toolbar is explained in the following illustration DAA ao Confirmation of node selection Stop user script Mode selection Shortcuts for NMT Commands Retrieve version Close the connection to the server info Quick selection buttons for Open a connection to the se
14. gt Description SDO write and message error type out the SDO write command type out the answer from the device and check the received value Parameters index object index subindex object subindex typ datatype of object val value Results 0 received no SDO abort code 1 received SDO abort code Version 3 2 7 CANopen Device Monitor Page 83 of 125 pert 33 2 PDO commands pdo set_rpdo lt scope gt lt pdo_nr gt lt cob gt lt trans gt lt index1 gt lt subl gt lt indexN gt lt subN gt Description Defines a RPDO at the device and a TPDO at the gateway Example pdo set_rpdo local 1 0x220 event 0x6200 1 0x6200 2 This defines a PDO to set the first two 8 bit ports on a digital output device according CiA 401 Index and sub index are the destination objects which must be available in the EDS file of the current device See pdo wpdo as a usage example Parameters scope locallremote local configure only CANopen Gateway pdo_nr number of pdo cob cob id for this pdo trans transmission type eventlrtrisync lt 1 240 gt index1 1st index to be mapped format 0x 4X subl 1st sub to be mapped indexN nth index to be mapped subN nth sub to be mapped Results pdo set_tpdo lt scope gt lt pdo_nr gt lt cob gt lt trans gt lt indexl gt lt subl gt lt indexN gt lt subN gt Description Defines a TPDO at the device and a RPDO at the gateway Example pdo set_tpdo
15. remote _ warning _ voltage disabled state OPERATION ENABLED mode Profile Position Delete Object Action Receive Figure 45 Status word bit box Version 3 2 7 CANopen Device Monitor Page 77 of 125 pert Control 6040 0 ME Shutdown _ mode_4 Switch On E models E Disable Voltage mode_b _ Guick Stop _ halt al _ Disable Operation El _ Enable Operation _ Fault Reset Figure 43 Control word bit box These extensions are special bit boxes for the status and the control word manui manu_12 manu_13 manu_14 manu_15 Delete Object Action send Receive Page 78 of 125 CANopen Device Monitor Version 3 2 7 pert 32 About amp Release Info Dialog 32 1 About Dialog The about dialog provides information about e the current release e the type of this release e the licensee e the license and e the available Tcl Tk packages 32 2 Latest Release Info Dialog When requesting information about the latest release of the CANopen Device Monitor a http connection to our server is established and the data approx 30 bytes are down loaded from the server NOTHING except your IP address IS SENT TO THE SERVER WHEN RETRIEVING THE LATEST RELEASE INFO Version 3 2 7 CANopen Device Monitor Page 79 of 125 pert 33 CDM Command syntax 33 1 SDO commands r lt index gt lt subindex gt lt typ gt Description SDO read procedure Parameters
16. this command the LSS slave saves the bitrate and node id The LSS slave has to be in LSS CONFIGURATION state Page 74 of 125 CANopen Device Monitor Version 3 2 7 pert 31 DSP 402 extension The DSP 402 extension consists of 3 components for the simplification of the work with drives in conformity with the DSP402 This extension can be activated via Extras gt Plug in gt DSP 402 Extension They are only available if the corresponding license has been purchased 31 1 State machine tab Device Monitor Node 28 Generic minimum capability device Configure DSP 402 State Machine Not ready to switch on Switch on disabled Ready to switch on Operation enabled Fault Reaction Active Cyclic read via 5DO Drive State 0x0023 Figure 42 DSP402 state machine The state deposited green is the current state of the drive Pale brown fields indicate pos sible next states and gray fields aren t obtainable directly from the current state The cur rent value of the status word is displayed under the state machine down on the right Version 3 2 7 CANopen Device Monitor Page 75 of 125 pert The configuration dialog can be opened by the button Configure This dialog allows the configuration of the acces mode to the device and the axle of the device These set tings are also valid for the other DSP402 extensions 31 2 Profile velocity mode tab The profile velocity mod
17. 01 2nd receive PDO mappil mnected to localhost Value Entry Frame Icl4 D065 Action Frame Saas online co Figure 6 Separation of a tab ME Help e CANopen Device Monitor x Network Node 26 SYNC Enable Sync Disable Sync User scripts Script 1 Scan Network MS 14 15 17 18 19 20 21 26 27 29 30 31 33 37 38 39 40 41 42 43 45 49 50 51 52 53 55 57 61 62 63 64 65 66 67 69 73 74 75 76 77 78 79 es es 87 88 89 30 91 37 98 99 100 101 102 103 Script2 Scripta Script 4 10 11 22 23 34 35 46 47 58 59 70 71 62 63 94 95 106 107 12 24 36 48 60 72 64 96 108 13 25 44 56 68 60 61 93 105 392 104 The upper command bar serves for sending the NMT commands to the whole network and with the lower one the current node is addressed The current node can be changed quickly by the node buttons in the lower part of the NMT tab Page 14 of 125 CANopen Device Monitor Version 3 2 7 pert 4 Configuration The Device Monitor can be adapted to the personal environment This adaptation can be stored in the file lt working directory gt cdm rc with the exception of the CAN bit rate A pattern of the file cdm rc is located in the lt CDM directory gt The bi
18. 13 1 Configuration of PDOs for the chart a aa a 36 14 Process Tab canaria A Se Ree as 39 15 PDO Process Tab ee cee a ds a e ES RA 40 16 Using Stripcharts s ens e os s e oa poe AE E a he we o 41 17 Extended object configuration o a a a a be 44s 43 TiAl SUdEr 25 125 BS oa i BAe a aeie a SSS RY os 43 17 2 Slider in a Top Level Window uds me 44 4 wae A 44 17 3 Switch Box Display of Objects 2 2 a 45 18 Usage of Octet strings es 44 cae ee deb ROR RE ew Ee Eee RA 46 18 1 Value entry frame f 6 46 oe RARE oe eRe Re EOS 46 18 2 Octet strings in scripts 2 2 47 Page 4 of 125 CANopen Device Monitor Version 3 2 7 19 User Specified Tabs ooo o Ok we oe GR Sek a ads 48 19 1 User specified tabs with support of test 2 0 0000020 48 19 2 User specified tabs without contents 52 19 3 Erasing User Specified Tab sets 2 2 0 o 53 20 Data Management with DCF File 2 a a aa 54 20 1 Creating a DCF ile o ds ke o RE A a Re a ce 54 202 Load gp e e a E e AS a Be ho a 55 pr E a ek A GS 55 21 UIE WICKS s e gist ek A ee a Gok ee E 56 22 Object Data Management with OCF File a a a a a 57 22 1 Saving of OCF files aaa be PERE Ke eda 57 22 2 Loadini yeas ep ee EG A ee a Ge e a BAYS 57 22 3 FileFormat 2 4 2 44 dom e ka BR ed o ak he A LER REE ES 57 23s CONSO A fs Pa a Gos a e Se a a ee eS Be 58 23 1 Tol Commands a 00000000000 58 DS i A A
19. 33 4 LSS commands lss baud2Index lt baudrate gt Description Converts the baudrate as number e g 125 or 1000 into the LSS table index Parameters baudrate baudrate as number Results returns baud rate index lss setHandler lt cmd gt Description set callback function to be called when ever a LSS message UNCONFIGURED DEVICE is received Parameters cmd the name of the Tcl procedure Results Page 92 of 125 CANopen Device Monitor Version 3 2 7 pert 33 5 Other CANopen commands cdm setSDOTimeOut lt node gt lt time gt Description Sets the SDO time out time for a specific node Parameters node node ID of the node time time out time in ms Results cdm enableGuarding lt node gt lt gtime gt lt ltime gt Description Starts the guarding of a node Parameters node node ID of the node that should be guarded gtime guarding time Itime life time factor Results cdm disableGuarding lt node gt Description Stops the guarding of a node Parameters node node ID of the node that had been guarded Results cdm setHeartbeat lt time gt Version 3 2 7 CANopen Device Monitor Page 93 of 125 pert Description Configures the heartbeat producer interval of the CANopen Gateway Parameters time interval in ms Results cdm enableHeartbeat lt node gt lt time gt Description Configures the heartbeat consumer ti
20. A 402 state is returned in the format of object 0x6041 statusword The communication is done via SDO This function can only be used for single drive devices This function returns a list with the following elements retsee vari able p402 ret stateactual CiA 402 state in statusword format The state is only valid if this function returns with ok Example for usage set retList p402 getState set retVal lindex SretList 0 if set retVal set p402 ret OK puts Error getState returns with set retVal set actualState lindex S retList 1 If actualState is 0x0027 the drive is in the state OPERATION ENABLED Parameters Results retList value of p402 ret actual CiA 402 state p402 changeState lt state gt lt delayTime gt Description This function changes into the desired CiA 402 state The desired CiA 402 state must be input in the format of object 0x6041 statusword Each drive needs a specific time to change the CiA 402 state This time is set by the argument delayTime The communication is done via SDO This function can only be used for single drive devices Example The argument state must be 0x0027 for a change into the CiA 402 state OPERATION ENABLED Version 3 2 7 CANopen Device Monitor Page 111 of 125 pert Parameters state desired CiA 402 state delayTime maximal time for state changing in ms Results ret see variable p402 ret p402 halt D
21. DO commands 0 eR ee Ee e A 80 33 2 PDO commands 24 26 c a doos s a eb adhd RS ee S GS 84 33 3 NMT commands o s e a Wok ta a yd E Re a 90 33 4 LSS commands lt 6465 48 aaa e SAS D ER ES 92 33 5 Other CANOpen COoMmmMaddsS 2 040 93 33 6 Test commands e a OS eR See RE ES 99 33 7 CDM Commands o sor e a SR Ee Be we Ss 103 33 8 DSP402 commands DSP402 Extension 2 202 2 110 34 Appendices 4 4 4 ou eee Gee ee EE EE wD Se SO Be ae Bo 116 34 Appendix 1 CANopen Commands in Overview 116 34 Appendix 2 CDM Commands in Overview 2 2 118 34 Appendix 3 Creation of an Object Description 2 2 119 Page 6 of 125 CANopen Device Monitor Version 3 2 7 34 Literature 35 Glossary Version 3 2 7 CANopen Device Monitor Page 7 of 125 pert 1 Introduction 1 1 Product Overview The CANopen Device Monitor CDM communicates with CANopen devices in CAN networks by using of various CANopen services Therewith the Device Monitor sup ports development diagnostic implementation and configuration of CANopen devices The Device Monitor is a graphical user interface Various drivers can be integrated in the Device Monitor in dependency of the used CAN interface The driver interface is called m4d server or CANopen server The communication between the graphical user inter face and the driver is done by the TCP IP protocol independe
22. HP 164 Load EDS G Remove Node 2 26 Icl4 D065 1 CANopen Li Preop Node Reset Comm Reset Appl Figure 39 Network overview window The network overview represents the nodes graphically organized in groups Pictures in GIF format are necessary for the visualization of the devices These picture files must have the same name as the EDS file and must be in the same directory Their maximum size can be 72 x 72 pixel The node menu which provides reloading of the EDS file and access to the NMT com mands can be accessed via the right mouse button Page 68 of 125 CANopen Device Monitor Version 3 2 7 pert 28 Project Files Project files are useful for projects with more than one device resp EDS File The can be saved and loaded via File gt Project and contain the following data e all nodes with links to their EDS files e links to the DCF files containing device specific values for the objects Parameter Value e links to the OCF files containing device specific values for the objects configuration settings for bit boxes sliders and object specific CallBack functions e configuration of the Process Image tab e configuration of the PDO Process Image tab If a project is loaded all nodes and there EDS files are loaded If DCF files are available for the nodes these are loaded too and the values in the DCF file are stored into the inter nal buffer OCF stored config
23. ID Description Returns the current remote ID Parameters Page 104 of 125 CANopen Device Monitor Version 3 2 7 pert Results Returns the remote id cdm setRemoteID lt id gt Description Sets the remote id and updates the OD tree Parameters id remote node id Results 1 success 0 invalid ID cdm loadEds lt fileName gt Description Loads an EDS file for a node and after that it looks for a description file with a matching name and loads it If there is a matching device specific rc file it is sourced to This file must contain valid Tcl or CDM commands Parameters fileName path to EDS file POSIX style Results setMessageLlogLimit lt limit gt Description Set a new limit of lines for the message log Parameters limit max number of lines in message log Version 3 2 7 CANopen Device Monitor Page 105 of 125 pert Results Returns OK if limit is ok otherwise a verbose error cdm hideGUI lt flag gt Description Hides the CDM GUI This function is useful for scripts that build their own user interface Parameters flag opt use noconsole to exclude the console window Results cdm showGUI lt flag gt Description Shows the CDM GUI Counterpart of cdm hideGUI This function is useful for scripts that build their own user interface Parameters flag opt use noconsole to exclude the console window
24. Monitor Page 3 of 125
25. Network Flexible Data Rate CAN Application Layer CANopen base CANopen Device Monitor CAN in Automation international users and manufacturers group e V Controlled Node Ethernet POWERLINK Communication Object CAN Message Communication Object Identifier Client SDO EtherCAT Device Monitor Electronic Data Sheet EtherCAT Slave Information file Emergency Object Ethernet POWERLINK Standardization Group EtherCAT Technology Group Managing Node Ethernet POWERLINK Network Management Object Dictionary Process Data Object unconfirmed service for real time communication Receive PDO Remote Transmission Request POWERLINK Device Monitor Problem Report Management System Service Data Object Confirmed data transfer service for parameter data Server SDO Sychronization Object Tool Command Language script language Transmission Control Protocol Internet Protocol Time Stamp Object Tcl Tool kit graphical Tcl extension Tcl Tk Transmit PDO element of a graphical user interface e g button entry filed menu Version 3 2 7 CANopen Device Monitor Page 121 of 125 pert 36 Index a Action tab 43 tab set 20 activate_bitrate LSS 74 after 97 b base64 47 bitwise representation 45 ae CAN bit rate 15 cdm addTab 52 cdm addTestTab 49 cdm deleteTab 53 cdm domainDownload 66 cdm rc 15 commands Tcl 58 d DCF file 54 description object 118 device change 15 device rc 16 devic
26. Object The object value will be set written by SDO Version 3 2 7 CANopen Device Monitor Page 21 of 125 pert The value in the field Value Entry Frame will be decremented by 1 Thereafter it will be sent to the device automatically The value in the field Value Entry Frame will be incremented by 1 Thereafter it will be sent to the device automatically Page 22 of 125 CANopen Device Monitor Version 3 2 7 pert 7 Menu Structure 7 1 File Load EDS ALL Load default EDS Recent EDS files Load device configuration save device configuration Project F Exit CTRL Load Project a Save Project Load EDS Loads an EDS file Load default EDS Loads an EDS file with mandatory objects Recent EDS files List of recently used EDS files Load device configuration Save device configuration New Project Load Project Save Project Exit 7 2 Edit Cut Copy Paste Loads OCF or DCF files Saves OCF or DCF files Starts a new project Loads an existing project Saves a project Exits CANopen Device Monitor Copy CTRL Faste CTRL Y Cuts selected text into clipboard Copies selected text into clipboard Pastes text from clipboard Version 3 2 7 CANopen Device Monitor Page 23 of 125 pert 7 3 View Toolbar Status Bar Console Message Log Network View 7 4 Connection Connect Disconnect Online Offline Interface W Status Bar F Console Message Log FP Networ
27. Results Page 106 of 125 CANopen Device Monitor Version 3 2 7 pert isColor lt color gt Description Checks if a color is a valid tcl color Parameters color color name or hex expression Results 1 is valid color 0 is no valid color int2asc lt i gt Description Converts an unsinged char value into a ASCII representation Parameters 1 unsigned char value Results Returns an ascii value int2bits lt i gt lt digits gt Description Converts an integer value into a binary representation like 0b01010101 Parameters 1 integer value digits length of the returned value opt Results Returns a binary value common every lt script gt lt ms gt Version 3 2 7 CANopen Device Monitor Page 107 of 125 pert Description This proc runs a script cyclically The global variable every script stores the after id for each script Parameters script script to run ms interval in ms opt defaults to 1000 Results clear_messagelog Description This proc deletes the content of the message log Parameters Results save_messagelog lt filePath gt Description This proc saves the content of the message log into a file Parameters filePath path to writable file Results clear Page 108 of 125 CANopen Device Monitor Version 3 2 7 pert Description This proc deletes the content of the CDM console Parameters Results
28. S Tab 30 1 LSS Mask e CANopen Device Monitor Node 64 Network Node A e VendorlD Revision 0x10001002 0x10001003 0x10001003 0x10001003 Figure 41 LSS Tab The LSS tab simplifies the configuration of CANopen nodes using the Layer Setting Services This tab can be activated via Extras Plug in gt LSS It is only available if the corre sponding license has been purchased Button Description Scan Network Scans the net for unconfigured devices Set Bit rate Changes the bit rate of all device within the network Activate Activates the changed bit rate of the device Store Saves the changed bit rate in non volatile memory Set Node ID Sets the node ID of the device selected in the list below Set Bit rate Changes the bit rate of the device selected in the list below Activate Activates the changed bit rate of the device selected in the list below Page 72 of 125 CANopen Device Monitor Version 3 2 7 pert Button Description Store Saves the changed bit rate in non volatile memory Devices that are already configured can be added to the list by Add configured device which is available via the right mouse button 30 2 LSS Commands In scripts or in the console the following LSS commands are available Switch Selective lss switch_sel lt vendorld gt lt product gt lt revision gt lt serialNo gt Set single LSS slave in L
29. SS CONFIGURATION state Switch global lss switch_glob lt 0 1 gt Set complete network in LSS CONFIGURATION 1 or LSS OPERATION 0 state Configuration of node id lss set_node lt nodeld gt Set the node id of an LSS slave in the state LSS CONFIGATION Request node lss get_node Get the node id of an LSS slave Identify LSS slaves lss identity lt vendorld gt lt product gt lt rev lo gt lt rev hi gt lt serial low gt lt serial hi gt Scans the network for nodes that are in the given address range Bitrate Configuration lss set_bitrate lt table _sel gt lt table_idx gt A lt gw_table_sel gt lt gw_table_idx gt Set the new bitrate of an LSS slave The LSS slave has to be in state LSS CONFIGURA TION The first two parameter define the bitrate of the LSS slave The last two parameter define the bitrate of the CANopen Server They are used when autobaud is to be set at the LSS slaves Version 3 2 7 CANopen Device Monitor Page 73 of 125 pert Bitrate Table index lt table_idx gt 1000 0 800 1 500 2 250 3 125 4 reserved 5 50 6 20 7 10 8 Autobaud 9 Only table 0 lt table_sel gt the standard CANopen table is supported by the CANopen Device Monitor Bitrate activation lss activate_bitrate lt time gt Activates the bitrate The CANopen Device Monitor responds after 2 time is elapsed The time is given in milli seconds Store Configuration lss store On reception of
30. TURN to send the octet string to the device Please note that the size of an octet string is limited to 127 characters 1203 00 00 00 00 00 00 00 Ok wrote lange 10 O lange 16 0 3 01 02 03 04 05 06 45 Ge Ga GF 79 07 08 09 0a 30 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 Joy e CANopen Device Monitor Node 32 File Edit View Connection Extras Windows F gy Node tajse set 32 66 105 127 E ner BOS Help A Communication Segment o Manufacturer Segment PDOLDDOLODOLODDL 2000 2001 2002 2004 2014 3000 3001 3002 3010 3011 3012 3020 3030 3040 UP Down load Domain Download Filename Upload Filename Process ID CANopen Timer Testvariable US Testvariable U16 Testvariable U32 Testvariable 18 Testvariable 116 Testvariable 132 Testvariable R32 Testvariable Oktet Testvariable Visible Strin Chart Process NMT Value Entry Frame hwo A SE Ok wrote O1WO2 K03 x04 KOS K06Enjoy aib component of DCF file _ used for saving configuration in Action Frame Receive from Object
31. _command Tcl commands appear in Courier constant width font Exceeds the length of a Tcl command line the paper width this line is finished with a backslash and continued in the following line example Fragments of code and examples appear in Courier con stant width font Ox lt value gt Hexadecimal values are designated by the prefix Ox lt key gt Keys are designated by lt gt braces lt set_value gt Replace set_value by the desired value if this term is a part of a functional description option Replace option by an option of the function Page 8 of 125 CANopen Device Monitor Version 3 2 7 pert directory Console Save gt All 1 3 Support by port Directories are signified with quotation marks the users way through menus port supports the user by telephone hot line and by seminars Additionally port offers consultations in the whole field of CANopen e g network planning network configura tion selection of devices and CANopen and CANopen Profile implementations Version 3 2 7 CANopen Device Monitor Page 9 of 125 pert 2 Installation The installation includes e the graphical user interface e the m4d server and e a layer 2 driver for the CAN interface For the installation the following steps are necessary 1 Maybe preparing installation steps are necessary depending on the used CAN Interface These steps are described in the file INSTALL in the
32. a device description or device configuration file with the same name as the EDS file but the extension rc is available This file has to be in the same directory like the EDS file EXAMPLE device_v1_1 eds and device_v1_1 rc gt right devicel_1 eds and device_v1_1 rc wrong This configuration file is used for the storage of device specific settings That can be local definitions or assignments like the definition of sliders for special objects but also statements with CANopen commands to initialize objects within the CANopen devices object dictionary After the installation of the Device Monitor the CDM directory contains some examples for device configuration files 4 4 Start Up Scripts A Tcl Tk script which is loaded at the start of the CANopen Device Monitor can be spec ified with the global variable autoExecScript in the configuration file cdm rc Page 16 of 125 CANopen Device Monitor Version 3 2 7 pert EXAMPLE specify start up script set autoExecScript demo tcl This script e g demo tcl is loaded after the complete start up of the CANopen Device Monitor That means that start up actions like loading the last project file or auto matically connect to the network are carried out before loading the script Version 3 2 7 CANopen Device Monitor Page 17 of 125 pert 5 CAN Interface Configuration As extension to the previous described method the CANopen Device Monitor is also capa
33. a device its object dictionary is displayed and communcation with the device is possible Using the tab Action objects can be accessed by SDO transfers e CANopen Device Monitor Node 64 CANopen Chip164 File Edit View Connection Extras Windows Help A Communication Segment PDO A Manufacturer Segment a Device Profile 1 y value Entry Frame A 6000 Read Input 8 Bit BQ 6200 Write Output 8 Bit Ok wrote 111 A 000 Number of Output 8 Bit 3 001 Write Output 1h to 8h WE used for saving configuration 6206 Error Mode Output 8 Bit Pee Jee Le 6207 Error Value Output 8 Bit 6401 Read Analogue Input 16 Bit 6421 Analogue Input Interrupt Tri NMT Description Action Frame E Receive from Object Send to Object 6422 Analogue Input Interrupt So 6423 Analogue Input Global Interr Ea 6424 Analogue Input Interrupt Up Object send an 6425 Analogue Input Interrupt Lo aa 6426 Analogue Input Interrupt Del 85 67FE Error Behaviour E PRRPRPRPRPRRP D 0 0 A Figure 15 Tab Action Write object select the object in the tree set value in Action tab Value Entry Frame Page 20 of 125 CANopen Device Monitor Version 3 2 7 pert execute SDO transfer by Action Send to Object Read object select the object in the tree execute SDO transfer by Action Receive from Object the received value is shown in Action gt Value Entr
34. age 41 of 125 pert With little effort you can write your own simple script that reads values from a device and displays them in the chart proc readAndShow index sub dataType set value r Sindex Ssub SdataType cdm addChartData list value 0 0 0 oe op Call this procedur very second common every readAndShow 0x6401 0x01 116 1000 op op Windows gt Clear All cdm clearChart or F7 clears the chart and the lt space gt key pauses the display The console or script command cdm saveChart lt fileName gt saves the con tent of the chart to a postscript file The chart can be zoomed by the right resp left mouse button The context menu provides the following actions Menu entry Description Clear Chart Deletes all values from the chart Save Chart Saves the current picture as PostScript file Save Data Saves all vales as CSV file Remove PDO Stops PDO reception and adding of further values Page 42 of 125 CANopen Device Monitor Version 3 2 7 pert 17 Extended object configuration 17 1 Slider Optionally the tabbed field Action can be extended by further elements A possible ele ment is a slider Figure 27 Action Frame Receive from Object Send to Object Object send value 0 mE 0 63 126 189 252 Figure 27 Tabbed field Action with slider A slider consists of a regulator and a scale The regulator
35. ain transfer Click with the right mouse button on a domain object to open the download menue Select upload or download to start the domain transfer E 3 Communication Segment Af Manufacturer Segment E 2000 UP Down load Domain see Ega zi Domain Download ame a 2 Domain Upload e ae la 2004 Process ID Figure 38 Domaintransfer Download from a script or from the console is performed by calling cdm domainDownload lt node gt lt index gt lt sub gt lt timeout gt lt file gt Description executes a program download Parameters node Node ID index index of the domain object where the file shall be down loaded sub subindex of the domain object where the file shall be downloaded timeout timeout in milliseconds file absolute path name of the file to be downloaded Return nothing Page 66 of 125 CANopen Device Monitor Version 3 2 7 pert Paths to the files that contain spaces must be enclosed in quotes Additionally the POSIX style must be used to specify the path EXAMPLE cdm domainDownload 32 0x1f50 1 25000 D Dokumente und Einstellungen Administrator Desktop prog bin A domain transfer from the device to the CANopen Device Monitor can be done by cdm domainUpload lt node gt lt index gt lt sub gt lt timeout gt lt file gt Version 3 2 7 CANopen Device Monitor Page 67 of 125 pert 27 Network overview window File Edit 4 BK5120 CANooen C
36. andler lt cmd gt Description Registers a indication function for sdo write indications The indication function is called when a device writes to the object dictionary of the CANopen server It has these arguments index index sub subIndex len length of data or b64 data data data For nun numerical data base64 encoding is used Page 96 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters cmd name of indication function Results dcf downloadDCF lt edsFile gt lt dcfFile gt lt nodeld gt Description This proc loads a DCF file and downloads its data to a given node Parameters edsFile path to EDS File dcfFile path to DCF File nodeld node id of device Results cdm pause lt msecs gt Description Waits for a number of milliseconds with event handling Parameters msecs ms to wait Results Version 3 2 7 CANopen Device Monitor Page 97 of 125 pert hbt setHandler lt cmd gt Description Registers a indication function for heartbeat events The indication function is called when a heartbeat event like BOOT UP HBT started or HBT lost arrives It has these arguments node node id data data from 309 3 server Parameters cmd name of indication function Results thbt unsetHandler Description Unregisters the indication function for heartbeat events Parameters Results Page 98 of 125 CANopen Device Monit
37. bes the buttons in the lower part of the mask Option Description Read from EDS Reads the values from the EDS file Read from Device Reads the current values from the device Send to Device Transfers the entered values to the device Store to DCF data Store the entered values into the DCF data buffer Send PDO Sends the current PDO to the device The values of the PDO are taken from the entries above Take into account that PDOs only can be sent or received in the state OPERATIONAL Only at RPDOs of the device Show PDO in Chart A PDO Indication function is configured so that the values of this PDO are displayed in the chart Tab The device must be configured correspondingly before Take into account that PDOs only can be sent in the state OPERATIONAL by the device Only at TPDOs of the device 13 1 Configuration of PDOs for the chart After pressing the button Show in Chart the following dialog window is opened Version 3 2 7 CANopen Device Monitor Page 37 of 125 pert Chart configuration Title Device state Title Y axis Values Title X axis sed Update interval msj 1000 5 Values Mame _ Color Status 1 blue Status 2 red 5DO Counter black Ok Cancel Figure 21 Chart configuration mask The title of the chart and of the axes and the names of the data can be configured there If the update interval is not 0 the chart is updated by a time trigger mechanism Le arriving data
38. bject to copy right CANopen is registered trademark licensed by CiA CAN in Automation e V Germany EtherCAT is registered trademark and patented technology licensed by Beckhoff Automation GmbH Germany We are thankful for hints of possible errors and may ask around for an information We will go all the way to verify such hints fastest Copyright 2013 port GmbH Regensburger Stra e 7 D 06132 Halle Tel 49 345 777 55 0 Fax 49 345 777 55 20 E Mail service port de Internet http www port de Page 2 of 125 CANopen Device Monitor Version 3 2 7 9 1 General Settings a A Gk od Bo Bode a ee we aE 28 O22 DCF Settings e uta doce we a ee BE Boke eae eee 4 EAL 29 9 3 Network Settings oa k eG bb ew Eee Aa 29 9 4 Color Settings e rca BOS ae eR om Be we a ow eR AA 30 9 5 Font Settings 6 espada wR eine A Sow amp ee ary d 30 10 NMT Tab acc Sd Go a he a A a ee eg A A 31 10 1 NMT commands 92101624220 64 49 404 4 BSG hE 4G 31 IQ 2 Userdenned S riptS s so cosg wa oe ee ee ew a Pe ee Rw 31 10 3 Network overview gh 4 44048 24 4 a0 4464 444 go 32 10 4 Device Information 040 aw a o a A A 32 11 Description Tab tek a a a de eae eke EAE EGS 33 11 1 Object Description o a a 33 11 2 Object Description File oder sed Baw eee pee A 33 12 Overview Tab aa aaa EO Hw ee Ee A ers 35 12 1 Index Overview ss arras a e Be we He 35 13 PDO Configuration Tab o a a a L 36
39. ble to start the CANopen Server by itself Thereby the CANopen Device Monitor handles the start the connection establishment and the closing of the CANopen Server m4d automatically At the first start of the CANopen Device Monitor after the installation the configuration dialog opens automatically After that the hardware configuration can be opened by Connection gt Configure CAN Interface The other method with a separate start of the CANopen Server is still possible so that its advantages like a remote control of device via a TCP IP network can be used too 5 1 Configuration Dialog Can Interface cand4linus Canopen server usrshare portbinem4d_s Device cand Baud Rate 125 Timeout d Advanced settings Le el Le TCP port local node ID send PRE OP at exit of server Keep server running at exit Figure 14 Hardware configuration dialog Is TCP selected as CAN Interface so the CANopen Server has to be started separately and all other options in the dialog are disabled The desired options have to be passed to the CANopen Server at its start The following options are available for all supported hardware interfaces Option Description CANopen Server path to the CANopen Server m4d Baud Rate CAN Baudrate kbit s TCP port TCP port used for the communication between the CDM and the CANopen Server m4d Page 18 of 125 CANopen Device Monitor Version 3 2 7 pert local node
40. ce The upper part of the tab shows the actual SRDO data from the SRDO object like the COB IDs The table below shows the mapping values from the mapping object This tab can be activated via dant license has been purchased GHB r MO O Action NMT Description PDO L55 Chart Process Value Entry Frame SRDO Y 1 11 2 1 SRDONr1 Object 1301 Direction Receive Transmit Invalid Refresh Time 500 SCT Time 50 COB id 1 291 COB id 2 292 Mapping E fixed CRC inverted Index Sub Bit Index Sub Bit 1 2000 01 08 2000 02 08 2 2001 01 08 2001 02 08 3 2002 01 06 2002 02 06 4 2003 01 08 2003 02 08 5 6 7 m O ni l 8 Action Frame Receive from Device Check Data Check and Send to Device p Extras gt Plug in gt Safety It is only available if the appen Page 70 of 125 CANopen Device Monitor Version 3 2 7 pert Button Function Receive from Device Read the data of the current SRDO object and of the appendant mapping object Check Data The values are checked for consistency and compliance with the standard Check and Send to Device The values are checked for consistency and compliance with the standard and transmitted to the device The map ping data are only transmitted if the mapping is not fixed Version 3 2 7 CANopen Device Monitor Page 71 of 125 pert 30 LS
41. ce Information Scan Network Mola s e 7 0 9 1t0 19 12 ada Doo anoa ga de go 36 EEE Fa A ETA E Ail Be 63 65 BR BY BB 69 70 71 fe 7a 74 75 Node ID 64 a2 83 84 85 86 BF DeviceType 0x70191 94 95 96 a7 98 a Pem E 108 107 108 FOS AAG AAAI GECMELCE Pele are 1 E led Figure 17 Device information When moving the mouse over found nodes device information are displayed as a tool tip Page 32 of 125 CANopen Device Monitor Version 3 2 7 pert 11 Description Tab 11 1 Object Description Action NMT SRDO Description PDOs 22 0 0642 software lib ds301 eds Identity Object This object contains general information about the device Sub Index 1 contains a unique value allocated each manufacturer Sub Index 2 identifies the manufacturer specific product code device version Sub Index 3 contains the revision number Bit 31 16 is the major revision number and Bit 15 0 the minor revision number Sub Index 4 identifies a manufacturer specific serial number ObjectType RECORD O d Figure 18 object description The object description contains additional information about the selected index of the object dictionary Beside the actual description the object code for complex objects or the data type and the default value is shown too The object description for each index is read from the object description file 11 2 Object Description File
42. cess image Add single objects by Drag amp Drop from the EDS tree The small button besides the value of the object serves for deleting Whole arrays or records can be added by adding the main index The display format hexadecimal decimal binary or ASCII can be con figured at the combobox in front of the value It is ignored by string values The settings of the process image can be saved with the complete CANopen Device Mon itor project via File gt Project gt Save Project When the project is opened again the process image settings are restored Version 3 2 7 CANopen Device Monitor Page 39 of 125 pert 15 PDO Process Tab The PDO Process Image tab displays the data of TPDOs from the CANopen network There are 2 ways to add Transmit PDOs of the CANopen nodes to the PDO process image e Drag amp Drop the PDO object from the object tree into the PDO process image e via the button Add to PDO Image in the PDO configuration tab To delete all PDOs press the right mouse button and select Clear PDO Process Image This also resets the PDO settings in the CANopen server m4d It is sometimes required to reset the PDO settings directly in the CANopen server if it has not been started from the CDM The display of the data is updated every 1000 ms when the PDO process image tab is active To update the values even when the tab is not visible activate Update even in background e CANopen Device Monit
43. d with the command cdm deleteTab lt pos gt Description deletes an additional tab Parameters pos position of the tab in the display starting with 0 Return nothing Version 3 2 7 CANopen Device Monitor Page 53 of 125 pert 20 Data Management with DCF File The CANopen Device Monitor can handle object values as DCF files ASCII format according to CiA 306 as XDC files XML format according to CiA 311 with the follow ing features object code VAR yes ARRAY yes RECORD yes DOMAIN no compact storage for PDOs analog to EDS for Arrays no Denotation no The base of the DCF file handling is the EDS file therefore it is not possible to load or save a DCF file without loading of EDS file before The handling of DCF files is also not possible when the object dictionary is scanned from the device Only the Object List is support when using XDC files 20 1 Creating a DCF file The file name of the DCF file can be selected freely by the user Objects which are relevant for the DCF file have to be marked by the checkbutton com ponent of DCF file on the tab field Actions The CANopen Device Monitor communicates via SDO with the device by the usage of an internal data buffer Page 54 of 125 CANopen Device Monitor Version 3 2 7 pert DCF File Load Set object value Internal data buffer in the Device Monitor Read from Device DCF File Figure 33 DCF data
44. e settings 16 doc file 118 e editor 15 EDS file 15 f file project 69 g get_node LSS 73 global_stop variable 51 Sa identity LSS 73 index 20 sje LoadConfig 57 logging 63 LSS activate_bitrate 74 get_node 73 identity 73 set_bitrate 73 set_node 73 store 74 switch_glob 73 switch_sel 73 m menu online 56 Message Log 63 network 68 NMT tab 31 NOTEPAD 15 0 object configuration file 57 description 33 118 OCF file 57 octet 46 offline 56 online 56 Options 28 p pause 97 PDO 36 60 preop 31 Preop All 31 Preop Node 31 procedure Tcl 59 profile position mode 77 program download 66 SDO 66 project file 69 afs Repository 15 S SaveConfig 57 Scan Network 31 scripting Tcl 64 script load 59 SDO program download 66 Send Sync 31 set_bitrate LSS 73 set_node LSS 73 slider 43 44 start 31 Start All 31 Start Node 31 stop 31 store LSS 74 strip chart 41 subindex 20 switch_glob LSS 73 switch_sel LSS 73 system requirements 8 to t_start tcl 48 tab Action 43 tab NMT 31 tab set Action 20 Page 122 of 125 CANopen Device Monitor Version 3 2 7 pert tabs user specific 48 Tcl commands 58 procedure 59 scripting 64 tree 20 sys update 51 user specific tabs 48 v variable global_stop 51 W wait 97 Version 3 2 7 CANopen Device Monitor Page 123 of 125 pert Page 124 of 125 CANopen D
45. e tab simplifies controlling CANopen drives in the profile veloc ity mode e Device Monitor Velocity Of x y Profile Velocity Mode Mode settings Profile velocity Profile acceleration 10000 Profile deceleration 10000 Target Velocity mim Actual Velocity Set new Velocity Halt Fault Reset Figure 43 Profile velocity mode tab 31 3 Profile position mode tab The Position Mode Tab simplifies the test and the commisioning of a device The speed the acceleration and the delay as well as the target position can be configured comfort ably Limiting values for these parameters are read from the objects of the device at the initialization of the tab and can t be exceeded After pushing the start button the drive executes the predefined movement The communication with the device is carried out via SDOs Page 76 of 125 CANopen Device Monitor Version 3 2 7 pert e Device Monitor X Profile Position Mode Icl4 D065 Mode settings Profile velocity Profile acceleration Profile deceleration Target position Trajectory settings Mode single set point v E abs Target position 2000 mmj Actual position 9561 uf Status 0x1227 z Start Halt Last Emergency none Figure 44 DSP402 Position Mode 31 4 Object extensions Status 6041 0 E x _ manu 15 manu 14 _ following error Mf setpoint ack _ limit active _ target reached MW
46. e transfered to the EDM not at every PDO cycle but with a configurable interval to reduce the load the EDM This interval can be configured in milliseconds or a value of 0 indicates an event driven transmission Parameters pdoNr number of PDO in EcatServer configuration time_ms time for PDO update in milliseconds Results nothing pdo setHandler lt num gt lt cmd gt Description Registers a PDO indication function for PDO The PDO indication function lt cmd gt is called when PDO number lt num gt arrives The function lt cmd gt is called with three arguments num PDO number dl number of data data list of data Parameters num number of PDO cmd name of PDO indication function Page 88 of 125 CANopen Device Monitor Version 3 2 7 pert Results pdo setPDOIndication lt num gt lt cmd gt Description Registers a PDO indication function for PDO pdo setPDOIndication is a compatibility alias to pdo setHandler The PDO indication function lt cmd gt is called when PDO number lt num gt arrives The function lt cmd gt is called with three arguments num PDO number dl number of data data list of data Parameters num number of PDO cmd name of PDO indication function Results pdo waitForPDO lt pdoNr gt lt script gt Description Waits for a PDO and evals a script when the PDO arrives Parameters pdoNr number of PDO script opt optional script that must ret
47. eAcc value of object 0x6083 delay Time transfer time in ms Results ret see variable p402 ret p402 ppChange lt targetPosition gt lt delayTime gt Description This function changes the target position in the Profile Position mode This function initiates an absolute movement in the single setpoint mode The movement is started by the execution of the new setpoint handling Each drive needs a specific time for the transfer of a new setpoint This time can be specified by the argument delay Time The communication is done via SDO This function can only be used for single drive devices Page 114 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters targetPosition value of object Ox607A delayTime transfer time in ms Results ret see variable p402 ret Version 3 2 7 CANopen Device Monitor Page 115 of 125 pert 34 Appendices Appendix 1 CANopen Commands in Overview Node Guarding e cdm enableGuarding lt node gt lt gtime gt lt ltime gt e cdm disableGuarding lt node gt PDO e pdo set_rpdo lt scope gt lt pdo_nr gt lt cob_id gt lt trans gt lt map_index1 gt lt map_sub1 gt lt map_indexn gt lt map_subn gt e pdo set_tpdo lt scope gt lt pdo_nr gt lt cob_id gt lt trans gt lt map_index1 gt lt map_sub1 gt lt map_indexn gt lt map_subn gt e pdo wpdo lt pdo_num gt lt length gt lt args gt e pdo rpdo lt pdo_num gt e pdo
48. ed for start lt Tcl Procedure gt abort lt Tcl Procedure gt error lt Tcl Procedure gt end lt Tcl Procedure gt EXAMPLE Version 3 2 7 CANopen Device Monitor Page 49 of 125 pert Two additional tab are created The first is named with the default name Test the second one gets the name Some Test Both tabs are assigned different example scripts Figure 26 shows the result t_start tcl add the test selection frames use standard values for the file t_files and name Test cdm addTestTab use user defined values for the file t_files2 and name Some Tests cdm addTestTab t_files2 Some Tests proc my_startHandler args cdm banner proc my_stopHandler args puts n n n n puts date sign puts n n El zZ uU t_files the first set of test scripts using the standard filename start my_startHandler stop my_stopHandler t_myfirst tcl my first test my_1st_test t_mysec tcl my second test my_2nd_test Scanning the network for CANopen devices t scan tel scan the network scan_test t_files2 all testfiles for the second set of tests comments allowed after Here we do not specify start and stop handlers so they won t be called t_scan tcl scan the network scan_test t_myfirst tcl my first test my_1st_test t_mysec tcl my second test my_2nd_test t_myth
49. escription This function activates the halt function 1 e the motion is halted The Halt bit in object 0x6040 controlword is set To reset Halt use the function p402 lt mode gt Change because the necessary functionality to reset Halt is mode specific The communication is done via SDO This function can only be used for single drive devices Example for reset Halt use p402 ppChange for the pp mode Parameters Results ret see variable p402 ret p402 modeSstop lt delayTime gt Description This function stops a motion by the CiA 402 state transition from the CiA 402 state OPERATION ENABLED into the CiA 402 state SWITCHED ON The drive is stopped The communication is done via SDO This function can only be used for single drive devices Note The operation mode is not changed to NO_MODE because not all drives support NO_MODE Page 112 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters delayTime maximal time for state changing in ms Results ret see variable p402 ret p402 pvStart lt targetVelocity gt lt profileAcceleration gt lt delayTime gt Description This function starts a motion in the Profile Velocity mode The Profile Velocity mode is configured by the mandatory objects of the pv mode The operation mode is set to Profile Velocity The motion is started by the change into the CiA 402 state OPERATION ENABLED The communication is done
50. ettings DCF Settings Network Settings _ Set DCF flag on change Colors Download configuration a er DCF import Fonts E Update Verify Configuration object after download E Save configuration after download OK Cancel Set DCF flag on change sets the DCF component flag at change of an object Download configuration after Automatic download of the configuration after DCF import DCF import Save configuration after Automatic saving of the configuration after down download load Update Verify Configura Automatic update of the object 0x1020 with the tion object after download current configuration time 9 3 Network Settings Options ioj xj General Settings Der Setting Network Settings Network Settings 3 SDO Timeout ms Configure Colors oy _ Configure _ Automatic Bus Off Recovery Fonts Ml Emergency Reception SDO Domain Timeout ms 30000 OK Cancel Version 3 2 7 CANopen Device Monitor Page 29 of 125 pert SDO Timeout ms SDO timeout in ms Automatic Bus Off Recovery Automatic Bus On after a Bus Off event Emergency Reception Reception of Emergency messages by the CANopen Device Monitor and forwarding to Emergency handler functions SDO Domain Timeout ms SDO timeout for domain transfers in ms 9 4 Color Settings Options Iof x DCF settings EI SERE CO constant indices Configu
51. evice Monitor Version 3 2 7 pert Table of Contents 1 Introduction er ee ke eR A OE Se RAM BRR DE ES 7 1 1 Product Overview 4 9 2S 4 Sch Ros we wh Rae a Bede Ew he SS 7 1 2 Co v ntonS s cies 44 Doe ah Re SAREE da 8 2 Installation bed kA rra 10 Be QuickStart fe a a a ao FR Oe SS R a e o ee A 11 3 1 Preparations e ee ke we we A ee e ke 11 3 2 First program start o 2 ke Pe BREA RM OE OHS Oe BER 11 3 3 Communication with a CANopen device 2 13 4 Configuration lt s a see Bo 2 as BAe EDR oS 15 4 1 Setting of the CAN Bitrate 2 a a a e 15 4 2 Loading of the Object Dictionary 0 a a a a a o 15 4 3 Device Specific Settings 264 4 2 a a Gk eA ef we Se Se 16 4 4 Start Up Scripts o oea a a e a HE Ee bee eB Ree ao 16 5 CAN Interface Configuration o 18 5 1 Configuration Dialog ee wk ca A A we ee Sy 18 6 Object Dictionary Accesses o oo a a a 20 7 Menu Structure 2 6 Ge aa e A A a A Be oe 23 Mie Files og wie e a a Bh RE ae a e DoF 23 Teza Edito ogoi i aos i AS E AA RA S E 23 Meda SIO ap ee he ee ee ee e n os ee es d e eS G 24 TA CONECO us pa o SOR Soe A eRe Be a ome 2 OS ee oo 24 ls CAR yee ane ok coe es ae Ue A ee ee 25 T6 WIDOWS x pce eae ate Ge B ot Em Bok ee ee SO A Ge SS 26 Tede Help 2 vue ace a el a ee Sek aM a ee 26 Be POCA sona da E Oe HS BHR Dh ea oe Be OS Bare 27 OEP a a be Se Rs Se Bee A GOS AAA AAA a 28 Version 3 2 7 CANopen Device
52. figured accordingly as well using SDOs The 1 is the number of the PDO It is of importance for further commands After that follows the COB ID and the transmission type The last parameters are the mapped objects They have to be specified as pairs of index and sub index Please regard that the EDS file for the device must be loaded and that the objects must exist in the EDS file To change an already configured PDO it must be deactivated before To deactivate the PDO the MSB of the COB ID must be set to 1 The COB ID to deactivate the PDO in the example above is 0x80000221 Page 60 of 125 CANopen Device Monitor Version 3 2 7 pert 24 2 Transmission of PDOs To send a PDO from the CANopen Device Monitor to the device it must be configured previously with pdo set_rpdo because it is a RPDO of the device After that it can be sent by pdo wpdo to the device EXAMPLE The RPDO 2 of the device shall receive two UNSIGNED 16 values and it is already configured pdo wpdo 2 2 0x 1234 Oxfedc The 1st 2 is the number of the PDO The 2nd 2 is the length of the PDO i e the number of mapped objects Take into account that PDOs only can be sent or received in the state OPERATIONAL 24 3 Request of PDOs using RTR If RTR is supported configured TPDOs of the device can be requested by RTR There fore it must be configured with pdo set_tpdo The following example shows how to request PDO 1 EXAMPLE pdo rpdo 1
53. flow 20 2 Load DCF files can be loaded via File gt Load device configuration Load DCF Before a DCF file will be loaded the CANopen Device Monitor executes a consistency check The DCF file has to match to the EDS file Criteria for the consistency check are The EDS file name entered in the DCF file LastEDS The date and time of creation modification in the EDS and DCF file To guarantee the consistency of the object dictionary the EDS file has to be older than the DCF file Loading of a DCF file does not change the CAN bit rate and the node id in the CANopen Device Monitor The parameter values are only loaded to the internal data buffer of the CANopen Device Monitor and are transfered to the device after Send see chapter Data Management with DCF file Send 20 3 Send All selected parameter values will be sent from the internal data buffer of the CANopen Device Monitor to the device per SDO via Extras Send conf to Device Sending is also allowed when the parameter values are not stored in a DCF file Version 3 2 7 CANopen Device Monitor Page 55 of 125 pert 21 Offline Mode The SDO communication to the device can be switched on off with the options off line online in the menu Connection when the Device Monitor is connected Therewith it is possible to create a DCF file without communication with the device SDO write online SDO write offline internal
54. g test scripts It contains a wid get with several check boxes for selecting test scripts Number and names of the check boxes are read from the configuration file lt work ing directory gt lt t_conf1 n gt Additional buttons are available for starting stopping and global selection of test scripts If tab_name is not given the name is built as Test counting from 1 for each new tab Parameters t_conf name of the file containing the names of the test scripts defaults to t_files tab_name name for labeling the tab Return internal name of the tab Format of the lt working directory gt t_files Lines beginning with are comments and are ignored Each line describes one addi tional check box lt script gt tcl lt label gt Tcl procedure name script tcl Name of the Tcl script that is to be executed label Name label for the check box Tcl procedure name Tcl procedure that carries out the test If the test was com pleted successfully the procedure shall return 0 Any other return value means an error occured If the proce dure has a parameter the test description from the t_files is passed in this parameter Script name label and Tcl procedure are separated by space or tab In addition special Tcl procedures can be registered for Start of a test run Abort of a test run Error of a test and End of a test run The Tcl procedures are specified as follows and are only executed for the test tab they were specifi
55. h numerical object can be displayed bitwise in a unique window 64 6000 001 ME _ bit oO _ bit 1 E bitz _ bit 3 _ bita E bits E bits _ bit 7 send Close object window Figure 29 Bit box in a top level window receive i All object extension can be activated by pressing the right mouse button in the object tree 3 6000 Read Input amp Bit 9 000 Number of Input 6 Bit 9 001 Read Input 1h to oh F 002 Read Input 9h i Bitbox I 6200 Write Output amp CA 6206 Error Mode Oute Slider window 6207 Error Value Cute 6401 Read Analogue b421 Analogue Input Set object action Delete object action Figure 30 Configuration of the GUI Extension The assignment of slider and bit boxes to particular objects can be saved in a OCF file Version 3 2 7 CANopen Device Monitor Page 45 of 125 pert 18 Usage of Octet strings 18 1 Value entry frame In the value entry frame octet strings can be written to or read from the device To write an octet string to a device select an object with data type octet string Then two entries will appear in the value entry frame The octet string can be typed into the upper entry To specify non printable values use the 1x00 notation It must be lower case letters and it requires exactly 2 digits after the x ASCII characters can be used as well EXAMPLE x00 x01 x02 x03 x05 x06 x07 x08 x09 xOa xff xfeHello World x0a x00 Hit RE
56. howHello Heinz Hello Heinz How are you Version 3 2 7 CANopen Device Monitor Page 59 of 125 pert 24 Scripting with PDOs To test the PDO handling of a device or to simulate complex control processes PDOs can be configured sent received and requested by scripts and by console commands H After a modification of the PDO configuration by Tcl Tk Scripts the reception and the transmission of PDOs in the PDO mask is not supported anymore As the CANopen Device Monitor resp the CANopen server acts like a CANopen device within the network PDOs must be configured internally so that they can be sent or received 24 1 Configuration of PDOSs in scripts To configure the PDOs the point of view of the remote device is used PDOs sent from the device are TPDOs and PDOs that are received by the device are RPDOs To config ure the PDOs the commands pdo set_tpdo und pdo set_rpdo can be used The following example shows the configuration of a TPDO For RPDOs it is simu lar and described in the section PDO commands EXAMPLE The device has one TPDO TPDO No 1 which contains the objects 0x6000 1 and 0x6000 2 It is trans mitted event trigged by the device Its COB ID is 0x221 The appropriate call to pdo set_tpdo is pdo set_tpdo local 1 0x00000221 event 0x6000 1 0x6000 2 The parameter local means that only the CANopen Device Monitor shall be configured If it were remote the remote device would be con
57. in the EDS tree you can access it for reading and writing on the action tab depending on the access type When pressing Send to object only the expression after the last blank is transmitted It is possible to write mathematical expressions into the entry field as well The CANopen Device Monitor calculates them and transmits the result to the device However the expression may not contain any blanks gt Value Entry Frame used for saving configuration _ component of DCF file 100 5 4 Figure 5 Formulas in the entry The NMT tab serves for sending NMT commands This can be torn off like every tab from the anchorage in the CANopen Device Monitor out into a separate window Version 3 2 7 CANopen Device Monitor Page 13 of 125 pert e CANopen Device Monitor Node 26 IclA D065 File Edit View Connection Extras Windows gy Node taj2e set 1 32 BA a Communication Segment Chart Process 1000 device type PDO SRDO 1001 error register Action NMT B A a 2 8 8 8 8 a pa DELELE 1002 manufacturer status regi 1003 pre defined error field 1005 COB ID SYNC messagi 1008 manufacturer device i0 100C guard time 1000 life time factor 1010 store parameter 1011 restore default paramete 1014 COB ID Emergency mesi 1018 identity objekt 1200 server SDO parameter 1400 1st receive PDO parame 1401 2nd receive PDO param 1600 1st receive PDO mappin 16
58. index object index subindex object subindex typ datatype of object lt uSlu16lu32118111611321r32lvs gt Results read value rr lt index gt lt subindex gt lt typ gt Description SDO read procedure type out the SDO read command and the answer from the device Parameters index object index subindex object subindex typ datatype of object Results read value rrc lt index gt lt subindex gt lt typ gt lt ref gt Description SDO read and compare procedure type out the SDO read command type out the answer from the device and compare the received value with the reference value In case of an error the global variable test_error is set to 1 Page 80 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters index object index subindex object subindex typ datatype of object ref reference value Results 0 received value is equal to the reference value 1 received value differs from the reference value rre lt index gt lt subindex gt lt typ gt Description SDO read and message error type out the SDO read command type out the answer from the device and check the received value Parameters index object index subindex object subindex typ datatype of object Results 0 received no SDO abort domain transfer 1 received SDO abort domain transfer w lt index gt lt subindex gt lt typ gt lt val gt Description SDO write procedure Parameters index object index subinde
59. ird tcl another my_3rd_test Page 50 of 125 CANopen Device Monitor Version 3 2 7 pert t_myfirst tcl Writ Heartbeat Producer and check if value can be read back proc my_lst_test args wwe 0x1017 0 ul6 1000 OK if S global_stop 1 return Canceled rrc 0x1017 0 ul6 1000 return 0 The tabs are visible after loading the file with the tab specification Loading can be done via the menu Console File Load File gt t_start tcl source t_start tcl or by issuing the source command in the Once after loading the new tab any changes at the files lt working directory gt t_start tcl and lt working directory gt t_ lt t_confl n gt are only recognized and valid after a restart of the CANopen Device Monitor and reloading of lt working directory gt t_start tcl The tabs for testing contain the following additional control buttons Select All mark all scripts for execution Select None deselect all check boxes remove all scripts from execution Start Test start loading and executing of the selected test scripts Abort Test stop execution of test scripts Normally the execution stops at the end of the currently running script If a run ning script has to abort immediately it must do some preperations The script must look for the state of the global variable global_stop If the Abort Test button is selected the value of global_st
60. is moving For operating use the following keys If the left mouse button is pressed in the trough the scale s value will be incre mented or decremented by the value of the resolution option so that the slider moves in the direction of the cursor If the button is held down the action is repeated If the left button is pressed over the slider the slider can be dragged with the mouse If the left button is pressed in the trough with the control key down the slider moves all the way to the end of its range in the direction towards the mouse cursor The up and left cursor keys move the slider by one to left The down and right cursor keys move the slider by one to right Further a storage of the object values with the option used for saving configuration is possible Version 3 2 7 CANopen Device Monitor Page 43 of 125 pert 17 2 Slider in a Top Level Window A slider in a top level window can be assigned to an object This window stays at the desktop even if other objects are selected in the tree structure 1 6200 001 36 Close object window Figure 28 Slider in a top level window The slider actions are the same as described for the Action tab slider above Close object window The top level window can be closed by selecting the button labeled with Close object window Page 44 of 125 CANopen Device Monitor Version 3 2 7 pert 17 3 Switch Box Display of Objects Eac
61. k Overview Online A Offline Toggles the view of the toolbar Toggles the view of the statusbar Toggles the view of the console only full version Toggles the view of the log window Toggles the view of the network overview Interface Connects to the CANopen server resp starts the CANopen server Closes the connection to the CANopen server resp closes the CANopen server Read and write accesses are performed directly with the device Read and write accesses are performed with the DCF data buffer Opens the dialog to configure the CAN interface Page 24 of 125 CANopen Device Monitor Version 3 2 7 pert 7 5 Extras scan Obj Dict Comm Scan Obj Dict Device Edit Obj Dict Show EDS File Export EDS File Ci4 306 3 format Send object values to device Read object values from device Set DCF component flag for all objects Unset DCF component flag for all objects Store Restore non volatile parameters Convert to concise DCF Plug ins Options Scan Obj Dict Comm Scan Obj Dict Device Edit Obj Dict Export EDS File Send object values to device Read object values from device Store Restore non volatile parameters Convert to concise DCF Plug ins Options Scans the communication profile segment of the object dictionary Scans the device profile segment of the object dictio nary Opens a simple OD Editor It is e g useful to add
62. local 1 0x220 event 0x6000 1 0x6000 2 Page 84 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters scope locallremote local configure only CANopen Gateway pdo_nr number of pdo cob cob id for this pdo trans transmission type eventlrtrisync lt 1 240 gt index 1 1st index to be mapped format 0x 4X subl 1st sub to be mapped decimal indexN nth index to be mapped subN nth sub to be mapped Results pdo wpdo lt num gt lt length gt lt args gt Description Transmits a predefined PDO It must be configure with set_rpdo before Example pdo wedo 1 2 Oxff Oxaf Parameters num tpdo number length number of data items args valuel value2 valueN Results pdo wwpdo lt num gt lt length gt lt args gt Description PDO write procedure type out the PDO write command Parameters num PDO number length number of data items args valuel value2 valueN Version 3 2 7 CANopen Device Monitor Page 85 of 125 pert Results nothing pdo rpdo lt num gt Description Requests a predefined PDO by rtr It must be configure with set_tpdo before Example pdo rpdo 63 Parameters num number of PDO Results pdo setEcatTpdo lt num gt lt node gt lt nodePdoNum gt lt mapCnt gt lt dataTypes gt Description Configure EcatServer to forward TPDO of the device to the EDM Example pdo setEcatRpdo 1 27 2 4 u8 ul6 ul6 us Parameters num n
63. m4d directory on the installation CD H Please read this file before you start the installation 2 Execute setup exe e Full Installation The installation of all software components is happened auto matically and menu driven This includes copying of all manuals e Customized Installation The selection of software components is possible which can be installed For the installation of the CANopen Device Monitor the following components are necessary CANopen Device Monitor m4d and layer 2 driver 3 For the icon on the desktop set the options for the call of the m4d server depending on your application An overview of the options are given by the help m4d h Alternatively the CANopen Device Monitor is able to start the CANopen server m4d For additional hints please see section Hardware Configuration 4 Define the working directory for the shortcuts on your desktop depending on your application Page 10 of 125 CANopen Device Monitor Version 3 2 7 pert 3 Quick Start 3 1 Preparations e Make sure that the CAN interface the Layer 2 driver and the CANopen server m4d are installed correctly e The path to the CANopen server m4d must be known mostly in the CDM direc tory e The preferential method for the start of the CANopen server must be clear possibility 1 the m4d is started by the CDM on your local computer possibility 2 you start the m4d on an arbitrary computer in the network and the CANopen Device M
64. me for a given node Parameters node node Id of monitored node time interval in ms Results cdm enableSync lt sync gt Description if no argument is provided it asks the user for a sync intervall and enables sync Parameters sync sync intervall in ms opt Results cdm readUu64 lt index gt lt subindex gt Description Read a u64 variable as octet string and return a string like 0x1234567812345678 Page 94 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters index index subindex subindex Results Returns a u64 value cdm writeU64 lt index gt lt subindex gt lt value gt Description Write a u64 variable as octet string Parameters index index subindex subindex value u64 value Results cdm status lt fileName gt Description Print out a lot of internal status informations It might be useful for support purpose Parameters fileName file name for output opt Results cdm disableSync Description Disables the transmission of SYNC messages Version 3 2 7 CANopen Device Monitor Page 95 of 125 pert Parameters Results emcy setHandler lt cmd gt Description Registers a indication function for emergencies The indication function is called when an Emergency message arrives It has these arguments node node id args emergency Parameters cmd name of indication function Results sdo setH
65. mples will be given for using Tel com mands in the Console window The bibliography refers to books and web pages for the Tcl language EXAMPLE set val 5 set the variable val to the value 5 set val show the current value of the variable val puts Hello put the word Hello at the Console comment set myarray baud 19200 define the array myarray set myarray parity even variables are referenced by using its name preceeded with S puts Bitrate myarray baud reference of the array myarray Further information can be found at www tcl tk http www tcl tk Page 58 of 125 CANopen Device Monitor Version 3 2 7 pert 23 2 Scripts Sequences of Tcl commands inclusive of controlling structures can be created with a text editor These files used to have the extension tcl and can be loaded from the CANopen Device Monitor per menu File gt Load File interactively input in the Console source lt file gt tcl Command sequences can be combined to procedures The procedure is executed by call ing the name of the procedure Procedures saved in Tcl files are available after loading the script file EXAMPLE file example tcl show Hello proc showHello name puts Hello Sname puts How are you return load the script with the source command in the Console source example tcl execute the defined procedure in the Console interactively S s
66. ne the data by it s index sub index and length The structure of a mapping entry is index subindex length 1A14 Transmit PDO Mapping Parameter Version 3 2 7 CANopen Device Monitor Page 119 of 125 pert Literature 1 2 11 Tcl and the Tk Toolkit Ousterhout John K Addison Wesley 1994 ISBN 0 201 63337 X Practical Programming in Tcl and Tk 2d ed Welch Brent Prentice Hall 1997 Tcl Tk Tools Harrison Mark O Reilly amp Associates 1997 Effective Tcl Tk Programming Harrison Mark McLennan Michael Addison Wesley 1998 Literature in the Internet http www tcl tk http wiki tcl tk http www activestate com solutions tcl http incrtcl sourceforge net blt index html The BLT Toolkit BLT is an extension to the Tk toolkit adding new widgets geometry managers and miscellaneous commands Tcl and the Tk Toolkit Ousterhout John K Jones Ken Addison Wesley 2010 second edition ISBN 978 0 321 33633 0 CANopen Device Monitor Wiki http www can wiki info CanOpenDeviceMonitor The CANopen Device Monitor Wiki is a constantly growing collection of sample scripts and tips Page 120 of 125 CANopen Device Monitor Version 3 2 7 pert 35 Glossary CAN CAN FD CAL CDM CiA CN COB COB ID CSDO EDM EDS ESI EMCY EPSG ETG MN NMT OD PDO RPDO RTR PDM PRMS SDO SSDO SYNC Tel TCP IP TIME Tk TPDO Widget Controller Area Network Controller Area
67. nt of the location of the Device Monitor and the CANopen server The user interface and the driver can be at the same computer or on different computers connected by a LAN typically an Ethernet TCP IP connection CAN Interface CAN Interface Figure 1 Structure of the CANopen Device Monitor The CANopen Device Monitor is available in two variations e full edition and Version 3 2 7 CANopen Device Monitor Page 7 of 125 pert e Starter Kit edition The StarterKit edition has the following limitations no console for work with scripts unconfigurable SYNC cycle fixed bit rate 125 kBit s no device configuration by DCF file support of only some fixed node IDs The CANopen Device Monitor has the capability to execute scripts in full edition A script can contain variables and control structures just like in every modern structured language Complete master applications can be developed using the language Tcl Tk http www tcl tk The Device Monitor has the following requirements to the system it is running on Operating System Windows Vista UNIX LINUX RAM 512 MByte Hard Disk 25 MByte The performance of the CANopen Device Monitor depends on the used CAN interface hardware Especially at high bus load and high baud rates some CAN messages may be lost 1 2 Conventions This manual uses the following conventions OPERATIONAL Communication states are written in capital letters tcl
68. onitor connects to the m4d e The name of the used CAN interfaces must be known E g can0 canl using can4linux CHANOO CHANO1 at the use of CPC hardware Lpy2Pp and additional unit device parameter at LevelX hardware 3 2 First program start At the first start of the CANopen Device Monitor the following dialog window appears which can vary depending on operating system and available hardware CAN Intertace Configuration CAN Interface caninu hd CanNopen Server s22f0 084 2 user_ marn ndd_s a Baud Rate 125 Device cand Timeout 000 Advanced Settings OK Cancel Figure 2 Hardware configuration dialog If the CDM shall only connect to a running CANopen server select at CAN interface TCP In this case you need to adjust only the host and the port of the server The dia logue window can be closed with OK Version 3 2 7 CANopen Device Monitor Page 11 of 125 pert In other case the following parameters must be typed in e CAN Interface e path to the CANopen server e baud rate of the CAN bus e name of can interface If all parameters are configured the dialog window can be closed with OK The CANopen Device Monitor starts the CANopen server now and the client server architec ture gets in the background All settings in this dialog window can be changed any time via Connection gt CAN Interface The CANopen Device Monitor star
69. op is set to 1 The script on the other side must not block the User Interface event loop so that the user is be able to select the Stop but ton Therfore the Tcl function update must be called regularly EXAMPLE Version 3 2 7 CANopen Device Monitor Page 51 of 125 pert Template for testing global_stop in test scripts global variables global global_stop initialize global variables set global_stop xecute application while global_stop read actual value of global_stop and update the GUI update 19 2 User specified tabs without contents A new tab will created by the following command cdm addTab lt title gt lt pos gt Description creates an additional empty tab Parameters title name of the tab pos position of the tab in the display default append as last tab Return internal name of the tab The empty tab can be designed by the application by input of Tcl commands at the Console or by Tcl scripts EXAMPLE Create an empty tab at position 0 with the title Service set name cdm addTab Service 0 Create a button in the center of the bottom of the tab with the name OK button Sname button text OK command w 0x1017 0 ul6 500 pack Sname button side bottom anchor center Page 52 of 125 CANopen Device Monitor Version 3 2 7 pert 19 3 Erasing User Specified Tab sets Tab set can be delete
70. or Node 64 PDO Image X PDO Process Image COB ID Data Node 72 PDO 1 Oxlc8 AIO 2944 AI1 29248 Node 64 PDO 2 Ox2c0 Analog Input 1h 19232 Analog Input 2h 16000 Node 32 PDO 1 Oxla0 12th Application Variable 0x0000124c Node 32 PDO 2 Ox2a0 7th Application Variable 0x00000004 E Update even in background Figure 24 PDO Process image The settings of the process image can be saved with the complete CANopen Device Mon itor project via File gt Project gt Save Project When the project is opened again the process image settings are restored Page 40 of 125 CANopen Device Monitor Version 3 2 7 pert 16 Using Stripcharts For data visualization the pre installed Chart tab can be used It shows as an example the usage of a strip chart After opening the Chart tab a strip chart is displayed Besides for the visualization of PDO data it can be also used by scripts Values are given to it by calling the Tcl proce dure cdm addChartData The procedure is defined as follows proc cdm addChartData valueList add new values to the strip chart window valueList contains a list of values for the strip chart EDS 9 cdm addChartData 1 2 3 EDS 10 cdm addChartData 1 2 3 e Device Monitor Node 32 CO4011A0 Values from Mode 32 Figure 26 strip chart after two calls to cdm addChartData Version 3 2 7 CANopen Device Monitor P
71. or Version 3 2 7 pert 33 6 Test commands cdm addTab lt titel gt lt pos gt Description adds a tab into the Tabset of the right side Parameters titel name of the Tab displayed at the pos position starting with 0 can be end Results frame the window name of the top level frame within this tab cdm deleteTab lt pos gt Description deletes a tab from the tabset Parameters pos position starting with 0 can be end Results cdm addTestTabOld lt filename gt lt title gt Description adds a special tab on the right side of the device monitor the tab card contains checkbuttons for test scripts the list with scripts is in a file and will set by user Parameters filename name of the file which contains a list of scripts for the spe cial tab title title of the tab Results window path to Tab Version 3 2 7 CANopen Device Monitor Page 99 of 125 pert cdm stringCenter lt string gt lt l gt Description center string prepend spaces to a given string if the result will be printed it looks like it is centered within a line lenght of 1 Parameters string unformated string l desired line length Results centered string cdm stringFill lt string gt lt endword gt lt 1 gt Description append spaces and endword at string until line length 1 Parameters string unformated string endword optional END word defaults to l desired line length defaul
72. pert CANopen Device Monitor User Manual Eile Console Edit Prefs History AN Help software 3 0 45 64 r 0x1000 0 u32 0x70191 software 3 0 46 2 64 r 0x1008 0 vs CANopen Chip164 software 3 0 47 64 w 0x1017 0 u16 1000 0K softuare 3 0 48 2 File Edit View Connection Extras Windows S s nocenalos set GHB re BOO a Communication Segment SRDO LSS Chart Process 3 1000 DeviceType Action Description PDO 1001 ErrorRegister 1002 ManufacturerStatusRegister 1005 COB ID SYNC Value Entry Frame HardwareV Hex 0x70191 Dec 459153 100B NodelD 100C GuardTime 100D LifeTimeFactor 100E COB ID guard Action Frame 1014 COB ID EMCY 1015 Inhibit Time EMCY 1017 Producer Heartbeat Time 1018 Identity Object 1400 RPDO1 CommPar 1600 RPDO1 Mapping 3 hito 1800 TPDO1 CommPar bit 1A00 TPDO1 Mapping F E bit2 J bit 3 online connected to localhost Receive from Object send to Object B 0 8 64 6000 00 la PRRPRRPRRRPRRPRePeeRe a ae Control 6040 0 E bite _ tecelve Shutdown _j mode_4 manu_11 J bit send JJ Switch On mode_5 manu_12 AAA Ml Disable Voltage _ mode_6 _ manu_13 Close object window _ Quick Stop halt manu_14 Disable Operation _ manu_15 _ Enable Operation _ Fault Reset Delete Object Action Send Receive
73. pport of test One of an additional tab is also predefined but only installed on request It is used to organize test scripts to be controlled by the CANopen Device Monitor It provides lists of check boxes for the user defined test scripts e CANopen Device Monitor Node 32 Generic mininmm capability device File Edit View Connection Extras Windows B Communication Segment Action NMT Description PDO SRDO A 1000 Device Type LSS Chart Process Testi a 1001 Error Register A 8 3 1016 Identity Object 3 000 number of entrie m 3 001 Vendor Id Help my first test _ my second test _ scan the network Figure 26 User Defined Tabbed Field with Test Scripts An example can be found in the directory lt working directory gt demo_t Configuration of the predefined tab for test organization is done by configuration files e lt working directory gt demo_t t_start tcl and e lt working directory gt demo_t t_ lt conf1 n gt tcl The file lt working directory gt demo_t t_start tcl configures all preconditions for testing It also defines all additional tab using the command cdm addTestTab Figure 26 shows an example for an additional tab Page 48 of 125 CANopen Device Monitor Version 3 2 7 pert cdm addTestTab t_conf lt tab_name gt Description Creates an additional tab on the right side of the CANopen Device Monitor It is predefined for organizin
74. re RO read only indices Configure WO write only indices Configure RW read write indices Configure OK Cancel This dialogue allows the configuration of specific colors for objects with different access types 9 5 Font Settings Options BIE DCF Settings B Network Settings IE Configure Colors Description Tab Configure Received Messages 2 Configure Sent Messages a 21 Configure ok Cancel This dialogue allows the configuration of specific fonts for different GUI elements Page 30 of 125 CANopen Device Monitor Version 3 2 7 pert 10 NMT Tab 10 1 NMT commands For the execution of NMT services this tab provides some buttons Button Description Start Network Set all nodes in the state OPERATIONAL Start Node Set the node with the active node id in the state OPERA TIONAL Preop Network Set all nodes in the state PRE OPERATIONAL Preop Node Set the node with the active node id in the state PRE OPERA TIONAL Stop Network Set all nodes in the state STOPPED Stop Node Set the node with the active node id in the state STOPPED Reset Comm Send the NMT command Reset Communication Reset Node Send the NMT command Reset Node Enable Sync Starts the cyclic transmission of the SYNC message Disable Sync Stops the cyclic transmission of the SYNC message One Sync Sends one SYNC message The control of the state machine is also possible by the con
75. rver recently used node IDs Figure 16 Toolbar Version 3 2 7 CANopen Device Monitor Page 27 of 125 pert 9 Options 9 1 General Settings Options PE General Settings f DCF Settings General Settings Network Settings E Read object on selection Colors E Auto Connect Fonts _ lt Del gt deletes complete input field _ Reload last project file at start up Ml Save all settings at exit _ Reuse last EDS file for empty nodes E Copy EDS files to project directory A eps repository Configure RI I OK i Cancel Read object on selection read object immediately on selection Auto Connect Connect to server at start up lt Del gt deletes complete entry field lt Del gt key deletes complete input field in value entry frame Reload last project file at start up The lastly used project file is opened automati cally at start up of the CANopen Device Monitor Save all settings at exit All settings options and connection settings are saved automatically Reuse last EDS for empty nodes The last EDS file is used for other node IDs with out assigned EDS file Copy EDS files to project directory The EDS files are copied from the repository to the project folder if it is saved EDS repository Configuration of the directory for the EDS reposi tory Page 28 of 125 CANopen Device Monitor Version 3 2 7 pert 9 2 DCF Settings Options Of x DCF S
76. sole 10 2 User defined scripts By pressing the buttons Script 1 to Script 4 scripts with the file names scriptl tcl script4 tcl are started if this files can be found in the current working directory or in the program directory Test starts the script t_start tcl if it exists Modify these scripts to match your needs and use them to automate repetitious tasks like configuring a device Tooltips over each button show the first line of the corresponding script file So the first line of a script contains a comment about the content of the scripts Additionally the last word of the first line of a script can be a valid color definition e g red or ffaall to modify the background color of the specific button Within these scripts all CDM com mands are available This function is only available in the full version Using the eval version only integrated demo scripts can be loaded Version 3 2 7 CANopen Device Monitor Page 31 of 125 pert 10 3 Network overview After scanning the network the buttons for the nodes get different colors Color Meaning background color no node found blue node found yellow active node during network scan To change the active node simply press the button with the desired node id If an EDS file has been loaded already for this node it is displayed in the EDS tree Otherwise an EDS file for this device can be loaded For all nodes different EDS files can be loaded 10 4 Devi
77. sub gt lt timeout in ms gt lt file gt Network e cdm profileScan lt dprf gt lt timeout gt e cdm getRemoteID e cdm setRemoteID lt node gt EDS e cdm loadEDS lt fileName gt Object dictionary access e cdm getDataType lt node gt lt index gt lt sub gt e cdm getObjectType lt node gt lt index gt e cdm getDefaultValue lt node gt lt index gt lt sub gt Test Protocol Header e cdm banner Tabbed Fields e cdm addTab lt tab_text gt lt pos gt e cdm addTestTab t_ lt conf gt lt tab_text gt e cdm deleteTab lt pos gt Formatting of Strings e cdm stringCenter lt string gt lt line length gt e cdm stringFill lt string gt lt endword gt lt line length gt Page 118 of 125 CANopen Device Monitor Version 3 2 7 pert Appendix 3 Creation of an Object Description An object description lt working directory gt lt device gt txt has an entry for every object This entry consists of 1 2 3 4 the index 4 digit hexadecimal followed by the EDS name an empty line and the description The description is not limited in the length The text of the description does not allow to contain an index see 1 at line start 1A00 Transmit PDO Mapping Parameter It contains the mapping parameter for the PDOs the device is able to transmit Sub index 0 contains the number of the mapped data objects All further entries defi
78. t rate is specified as start up option of the m4d server It is valid for the CANopen Network not only for one Device Monitor instance During start up the Device Monitor loads the file lt working directory gt cdm rc Please use an editor that is capable of handling LF line endings correct Do not use notepad exe H The following sub section can be skipped if the CANopen server m4d is started by the CANopen Device Monitor For additional hints please see section Hardware Config uration 4 1 Setting of the CAN Bitrate The CAN bit rate will be set at the call of the m4d server Windows A ProgramFiles CANopen gt m4d_ lt driver gt _s exe b lt CAN bit rate gt S Unix usr bin m4d_s b lt CAN bitrate gt S All CAN bit rates defined in CANopen are available 4 2 Loading of the Object Dictionary Every device manages its parameters in an object dictionary The object dictionary can be stored in a CANopen defined format the Electronic Data Sheet or EDS file Every device has its own EDS file During start up the Device Monitor can load a default EDS file If you exchanged CANopen Devices you can load the EDS File of the CANopen device File Load EDS The management of the EDS files is simplified by the EDS repository The repository is a directory that contains all EDS files Via Extras gt Options EDS Repository the EDS repository can be configured If the EDS repository is configured correctly the following
79. ts the CANopen server now and at success the online status 1s displayed in the status bar and the background of the entry field turns pink H A valid configuration of the hardware interface is saved by the CANopen Device Monitor and can be reused at the next start of the program Additionally it is possible to activate Extras gt Options gt Auto Connect so that the CANopen Device Monitor connects automatically at every start of the program e CANopen Device Monitor Node 32 Generic minimum capability device File Edit View Connection Extras Windows Help gy Nodeta sz set 1 32 64 126 127 GRR recor 58 O g B Communication Segment 1000 Device Type 29 1001 Error Register 1018 Identity Object Value Entry Frame m LSS Chart Process Description PDO Action Frame Receive from Object online Figure 3 CANopen Device Monitor Page 12 of 125 CANopen Device Monitor Version 3 2 7 pert 3 3 Communication with a CANopen device Adjust the node ID of the CANopen device in the tool bar first Please take into account that the choice must be confirmed with Set ls x Node Id 32 En 1 32 a ej Figure 4 Toolbar As a second step the EDS file of the device can be loaded via File gt Load EDS tively the mandatory objects can be accessed by the default EDS Alterna After the selection of an object
80. ts to 80 Results formatted string cdm banner Description prints a headline with device and user characteristic Parameters nothing Results nothing Page 100 of 125 CANopen Device Monitor Version 3 2 7 pert cdm putsDateTime Description prints the current date and time Parameters nothing Results nothing cdm commentInput lt wtitle gt lt cancelstring gt Description user input for comments Parameters wtitle window title cancelstring cancel string Results nothing cdm userDialog lt title gt lt type gt Description user response dialog if a dialaog is finished with Not Ok another dialogbox for giving a reason is opened Parameters title additional text for displaying to the user type specifies the type of dialogue only wait for OK decide between OK and NotOk decide between OK NotOk and Abort decide between OK and NotOk without comment decide between list of given choices Burro Version 3 2 7 CANopen Device Monitor Page 101 of 125 pert Results 0 decided for OK 1 decided for Not OK 2 decided for Abort or selected button text for type 4 Page 102 of 125 CANopen Device Monitor Version 3 2 7 pert 33 7 CDM commands cdm getObjectType lt node gt lt index gt Description Returns the objectType Parameters node node ID means current node ID as d or 0x x index index as
81. umber of pdo in EcatServer node Slave node Id nodePdoNum pdo number at node mapCnt number of mapped objects dataTypes list of dataTypes which are mapped Results Returns OK or error message pdo setEcatTpdo lt num gt lt node gt lt nodePdoNum gt lt mapCnt gt lt dataTypes gt Page 86 of 125 CANopen Device Monitor Version 3 2 7 pert Description Configure EcatServer to send data to a RPDO at the device Example pdo setEcatRpdo 1 27 2 4 u8 ul6 ul6 u8 Parameters num number of pdo in EcatServer node Slave node Id nodePdoNum pdo number at node mapCnt number of mapped objects dataTypes list of dataTypes which are mapped Results Returns OK or error message pdo resetEcatTpdo Description This proc resets all configured TPDOs at the EcatServer Parameters Results pdo resetEcatRpdo Description This proc resets all configured RPDOs at the EcatServer Parameters Results pdo setPDOCycle lt time_us gt Version 3 2 7 CANopen Device Monitor Page 87 of 125 pert Description The EcatServer as EtherCAT Master exchanges the PDO data with all connected slaves at a given interval which is called here PDO cycle This PDO cycle can be configured with that function Parameters time_us time for PDO cycle in microseconds Results nothing pdo setPDOTransmission lt pdoNr gt lt time_ms gt Description Process data from the slaves ar
82. urations and configurations made at the Process Image tab are restored 28 1 Import Export of CCM project files Project files of the CANopen Configuration Manager CCM can be loaded Likewise the CCM can import project files of the CANopen Device Monitor Not all settings are imported in both ways but the Node lt gt EDS assignments and the connections defined in the CCM are preserved Version 3 2 7 CANopen Device Monitor Page 69 of 125 pert 29 SRDO Tab CANopen Device Monitor File Edit View Connection Extras Windows S gy Node td 1s set xl Help D D D D D m_ Ca PEDALA PRRPRRRRLRR 1015 Inhibit Time Em 1017 Producer Heart 1018 Identity Object 1301 1 SRDO param 000 Number of En 001 Information di 002 Refresh Time 003 SRDO valid ati 004 Transmission 005 COB ID 1 006 COB ID 2 1381 1 SRDO mappi 000 Number of En 001 1 SRDO Map 002 1 SRDO Map 003 2 SRDO Map 004 2 SRDO Map 005 3 SRDO Map 006 3 SRDO Map 007 4 SRDO Map 008 4 SRDO Map 13FE Safity Configur anrr O e online connected to localhost Figure 40 SRDO mask The SRDO tab combines all settings of a SRDO At the selection of a SRDO Object in the object dictionary the SRDO tab is updated with the data from the EDS or with previ ous read data from the device By pressing the Read from Device button the data are read immediately from the devi
83. urn 1 if it exists Within the script the variables val 1 val 2 val n can be used They contain the values of mapped objects in the PDO val 1 refers to the Ist object val 2 to the 2nd and so on Results Version 3 2 7 CANopen Device Monitor Page 89 of 125 pert 33 3 NMT commands nmt start lt node gt Description Sends the NMT command start to one or all nodes Parameters node node ID 0 addresses the whole network Results inmt stop lt node gt Description Sends the NMT command stop to one or all nodes Parameters node node ID 0 addresses the whole network Results inmt preop lt node gt Description Sends the NMT command enter pre operational to one or all nodes Parameters node node ID 0 addresses the whole network Results inmt resetComm lt node gt Page 90 of 125 CANopen Device Monitor Version 3 2 7 pert Description Sends the NMT command reset communication to one or all nodes Parameters node node ID 0 addresses the whole network Results inmt resetAppl lt node gt Description Sends the NMT command reset node to one or all nodes Parameters node node ID 0 addresses the whole network Results nmt resetServer Description It reset the ECAT server and rebuilds PDO data Parameters Results Version 3 2 7 CANopen Device Monitor Page 91 of 125 pert
84. ved messages to CDM and not all are able to display it s own messages sent In this case messages sent are not displayed or displayed in red color The message shown must not be displayed in the correct time order It is only the time when the message is scheduled to the driver The message itself is sent when there are no messages with a higher priority on the bus The Message Log has a remarkable influence on the performance of the CANopen Device Monitor at high bus loads To increase the performance close the Message Log window H Message logging is not supported by every CANopen server 25 1 Scripting Interface Some parts of the functionality of the Message Log can be used by scripts The provided functions are open_messagelog Description Open the message log window Page 64 of 125 CANopen Device Monitor Version 3 2 7 pert Parameters none Results none clear_messagelog Description Clear the content of the message log Parameters none Results none save_messagelog lt fileName gt Description Save the content of the message log into a file Parameters fileName path to file Results none Version 3 2 7 CANopen Device Monitor Page 65 of 125 pert 26 SDO Program Download The Device Monitor is capable of downloading files to CANopen devices This can be any kind of file e g new software versions parameters etc The CANopen device has to support the SDO Dom
85. via SDO This function can only be used for single drive devices Parameters target Velocity value of object Ox60FF profileAcceleration value of object 0x6083 delay Time maximal time for state changing in ms Results ret see variable p402 ret p402 pvChange lt targetVelocity gt Description This function changes the velocity of the movement in the Profile Velocity mode The communication is done via SDO This function can only be used for single drive devices Parameters targetVelocity value of object Ox60FF Results ret see variable p402 ret Version 3 2 7 CANopen Device Monitor Page 113 of 125 pert p402 ppStart lt targetPos gt lt profileVel gt lt profileAcc gt lt delayTime gt Description This function starts a motion in the Profile Position mode The Profile Position mode is configured by the mandatory objects of the pp mode The operation mode is set to Profile Position This function initiates an absolute movement in the single setpoint mode The motion is started by the change into the CiA 402 state OPERATION ENABLED and the execution of the new setpoint handling Each drive needs a specific time for the transfer of a new setpoint This time can be specified by the argument delayTime The communication is done via SDO This function can only be used for single drive devices Parameters targetPos value of object Ox607A profile Vel value of object 0x6081 profil
86. vice Monitor Version 3 2 7 pert 25 CAN Message Logging Each CAN message on the CAN bus can be displayed in a separate message log window It can be activated by selecting View gt Message Log Mark CTRL C gt Clear lt C TRAL L Save CTRL S gt Find lt CTRL F show server status F Show time marks Close lt ETRL E gt Figure 36 Message Log file menu Menu entry Description Mark Adds a marker Save Saves the content in CAN REport format Show server status Shows status information of the CANopen server Show time marks Inserts a time mark every minute Find Opens a Find dialog Close Closes the log window The message is displayed in the CAN REport message format lt COB ID dec gt lt COB ID hex gt lt Type gt lt Data hex gt EXAMPLE 1000 0x3e8 sD 11 22 33 44 55 66 77 88 A data message with ID 3E8h was received It contains 8 data bytes 11h 22h 33h 44h 55h 66h 77h and 88h The message logs can be loaded with the CAN REport and so they can be interpreted with its sophisticated extensions Version 3 2 7 CANopen Device Monitor Page 63 of 125 pert e CAN Message Log M Ei File stop 1793Dx701 1656 02740 1793Dx701 1656 0x740 1600 0640 1472 025e0 1600 0640 1472 025e0 1600 0640 1472 025e0 1600 0640 1472 025e0 1793Dx701 1656 0x740 Figure 37 Message Log window Not all CAN drivers of the CANopen Server m4d are able to send all recei
87. view Some rescritions exist when reading or writing sub indices Sub indices with the data type domain cannot be read or written and PDO PDO mapping and SRDO objects can not be written from the overview tab For these objects it is required to meet a specific order when writing to them but they can be configured by the PDO configuration tab or the SRDO configuration tab requires Safety PlugIn Version 3 2 7 CANopen Device Monitor Page 35 of 125 pert 13 PDO Configuration Tab The PDO tab simplifies the configuration of PDOs At the selection of a PDO object in the EDS tree the mask is updated with values from the EDS The PDO parameters sim ply can be adjusted over the mask New objects can be moved from the EDS tree into the mapping table by drag amp drop A double click deletes them within the mapping table The table is unalterable at a static mapping e CANopen Device Monitor Node 32 C04011A0 PDO l E3 PDO Configuration Frame Object 0x1400 COB ID oxo0000220 Transmission type Oxff nhibit time 100 us Event timer ms EA Mapping Table Length Name Ox6200 0x01 6 Write Output Byte 1 0x6200 0x02 8 Write Output Byte_2 PDO Data mss for Read from EDS send PDO Store to DCF data Read from Device Show PE 1 Chart send to Device Figure 20 PDO Tab Page 36 of 125 CANopen Device Monitor Version 3 2 7 pert The following table descri
88. waitForPdo lt pdo_num gt lt script gt e pdo setHandler lt pdo_num gt lt proc gt e pdo setPDOIndication lt pdo_num gt lt proc gt compatibility alias to setHandler Reset Application e nmt resetAppl lt node gt Reset Communication e nmt resetComm lt node gt SDO e r lt index gt lt subindex gt lt type gt e rr lt index gt lt subindex gt lt type gt e rrc lt index gt lt subindex gt lt type gt lt ref_val gt e rre lt index gt lt subindex gt lt type gt e w lt index gt lt subindex gt lt type gt lt val gt e ww lt index gt lt subindex gt lt type gt lt val gt e wwe lt index gt lt subindex gt lt type gt lt val gt lt ref_val gt e wwe lt index gt lt subindex gt lt type gt lt val gt SYNC e cdm enableSync lt cycle gt e cdm disableSync Communication state change e nmt preop lt node_id gt Page 116 of 125 CANopen Device Monitor Version 3 2 7 pert e nmt start lt node_id gt e nmt stop lt node_id gt Node Monitoring e hbt setHandler lt callback gt e hbt unsetHandler Version 3 2 7 CANopen Device Monitor Page 117 of 125 pert Appendix 2 CDM Commands in Overview Date Time e cdm putsDateTime Dialog e cdm userDialog lt title gt lt type gt Download e cdm domainDownload lt node gt lt index gt lt sub gt lt timeout in ms gt lt file gt e cdm domainUpload lt node gt lt index gt lt
89. x object subindex typ datatype of object lt uSlul 6lu32118111611321r32lvs gt val value Results OK value has been written to the object ERROR CiA 309 3 error code if SDO transfer failed Version 3 2 7 CANopen Device Monitor Page 81 of 125 pert ww lt index gt lt subindex gt lt typ gt lt val gt Description SDO write procedure type out the SDO write command and the answer from the device Parameters index object index subindex object subindex typ datatype of object val value to write Results nothing wwe lt index gt lt subindex gt lt typ gt lt val gt lt expected gt Description SDO write and compare the expected result the returned value is compared with the expected one typical a write can return OK or some errors beginning with error one or two lines with the command and the result are printed to std out the last line contains a right justified flag for OK the returned value matches the expected FAILURE the returned value does not matche the expected In case of an error the global variable test_error is set to 1 Parameters index object index subindex object subindex typ datatype of object val value expected the expected return string Results 0 received value is equal to the expected value 1 received value differs from the expected value Page 82 of 125 CANopen Device Monitor Version 3 2 7 pert wwe lt index gt lt subindex gt lt typ gt lt val
90. y Frame Because of the fact that reading an object may trigger an unwanted reaction an object is only read on request But if Extras gt Options Read object on selection is active the selection of an object triggers the SDO transfer to read this object Value Entry Frame Hexadecimal values are designated by the prefix Ox example 0x10 Enter strings consisting of one or more parts without quotation marks Spaces at the end of the string will be ignored Is this field empty the value O will be sent lt DEL gt deletes the contents of this field lt ENTER gt sends the value lt Shift ENTER gt If an URL is in this entry the web browser is started The last word of the value in the entry field is evaluated as a mathematical expres sion before sending it with an SDO transfer Try to put something like 0x 80 10 in it Component of DCF file By this checkbutton the object is marked for DCF file handling see chapter Data Management with DCF File Used for saving configuration If this check box is activated the CANopen Device Monitor marks this object for storing its value in a object configuration ocf file see chapter Object Data Management with ocf File Cyclic update If this check box is activated the value is read and updated cyclically Active bit boxes and slider displaying the value of this object are updated too Receive from Object The object value will be requested by SDO Send to

Download Pdf Manuals

image

Related Search

Related Contents

  Gateway 5860 Personal Computer User Manual  SB3100Di  Mots d`houx n°12  GENESE DU PROJET  Digitus MINI KVM Switch 1User - 2PCs, Audio  Coupled Regional Ocean Atmosphere Model (CROAM) User Manual  Untitled  Kensington SafeDome  Atomic 3000 - EMPIRE Light & Sound  

Copyright © All rights reserved.
Failed to retrieve file