MegunoLink can play back the content of a text file as though it was being received by a serial port. You can record messages sent from your Arduino with the log to file visualizer then replay the log. This can be useful for creating demos of the interface when the hardware isn’t readily available.
To setup a file source connection:
- Open a connection manager visualizer
- Choose File from the Add Connection drop-down menu
- Select the file that the connection will play back
The title box lets you give the connection a name. This is useful to keep track when you have multiple connections. The name you enter here will be displayed on the connect button shown in visualizers.
Use the browse button to select a file. The path can be absolute or relative to the MegunoLink project file. Right-click on the file-path to change between the two options.
Click the Connect button to open the connection and begin receiving data. Drag the slider back and forth to change the playback position in the file. Click the rewind button () to resume playback from the start of the file.
You can control the playback rate from the File Source Configuration dialog. Click the Advanced button to show the configuration window. Increase the data rate to play the file faster; decrease it to slow down playback. When the Loop box is checked, the file will restart playback automatically when MegunoLink reaches the end of the file.
If you check the Start when project loads box, the source will start playback as soon as the project is loaded into MegunoLink.