Hi John,
The FileReaders expect a binary input file rather than a text file.
You can convert your text file to a binary file using a script in our
distribution:
$STREAMIT_HOME/misc/dat2bin.pl --int Rand.txt Rand.bin
and then use a FileReader<int>("Rand.bin") to read the data.
There is a comparable script, bin2dat.pl, for converting FileWriter
output to text format.
-Bill
On Sun, Nov 30, 2008 at 10:08 AM, Ike Patel <[EMAIL PROTECTED]> wrote:
> Hello to all,
>
> I am using streamit to work on a project. It requires input of random
> number file. I tried putting the numbers in a txt file and using FileReader
> to read from it, but it does not seem to work. What should I do to create
> such a file or what extension is necessary for the file to be read? I am
> currently using the Eclipse plugins.
>
> This is what I am currently doing, and this is wrong.
>
> Example of File
>
> Rand.txt
> 12
> 15
> 14
> 17
> 18
>
> then I write
> void->void pipeline RandNum {
> add FileReader<int>("C:/Rand.txt");
> ...
> }
> Thanks
> --John
>
> _______________________________________________
> StreamIt-users mailing list
> [email protected]
> https://lists.csail.mit.edu/mailman/listinfo/streamit-users
>
>
_______________________________________________
StreamIt-users mailing list
[email protected]
https://lists.csail.mit.edu/mailman/listinfo/streamit-users