Comments (10)
I think, it is not outdated. See also standard IEC 61800-7 (this is CiA402), you may be able to buy it.
It is not so complex to use 8 drives with single node-id device. Make 8 copies of device profile objects (0x6000+) with an offset 0x800. For example, second drive has objects at index 0x6800+, third at 0x7000+, etc.
Then make enough PDOs, for example 8*4=32, depending on your needs. Then configure PDOs by hand. Just smartly choose COB IDs and mappings for each PDO, so you won't have a mess. And make some documentation about your configuration.
from canopennode.
Object Entries are not directly linked to addresses. You need to use PDOs for this (TPDO for transmitter, RPDO for receiver(s) ). If you do this correctly, updating the value will lead to TPDO transmission, which in turn will update on all devices with configured RPDO.
from canopennode.
Okey but I configure the Tx RX PDO like in the picture.
I think that's waht you mean, but if I update the object now, it will send to both devices and I will send different values to each device e.g. 0x01 to device 1 and 0x02 to device 2 at the same time. Or is there a function to update the object correspond the the COB-ID, that I might have overlooked.
from canopennode.
you need to configure txpdo in sending device (0x1800 registers) and rxpdo in receiving device (0x1600 registers). for two independent transmission you need two tpdo in sending device (e.g. 181+1800 and 182+1801) and one rpdo each in receiving device (e.g. rx1: 181 + 1600, rx2: 182 + 1600)
from canopennode.
I probably have a similar problem as Tim if I understand correctly or at least the part he will come to next.
I have 4 motors of the same kind and i want to controll them independently. They all use the same mapping and I have no way to change it.
I can controll each motor alone when setting the eds file and change the values of the object. I also understand that i need to make 4 txpdo's with the COB-ID and Index (e.g. 181+1800, 182+1801, 183+1802, 184+1803). But how can I differentiate the objects? All 4 of them work with 0x6040 for the controlword. Can you point out how to change the value independently or isn't this possible and I have to change the value send txpdo1, change value send txpdo2 and so on?
Really appreciate your help.
from canopennode.
@BenjaminLangeEmbedded sprichtst du deutsch, das bekomme ich auf enlisch nicht erklärt...
- Mit dem R/TPDO Mapping erstellst du eine Verknüpfungstabelle zwischen Objekteinträgen in zwei Geräten. Eines davon (Motoren) kann eine feste Konfiguration haben. Das kannst du auf der anderen Seite durch entsprechendes Mapping geraderichten (ist CANopen Seitig auch so gedacht).
- Du kannst dein Mapping jetzt so einstellen, dass ein beliebiger Objekteintrag von deinem Gerät auf den fest vorgegebenen Eintrag auf dem anderen Gerät übertragen wird.
Bsp: Deine 4 Motoren möchten jeweils 0x6040 auf dem ersten Byte des PDO sehen. Du erstellst nun 4 TPDOs, der erste mappt in deinem lokalen OD 0x2000, der zweite 0x2001, usw. jeweils auf das erste Byte des TPDO. Jeder der TPDOs bekommt eine COB-ID, diese ist im lokalen Gerät und in den Motoren einzustellen. Das korrekte RPDO Mapping im Motor ist bereits fest vorgegeben. Der PDO Mechanismus sorgt nun automatisch dafür, dass jede Änderung in 0x2000 im Motor 1 in 0x6040, 0x2001 in Motor 2 in 6040 usw übernommen wird.
english machine translation:
With R/TPDO mapping, you create a linking table between object entries in two devices. One of them (motors) can have a fixed configuration. You can align that on the other side through corresponding mapping (similarly intended in CANopen).
Now, configure your mapping so that any object entry from your device is transmitted to the predefined entry on the other device.
Example: Your 4 motors each want to see 0x6040 at the first byte of the PDO. You now create 4 TPDOs, the first maps in your local OD 0x2000, the second 0x2001, etc., each to the first byte of the TPDO. Each of the TPDOs gets a COB-ID, which is to be set in the local device and in the motors. The correct RPDO mapping in the motor is already predefined. The PDO mechanism now automatically ensures that any change in 0x2000 in Motor 1 is transferred to 0x6040, 0x2001 in Motor 2 to 0x6040, and so on.
from canopennode.
@martinwag Das passt ja gut :) Erstmal vielen Dank für deine Hilfe.
CanOpen ist neu für mich und hier stoße ich auch vom programmieren her an meine Grenze daher echt nett von dir.
Ich habe jetzt mal im Editor die Objekte erstellt. Node-ID dann dementsprechen 1,2,3,4. Passt das so?
Und dann bin ich mir auch unsicher beim Zugriff auf die Parameter/Variablen. Wenn ich dich richtig verstehen liegen diese jetzt bei den TPDO's bei 0x1A00 bis 0x1A0F und für die RPDO's bei 0x1600 bis 0x1607 richtig?
Wie greife ich dann auf diese zu?
Geht das auch über OD_set oder OD_get also OD_set_u32(OD_find(OD, 0x1A00), 0x00, val, odOrig) ? Aber wie komme ich dann bei diesem an die 3 verschiedenen Einträge ran (0x6081, 0x6083, 0x6084)?
Wäre super wenn du mir hier noch einen Tipp geben kannst.
Translation:
Firstly, thank you very much for your help.
CanOpen is new to me and I'm reaching my programming limits here, so that's really nice of you.
I have now created the objects in the editor. Node ID then corresponds to 1,2,3,4. does that fit?
And then I'm also unsure about accessing the parameters/variables. If I understand you correctly, these are now at 0x1A00 to 0x1A0F for the TPDOs and at 0x1600 to 0x1607 for the RPDOs, right?
How do I access them then?
Is this also possible via OD_set or OD_get, i.e. OD_set_u32(OD_find(OD, 0x1A00), 0x00, val, odOrig) ? But how do I get to the 3 different entries (0x6081, 0x6083, 0x6084)?
Would be great if you could give me a tip here.
TX Motors (manufacturer):
RX Device (me) :
RX Motors (manufacturer):
TX Device (me):
from canopennode.
Or is it better to write directly?
Like:
OD_RAM.x1A00_TPDOMappingParameter.applicationObject1 = xxx;
OD_RAM.x1A00_TPDOMappingParameter.applicationObject2 = xxx;
Can't get my hands on the hardware until tomorrow to test it.
Thanks again.
from canopennode.
If you are completely new to CANopen, I would recommend having a look at "embedded networking with can and canopen" (https://www.canopenbook.com/) this explains SDO/PDO stuff quite extensively. I don't have time to go trough your post right now, sorry.
from canopennode.
In DSP402 (v2 26-July-2002), PDO's from different motor (axle) has offset of 64. In this proposal, up to 8 motor (axle) controllers can be supported.
Note: I don't have access to the official CiA-402 specification document. This is definitely outdated.
best regards,
Sicris
from canopennode.
Related Issues (20)
- Open and close brackets mismatch in CO_Emergency.c HOT 1
- How to handle SIGSEGV during the communication process to prevent program crashes HOT 4
- Configuring the micro as MASTER problem, CO_NMT_sendCommand() not defined HOT 1
- Multiple nodes, NMT problem HOT 2
- return CO_ERROR_OUT_OF_MEMORY HOT 1
- Questing about NMT and Heartbeat status queries HOT 1
- MISRA 2004 compliant for a few rules HOT 3
- Issue with include style fo Arduino HOT 4
- Porting SRDO to v4.0 HOT 4
- Trying to receive SDO messages in SDO client over the CO_SDOclient_receive HOT 5
- Unsigned int 24 bits HOT 5
- Enter the pre-oprational state HOT 5
- Please help HOT 3
- RPDO configuration every 2 Syncs HOT 1
- How to make it possible to receive all messages (SDO, PDO, NMT) in raw form? HOT 2
- Compiler warnings HOT 1
- Compiling without "CO_SINGLE_THREAD", using "1 w 0x1010 1 vs save" via ascii gateway causes deadlock (CO_LOCK_OD)
- Send CO_NMT_RESET_COMMUNICATION to node
- Wrong definition of CO_storage_entry_t
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from canopennode.