Not sure if this is the right part of the forum for this question, but is there a way to print to the serial port, then print over what I just printed? I'm displaying data from FFT bins and rather than the data scrolling down the window, I'd like the "Bin x value = " to appear static and only the actual value after the equals to update.
Is there a way to back up a defined number of lines with Serial.print, then print over what was just printed with the next set of values?
It depends on the terminal emulator you are using. There are ASCII codes to move the cursor around the screen, look them up in the ASCII listing. Then find a terminal emulator that will obey them.
Is there a way to print to the serial port with Serial.print, then print over what I just printed? I'm displaying data from FFT bins and rather than the data scrolling down the window, I'd like the "Bin x value = " to appear static and only the actual value after the equals to update.
So after a print of all the bin values, I'd like to move the cursor up a defined number of lines to the beginning of the display then print over what was just printed with the next set of values?
Other folks understood the "rubbish" title and gave the answer I was looking for
Well it might be the answer you were looking for but you got two wrong answers so where does that get you? One said it couldn't be done and the other said it was an escape sequence, which it isn't.
If you connect a terminal program that understands carriage-return (\r) then you can "return" to the start of the line and print over it. The inbuilt terminal program is not such a thing.
A more general solution might be to hook up an LCD screen (available quite cheaply) possibly using a serial (or other) "backpack" to simplify talking to it. Then you can just cursor address to your heart's content.
BTW recursion is when a function calls itself. Overwriting might be a better description. You can always amend your first post to correct the subject line, a good subject line tends to draw in people who know something about that subject.