Remora - Rpi Software Stepping Using External Microcontroller via SPI

More
3 years 9 months ago #261787 by 4170-thomasnobi
Thank you very much scotta and cakeslob for the good work.
Now the PWM is activated correctly.
I found a small difference in the notation of "Period US" (documentation) and "Period us" (source code).
With best regards Thomas

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

More
3 years 9 months ago #262377 by cakeslob
cakeslob remora bulletin incoming

- remora driver for upboard
github.com/mrbubble62/UPBoard-Remora
github.com/mrbubble62/UPBoard-Remora/tre...C/Components/Upboard
the parts I understand is, I think hes using spidev and a modified UP RPI.GPIO, which could mean its not impossible to get this working with other sbc like rockchip or allwinner

- remora static config ( no sd card needed)
github.com/cakeslob/Remora/tree/static_config
the guys from Expatria-Technologies who are doin the flexi-hal, modified remora to use a static compiled config. I took that stuff and mashed it into regular remora. using mbed studio, you edit you config and compile it with your firmware and bingo, no sdcard. so far only stepgen, inputs/outputs and single pwm are supported (thats what was in flexihal). I also added blink, and i am trying to figure out the others. ive tested on the fystec spider, and nucleo-446 and so far results are good. i havent tested it yet with steppers connected. the firmware is almost small enough to fit on a bluepill f103 but i dont know how to get the firmware smaller.

- working on manta m8p target and had to upgrade to mbed6, so far it compiles at least. is there a specific reason remora is not mbed6? also bought a mks skipr with rockchip and 407.i forgot to check my notes before buying, so it will have sd card issues
github.com/cakeslob/Remora/tree/mbedos6
The following user(s) said Thank You: tommylight

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

More
3 years 9 months ago #262382 by scotta
For the LPC1768 boards, MODDMA is needed, which unfortunately has not been migrate to Mbed OS6. I did have a go and got it kind of working but it was unstable. If we drop LPC1768 support, we could move to OS6.

We'd still suffer from bootloader issues which have not be solved for some boards STM32F and the SKR3.

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

More
3 years 9 months ago #262419 by cakeslob
Its like an issue with and because of the bootloader. I find the bootloader to be a smaller issue compared to sdcard because the boards still function without out the bootloader.
I spent a few weekends trying to debug SD on spider which uses spi, I can get as far as card initialization at an sd level(not remora), but the SD cant read any of the sd card CSD registers. tried lots of things with configuring/debugging the sdblockdevice but thats as far as I could get.
On MKS boards, it will at least load the config from the SD, but it cause an issuefor the next time it boots and the sdcard needs to be powercycled before it will work by either physically ejecting the card or doing 2 power cycles on the board (first power cycle doesnt work second one does)


One thing I saw while looking into it, and it seems to makes sense, was this from klipper
github.com/Klipper3d/klipper/pull/4885
This makes some sense because after a the bootloader successfully loads the firmware from SD, the spi busses shut down, so remora cannot load the config.txt or connect.
Sorry, the stuff gets out of my league very fast, but not for lack of trying.

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

More
3 years 9 months ago #262787 by cakeslob

For the LPC1768 boards, MODDMA is needed, which unfortunately has not been migrate to Mbed OS6. I did have a go and got it kind of working but it was unstable. If we drop LPC1768 support, we could move to OS6.
I see. Im not going to suggest that, it appears there is still interest for those boards.

We'd still suffer from bootloader issues which have not be solved for some boards STM32F and the SKR3.
Just finished up testing, mbed6 changed some things with system_clock, which appear to be bootloader related.
Octopus446 - working with bootloader
Monster8 - bootloader messing with comms
Spider - working with bootloader , and not working without bootloader

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

More
3 years 9 months ago #263209 by cakeslob
I was working on the stm32g0b1 manta 8 this weekend, got everything working, bootloader, sd, servo and base, and thats where it stops working, and loops that in terminal. I locked up the one board while trying to set up debug to find out why. I copied the stm32f1, and went from migration guides f1 to f0, then f0 to g0. It says something about a dmamux.
github.com/cakeslob/Remora/tree/mbedos6/...a-OS6/TARGET_STM32G0
www.st.com/resource/en/application_note/...microelectronics.pdf
www.st.com/resource/en/application_note/...microelectronics.pdf
www.st.com/en/microcontrollers-microproc.../stm32g0-series.html


When I was setting up the G0B1 to work with bootloader, I think I see the problem with the SKR3 bootloader.
github.com/cakeslob/Remora/blob/hello-wo...3/system_clock.c#L57

This seems the issue with the bootloader, bootloader appears to be working now with this in the system_clock. I cant figure out the proper systemclock settings to print hello world properly though, Ive done something wrong with the config

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

Time to create page: 0.198 seconds
Powered by Kunena Forum