cancel
Showing results for 
Search instead for 
Did you mean: 

The elf loader file is not accessible [only via *.bat]

Martin Kathke
Associate
Posted on May 29, 2018 at 09:40

Hello everybody,

i have a strange problem, hope that someone has a great idea what i can do...

We have custom board's with the stm32f7 and f4. Normaly we flash the device via bat (or open ocd(which is working)).

The bat looks like this:

..\st-link\ST-LINK_CLI.exe -c SWD UR -Rst

..\st-link\ST-LINK_CLI.exe -c SWD UR -P firmware.hex

..\st-link\ST-LINK_CLI.exe -c SWD UR -P bootloader.hex

..\st-link\ST-LINK_CLI.exe -c SWD UR -Rst

pause

Since someday's i get the follow error message while flashing:

The elf loader file is not accessible.

This is the complete output from the console:

ST-LINK SN : 33FF68064D4E353545150843

ST-LINK Firmware version : V2J24S4

Connected via SWD.

SWD Frequency = 4000K.

Target voltage = 3.2 V.

Connection mode : Connect Under Reset.

Device ID:0x449

Device flash Size : 512 Kbytes

Device family :STM32F74x/F75x

Loading file...

Flash Programming:

File : firmware.hex

Address : 0x00200000

Memory programming...

?????????????????????????????????????????????????? 0%

The elf loader file is not accessible.

We have this problem on two PC's and one PC is working.

I already tried:

Flashing via St-Utility -> Working without a problem

Flashing via openocd -> 

Working without a problem

SWD Frequenz to 1800K -> Same problem

Updated St-Utility 

-> Same problem

Firmware Update the St-Link 

-> Same problem

Take a Brandnew ST-Link 

-> Same problem

Updated Win driver 

-> Same problem

Taking the st-link from the pc which is working 

-> Same problem

What can i do or try?

If you know something i would be very happy

Thank you and have a nice day!

#loader #elf #bat
3 REPLIES 3
AvaTar
Lead
Posted on May 29, 2018 at 10:21

Are you sure you are not having spaces in the path name of your ELF file ?

And if so, is the path surrounded by ' - characters ?

Martin Kathke
Associate
Posted on May 29, 2018 at 11:08

Yes i'm hundert percent sure.

But you have give me a idea. 

I copyd the bat and hex file directly to the st link folder. There It's working. So for me it looks like i have a not acessable file or something like this.

Posted on May 29, 2018 at 11:28

Path names in Windows are often not what it seems.

And for certain system paths special restrictions apply, and strange this happen if you try 'normal business' there.

I would switch the batch echo output on, to see the actual path. Perhaps another invalid character.