industrialNETworXnetx

Tomas Kohout

Tomas Kohout

| 12.03.2010 | 11:01 | 15 replies

PDO mapping

Hello,

I'am using CifX PCI card with ethernet powerlink firmware and I have some problem with setting PDO communication.

After the node gets into operational state, I create following objects in OD:

0x1400 - rx communication parameter

0x1600 - rx mapping

then I create subobjects with subindex 1

0x1400(1) - rx communication parameter

0x1600 (1)- rx mapping

next, I set number of entries to 0 ... 0x1400(0)=0, 0x1600(0)=0

then, I set node ID in 0x1400(1) to 0x11 (station 17 from which I'd like to recieve PDO's)

I also set mapping parameters in 0x1600(1)

finally I set number of entries in both objects to 1 to activate the changes.

 

Durring this setting no error occures, but the mapping doesn't work. There are still zeros in desired objetcs.I have the same problem with Tx mapping . Any idea what am I doing wrong ?

 

Thanks

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 12.03.2010 | 13:54

Hi,

the objects must be created before the node gets active.
It makes no sense to create those objects after boot up of the node.
 
In addition, the delivered XDD file is defined for static mapping. It must be adapted for dynamic mapping first. Otherwise, the master will not write those objects.
 
The objects are not handled by the stack, so setting these objects has no influence to the stack.
 
The stack does not implement dynamic mapping internally. This is left to the application.

Regards
AJ

Tomas Kohout

Tomas Kohout

| 16.03.2010 | 15:41

Hi,

so,when do I have to set mapping to make it work? in which state ?

My object is to read some bytes from PDOs from other nodes in network. Theese bytes are allways on the same possitions in PDO, so I don't need dynamic mapping, right ?

 

Tomas

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 16.03.2010 | 16:47

Hi Tomas,

in your case you are using a loadable firmware which does not support the CN-toCN communication. The firmware does only take data from the PolReq frame.

Regards
AJ

Tomas Kohout

Tomas Kohout

| 16.03.2010 | 18:17

And is there any possible way, how to read data from PRes frames of other nodes ? different firmware, hardware ?

Andreas Jacob

Andreas Jacob

Hilscher Gesellschaft fuer Systemautomation mbH

| 16.03.2010 | 18:30

As I wrote before, not on a loadable firmware and as far as I know not on a cifX board.

Maybe the Hilscher hotline have one more hint.

Regards
AJ

Tomas Kohout

Tomas Kohout

| 24.03.2010 | 17:29

Hallo again,

thank you for your replies. I have one more question, you wrote that the firmware does only take data from the PolReq frame. Did you mean payload data form Preq frame ?

Thank you

Tomas

code- small

code- small

Hilscher Gesellschaft für Systemautomation mbH

| 25.03.2010 | 11:01

Hello Thomas,

This is right. The data that is presented to the application comes from the payload data of the PReq frame.

 

Greetz,

 

code-small

Tomas Kohout

Tomas Kohout

| 26.03.2010 | 11:23

Hi,

And is this data available on loadable firmware?I know that AJ wrote that it is, but I don't know how. Using PDO mapping ?

Regards

Tomas

code- small

code- small

Hilscher Gesellschaft für Systemautomation mbH

| 26.03.2010 | 11:33

Hi,

the stack has no provisions to do dynamic PDO mapping. The actual PDO mapping implementation is left to the application. Therefore, the data is not linked to the objects. They do not reflect the actual data from the bus without any help from the application. So, the actual data comes only via the input and output areas of the DPM.

 

Greetz,

code-small

Tomas Kohout

Tomas Kohout

| 02.09.2010 | 10:31

Hello,

I would like to ask on possibilities of SDO communication with loadable firmware on comx module. Is some SDO transfer between CN and MN possible ? like reading/writing object dictionary entries of CN by MN?

Thanks

Tomas

code- small

code- small

Hilscher Gesellschaft für Systemautomation mbH

