Activity Testing The Stampplot Graphical Plotting Software Interface

In this activity, we will use the PlotIt.bs2 program to create a graph in StampPlot. This will allow us to test both our program and our connection to StampPlot.

V Open PlotIt.bs2 in the BASIC Stamp Editor.

V In the Piot_it subroutine, change the values of ch0 through ch3 as shown below.

changes to ch0 = 25 ch1 = 5 0 ch2 = 75 ch3 = 100 checkSum = 0

V Note that the checksum = 0 statement remains unchanged.

V Download the modified code to the BS2 by clicking on the Run icon or by typing Ctrl-R. You should see the Debug Terminal pop up with the RX LED flashing and some gibberish scrolling across the screen. These are actually the ASCII symbols for the numbers that you just changed above.

V Check the top of the Debug Terminal to note which COM Port is being used.

V Now close the Debug Terminal (but not the entire BASIC Stamp Editor). This frees up the COM port for StampPlot.

V Open StampPlot again, if it isn't already open.

V In the lower left corner, set the COM Port to the same one that was being used by the BASIC Stamp Editor's Debug Terminal.

V Click on the Plot icon at the top of the screen (it looks like a small sine wave graph on the tool bar). The Enable Plotting box at the bottom of the screen should be checked.

V Click on the Connect button in the lower left corner (or the handshake icon on the toolbar).

You should see four straight lines in different colors being plotted across the screen at 0.5., 1.00, 1.50, and 2.00 volts, as shown in Figure 1-5. If you do, then you have reached a major milestone in your programming efforts. From here on you will be able to use StampPlot for all the other experiments as well as for testing the A/D converter software that comes next.

Figure 1-5

Test Plot of All Four Channels

Figure 1-5

Test Plot of All Four Channels

V Return to the BASIC Stamp Editor and close the PlotIt.bs2 program without saving the changes. When you use the program again, the value of the ch0 through ch3 variables will need to be zero, as they were originally.

V Congratulate yourself for a job well done up to now!

Solar Power

Solar Power

Start Saving On Your Electricity Bills Using The Power of the Sun And Other Natural Resources!

Get My Free Ebook


  • raino
    What symbols in stampplot instructions?
    7 years ago

Post a comment