Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[SOLVED] Questions about hardware programmer

Status
Not open for further replies.

freejustice

Newbie level 2
Joined
Oct 30, 2014
Messages
2
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
18
Actually I am quite interested in the basic working principle of hardware programmer.
I think it programs the MCU by controlling the pins in a certain order so that the .hex program file can be written into the target MCU, but i am extremely unsure about it.
Meanwhile I also want to know do all MCUs contain bootloader? What is the role of a bootloader when we burn the program file into the MCU?
Finally... If a hardware programmer merely programs the MCU by controlling the pins, then why can't we directly program the MCU with our computer? It sounds unnecessary to use a programmer then.....

:-?:-?
 

You can load the program to flash using bootloader. Some microcontrollers, like HC11 of motorola/freescale can be programmed direclty with COM port using TTL levels. Some microcontrollers have USB bootloader.
But who will work with microcontroller without debug possibility? That's why we are using debug tools.
Cheepest variant - STLink v2 (5$ from ebay) and STM8/STM32 microcontrollers.
 

Boot Loaders are part of the program that was used to have minimum level of features, example - If you need autofirmware upgradation without external programmer, then you can write a very small program that will get data from external host via serial or anyother mode of communication, and erase the data and write the data to flash.
so that the chip can be sent by bootloaders alone where bootloader can take part of the whole program.

this is just one example. bootloader is the first part of the program that will boot.
 

so boot loader is a must for the mcu to function properly

then how can we program the boot loader into the mcu ?
if the mcu doesn't have the boot loader, how can we use spi or uart to burn the boot loader and our target program into the mcu ??
 

A bootloader is not always necessary. Its a program already in the MCU that gives it enough ability to receive a new program over a serial link. Usually, you can use direct hardware driving as well, in fact it is normally necessary to do that to put the bootloader progam in the MCU in the first place!

Note that you don't normally load a hex file into an MCU unless the bootloader program is designed to read it and convert it back to binary. The hex file is a text version of the binary information with address headers and checksums added to it. The MCU itself will only execute a binary program so either the bootloader or the programming hardware has to interpret the contents of the hex file, convert the data part of it to binary then load it in the appropriate MCU address.

Brian.
 

Hi,

so boot loader is a must for the mcu to function properly

No


then how can we program the boot loader into the mcu ?
if the mcu doesn't have the boot loader, how can we use spi or uart to burn the boot loader and our target program into the mcu ??

When referring to popular chips like Pics and Atmels you must use a hardware programmer to burn in either the program code direct or if prefered to burn in a bootloader program so you can load the user program via a simple pc serial link.
 

Status
Not open for further replies.

Similar threads

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top