Remora for RP2040

More
2 years 2 months ago #307680 by cakeslob
Replied by cakeslob on topic Remora for RP2040

Encoder support is also something I am looking to have. Then the rp2040 is then probably not the best option any more. How can I estimate the performance in terms of drive frequency for the axis?

I think this is how to do the math for the axis timing, im fairly sure its the same idea
linuxcnc.org/docs/devel/html/motion/twea...ose_your_base_period

If encoder support is what you need, the rp2040 does not support encoders at this time, and im not sure if it will or what its limits will be. the RT1052 will probably be your best bet if you want something ethernet

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

More
2 years 2 months ago #307704 by Limo
Replied by Limo on topic Remora for RP2040
I have looked through the remora documentation and there are software encoders mentioned with a frequency up to 30kHz. If I get close to that number with a rp2040 I am fine with that. That would result in theoretical encoder resolution to roughly 360ppr with 5k rpm and 30kHz max input frequency. It is just the question if the pi2040 is up to the task of handling these things

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

More
2 years 2 months ago #307743 by scotta
Replied by scotta on topic Remora for RP2040
As Cakeslob mention, the RP2040 fork does not currently have encoder (software or hardware) support. It wouldn't take much to port over the software encoder module to the RP2040 though. Limited to base thread frequency.

github.com/scottalford75/Remora/tree/mai...-OS5/modules/encoder

If someone was keen they could also potentially look at the PIOs to increase the capable frequency.

github.com/p-o-l-e/quadrature-decoder

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

More
2 years 2 months ago #307752 by Limo
Replied by Limo on topic Remora for RP2040
How much effort in programming skills are needed, to implement the hardware encoder support with the PIO? And where is the best place to start. To be honest I am not very familiar with linuxcnc let alone remora. If it is within my capabilities I would really want to get a go at it. I would really appreciate if someone can point me in the right direction where to start looking.

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

More
2 years 2 months ago #307848 by cakeslob
Replied by cakeslob on topic Remora for RP2040
Hey Scott, about adding the encoders. The RP2040 W5500 firmware is similar to the STM32 W5500 firmware, in the sense that they both use the pingpong buffer thing. Ive been trying to add encoders/PWM to that firmware, but Im encountering an issue. I dont know where to send the data. There are examples for digital in/out and stepgen stuff, but there is no examples for PV/SP modules. Where ever its going, it should be similar for both firmwares.

Here is my initial attempt at encoders, but I cannot yet get it to compile
github.com/cakeslob/Remora-STM32F4xx-W55.../Src/modules/encoder

Here is what Drew and I were working on for PWM, it compiles, but doesnt yet work either.
github.com/cakeslob/Remora-STM32F4xx-W55...main/Src/modules/pwm

I was wondering if you could give me a few pointers? (pun intended)
But seriously, where do we send the data for PV/SP? The pointers are different than the other versions of remora, and I am stuck.

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

More
2 years 2 months ago #307975 by scotta
Replied by scotta on topic Remora for RP2040
For the RP2040 Andrew implemented the double buffers and methods to get the current buffer.

this->rxData = getCurrentRxBuffer(&rxPingPongBuffer);
this->txData = getCurrentTxBuffer(&txPingPongBuffer);

I'm waiting on stock of the RP2340 to arrive so I can get another new toy. It looks like the RP1 is getting more and more popular and with the version of the RP2340 with more IO would allow for even more functionality.

Might be a good excuse to learn the PIO stuff and port over the other Remora modules. At the time I did the RP2040 it was suitcase project while I was travelling for work.
The following user(s) said Thank You: itsemast

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

Time to create page: 0.207 seconds
Powered by Kunena Forum