-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build kernel module #1
Comments
Hi Sirop, sorry for the late reply. I just used ecslave in user space. So you've already made it run as kernel module now? |
Hallo @ningfei . I edited the Makefile in ecslave/kernel and corrected some minor bugs. But I do not think that ben Jehuda (the author) fully tested his kernel version So the kernel module runs, but sharing any data with the user space awaits yet some implementation effort. How was your experience with the pure user space version? |
Hi @sirop Cool! I haven't worked on the ethercat project for a while. But back to that time, iirc, I also saw that the kernel version was not ready/easy to use. The user space version works well (as showed by some preliminary tests, I had the ethercat master on my latop and used raspberrypi as simulated slaves). Here you need a small fix like de8e128. Otherwise, if you connect from the master to slaves, you will get a "topology calculation error" in dmesg. Besides, I'm still not clear about how to create different topologies with ecslave. |
@ningfei Is you de8e128 commit about this problem? Or maybe I do not understand what you mean with "topology"? Any kind of physical ring? |
Guess you referred to |
I guess you are right. Connect the slave to the master, start the ethercat master service, start the ecslave simulation, on the master side, you will then get some information about the master/slave link from dmesg. With the Yes, by "topology" I mean creating star/tree/ring slaves. The modification in de8e128 actually refers to P. 31, Section 3.19 ESC DL Status. The ethercat master needs to query the DL status register of each slave to determine the (chnage of) topology of the slaves. So for the above "topology calculation error" in dmesg, we need to change the Thank you for the hint about adopting the |
Hallo again. Hope you got well over the holidays. So applied your patch de8e128 . Then I just copied some lines from the Arduino version: So PDO exchange is possible, but I get strange offset values for the PDOs of the master branch:
yield
I could live with P.S. As you see I work with https://github.com/machinekit , but I hope that the code of https://github.com/sirop/EtherCAT_HAL/blob/master/pdoLIBIX2dc.comp is nevetheless readable for you. |
Hi @sirop, Hope you enjoyed the holidays, too. In our case, after de8e128, there won't be any topology error. If L21-L43 from ec_regs.c turns out to be a better solution for this as you mentioned, I will then merge it later. For the PDO exchange, I think we hadn't went that further. I asked my friend. But he's now working on a physical slave rather than the virtual ecslave, unfortunately...I just stared your two ethercat related projects, will try the PDO part when I get time. |
Hi guys, I would like to test the kernel version of the EtherCAT slave. @sirop do you still have any hints of the modifications you have made to the Makefile to make the kernel module compile? |
Because of legal reasons I am not allowed to comment on this. If you are looking for an inexpensive but configurable slave, I'd recommend |
Hallo.
Did you manage to build the kernel module of ecslave?
My Makefile as for now:
yields:
The text was updated successfully, but these errors were encountered: