Ethercat HAL driver

More
8 years 3 months ago #114823 by chimeno
Replied by chimeno on topic Ethercat HAL driver
Hi Ilya,
I do not know if I can help you, I do not know much English and I am not a programmer, and I do not use ASDA-A2-E, I hope I can give you some clue, do not know if you have registered P0-09 in the initial configuration in TX_PDO?

regards
Chimeno
More
8 years 3 months ago #114831 by sqmathlete
Replied by sqmathlete on topic Ethercat HAL driver
@ Ilya

In your linuxcnc code try something like
Code:
<sdoConfig idx="6060" subIdx="0"><sdoDataRaw data ="60 60 00 02 00 08 00"/></sdoConfig>

note: data is in hex little-end-in format.

regards,
Dan
More
8 years 3 months ago #114882 by Ilya
Replied by Ilya on topic Ethercat HAL driver
@ Chimeno

Do you mean the ethercat-config configuration.xml?
For each servo I wrote this:
Code:
<slave idx="0" type="DeASDA" name="3A1"> <dcConf assignActivate="300" sync0Cycle="*1" sync0Shift="-25000"/> </slave>
I would try to use type= "generic", and describe all the pins manually, including the parameter I need(p 0-09 index 0x2009), but it is not in the RxPdo section, like 0x6040 (Control Word)
In the first message I attached the factory xml file. In this file you can find the following line - "DRV's Parameter P0-09".
I also will attach it, hope this will help you understand what I mean.


@ Dan

I didn't quite understand how I would know what to write in data
I tried using your example, but the servo remains in PREOP mode after starting linuxcnc
In my xml file, I describe my servos as shown above
Can I add "sdoConfig" tags directly there? Or do I have to use type="generic"?

Thanks,
ilya
Attachments:
More
8 years 3 months ago #114926 by sqmathlete
Replied by sqmathlete on topic Ethercat HAL driver
@ Ilya

Things are getting a bit confusing and I feel like we might be heading down a rabbit hole, so lets just step back a minute. What you are interested in is

The offset between the motor position and Z phase. The range is from -5000 to +5000. If the position is the same as Z phase, its value is 0. The bigger the value is, the more the offset will be.

I want to use this feature to remove the physical inaccuracies of the endpoints sensors.



From the ASDA-A2 manual P0-09 CM1 Status Monitor Register is defined from P0-17

If the parameter P0-17 write the value 18, then you can read the value of the "Z phase" in the parameter P0-09.


What this says to me is that you are "monitoring" the value of the Z-phase offset or in other words you are trying to read that number not set it.

This leads me to believe that it is more of a problem with the set up of your homing routine.
If you are using the internal homing routine of the amp
1)What number is your homing routine?
2)Does it correspond to one that uses the Z-phase of the encoder?

If this is all good then I would look at object 0x607C Home Offset (ASDA-A2-E manual). you will be able to set the object with the code format from above. Also, you probably need to use the generic form and break out all the pins like Chimeno said.

If you are not using the internal homing routine then can you just specify HOME_OFFSET in the .ini file?

regards,
Dan
More
8 years 3 months ago #114928 by sqmathlete
Replied by sqmathlete on topic Ethercat HAL driver
@ Ilya,

This might be helpful for manually converting Hex => Little Endian

www.scadacore.com/tools/programming-calc...nline-hex-converter/

regards,
Dan
The following user(s) said Thank You: Ilya
More
8 years 3 months ago #115168 by chimeno
Replied by chimeno on topic Ethercat HAL driver
Hello Ilya,
  I think that the paremtro that try to configure and later read is not in the configuration, "DeASDA", you would have to use the "generic" method or try to modify the file lcec_deasda.c and lcec_deasda.your wish, I first usually configure everything through TwinCAT and then export all the configuration and parameters to the corresponding files, I hope I can help you with something.
regards
Chimeno
The following user(s) said Thank You: Ilya
Time to create page: 0.609 seconds
Powered by Kunena Forum