trioprimo.blogg.se

Coolterm code
Coolterm code






coolterm code

Initially I thought the values would be either 0 or 1 but I noticed that the "if(val = 0)" statement was not doing anything.

  • Inspired by the "printArray" statement, I added a "print(val)" statement so that I could see what value was being read and stored in the variable "val".
  • The "draw()" function has an inherent infinite loop, so when I tried to add the "while(true)" loop within the function it did not work.
  • This name was essential for defining the "portName" variable.

    COOLTERM CODE SERIAL

    I could alternatively use CoolTerm to find out the name of the serial port that I was using. The "printArray(Serial.list())" statement helped display the name of the serial port.Here is the file and here is an image of the codes with some of my annotations:Ī few things I wanted to mention about the code: I modified one of the example codes in Processing with the help from Rob and Tiffany. I managed to get Processing to recognize the signals that my passive infrared motion sensor sent and change the color of the square whenever it detected a motion.

    coolterm code coolterm code

    I have kept my example simple as I don't anticipate doing a lot of interface or application programming for my final project. Both Anya and Nathan suggested that I start with Processing, as it is easier to play with for beginners. This week we were asked to write an application that interfaces with an input or output device that we made. Interface and Application Programming Interface and Application Programming








    Coolterm code