Linux Today: Linux News On Internet Time.
Search Linux Today
Linux News Sections:  Developer -  High Performance -  Infrastructure -  IT Management -  Security -  Storage -
Linux Today Navigation
LT Home
Contribute
Contribute
Link to Us
Linux Jobs


Top White Papers

More on LinuxToday


Building an Arduino Pest Repeller on Linux (Part 2)

May 02, 2014, 09:00 (0 Talkback[s])
(Other stories by Carla Schroder)

An Arduino sketch contains two required functions: setup() and loop(). setup() contains code that you want to run once at the beginning of your sketch, such as pin modes and initializing hardware. In our ez1_measure.ino sketch we set our data transmission speed in setup(). We are setting a serial port speed even though our Arduino is connected with a USB cable because it is still a serial port, a proper UART (Universal Asynchronous Receiver/Transmitter), and it supports the standard serial port speeds: 300, 1200, 2400, 4800, 9600, 14400, 19200, 28800, 38400, 57600, or 115200 baud. And that is why the Arduino IDE has a serial monitor where we can watch the output of our sketches.

Complete Story

Related Stories: