VSIDE - VS1053 - Uploading code with a microcontroller

Installing and using VSIDE tools for VLSI Solution's devices that contain a VSDSP signal processor.
Post Reply
Without
User
Posts: 8
Joined: Wed 2015-07-08 9:45

VSIDE - VS1053 - Uploading code with a microcontroller

Post by Without » Mon 2015-07-13 12:22

After compiling and uploading the data. is the data stored in the VS1053 flash? So after rebooting the VS1053 is loading my program?

User avatar
pasi
VLSI Staff
Posts: 1511
Joined: Thu 2010-07-15 16:04

Re: VSIDE - VS1053

Post by pasi » Mon 2015-07-13 12:26

The code you upload to vs1053 is going into RAM. There is no FLASH inside the vs10xx chips (except vs1005).

If you have a standalone application, you store the boot image into a SPI EEPROM from where the vs1053 loads it.

If you have a plugin, your microcontroller must upload the code after power up and after hardware reset.
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

Without
User
Posts: 8
Joined: Wed 2015-07-08 9:45

Re: VSIDE - VS1053

Post by Without » Mon 2015-07-13 21:38

I don`t want to use a EEPROM for security reasons. Can I upload the content myself to the VS1053 using a microcontroller? If so, where can I find the imagefile? And can I connect my controller to the RS232 port of the VS1053 to upload the content?

User avatar
Panu
VLSI Staff
Posts: 2585
Joined: Tue 2010-06-22 13:43

Re: VSIDE - VS1053

Post by Panu » Tue 2015-07-14 5:22

Hi!
Without wrote:Can I upload the content myself to the VS1053 using a microcontroller?
Pasi already answered you:
pasi wrote:If you have a plugin, your microcontroller must upload the code after power up and after hardware reset.
The key word here is plugin. The compiler toolchain, among other things, produces a plugin file which is a C file, in one of two possible formats, which contains an array of data writes to SCI_WRAMADDR and SCI_WRAM registers you can do using SPI.

It is technically possible to upload code using UART and the VS3EMU protocol (and internally at VLSI we do this sometimes) but I don't think there are any examples published about loading code this way (though I might be wrong).

-Panu
Info: Line In and Line Out, VS1000 User interface, Overlay howto, Latest VSIDE, MCU Howto, Youtube
Panu-Kristian Poiksalo, VLSI Solution Oy

User avatar
pasi
VLSI Staff
Posts: 1511
Joined: Thu 2010-07-15 16:04

Re: VSIDE - VS1053 - Uploading code with a microcontroller

Post by pasi » Tue 2015-07-14 12:58

You can use coff2allboot to also generate a plugin array to be compiled into your microcontroller program. You then upload the program using SCI_WRAM and SCI_WRAMADDR (possibly other registers are loaded, but not normally), and after the upload you start the code with the appropriate write to SCI_AIADDR register. This write can be also in the plugin array, if you give the -x option to coff2allboot.

For example

Code: Select all

coff2allboot -i plugin -x 0x50 -o myprogramplugin.c Emulation-Debug\myprogram.coff
Note that programs (applications that take over the system) started from SPI boot and programs started using plugin array find the vs10xx system in different states. For example, you need to call Enable() when the program is started using SCI_AIADDR, because first call happens from inside the SCI interrupt handler, and also clear the applAddr function pointer to avoid recursion if you use any of the system functions (applAddr is called among other things when samples are output, so it would call your main again).
Visit https://www.facebook.com/VLSISolution VLSI Solution on Facebook

Post Reply