Remora - Rpi Software Stepping Using External Microcontroller via SPI

More
04 Aug 2021 12:28 #216905 by mhel

well let's do it, what do you have so far and where can i add to it?
 

I've uploaded my non-PRU version.
github.com/mhelmarc/Jaqueza-NC
Same issue, I can't figure out yet.
When coming from e-stop on first run
it goes idle but it works the on the second press of e-stop.

My observation is:
On first run after pressing the e-stop button on Axis, only the header PRU_READ
is sent and no payload. The controller assumes that there's data so it set SPIdata to true.
So the main loop try to change the state to ST_RUNNING, but there's actually no data
and becomes a sequence of errors so it goes idle again.
Still trying to figure out how to fix it, but other than that it seems stable.

Please Log in or Create an account to join the conversation.

More
04 Aug 2021 13:55 #216909 by gtt38
Hi thanks I’m gonna try. But can you upload the modded lib too ?

Please Log in or Create an account to join the conversation.

More
More
04 Aug 2021 14:01 #216912 by gtt38
So I was using the good one 
let’s try

Please Log in or Create an account to join the conversation.

More
04 Aug 2021 14:03 #216913 by Cncninja
yes, it's all set up on a 1.4turbo I have TMC drives and 8822.

Please Log in or Create an account to join the conversation.

More
04 Aug 2021 14:15 #216916 by gtt38
After a quick try, it works pretty good. Good job Mhel ! The good thing with your code is that it could be easily ported to F1 and F0 with this library. The bad thing is a lot of modifications of the library are needed if you want to port to F0/F1.
For the E-stop I had the same issue.

Please Log in or Create an account to join the conversation.

More
04 Aug 2021 14:56 #216918 by mhel
Great, now try to figure out the E-Stop problem. :-)

@Cncninja
I'm confused I thought you already have an STM32 hardware,
a quick search shows your Turbo board is based on LPC176x ?

Please Log in or Create an account to join the conversation.

More
06 Aug 2021 03:06 #217020 by scotta

  Most 3D printer board manufacturers don’t use the right pin mapping of the chip. The chip is using software pwm to generate steps if the pin is not hardware pwm. I’m trying to use P2.0 to P2.5 for step generation with good results.
The step generation limitation could come from the SPI communication too slow maybe.


 

SPI comms runs at the Servo Thread frequency and it passes the required step frequency. All steps are generated in the Base Thread, which is the limiting factor.

BR
Scott

Please Log in or Create an account to join the conversation.

More
06 Aug 2021 03:08 #217021 by scotta

well let's do it, what do you have so far and where can i add to it?
 
I've uploaded my non-PRU version.
github.com/mhelmarc/Jaqueza-NC
Same issue, I can't figure out yet.
When coming from e-stop on first run
it goes idle but it works the on the second press of e-stop.

My observation is:
On first run after pressing the e-stop button on Axis, only the header PRU_READ
is sent and no payload. The controller assumes that there's data so it set SPIdata to true.
So the main loop try to change the state to ST_RUNNING, but there's actually no data
and becomes a sequence of errors so it goes idle again.
Still trying to figure out how to fix it, but other than that it seems stable.

Hi, 

Great to see some further work on the STM32 version. Just curious, what makes this a non-PRU version?

Thanks
Scott

Please Log in or Create an account to join the conversation.

More
06 Aug 2021 11:02 #217046 by mhel

 what makes this a non-PRU version?

Hi Scott,

technically it is still programmable :-)
I thought the idea of PRU is re-programmability without actually
re-compiling the source. Unlike my other attempt the non-PRU
has all the configuration hard-coded. As the library used is
heavy on templates which as I found out only works at compile time.
 

Please Log in or Create an account to join the conversation.

Time to create page: 0.186 seconds
Powered by Kunena Forum