-
Notifications
You must be signed in to change notification settings - Fork 39
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
SD Bootloader #27
Comments
You could try flashing my build for the 1284p? I managed to get serial working, the only issue is that the device signature is wrong and your flasher will think it is an ATmega 1284 non 'p'. Cable select is on pin 4, iirc, you were not supposed to use cable select on pin 10. Can't remember why or whatnot, but the above works. |
By default the ATmega1284P standard variant requires Mighty 1284P to be installed: You can easily modify avr_boot to reference the MightyCore variant by simply changing line 384 of boards.txt from:
to:
Looking at the documentation I wrote now I see that I didn't explain that. Although MightyCore is superior in every other aspect, I chose Mighty 1284P by default because it has the Sleeping Beauty variant, which MightyCore does not. Since that time I got the author of the Sleeping Beauty to provide an open source license so I am now able to add native support for that variant to avr_boot, which I planned to do for the next release. However, there has not been any development work merged to the avr_boot bootloader code since the last release so no reason for a new one.
After you change the Tools > SD CS Pin option you need to to a Tools > Burn Bootloader again. Also, make sure you have the correct pin on the ATmega1284P connected. For the avr_developers variant Arduino pin 10 is mapped to PD2. |
Awesome, thanks guys for the support, will give that a try :) |
OK guys, the pinout problem is sorted thankyou so much, I should have said, but I'm not using an Arduino board of any variant, as i basically have made my own complete board using a blank 1284P (40 pin), as its a prototype, I'm using an adafruit micro SD (just because the buffer IC and 3.3v reg are on board). Many thanks Jono |
The correct fuses should be set when you do Tools > Burn Bootloader. I did fairly comprehensive testing with ATmega1284P before the release but there are a lot of possible combinations of settings so it's possible I didn't test your exact configuration and there's a problem. I'll try to get around to doing a test soon.
ICSP uses SPI, the SD reader uses SPI also. So that statement makes me suspicious. However, if I understand correctly, you've already verified that the SD module is working correctly. |
Yes everything working OK, ICSP is now working (I had the MISO and CLK pinout incorrect) as does the SD when running, ive had a look a fuse calculator online, I now understand how those are set but Im not sure what all the options provide, it just doesn't seem to access the SD and load the BIN file on boot as it should, is there a fuse setting that allows SPI to be initiated on boot? Regards John |
Hi Guys, I know you are all very busy but if anyone cane me with this I would be most grateful, its driving me nuts. this is the message from AVRDUDE when I try to load it. Writing | ################################################## | 100% 81.68s avrdude.exe: 130662 bytes of flash written Reading | ################################################## | 100% 67.21s avrdude.exe: verifying ... avrdude.exe: safemode: Fuses OK avrdude.exe done. Thank you. What am I doing wrong, I have followed the instruction, and checked and double checked fuse settings, I increased the bootloader size to 4096 in the fuse settings, yet still I cannot get this to load the new BIN file. Any ideas anyone?? Regards Jono |
Please provide more information on what you meant by "does not seem to install correctly".
Is that the message from when you're using BIT BURNER? |
We'll continue the conversation here: |
Hi zevero,
I have been working on a project and would like to be able to flash my 1284P from SD card for updates, I have loaded your avr_boot, firstly i am unable to select standard pinout as it will not compile, so i left it set as avr-developers.com, this must be different from standard as it my program although runs and loads does not run as it should (i was using the mightycore bootloader before), if i reload that, the code runs fine.
Using avr_boot, I created BIN file as instructed and tried to load it , i moved my SD card CS to pin 10 (as i thought you should not use pin 4 on the 1284P the SS pin as a CS)
However the hex file does not load, it just boots up as before with program not operating as it should, when i reload Mighty Core (standard pin), my project runs fine. am i doing something wrong or is there another library to use? i tried downloading the Mighty 1284P standard as in your option selection, i just get a boards.txt error.
here is a copy of the error if i select standard Mighty1284P
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0xc pc=0x4a75b7]
goroutine 1 [running]:
panic(0x54ef00, 0x12080030)
/home/jenkins/go/src/runtime/panic.go:500 +0x331
arduino.cc/builder.(*SetupBuildProperties).Run(0x614ef0, 0x120ce000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/setup_build_properties.go:84 +0xfa7
arduino.cc/builder.(*ContainerSetupHardwareToolsLibsSketchAndProps).Run(0x614ef0, 0x120ce000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/container_setup.go:59 +0x2b6
arduino.cc/builder.runCommands(0x120ce000, 0x12089dc0, 0x3, 0x3, 0x1, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:191 +0xe2
arduino.cc/builder.(*ParseHardwareAndDumpBuildProperties).Run(0x12089dec, 0x120ce000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:180 +0xdc
arduino.cc/builder.RunParseHardwareAndDumpBuildProperties(0x120ce000, 0x0, 0x0)
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/builder/builder.go:227 +0x35
main.main()
/home/jenkins/workspace/arduino-builder-all-cross/src/arduino.cc/arduino-builder/main.go:329 +0xf78
C:\Program Files (x86)\Arduino\arduino-builder returned 2
Error compiling for board ATmega1284/P.
Kind Regards
Jono
The text was updated successfully, but these errors were encountered: