Using standard io stream:stdin and stdout in a matlab exe
问题 Question I want it to 'listen' to the standard input stream in a running (compiled) Matlab executable. This is how I believe it is done in c or a similar language: #include stdio.h fgets(line, 256, stdin) Or more elaborately, it it can be used as such: if (!fgets(line, 256, stdin)) return; if (line[0] == '\n') continue; sscanf(line, "%s", command); Answer For completeness I will leave the background and notes intact, but with the help of Amro and EitanT I have managed to work it out.