Help with computer communication

Is it possible for arduino to read a .txt file and be able to use the information inside as a string in coding? And if so, what would the code look like?

For example, I'm trying to get a number from a .txt file, say 5, and turn that many LED lights on.

Any suggestions would be great. Thank you.

Arduino has no concept of files or folder or anything like it.

You would have to have some kind of program on the Pc that reads the file and send whatever is needed to the Arduino board.


Thank you.

I used the program MTTTY to send data from a .txt file to my arduino board; however, when MTTTY is running, I can't change the .txt file to a new value. It tells me that access is denied.

Also, is there an equivalent program to MTTTY for macs?

Sorry, i don't know MTTY, and i'm a PC kind of guy :-) so i litterally know nothing about Mac software.


What program will be editing the txt file?

a java application is going to be sending it a number every few minutes, but even if i can't even change it manually

Are you creating the java application? If so why not have it send the values directly to the serial port?

i've already made the program. and i have thought about communicating with the serial ports, but i'm using university computers and don't have the administrative powers to add communication files to the java library.