Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Media Init Fail #22

Closed
lukasradek opened this issue Apr 3, 2023 · 8 comments · Fixed by MarlinFirmware/Marlin#25648
Closed

Media Init Fail #22

lukasradek opened this issue Apr 3, 2023 · 8 comments · Fixed by MarlinFirmware/Marlin#25648

Comments

@lukasradek
Copy link
Contributor

I need to print from SD for my Marlin development inside Marlin Simulator but unfortunately I cannot mount the FAT32 image.
I am compiling with the example config from Marlin Configurations and once inside simulator I click "Generate Empty Image". fs.img is created, SD Card Present is checked but I am getting "Media Init Fail" message from printer.

@p3p
Copy link
Owner

p3p commented Apr 3, 2023

Can you make sure you have the newest version of the library, deleting .pio from Marlin and .cache from .platformio in your home folder is the easiest way to be certain.

also are you using Windows?

@lukasradek
Copy link
Contributor Author

lukasradek commented Apr 4, 2023

I am on Windows 11.
I tried deleting .pio and .cache and the issue still persists.

I am also trying to enable DEBUG_CARDREADER to get more info out of it but I haven't been able to solve Undefined reference to hex_address(void const*) during linking yet.

@p3p
Copy link
Owner

p3p commented Apr 7, 2023

This was a bit convoluted to debug, not least as I had to use Windows for the first time in ages, and it wasn't happy about the updates and CPU change ^^,

To fix it go in Marlin/src/sd/SdFatStructs.h and find struct partitionTable , change unsigned to uint8_t that should reduce the structure back to 16 bytes as it needs to be.

@lukasradek
Copy link
Contributor Author

lukasradek commented Apr 7, 2023

The Man, the Myth, the Legend! Thanks.
And also killed two marlins with on spear 🙂.

Also your Windows must be grateful 😁.

@p3p
Copy link
Owner

p3p commented Apr 8, 2023

Closing as the fix was merged into Marlin, although you haven't confirmed it worked for you.

@p3p p3p closed this as completed Apr 8, 2023
@lukasradek
Copy link
Contributor Author

Sure it worked! I thought it was obvious from the my reaction 😉. Thanks for the quick fix.

@p3p
Copy link
Owner

p3p commented Apr 8, 2023

Was just making sure as you didn't close the issue ;), thanks for bringing the problem to my attention it must have never worked on windows.

@lukasradek
Copy link
Contributor Author

To be honest... it didn't even occur to me, that I can close the issue myself 😁. Usually when I open issue somewhere, it is not solved for a looong time, so I am not practicing the "closure" part.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants