View unanswered posts | View active topics It is currently Wed Aug 20, 2014 4:51 am






Reply to topic  [ 6 posts ] 
File streaming? 
Author Message
Rookie

Joined: Thu Aug 01, 2013 7:03 pm
Posts: 23
Post File streaming?
Hi, I was wondering if it is possible to make/read/write a file on the NXT, such as a .txt for example. Also, on the computer during remote control debugging? I've done it in C++, so I just wondered. Thanks in advance! :)


Sat Aug 03, 2013 2:06 pm
Profile
Professor
User avatar

Joined: Sat May 18, 2013 1:24 pm
Posts: 272
Location: Olympia, WA
Post Re: File streaming?
For the text file part, see this: http://www.robotc.net/wiki/NXT_Functions_File_Access
Very much similar to <fstream>, I might add :)

_________________
FTC Team 6424, the 'Oly Cow - Chief programmer.
FRC Team 4450, Olympia Robotics Federation (ORF).

and also quadrotors. Quadrotors!


Sat Aug 03, 2013 2:58 pm
Profile
Rookie

Joined: Thu Aug 01, 2013 7:03 pm
Posts: 23
Post Re: File streaming?
Thanks!


Sat Aug 03, 2013 3:12 pm
Profile
Expert
User avatar

Joined: Fri Nov 02, 2012 12:07 am
Posts: 164
Location: California, USA
Post Re: File streaming?
I didn't know thet the NXT supported the .txt extension! :shock: :shock: :shock: .

So does that mean that I can upload a .txt to the NXT?
If so, can I display it like a document on the screen like you can for sounds, or will it not display properly like .ric?

_________________
string Robored = "Awesome"
~~Neil Balch~~


Sat Aug 03, 2013 7:46 pm
Profile WWW
Professor
User avatar

Joined: Sat May 18, 2013 1:24 pm
Posts: 272
Location: Olympia, WA
Post Re: File streaming?
You would have to parse the file into a buffer string, and then print that to the screen. I don't think you can print a .txt directly to the screen.

_________________
FTC Team 6424, the 'Oly Cow - Chief programmer.
FRC Team 4450, Olympia Robotics Federation (ORF).

and also quadrotors. Quadrotors!


Sat Aug 03, 2013 8:22 pm
Profile
Expert
User avatar

Joined: Fri Nov 02, 2012 12:07 am
Posts: 164
Location: California, USA
Post Re: File streaming?
Ok, thanks!

_________________
string Robored = "Awesome"
~~Neil Balch~~


Sat Aug 03, 2013 10:02 pm
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 6 posts ] 

Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  



Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software for PTF.