| 02.09.2010 | 10:51

Hello,

 

SDO communication is required to be supported by the stack.

The MN is writing some objects at every bootup if required. At least the cycle time has to be configured via SDO.

But I guess you mean probably whether the host can add some objects which can be accessed by the MN. If that is so, the answer is yes.

Greetz,

code-small

 

Tomas Kohout

Tomas Kohout

| 03.09.2010 | 13:14

Thanks for your answear.

Now I am testing creating some objects and subobjeccts from host. First I create object

index 2000

numOfSubobjects 2

maxNumOfSubobjects 2

objAcces 0x8 - indexed

objCode 0x8 - array

datatype 0x7 - unsigned 32

 

then I create subobject on subindexes 1 and 2

mode  0x0  - storage

direction 0x0 - not def.

subobjAcces 0xFFFF

datatype 0x7 - unsigned32

fieldLen 1

relAdress 0

 

I get no error code, but when I acces this object for read or write it behave like a simple variable object. on every sub index is the same value. In addition the writed value is not writed correctly. Only 3bytes are correct, fourth is different ...

Do you think I have wrong parameters when creating objects and subobjects or the mistake is in my application?

 

code- small

code- small

Hilscher Gesellschaft für Systemautomation mbH

| 07.09.2010 | 09:44

Hi Tomas,

 

if you would add the method used for reading and writing the object, I could check all bits together.

If it is via master, send us a trace.

If it is via packet, send us a binary dump of those packets used.

 

Greetz,

code-small

 

Tomas Kohout

Tomas Kohout

| 09.09.2010 | 09:41

Hi code-small

I am doing it via packet.

For writing, are packets as follows:

For subobject 2000/1

==============DATA===================                                                                                  
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0                                                                                        
 7  0  0  0  0  0  0  0  0  0  0  0 B0 13  0  0                                                                                        
 0  0  0  0  0  0  0  0  0 20  1 11 22 33 44                                                                                           
====================================

for subobject 2000/2

==============DATA=================                                                                                 
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0                                                                                         
 7  0  0  0  0  0  0  0  0  0  0  0 B0 13  0  0                                                                                         
 0  0  0  0  0  0  0  0  0 20  2 12 34 56 78                                                                                            
==================================

 

And packets for reading:

request for object 2000/1

==============DATA================                                                                                  
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0                                                                                        
 3  0  0  0  0  0  0  0  0  0  0  0 B2 13  0  0                                                                                        
 0  0  0  0  0  0  0  0  0 20  1                                                                                                       
==================================

confirmation with data:

===================DATA============                                                                  
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0                                                                                        
 4  0  0  0  0  0  0  0  0  0  0  0 B3 13  0  0                                                                                        
 0  0  0  0  0  0  0  0 11 22 33  2                                                                                                    
===================================

request for object 2000/2:

===============DATA==================                                                                                  
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
 3  0  0  0  0  0  0  0  0  0  0  0 B2 13  0  0
 0  0  0  0  0  0  0  0  0 20  2
=====================================

confirmation:

================== DATA ===============
20  0  0  0  0  0  0  0  0  0  0  0  0  0  0  0
 4  0  0  0  0  0  0  0  0  0  0  0 B3 13  0  0
 0  0  0  0  0  0  0  0 11 22 33  2
======================================

Thank you for any advice

Regards

Tomas

 

 

 

code- small

code- small

Hilscher Gesellschaft für Systemautomation mbH

| 10.11.2010 | 12:40

Hi Tomas,

 

what I am missing is the object creation request that would give me the information to check for whether the bits there are set correctly.

 In fact, there is the flag EPLCN_PCK_OD_CREATE_OBJECT_OBJ_ACCESS_INDEXED which must be set in the element usObjAccess of the EPLCN_PCK_OD_CREATE_OBJECT_REQ_T, otherwise the stack assumes a simple variable.

Greetz,

code-small

Login