0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #30 on: May 08, 2012, 12:45:44 pm » |
Do you want to work together on this? I have code for doing the hex file (from my bootdrive project) but I'm wondering if it's worth the space. It's only a small simple command to convert it.
I was going to try to squeeze it down to either: 1. get it out of the 4k bootloader zone (into at least the 2k zone) 2. add back serial programming. The Optiboot code is very small and should be easy to integrate (I ported it into my bootdrive code)
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Full Member
Karma: 0
Posts: 130
|
 |
« Reply #31 on: May 08, 2012, 12:58:30 pm » |
Yes, that would be great. I have doubts about the 2K target, I'd rather focus on fixing the 2boots if we go in that direction. I guess it is something really small that is missing to get it working.
My ideal bootloader will have these features, in order of importance:
* SD card flashing (only if new file is uploaded) * EEPROM based firmware file name * Serial programming * .HEX rather than .BIN * 2K
With the EEPROM based firmware file name, the application may switch itself to a TFTP sketch that will run for 20 minutes and revert back to the original application. The TFTP will wait for incomming connection and if found will save the uploaded file to the SD card (new firmare)..
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 8
|
 |
« Reply #32 on: May 08, 2012, 12:59:48 pm » |
i also have the code for loading from eeprom EDIT: I mean: the code for reading the filename from eeprom 
|
|
|
|
« Last Edit: May 08, 2012, 01:01:56 pm by eudaldcp »
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #33 on: May 08, 2012, 01:03:18 pm » |
Cool. Can we agree to use one github? We can all be contributors, or we could designate one master and do forks/pulls.
Martin, I like the load only if new, and would incorporate that right away. The LED thing should be under ifdef with some defines to make it board dependent. I have an idea how to handle this in the makefile (similar to 2boots).
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Full Member
Karma: 0
Posts: 130
|
 |
« Reply #34 on: May 08, 2012, 01:11:21 pm » |
I think it will be best to do it this way. As I am less experienced, I suggest you take the lead.
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 8
|
 |
« Reply #35 on: May 08, 2012, 01:12:05 pm » |
Hi guys, I agree to make a colaborative github, also, I would like to give an other chance to the 2boots code. I sent a mail to the main developer of 2boots explaining our problems. I still waiting for an answer... But 2boots is based in another code => https://www.mikrocontroller.net/topic/67047 and this one might work for FAT16, if works, we will have 2K extra for including all this stuf!!
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #36 on: May 08, 2012, 01:20:46 pm » |
This is great. Martin, I added you as a collaborator to https://github.com/osbock/avr_bootEudaldcp, what's your github id? I spent a lot of time on 2boots, and actually got about 50% done rewriting it using the sdfat library code. It was really hard to debug. I'm hoping that changes when I get the Dragon I ordered (allows breakpoints.) hold off on putbacks to the repository until I branch (to preserve the current working version.)
|
|
|
|
|
Logged
|
|
|
|
|
Offline
Newbie
Karma: 0
Posts: 8
|
 |
« Reply #37 on: May 08, 2012, 01:24:50 pm » |
Ive just created an account. My ID in github is: eudaldcp 
|
|
|
|
|
Logged
|
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #38 on: May 08, 2012, 01:30:28 pm » |
OK, you are added. WE can probably take this offline to github, unless they are general ideas you feel others would be interested. I created the v.1 branch which nobody should touch (putback to master) Later today I'll draft some groundrules. Basically if you are confident with your change, you can put it back directly. If you want a review, it is best to fork the repository, and then do a pull request.
Also, if you have "application specific features" that aren't of general use, you should probably just put those in your own fork. You can have as many as you want.
|
|
|
|
|
Logged
|
|
|
|
|
MC
Offline
God Member
Karma: 9
Posts: 676
|
 |
« Reply #39 on: August 22, 2012, 10:53:50 am » |
Hi to everyone, interesting thread.
I've a lot of problems to let it working. I'm using an arduino ethernet board 4gb Microsd sdhc, partitioned to only 2gb fat16 formatted.
I've dowload the code from here :https://github.com/osbock/avr_boot/downloads
I've compiled and flash fw into my board making only little modifications at the file provided then i've put a app.bin sketch file named in the root of sdcard. Nothing happen, after reset, app.bin fw not loaded, i can see only the board led (in my board connected to pin9) always on.
Any suggestion? Thanks in advance.
|
|
|
|
« Last Edit: August 22, 2012, 11:05:36 am by niki77 »
|
Logged
|
Vi è una spiegazione scientifica a tutto. La fede è solo quell'anello che si porta al dito dopo il matrimonio.
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #40 on: August 22, 2012, 11:54:02 am » |
Did you set the chipselect? It's been a while since I tried this and some folks have made some changes. I'll try to look and see if I can see anything obvious. Unfortunately I don't have an arduino ethernet to test
|
|
|
|
|
Logged
|
|
|
|
|
MC
Offline
God Member
Karma: 9
Posts: 676
|
 |
« Reply #41 on: August 22, 2012, 02:48:31 pm » |
No i've not set any chipselect.
For what Board that fw is ready TO go? It's possibile that problem come from sdhc card? Thanks again tor your time.
|
|
|
|
|
Logged
|
Vi è una spiegazione scientifica a tutto. La fede è solo quell'anello che si porta al dito dopo il matrimonio.
|
|
|
|
0
Offline
Newbie
Karma: 0
Posts: 27
Arduino rocks
|
 |
« Reply #42 on: August 22, 2012, 02:53:28 pm » |
By default it's set up for Arduino Ethernet (someone else tested it, though I emulated it with a specially wired sd holder) I think your problem might be that it is looking for the program name in eeprom. It is supposed to default to app.bin, but I'm not sure that's tested.
You are trying to load a binary file right? this firmware doesn't read hex files. This was a feature that someone wanted, but I think I'm going to revert back to a fixed filename. Your program could always rename another program to app.bin .
|
|
|
|
« Last Edit: August 22, 2012, 02:56:14 pm by osbock »
|
Logged
|
|
|
|
|
MC
Offline
God Member
Karma: 9
Posts: 676
|
 |
« Reply #43 on: August 22, 2012, 03:35:06 pm » |
Sure i try TO upload a bin file, not an hex .
I thought that this bootloader does not read filename from eprom but it is already made fixed to app.bin. I need to see deep the code...
|
|
|
|
|
Logged
|
Vi è una spiegazione scientifica a tutto. La fede è solo quell'anello che si porta al dito dopo il matrimonio.
|
|
|
|
MC
Offline
God Member
Karma: 9
Posts: 676
|
 |
« Reply #44 on: August 23, 2012, 02:37:02 am » |
Little update: i've let it working flashing directly this hex file for bootloader : http://baldwisdom.com/data/ArduinoEthernetSDBoot.hexIn wich is different from the code on github? Thanks again osbock.
|
|
|
|
|
Logged
|
Vi è una spiegazione scientifica a tutto. La fede è solo quell'anello che si porta al dito dopo il matrimonio.
|
|
|
|
|