scottalford75 / Remora

Remora is a free, opensource LinuxCNC component and Programmable Realtime Unit (PRU) firmware to allow LPC176x and STM32F4 micro-controller controller boards to be used in conjunction with a Raspberry Pi to implement a LinuxCNC based CNC controller.
128 stars 32 forks source link

Question regarding feasibility of supporting CAN communication #36

Open piotrrak opened 1 year ago

piotrrak commented 1 year ago

Hello Scott

Please do consider it feature request, just asking about feasibility and how hard would it be in your eyes. Asking since I've seen your work on E500/ethernet and started wondering about that.

I've ordered recently some Manta MP8, Octopus Pro and bunch of EEB 36 and 42 from BigTechTree which should be here tomorrow. EEB36/42 are kind of interesting extruder boards with its own STM32F0 (v1.0) or STM32G0 (v1.1) ie. Cortex M0 that communicate over CAN.

It would make some sense for my project to communicate with Octopus Pro for few of my axes but for one or two of them it'd be neat to use such EEB boards. Given that I've also got Odrive (also CAN and STM32 based) for some Leadshine servo motors laying around, basing all communication on CAN bus starts make lot of sense for this and future projects. It could possibly make it versitile and future-proof in terms of expanding/ammending it later.

Just thought I ask first before I'll start butcher your code on my own :) Your feedback on such direction, would be really appreciated.

Cheers /P

cakeslob commented 1 year ago

CAN would be good because I think it supports longer distance than spi would. ?I just wish btt would sell their CAN bus RPI board individually, but in the mean time I have an spi to can adapter in case something comes up.

I dont really know much about CANopen or cia402 (can over ethercat?) but there are several implementations Ive seen you could gather insight from. In addition to the odrive, I know of STMBL as well as this one https://hackaday.io/project/181058-ethercat-servodrive

As a starting point , you could try to make one of the eeb communicate directly with linuxcnc over can.