Page 2 of 2

Re: VS1010 and eMMC

Posted: Tue 2019-08-20 5:58
by rflores765
Hi Panu!

Thanks for all the effort! It is very much appreciated!!

I followed the instructions for the UART method and I got it to work!! I moved some MP3 files from the dev board and the default player plays them great!

To answer some questions:
It may be due to the runlevel (2) or due to something else.
I did solder on a jumper such that there wouldn't be a need to keep pressing the button for each power cycle to get to runlevel 2.
Tomorrow I must check the voltages, if they are stable or not.
Voltages will be most stable with a battery plugged-in instead of only USB power.
Does the XTAL have the 1M resistor across XTALI,XTALO?
There is no resistor across XTALI/XTALO. I will add this to the list of reworks needed for the prototypes. I tried a 470k resistor as in the dev board but that didn't work very well.
Next I wrote a small BOOT.DLX patch to boot the unit differently based on the button presses. I was able to detect S1 and S3 using the schematic Tuukka had. S1 forces it to mass storage, S3 forces it to player, others remain at default runlevel (2). This is what you would do in your product.. the SPI0 resistors set the default runlevel, but when the eMMC is formatted, the BOOT.DLX program is run and that program determines what the board does.
Thanks for this bit of info. It will be very useful! In this boot.dlx, can the GPIOs be set to to turn on or off LEDs? I ask so I can use an LED color to indicate how the product is booted in production.

So to understand correctly, would you recommend the next rev of this schematic (or any future design) be drawn such that it defaults to runlevel 1 (or any of the ones you mentioned) then simply drop in a boot.dlx to choose the runlevel based on the specific UI of the design?

Again thanks for all the effort!

Re: VS1010 and eMMC

Posted: Tue 2019-08-20 15:56
by Panu
Great! And thanks for your feedback!
In this boot.dlx, can the GPIOs be set to to turn on or off LEDs?
Yes, please use the boot.dlx solution from the previous post as basis for writing your own firmware. I will help, of course.

Hmm, one thing came to mind.. VS1010 SD driver also supports 4-bit mode and high speed USB for eMMC, not just for SD cards. So you can try if runlevel 14 (Reboot 14) also works in your board. It's faster than the 12M USB with single bit MMC data connection (runlevel 2).


Re: VS1010 and eMMC

Posted: Wed 2019-08-21 7:30
by rflores765
Yes runlevel 14 would be the better option. I'll give it a shot with a new board!

Re: VS1010 and eMMC

Posted: Tue 2019-08-27 4:42
by rflores765
Hi Panu!

Thanks for the solutions! I was able to modify boot.dlx so pressing S1 sets the runlevel to 14. This works well and I can see an increased speed in file transfer.

Thanks again for the effort!

Re: VS1010 and eMMC

Posted: Fri 2020-08-14 10:07
by Panu
To initialize factory-emptied eMMC card using USB:

- Reboot VS1010D to runlevel 1 (USB RAMDISK).
- Connect Windows PC.
- Disk called "VS1010C_RAM" will come up (it's unchanged from VS1010C, so the name still says VS1010C even though it's VS1010D, sorry.)
- copy the "eMMC_ramdisk_usb_init_n3.img" file to the ramdisk.
- The ramdisk will close and detach from the USB.
- The USB will come up again, this time with the eMMC.
- Format the card to FAT32 using Windows.* (Third party software may be needed to format 64G or larger cards to FAT32)
- Copy mp3 files to the card.

- Do NOT copy any BOOT.DLX file which has not been SPECIFICALLY made for your product to the card as this may brick the unit in a way which is very difficult to recover from!

VS1010 eMMC init.jpg
VS1010 eMMC init.jpg (53.7 KiB) Viewed 815 times
*) Using Windows or OS which uses ATAPI_READ_FORMAT_CAPACITIES instead of SCSI_READ_CAPACITY is recommended.