Basic HTML Version

|  | Table of Contents |  | View Full Version

Page 111 - 2629_Devagiri_C-7
P. 111

    Step   7    Select the desired programming mode.
     You entered an Adventure Island where everything runs on student-made inventions.
     Which device would you like to be present there and how would it make life easier on
     the island?

     IDE OF ARDUINO

     The Arduino Integrated Development Environment (IDE) is a software platform where you can
     write, edit and upload code to an Arduino board. It helps you control electronic components like
     lights, motors and sensors. The IDE checks for errors and allows you to upload code via USB. It also
     provides helpful error messages to guide you in fixing issues, making it easier to organise, test and   You can modify the code as per your requirements. Use the BLOCKS + TEXT coding for better
     control your projects.
                     understanding of the program. The on start and forever blocks are already present in the code
                     editor by default. Now, let’s focus on understanding the programming.
     WORKING OF ARDUINO IDE
                     Block based programming:
     You  can understand  how  Arduino  works through this example  of blinking  an LED,  which
     demonstrates how it processes and interacts with electronic components. The Arduino allows you
     to control electronic components like LEDs by programming it with either block or text coding.
     In  this circuit,  the Arduino  UNO  is placed  on the workspace  with the breadboard  next to  it.
     The LED and resistor are then positioned on the breadboard.
     To make an LED blink using an Arduino, follow the given steps:

     Step  1   Connect one leg of the resistor to the anode of the LED.
     Step  2    Connect the other leg of the resistor to Digital I/O Pin 13 on the Arduino UNO using a
     jumper wire.

     Step  3    Connect  the cathode  of the  LED  to  the  negative rail on the  breadboard  using  a
     jumper wire.
     Step  4    Connect the GND pin on the Arduino UNO to the negative rail of the breadboard

     using a jumper wire.

                     Step  8      Drag and place the set pin 13 to HIGH block from the Output section inside the forever
                                 block. This will turn the LED on.

                     Step  9      Drag and place the wait 10 secs block from the Control section directly under the set
                                 pin 13 to HIGH block. You can modify the time and adjust the duration as per your
                                 requirement.

                     Step  10     Drag and place the set pin 13 to LOW block under the wait 10 secs block. This will turn
                                 off the LED.
     Step  5   Click the Code button to open the code editor.  Step  11    Drag and place the wait 2 secs block under the set pin 13 to LOW block. This delay will
     Step  6   Click on the EDIT MODE dropdown button.  be applied before the LED turns back on.

                                                                                                                      109
                                                                                         Designing Circuits with Tinkercad

| 106 107 108 109 110 111 112 113 114 115 116 |