some sectors are write protected

Post here first, or if you can't find a relevant section!
dev
Posts: 62
Joined: Sun Feb 19, 2017 8:41 am

Re: some sectors are write protected

Post by dev » Sun Nov 12, 2017 6:46 pm

Hi,

@Rick, I was facing problem while flashing using stlink utility but i could flash using arduino ide.
But after flashing USB bootloader, i couldn't flash using STM32duino bootloader. i used this method before(6 months ago).

@pito, i tried suggested binary too. But not working for my board. Board is detected as COM port but not able to flash the code using usb bootloader.

User avatar
Pito
Posts: 1593
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: some sectors are write protected

Post by Pito » Sun Nov 12, 2017 6:48 pm

Did you flash the bootloader maple_mini_boot20.bin binary with the ST-Link dongle??
Do you use the Maple Mini board? Post a link to your board, plz.
Pukao Hats Cleaning Services Ltd.

dev
Posts: 62
Joined: Sun Feb 19, 2017 8:41 am

Re: some sectors are write protected

Post by dev » Sun Nov 12, 2017 6:52 pm

Yes, i flashed using stlink clone dongle. I have following board with me.
STM32Mini (1).jpg
STM32Mini (1).jpg (132.99 KiB) Viewed 57 times

User avatar
Pito
Posts: 1593
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: some sectors are write protected

Post by Pito » Sun Nov 12, 2017 6:53 pm

That is not Maple Mini board.
Hi,
I was flashing maple mini with st-link clone and st-link utility
You indicate from very beginning your board is Maple Mini.. :(
That is the BluePill board..
This is the binary for your board:
https://github.com/rogerclarkmelbourne/ ... 0_pc13.bin
Pukao Hats Cleaning Services Ltd.

dev
Posts: 62
Joined: Sun Feb 19, 2017 8:41 am

Re: some sectors are write protected

Post by dev » Sun Nov 12, 2017 6:57 pm

ohh...yes. Sorry for that. But i did mentioned stm32f103c8t6.

i know some threads were going on about name of boards.

yes. I have blue pill board.

User avatar
Pito
Posts: 1593
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: some sectors are write protected

Post by Pito » Sun Nov 12, 2017 7:00 pm

Ok, try to flash the BluePill bootloader binary with the ST_Link dongle.
Tell us exactly what is the problem during flashing the bootloader binary with the ST_Link Utility.
We'll try to help you, you have to describe in detail what you have done so far.
The flashing the bootloader with the ST_Link is easy.
Do not power the board from both BP usb and ST_Link, choose only one of them. Use 3.3V only (ie. from ST_Link dongle do use 3.3V).

Sometimes the ST_Link Utility cannot connect. Select Target->Settings->Mode - "Connect under Reset" and press reset button on the BP immediately after you click Target->Connect.
Pukao Hats Cleaning Services Ltd.

dev
Posts: 62
Joined: Sun Feb 19, 2017 8:41 am

Re: some sectors are write protected

Post by dev » Sun Nov 12, 2017 7:11 pm

I am flashing using STlink dongle only, but i get the error continously. I have to reset the board 3-4 times for one flash(which was not the case before two days).

I flashed binary you mentioned. and flashing code as

Code: Select all

// the setup function runs once when you press reset or power the board
void setup() {
  // initialize digital pin PB1 as an output.
  pinMode(PC13, OUTPUT);
}

// the loop function runs over and over again forever
void loop() {
  digitalWrite(PC13, HIGH);   // turn the LED on (HIGH is the voltage level)
  delay(100);              // wait for a second
  digitalWrite(PC13, LOW);    // turn the LED off by making the voltage LOW
  delay(300);              // wait for a second
}
(this code works if flashed via stlink).

after that i selected stm32duino bootlader and COM port which came as 10.

the hit on UPLOAD button then i got following error on output window.

Code: Select all

maple_loader v0.1
Resetting to bootloader via DTR pulse
Searching for DFU device [1EAF:0003]...
dfu-util - (C) 2007-2008 by OpenMoko Inc.
Couldn't find the DFU device: [1EAF:0003]
This program is Free Software and has ABSOLUTELY NO WARRANTY
while uploading LED was blinking for 1 sec and then stopped following line were on output window.

Code: Select all

Searching for DFU device [1EAF:0003]...
which didn't find proper dfu bootloader i guess.

User avatar
Pito
Posts: 1593
Joined: Sat Mar 26, 2016 3:26 pm
Location: Rapa Nui

Re: some sectors are write protected

Post by Pito » Sun Nov 12, 2017 7:25 pm

I am flashing using STlink dongle only, but i get the error continously.
Stop messing with Arduino sketches, unless you have flashed the bootloader successfully.

How do you flash the bootloader with "ST_Link dongle"?
Do you use the ST_Link Utility in order to flash the bootloader??
What errors you get when flashing the bootloader??
What do you see on the BP LED after you flashed the bootloader?
Last edited by Pito on Sun Nov 12, 2017 7:31 pm, edited 3 times in total.
Pukao Hats Cleaning Services Ltd.

User avatar
RogerClark
Posts: 7160
Joined: Mon Apr 27, 2015 10:36 am
Location: Melbourne, Australia
Contact:

Re: some sectors are write protected

Post by RogerClark » Sun Nov 12, 2017 7:26 pm

Sounds like the USB pullup resistor problem

User avatar
Rick Kimball
Posts: 1038
Joined: Tue Apr 28, 2015 1:26 am
Location: Eastern NC, US
Contact:

Re: some sectors are write protected

Post by Rick Kimball » Sun Nov 12, 2017 7:29 pm

dev wrote:
Sun Nov 12, 2017 6:57 pm
ohh...yes. Sorry for that. But i did mentioned stm32f103c8t6.
"A rose by any other name would smell as sweet"...

Maybe those words ring true with Shakespeare and love. Unfortunately, the name of the board is important here. I hate wasting my time on this kind of confusion. Why do people find it so hard to identify what they are using?
-rick

Post Reply