Pages: 1 [2] 3   Go Down
Author Topic: BOOT LOADER  (Read 3372 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Sr. Member
****
Karma: 1
Posts: 322
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I knew y'all would understand.  If I need to be a "Power User" then I should change jobs.  One that requires cleaning products.
Logged

Offline Offline
Full Member
***
Karma: 2
Posts: 158
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I wonder why installing a boot loader directly on a blank ATmaga from the IDE is not an option
 at arduino UNO ??

Is it so complicated matter ?
Is the change needed so big ?

Elico
Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 547
Posts: 27363
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Installing the bootloader is not difficult, just need an AVR ISP to control the SCK/MISO/MOSI/Reset pins.
One can use a dedicated device to do it, I use this one
http://www.mdfly.com/index.php?main_page=product_info&cPath=5&products_id=415
and select Tools: Burn Bootloader in the IDE.

Or one can use the Optiloader sketch, download it into an Uno or equivalent,
connect power, gnd, D13 to D13 (SCK), D12 to D12 (MISO), D11 to D11 (MOSI) and Uno's D10 to programmed devices' Reset pin.
Programmed device needs 16 MHz crstal/caps, or comparable resonator, or be another board:
https://github.com/WestfW/OptiLoader
See the video in this thread
http://arduino.cc/forum/index.php/topic,68183.0.html

Nick Gammon also has a nice article on programming bootloaders,
http://www.gammon.com.au/forum/?id=11635

Alternately if one has an FTDI equipped board, or an FTDI breakout board, one can use that to bit-bang a bootloader in.
http://www.geocities.jp/arduino_diecimila/bootloader/index_en.html
« Last Edit: May 31, 2012, 01:55:28 pm by CrossRoads » Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Sr. Member
****
Karma: 1
Posts: 322
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I wonder why installing a boot loader directly on a blank ATmaga from the IDE is not an option at arduino UNO ??

Installing a boot loader onto a blank chip is not a big deal.  However, it is not part of the Arduino design.  The most common method is to use ISP (In System Programming) also know as an ICSP (In Circuit Serial Programming).  Devices to do this are very common.

You have options, some you have read about and some pointed out by CrossRoads.

The easiest, and maybe the cheapest is to get a USBasp.  They can be had for less than $5.  It probably will have a 10 pin connector, you will need to spend another $2.50 to get a 10 pin to 6 pin adapter.  After that you are set to program as many chips as you would like.  Just plug it up and go to town.

I believe that you can also load the sketch "ArduinoISP".  This will turn your Arduino into an ISP.  I suspect it will work on the Uno, although I have never used it.
You then need to wire up the new chip.  You can't replace the chip in your Uno because you will be using that one to run the sketch.  All you need is a little breadboard and 6 wires.  I have not purchased a breadboard in a while but this might be a couple dollars cheaper.  But you need to be careful with your wiring.

Is it so complicated matter ?   Is the change needed so big ?

I'm sure that you would like to be able to use the same USB cable that you use to load your sketches to also load your boot loader, but alas it is not to be.
« Last Edit: May 31, 2012, 02:51:00 pm by RandallR » Logged

Global Moderator
Boston area, metrowest
Offline Offline
Brattain Member
*****
Karma: 547
Posts: 27363
Author of "Arduino for Teens". Available for Design & Build services. Now with Unlimited Eagle board sizes!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

"I'm sure that you would like to be able to use the same USB cable that you use to load your sketches to also load your boot loader, but alas it is not to be."
Not totally true - the final option I listed does just that, works great on a duemilanove style board where one has access to the pins of an FTDI chip.
Logged

Designing & building electrical circuits for over 25 years. Check out the ATMega1284P based Bobuino and other '328P & '1284P creations & offerings at  www.crossroadsfencing.com/BobuinoRev17.
Arduino for Teens available at Amazon.com.

Offline Offline
Full Member
***
Karma: 2
Posts: 158
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I hope some one will build ans sell such a fast and easy boot loader for the UNO chip .
I am sure it will have a good market ..

Elico
Logged

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 502
Posts: 19086
Lua rocks!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I wonder why installing a boot loader directly on a blank ATmaga from the IDE is not an option
 at arduino UNO ??

Is it so complicated matter ?
Is the change needed so big ?

Well, you tell me where the bootloader would come from?

In order to make a chip that could install its own bootloader you would need a second chip, either with the bootloader on it, or with code to install the bootloader on the first chip. So how does the code get on the second chip? Well you would need a third chip to install the bootloader on the second chip. But what about the third chip you ask? Well I'm glad you did, because that brings us to the fourth chip...

You can do it right now if you buy the external hardware (an ICSP programmer) ... that is effectively the "second chip". They could supply one with each Uno, if they didn't mind doubling the price.
Logged


Offline Offline
Sr. Member
****
Karma: 1
Posts: 322
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Well Nick you did it again.  You put your finger on the solution.
In order to make a chip that could install its own bootloader you would need a second chip, ...

The Uno has just that.  The Uno has 2 chips on it.  It also has 2 ISP headers.  So you just need to add the programming software to the USB interface chip.  You would need a jumper to let the interface chip know which program to run.  I would use what Arduino calls pin D10.  Start by setting it to input and write it HIGH.  Then read it.  If it is connected to ground via a jumper then it should work in the usual USB to serial mode.  If it is HIGH then it is connected to the reset pin of the primary chip (via the jumper moved to the other position).  You are now ready to down load your new bootloader.

You probably can not modify an existing UNO but it would be great and cheap improvement for the next revision, if there are any more revisions. 
Logged

Global Moderator
Offline Offline
Brattain Member
*****
Karma: 502
Posts: 19086
Lua rocks!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes I suppose you could do that. But say the bootloader is changed (to fix some bug) then you need an external programmer to change the USB interface chip (to upload the new bootloader-uploading code). So you've just shifted the problem along one chip. Let's put it like this: say you have a Uno board with the USB chip programmed to install bootloaders, you may as well supply it with the bootloader installed as well (on the main chip).

The sort of situation where people need to buy blank chips and install bootloaders, is one where they would have a spare board around to put the bootloader on the chip. As I describe here:

http://www.gammon.com.au/forum/?id=11635

The whole thing about bootloaders is that it is a chicken-and-egg situation. Without a bootloader "burner" (ie. an ICSP programmer) you can't install a bootloader, nor indeed can you make a device that makes bootloader burners. Thankfully the word has plenty of them now.

I hope some one will build ans sell such a fast and easy boot loader for the UNO chip .
I am sure it will have a good market ..

Well I suggest you make one then.
Logged


Offline Offline
Full Member
***
Karma: 2
Posts: 158
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Yes who knows ...
Logged

Offline Offline
Full Member
***
Karma: 2
Posts: 158
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i really think that the next UNO will include the following (and mre)
1> A ZIP socket for the main chip .
2> An easy way to burn the boot loader on a blank ATmega .

Looks to me it is possible and really needed to developers .

Elico
Logged

Gosport, UK
Offline Offline
Faraday Member
**
Karma: 21
Posts: 3113
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I really don't think either will be included. For most users, a zif socket simply isn't needed, and would increase the cost. As has been said, a USBasp, for under $10, including adaptor, makes burning a bootloader easy, and, again, most users won't need to do it, when buying a new chip with a bootloader already installed will be enough.
Logged

North Queensland, Australia
Online Online
Edison Member
*
Karma: 74
Posts: 2224
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

To solve your need for an easy way to remove/replace the atmega, just buy an extra 28 pin IC header.

Place your IC in the header then  plug that header onto the board header...
Some IC headers are quite easy to separate from each other, and if its not, then you don't have to worry about damaging the IC pins when levering it off.

Mine are used now and separate quite easily. It also holds in tight enough for a quality connection.
Logged


Global Moderator
Offline Offline
Brattain Member
*****
Karma: 502
Posts: 19086
Lua rocks!
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

i really think that the next UNO will include the following (and mre)
1> A ZIP socket for the main chip .
2> An easy way to burn the boot loader on a blank ATmega .

What is a ZIP socket? Do you mean a ZIF (Zero Insertion Force) socket?

Well here is the first problem:



As you can see, the ZIF socket is big. So it is higher than the headers you plug the shields into. So none of the existing shields will work. Unless you make the whole thing much larger.

Next, ZIF sockets are expensive. I am seeing quotes of around $16 on Digi-Key.

So you are saying you think the next Uno should be somewhat larger, not compatible with existing shields, and cost 50% more? Is that it?

Quote
2> An easy way to burn the boot loader on a blank ATmega .

Why, exactly? Do you think people will buy Unos and then buy extra blank chips and want to hit a button and have the bootloader programmed? Why not just buy this for example:

https://www.adafruit.com/products/462
Logged


Gosport, UK
Offline Offline
Faraday Member
**
Karma: 21
Posts: 3113
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Was just coming to post this one, for $13: http://evilmadscience.com/productsmenu/tinykitlist/253 - similar to the adafuit one.
« Last Edit: June 01, 2012, 03:05:25 am by dxw00d » Logged

Pages: 1 [2] 3   Go Up
Jump to: