On 14-06-2005 alle ore 11:35, Anonimo wrote: Trying to save a bit of time, is there a Mass Storage demo written for the str71x ? Regards sjo also I need to develope a Mass Storage using STR71x and SD cards. If you will find info/demo (just to save a bit of time, as you told), please let me know. I will do the same...
Hello Sjo and to all of you ot the forum (thank you Smart)
ST gave me ST72651 mass storage firmware, and I studied it to understand how to port it to STR71x... If you bear with me, I try to summarize what I have understood... The code implements a device able to interface different kind of mass storage. It looks like not all the source is available as, for instance, I cound not find the definition of Vec_main (in the main.c module). . Other missing functions are some SCSI functions. The USB protocol is managed by modules which are mostly written in assembler.. It implements end point 0. plus other 5 end point. It looks like only end point 2 is used for mass storage. At least the BOT_Action function does the necessary interworking between the USB protocol end point 2 and the mass storage drivers, through the SCSI module which contains the RBC commands interpreter. The SCSI module should interwork with the different mass storage (MAL), but the missing functions do not make clear where and how they interfaces for instance the MMC module. The MMC module implements interfacing with MMC mass storage through the DTC. As conclusion these modules cannot be used as they are because or are they written in assembler or are using directly hardware registers and specialized processor as the DTC. However they may help to understand and evaluate the complexity of the implementation and above all to solve any problem wich may arise during design or testing. So, have you any suggestion? Is there the possibility to abbreviate the distance? I hope that it could be possible ... ciao DiGi
The Mass-storage needs only 2 EPs. Since the USB library is generic, you can see references to different EPs, namely 5 ! What concernt the assembly code in 7265x solution, it will be anyway replaced by ST7x USB library. Anyway for all functions written in assembly, there is accompanying ''C'' code. Isn't it ? The 7265x uses DTC which is an embedded co-processor. Definately you will not be able to use these functions. The physical layer interface will anyway depend on the micro itself. You will also find the ''C'' code for physical layer, which is used for launching the DTC functions. I think it is still a good help. The Call to MMC functions is done through software interrupt ''TRAP''. You can directly replace them using function Call.