PuTTy

From robotics

Installation

You can download PuTTy.exe from here which does not require any installation. Simply Run the putty.exe file from anywhere you would like.

How to Use

Putty is used for SSH/Telnet/Rlogin (Remote command line access) and as a serial communication port.

We will be using the Serial communication port feature for displaying and logging data as well as debugging.

putty setup steps
Step 1: Open putty.exe
Step 2: Select Serial
Step 3: Type in your COM port "COM12"
Windows: Start->Devices and Printers
Right click on the device and select properties.
Step 4: Set the Buad Rate. (115200)
Step 5: Select Open.

Streaming to a File

PuTTy can stream console data to a file which will be easier than copy and pasting from the terminal to obtain sensor data for your lab reports. To setup data streaming within PuTTy, go to

Session > Logging

and under Session logging choose All session output. You can then press the browse button to choose where to select the file and to give it a desired file extensions (.csv for Excel).

Formatting Output for Excel

The .csv format means Comma Separated Values which works exactly how it sounds: your have each of your data values separated by a comma for each cell column and a newline for the next row. Here is an example of how you might print out your values for Excel, please note only the relevant parts of code have been included.

Output that can be read by Excel
  printf("Time, Analog Reading, Degrees, Volts, Encoder Ticks\n");
  sprintf(pBuffer, "%llu,%d,%d,%d,%llu\n", timer, \
            anaReading, degrees, volts, encTicks);
  printf(pBuffer);

Once your data is gathered, exit PuTTy to stop streaming data and you can view the file.

Resulting .csv file

Enable Writing a Whole String

By default you can only write one letter at a time to your board. While not required, you can change this behavior by going to

Terminal

and under Line discipline options choose the Force on option for Local echo and Local line editing.