Hello,
I am playing with a STM32F746NG board, and I am trying to implement a chess game on the board.
To do this, I have found an existing Chess Engine (TSCP) and it is working perfectly in Visual Studio.
However, when I was trying to integrate this engine to my embedded application, this crashed my application... and I have then realised that the TSCP code was trying to use "fopen" to read a txt file.
This seems nonsense for the embedded application to read a txt file that doesn't exist in the system. So that I have actually read [1] & [2]. [2] explains the file system.. but then I am confused..
For the file system, it supports 1) USB memory drive, 2) memory card, 3) RAM, 4)NOR Flash, 5) NAND Flash. I obviously dont understand the NOR & NAND Flash..and I also couldn't find any USB port for a flash drive. Furthermore, I don't have any memory cards. I am wondering if I must use the "RAM" option. What would you suggest??
In case of using the RAM, so how can I transfer my existing txt file to this file system from my laptop?
Thanks!!
[1]http://www.keil.com/pack/doc/mw/FileSystem/html/fs_create_app.html#fs_Device_Configuration [2]http://www.keil.com/pack/doc/mw/FileSystem/html/
If it just needs to process lines from a text file, you might be better off inlining the data as a string, or array of strings, in a .C file, and emulating the fopen/fread/fclose aspects of the access.
Perhaps look at examples where people are creating a web-server, and there is a script to process several files into structures, and C code, that is then compiled in with the application.
Thanks @Westonsupermare Pier. I am feeling lucky that I have posted a question here. lol Your suggestion is really a simple and straight forward solution. Why haven't I thought about this before? lol Thanks again!!