Remora for RP2040

More
2 years 7 months ago - 2 years 7 months ago #295824 by Jaron
Replied by Jaron on topic Remora for RP2040
When I try to jog the X Y or Z axis this error pops up, I thought this servo period thing was the culprit. The error I get when trying to move an axis is as follows:
Warning: Spoiler!


When starting and pressing the E-stop in the GUI I get the previous error. Then I can turn the machine on and press the X Y o Z jog buttons. But then I get that error.
I don't think the E-stop can be triggered on the pico since I don't even have it defined in my config file.

I think the outputs acting up on the Pico means that the gpio's are not yet initialized. When running a simple LED blink via MicroPython on one output the LED toggles nicely. I'm guessing the GPIO's don't get initialized properly on the board, maybe that is due to my config file?

This is what I use currently:
(Config file)

​​​​​​​
Code:
{ "Board": "PICO_ETHERNET", "Modules":[ { "Thread": "Base", "Type": "Stepgen", "Comment": "X - Joint 0 step generator", "Joint Number": 0, "Step Pin": "GP2", "Direction Pin": "GP3" }, { "Thread": "Base", "Type": "Stepgen", "Comment": "Y - Joint 1 step generator", "Joint Number": 1, "Step Pin": "GP4", "Direction Pin": "GP5" }, { "Thread": "Base", "Type": "Stepgen", "Comment": "Z - Joint 2 step generator", "Joint Number": 2, "Step Pin": "GP6", "Direction Pin": "GP7" } ] }
*I've also tried using the "Type": "Blink" in the config to Toggle an LED and I didn't have any success..
Last edit: 2 years 7 months ago by Jaron.

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

More
2 years 7 months ago #295848 by cakeslob
Replied by cakeslob on topic Remora for RP2040
blink will just strobe at a set rate as soon ass it connects to ethernet, so i would try to see if you can get that working first. if blink didnt work properly, its possible your stepper config was not loaded to the pico either, which would result in a following error.




I dont know what to tell you about the emctask error, except that ive seen several users with the issue recently, but I dont know what solved it

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

More
2 years 7 months ago #297274 by Jaron
Replied by Jaron on topic Remora for RP2040
I've tried to do some digging and got the uart debugging to work.
This is my output:
Code:
Remora for RP2040 starting (core0)... netif link status changed up netif status changed 10.10.10.10 Remora for RP2040 starting (core1)... ## Entering SETUP state 1. Loading JSON configuration file from Flash memory 2. Parsing JSON configuration file Config deserialisation - Deserialization succeeded 3. Configuring threads Creating thread 40000 Creating thread 1000 4. Loading modules Creating a std module Creating an Ethernet communication monitoring module Base thread object X - Joint 0 step generator Creating a std module Creating Pin @ pin = GP65508

It seems to stall when trying to initialize the first pin with very high pin number.
I've never initialized it like that so now I have some questions.
I've tried uploading a new config via python3 upload_config.py nvem-basic-config.txt and that doesn't seem to do anything. The command excecutes correctly but when rebooting the pico after it still give the same uart debug return.

It might be that the pico is just stuck with this config and because of it it won't boot and can't change it's config.. 
When I re-program the pico by flashing the UF2 image, does the configuration change to default from boardconfig.h?
I've tried flashing the pico also without setting a config file but this still happens, is there any way to hard code the pin definitons or maybe remove the pin configuration from the pico?

Thanks for the help, 
 

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

More
2 years 7 months ago #297291 by cakeslob
Replied by cakeslob on topic Remora for RP2040
alright its getting stuck from a bad config load?

wipe the whole chip probably before you reload the firmware, or just eraser the chip sector with the bad config
The following user(s) said Thank You: Jaron

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

More
2 years 7 months ago #297305 by Jaron
Replied by Jaron on topic Remora for RP2040
Good idea to wipe the whole chip, didnt know that was needed or possible for the RP2040.

Oh my god, it actually worked!
I used the flash_nuke.uf2 file from  electrocredible.com/how-to-reset-raspberry-pi-pico-w/ . At first I unplugged the pico after dropping the file on the pico directory and it makes the disconnecting sound from the computer, DON'T DO THIS. It seems like it takes quite a few seconds to wipe the whole memory of the pico and once it's done it returns to bootloader mode and shows up as a directory again.

After that I dropped the remora.uf2 on there and got a nice blinking LED and everything, error in linuxCNC is also gone, I'll check if everything else works aswell tomorrow. Really glad I got passed this though.

Thanks!
 

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

More
2 years 7 months ago #297371 by Jaron
Replied by Jaron on topic Remora for RP2040
After trying to change the board config.txt file (Uploading via upload_config.py) it still gets bricked and firmware gets stuck on either "pin = GP65508" or "pin = GP65518" on boot.
I thought I could just change the board configurations in boardconfig.h of the firmware, compile it and then use remora like that but sadly i've not gotten that to work yet. 
I thought it loaded the pin definitions from here but after trying numerous changes, wipes and re-compiles I can't even get another pin to blink.
The on board LED blinks and I though this was because of the line
Code:
BlinkPinConfig BlinkConfigs[] = {{"Blinky on GP25", "GP25", 0} 
in the file boardconfig.h
But changing this to for instance GP04 and having an LED attached to pin 4 of the pico. It still blinks the on board LED and not GP04.
I'm at a loss again as to what I can try. I've tried to do a complete re-build of the firmware thinking my code didn't compile poperly but I might just be misunderstanding this config file.

If anyone has tips or hints as tot what I could try I'd be really thankfull.

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

Time to create page: 0.289 seconds
Powered by Kunena Forum