Error: could not load executable!

Writing software that controls the system and peripherals such as displays, SD cards, Buttons, LEDs, Serial Ports etc.
Post Reply
JEG
User
Posts: 6
Joined: Sat 2015-11-21 12:40

Error: could not load executable!

Post by JEG »

Hi,
My level of experience with VSOS is beginners level. I just received my vs1005 breakout board. I am trying to compile and run the Simple MP3 Player code. The code compiles OK, but when I try to run in debug mode I get the following error:

Loading system 'C:/VSIDE/plugins/emulator.system'...
Loading 'Emulation-Debug/MyProjectmp3new.coff'...
Error: could not load executable!

Any suggestions will be appreciated.
User avatar
Panu
VSDSP Expert
Posts: 2821
Joined: Tue 2010-06-22 13:43

Re: Error: could not load executable!

Post by Panu »

You can't run VSOS programs via the emulator, you must copy the program (MyProjectmp3new.ap3) (which could be a too long file name) to the flash and run it from the flash, just as you would run a ready-made program such as "playfile song.mp3".

With the breakout board, it's easiest to get started with the UART SHELL. With the UART shell, you can use your board like it was a computer. Later you can automatize running programs, or perhaps add a LCD screen etc for a graphical interface.

To get the basic idea on how VSOS works, take a look at the educational videos at viewtopic.php?f=13&t=1273#p5655

and take a look at the UART shell thread to get a basic idea on how the command line works. viewtopic.php?f=13&t=1615

Then get the latest VSOS distribution, copy the "small_root" files to your breakout board's flash. Then you can use it from the uart shell command line, run programs you have written etc. viewtopic.php?f=13&t=680&start=50#p8242

-Panu
JEG
User
Posts: 6
Joined: Sat 2015-11-21 12:40

Re: Error: could not load executable!

Post by JEG »

Thanks for the reply. So there is no way of using the debugger in VSIDE to step through code, set breakpoints, and view registers?
User avatar
Panu
VSDSP Expert
Posts: 2821
Joined: Tue 2010-06-22 13:43

Re: Error: could not load executable!

Post by Panu »

Hi!

You can debug code that is loaded to the RAM via the IDE: that means executables that are running directly on the hardware and not loaded through the OS or called from the ROM. Since the debugger cannot place breakpoints into ROM, you lose control of your program when ROM functions are called.

Sometimes when I need to debug with the debugger something that runs on the VSOS, I make a custom kernel, e.g. take the kernel template and add a function (into main.c) and add a call to that function into kernel_main(). The kernel itself can be loaded using VSIDE UART and thus also the additions I have made to the custom kernel. That way I can debug VSIDE programs as long as I have set breakpoints into the RAM-loadable code.

I originally developed VSOS kernel itself using VSIDE's simulator and emulator, carefully not importing any ROM libraries or symbols.

-Panu
avizet
Senior User
Posts: 28
Joined: Tue 2021-06-29 11:25

Re: Error: could not load executable!

Post by avizet »

Hi Panu!

I'm getting the same error. Can you please suggest me how can I debug the VS1010D mini dev board using VSIDE? (Video link will be preferable)

Regards,
Avizet
Hannu
Senior User
Posts: 264
Joined: Mon 2016-05-30 11:54

Re: Error: could not load executable!

Post by Hannu »

For same error you get the same answer :) VS1010 runs VSOS from ROM. Running VSOS applications on emulator isn't supported.

Have you already watched these videos?
https://www.youtube.com/channel/UC9Ueao ... i99vjea_Tg
avizet
Senior User
Posts: 28
Joined: Tue 2021-06-29 11:25

Re: Error: could not load executable!

Post by avizet »

Hi Hannu!

Thanks for the replay. I got the point. Can you please suggest me how can I build the UART communication protocol with VS1010D where I can give command and get response from the board? If you have any demo code for this communication system then please share.(through FTDI is preferable).

Regards,
Avizet
User avatar
Henrik
VLSI Staff
Posts: 1238
Joined: Tue 2010-06-22 14:10

Re: Error: could not load executable!

Post by Henrik »

Hello!

Just in case someone reads this thread in the future: Avizet's latest question is addressed in the following thread:
viewtopic.php?f=6&t=2802

Kind regards,
- Henrik
Good signatures never die. They just fade away.
Post Reply