Hi chiupohsi
I've taken a look of your code, but I'm not quire sure what you wanted to ask. If I understand you correctly, there are 3 important fators in your questions:
1. RS-232 port: Your code seems to read data from RS-232, but you only initialize the port and
then read data from it. The general flow of using RS-232 is initial -> write (commands) -> read (data) -> close it. I attached an example below (basic serial write and read vi).
But if you really can read data from your RS-232 port, then it's fine.
2. You mentioned you displayed a digital output (0~255) at your terminal via an ADC and a adjustable resistance. Then your signal should be a Hi-Low digital siganl.
However, you also mentioned its voltage range is from 0~5V. Do you mean it's a digital signal with Low (0V) and High (5V) or it's an 0~5V analog signal? If it's
a digital signal, after you convert to byte array, you can further convert it to a digital waveform and display it in a digital waveform graph
3. I guess your last question is how to display "time" as the x-scale of a waveform chart. I attached an example below using property node to fulfill your need.
BTW, it's an English discussion forum. If you type in Traditional Chinese, there will be few to reply your post. Try to post at Chinese Forum at the following link
http://ni.com/taiwan/forum
Vincent