View previous topic :: View next topic |
Author |
Message |
autoguider
Joined: 24 Sep 2007 Posts: 82 Location: Aachen
|
Posted: Sat Mar 24, 2018 8:23 pm Post subject: MCS bootloader fuses |
|
|
Dear All,
I adapted the bascom bootloader example to my processor AVR (ATMEGA168 -20PU), crystal and baud rate.
Code: |
$crystal = 6144000
$baud = 57600
$regfile = "m168def.dat"
Const Loaderchip = 168
|
I sent the compiled program via ISP device to the AVR using the fuse set decribed in the attached image.
Does this set allow the bootloader to work ?
When trying to load another program I use the fuses set as follows
$prog &HFF , &HE7 , &HDF , &HF9
When selecting in the IDE the MCS Bootloader I put the serial values on COM11 ( USB,RS232 adapter with 57600 baud)
In the MCS loader section I put Bootsize to 1024 and reset to soft with the value ABC(123)
When trying to send another compiled program to the AVR COM 11 gets opened and it says sending init byte.
The bootloader gets stuck and after cancellation I see in the Log Window Loader returned: 0
I assume that i did something wrong on the fuse bits.
If you have some adivce to me it would be great.
best regards
Christian
(BASCOM-AVR version : 2.0.7.9 , Latest : 2.0.8.1 ) |
|
Back to top |
|
|
EDC
Joined: 26 Mar 2014 Posts: 971
|
Posted: Sat Mar 24, 2018 9:47 pm Post subject: |
|
|
You should set Extended Fusebit Q into 0 then Extended Fusebits became &HF8
Boot reset vector should simply point to Bootloader - not to $00 cause it means flash start where Bootloader is on the flash end. |
|
Back to top |
|
|
autoguider
Joined: 24 Sep 2007 Posts: 82 Location: Aachen
|
Posted: Sun Mar 25, 2018 12:10 am Post subject: |
|
|
I did it the recommended way
$prog &HFF , &HE7 , &HDF , &HF8 in the program to be flashed and started.
In the log window I can read:
Open COM11
Sending Init byte
Nothing else.
Simulataneously I pushed the reset button on my board.
Still no rsponse.
BR
C |
|
Back to top |
|
|
EDC
Joined: 26 Mar 2014 Posts: 971
|
Posted: Sun Mar 25, 2018 4:32 pm Post subject: |
|
|
Do you read this topic? LINK |
|
Back to top |
|
|
autoguider
Joined: 24 Sep 2007 Posts: 82 Location: Aachen
|
Posted: Tue May 22, 2018 12:30 pm Post subject: |
|
|
Many thanks for the good advice.
Programming using the bootloader went well.
BR
Chris |
|
Back to top |
|
|
|