STM32F469i Disco SD Card FAT 4Bit mode
Moderator: Benj
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
Now I have a STM32F469i discovery board. This board has a SD card connector for 4bit mode.
I hope this this faster than the spi mode.
Would it be possible to integrate this mode into flowcode7?
Now I have a STM32F469i discovery board. This board has a SD card connector for 4bit mode.
I hope this this faster than the spi mode.
Would it be possible to integrate this mode into flowcode7?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hello,
Currently we support the SD cards on the disco boards but only using the SPI interface.
We can certainly explore the API mode as it should be faster but probably a lot more resource intensive. There are likely to be existing libraries we can tap into so maybe not too big a job.
I'll add it to the list to investigate.
Currently we support the SD cards on the disco boards but only using the SPI interface.
We can certainly explore the API mode as it should be faster but probably a lot more resource intensive. There are likely to be existing libraries we can tap into so maybe not too big a job.
I'll add it to the list to investigate.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
Thank You for the info.I'll change my own hardware on a 4bit SD card connection. So I can use first the SPi and maybe later the "API" mode. I think later I have just to change the software. And I believe with flowcode 7 it will be easy as always.
Thank You for the info.I'll change my own hardware on a 4bit SD card connection. So I can use first the SPi and maybe later the "API" mode. I think later I have just to change the software. And I believe with flowcode 7 it will be easy as always.
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I tried to connect the sd-card to a "software" Fat
But I can not control the chipselect on C11 from the menu of FC7.
Is it possible to use
C8-C12 and D2 by software?
I tried to connect the sd-card to a "software" Fat
But I can not control the chipselect on C11 from the menu of FC7.
Is it possible to use
C8-C12 and D2 by software?
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
How is it now 2 months later?
It would be nice to use the SD card on the STM32F469 in 4Bit mode. Also a longer filename than 8digit would be nice.
How is it now 2 months later?
It would be nice to use the SD card on the STM32F469 in 4Bit mode. Also a longer filename than 8digit would be nice.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hello Stefan,
Have you managed to get the FAT component working at all in it's current state?
Have you managed to get the FAT component working at all in it's current state?
Yes I agree these would be nice to have, unfortunately I am rather busy at the moment, they are on the list but currently low priority.It would be nice to use the SD card on the STM32F469 in 4Bit mode. Also a longer filename than 8digit would be nice.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
Yes the Fat is comfortable to use and I'm working with it on PIC-Board and the STM32F469 Disco Demoboard.
I use a RTCC to generate the filename. The file was generatet 2017_06_21 at 14:29 and 29 sec.
But the filename looks poore like 21142929.wav
It's bether if the filename is longer like 2017_06_21_14_29_29.wav (19 digit)
And the speed is fast enough for the 2channel Project. But now I'm working on 8Channel version.
So I just hope the 4Bit mode is 4time faster.....
At the moment I can work with it and hope to upgrade the FAT soon.
Yes the Fat is comfortable to use and I'm working with it on PIC-Board and the STM32F469 Disco Demoboard.
I use a RTCC to generate the filename. The file was generatet 2017_06_21 at 14:29 and 29 sec.
But the filename looks poore like 21142929.wav
It's bether if the filename is longer like 2017_06_21_14_29_29.wav (19 digit)
And the speed is fast enough for the 2channel Project. But now I'm working on 8Channel version.
So I just hope the 4Bit mode is 4time faster.....
At the moment I can work with it and hope to upgrade the FAT soon.
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I saw in Flowcode7 Fat Propertis "set time and date"
Can I set the creating time from the File with this propertis?
At the moment I dont support it and if I put the Card after recording, in the computer fill in the the time from the computer.
I saw in Flowcode7 Fat Propertis "set time and date"
Can I set the creating time from the File with this propertis?
At the moment I dont support it and if I put the Card after recording, in the computer fill in the the time from the computer.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hello Stefan,
Yes this function should allow you to change the timestamp when creating a file, maybe also for modifying a file, without calling the function then we default to the compilation time and date.
Yes this function should allow you to change the timestamp when creating a file, maybe also for modifying a file, without calling the function then we default to the compilation time and date.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
Thank you for the help. It's looks much bether with the create_time and the shortname with 8.3 digit
Do you know if I can use the Authors propertie in a way?
And on the end of a recording, I have to write in the first sector some infos. But flowcode is not showing me which is the first sector.....
Thank you for the help. It's looks much bether with the create_time and the shortname with 8.3 digit
Do you know if I can use the Authors propertie in a way?
And on the end of a recording, I have to write in the first sector some infos. But flowcode is not showing me which is the first sector.....
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hello,
The author might be stored as part of the extended filename, though I can't find specific reference to where and how this would be done. I do know that at the moment we don't support it.
Some info on FAT, file entries and extended file names.
https://en.wikipedia.org/wiki/Design_of ... file_names
As for writing some info in the first sector, this could be problematic, the first sector is usually the boot sector and contains some critical information about the disk. Writing to this sector could potentially make the disk corrupt or unstable. What about instead saving the data into a second file?
The author might be stored as part of the extended filename, though I can't find specific reference to where and how this would be done. I do know that at the moment we don't support it.
Some info on FAT, file entries and extended file names.
https://en.wikipedia.org/wiki/Design_of ... file_names
As for writing some info in the first sector, this could be problematic, the first sector is usually the boot sector and contains some critical information about the disk. Writing to this sector could potentially make the disk corrupt or unstable. What about instead saving the data into a second file?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I mean not the first sector of FAT, I mean the first sector from the file.
I mean not the first sector of FAT, I mean the first sector from the file.
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Aha Ok that should be possible.I mean not the first sector of FAT, I mean the first sector from the file.
When you are done writing to the file open the file again and this will load the local 512 byte buffer with the first sector of the file.
ReadByteFromBuffer will allow you to read a byte from the local buffer.
WriteByteToBuffer will allow you to override a byte in the local buffer.
WriteFileSector will write the local buffer back to the card overwriting the first sector of the file.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
I've created a file with Author properties and looked at the record in Winhex to see the format.
Unfortunately it doesn't look particularly simple and may only work correctly with Windows operating systems so for now until I can find a better explanation of how it's done we will not be adding this functionality to the component.
Extended file names would be nice and it may be along similar lines?
Unfortunately it doesn't look particularly simple and may only work correctly with Windows operating systems so for now until I can find a better explanation of how it's done we will not be adding this functionality to the component.
Extended file names would be nice and it may be along similar lines?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I tried this "file open again" and write to the first sector again.
it's working and it's a big help
So I can write some infos there.Thank you Ben
I tried this "file open again" and write to the first sector again.
it's working and it's a big help
So I can write some infos there.Thank you Ben
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I already know the FAT by Flowcode is reliable and easy to use.
But I'm not satisfied with the speed. Is there something new to the 4 bit mode?
I already know the FAT by Flowcode is reliable and easy to use.
But I'm not satisfied with the speed. Is there something new to the 4 bit mode?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Currently working on (amongst other things) a new SD card E-block which has both the SPI and API modes available.
Once I have this it should be simple enough to add a API mode to the component (hopefully). Most if not all of the examples I have seen are for SPI mode so I'm hoping the ST ARM library will help here. Edit - I've had a look through this and it looks fairly horrific.
The API mode should be approx a factor of 4x faster but this is just a guess based on the number of parallel data pins.
Once I have this it should be simple enough to add a API mode to the component (hopefully). Most if not all of the examples I have seen are for SPI mode so I'm hoping the ST ARM library will help here. Edit - I've had a look through this and it looks fairly horrific.
The API mode should be approx a factor of 4x faster but this is just a guess based on the number of parallel data pins.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
I know it is not easy. But my application sampled data and created wavefile. I can sample instead 4khz with 16khz with the same processorspeed. Also, I can not increase the SPI clock arbitrarily so these 4bit are already a big help.
I know it is not easy. But my application sampled data and created wavefile. I can sample instead 4khz with 16khz with the same processorspeed. Also, I can not increase the SPI clock arbitrarily so these 4bit are already a big help.
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
How is the SD card E-block which has both the SPI and API modes available?
I like to create my own hardware with a Pic. Can I have some info from the new Eblock? Can I use the same controler?
It is also not clear to me whether I can use any pin for the API mode or the PIC must have a specific port.
And whether this SD/SDIO/eMMc is something useful.
http://www.microchip.com/wwwproducts/en ... 1025DAA176
50 MHz SD/SDIO/eMMC bus interface
maybe you know more ....
How is the SD card E-block which has both the SPI and API modes available?
I like to create my own hardware with a Pic. Can I have some info from the new Eblock? Can I use the same controler?
It is also not clear to me whether I can use any pin for the API mode or the PIC must have a specific port.
And whether this SD/SDIO/eMMc is something useful.
http://www.microchip.com/wwwproducts/en ... 1025DAA176
50 MHz SD/SDIO/eMMC bus interface
maybe you know more ....
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hello,
The EB board is coming on but will take a while to hit the shelves. Should be an easy board for you to replicate yourself, basically just a means of connecting the pins of the SD card to the micro.
The EB board is coming on but will take a while to hit the shelves. Should be an easy board for you to replicate yourself, basically just a means of connecting the pins of the SD card to the micro.
Any pin should be fine.It is also not clear to me whether I can use any pin for the API mode or the PIC must have a specific port.
It looks like the device you pointed to has a built in bus to talk to the SD card. This will likely be a bit faster then bit banging out the signals but we will not likely support this in Flowcode as it's very chip specific and against the development policies where it should simply just work on pretty much any device. You should be able to use say the Microchip Harmony libraries as is in Flowcode which should allow you to access the functionality.And whether this SD/SDIO/eMMc is something useful.
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
-
- Valued Contributor
- Posts: 654
- Joined: Fri Aug 19, 2016 2:09 pm
- Location: switzerland
- Has thanked: 182 times
- Been thanked: 179 times
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Ben
This is a good news and thank you for the infos.
I'm already drawing the hardware.
What has the new EB board for a number?
And is there a component for FC7 for the new EB board already?
This is a good news and thank you for the infos.
I'm already drawing the hardware.
What has the new EB board for a number?
And is there a component for FC7 for the new EB board already?
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Hi Stefan,
I'm not at liberty to say much on this at the moment, all will be revealed shortly.What has the new EB board for a number?
No currently only the FAT component is available which uses the SPI communications mode. We will likely add the API mode to the FAT component in the future but this is currently fairly low priority.And is there a component for FC7 for the new EB board already?
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
- Benj
- Matrix Staff
- Posts: 15312
- Joined: Mon Oct 16, 2006 10:48 am
- Location: Matrix TS Ltd
- Has thanked: 4803 times
- Been thanked: 4314 times
- Contact:
Re: STM32F469i Disco SD Card FAT 4Bit mode
Leigh has just informed me that the 4-bit API mode requires a license fee paid to the SD association.
So it look even less likely that we will be doing anything to support this.
Some info on this here but not enough to know the full score.
https://electronics.stackexchange.com/q ... de-license
So it look even less likely that we will be doing anything to support this.
Some info on this here but not enough to know the full score.
https://electronics.stackexchange.com/q ... de-license
Regards Ben Rowland - MatrixTSL
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel
Flowcode Product Page - Flowcode Help Wiki - Flowcode Examples - Flowcode Blog - Flowcode Course - My YouTube Channel