Hi, I've this ChucK code:
"examples/vento.txt" => string filename;
FileIO fio;
// open a file
fio.open(filename, FileIO.READ);
// ensure it's ok
if(!fio.good()) {
cherr <= "can't open file: " <= filename <= " for reading..." <= IO.newline();
me.exit();
}
fio.readLine() => string velocity;
fio.readLine() => string direction;
the file is:
10
12
(it's updated with python every minute)
and I want to convert velocity and direction in int (or better float).
How can I do this?
Thanks