Electronic theory

 

Arduino is a convenient, flexible, and easy to use open source electronic prototype platform. Contains hardware (various types of Arduino boards) and software (Arduino IDE). It was developed by a European development team in the winter of 2005. Its members include Massimo Banzi, David Cuartielles, Tom Igoe, Gianluca Martino, David Mellis and Nicholas Zambetti.

http://www.stone-hmi.com

It is built on the open source simple I/O interface version, and has a Processing/Wiring development environment similar to Java and C language. It mainly contains two main parts: the hardware part is the Arduino circuit board that can be used for circuit connection; the other is the Arduino IDE, the program development environment in your computer. You only need to write the program code in the IDE, upload the program to the Arduino board, and the program will tell the Arduino board what to do.

Arduino can perceive the environment through various sensors, and feedback and influence the environment by controlling lights, motors and other devices. The microcontroller on the board can be programmed by the Arduino programming language, compiled into a binary file, and burned into the microcontroller. The programming of Arduino is realized through Arduino programming language (based on Wiring) and Arduino development environment (based on Processing). The Arduino-based project can only include Arduino, or it can include Arduino and other software running on the PC, and communicate between them (such as Flash, Processing, MaxMSP).

How to connect arduino to the display

There are two wiring methods for this display: one is a more flexible method (you can use any pin on the Arduino), and the other wiring method is much faster (4-8 times faster, but you must use hardware SPI) Pin). Let's start to demonstrate how to use the former method.

Note: The packaged version has been connected to SPI. If you already have a soldered board, you can skip the connection instructions and go directly to the graphics library section to view the library source code and examples.

In one method, you can use any 4~5 pins. In the example, we use pins 4, 5, 6, 7, and 8. If you have successfully made it work properly, you can change these pins in the wiring and program.

Start by connecting the power pins. See the picture above;

As shown in the figure below, ground the leftmost pin and connect the adjacent pin to +5V high level. The rightmost pin (backlight) is also connected to +5V. If you plug in the Arduino, you should see the backlight light up.

Then connect the RESET pin of TFT and D/C pin (the data/command selection pin of TFT), and connect the RESET pin (third from the left) to pin 8 of Arduino. D/C pin (fourth from left) is connected to pin 7, as shown in the figure below.

Finally, we connect the remaining digital pins, TFT_CS (TFT chip select), MOSI (data sent to TFT) and SCK (clock signal sent to TFT), as shown in the figure below.

Please note that you need to skip stitches and connect the 6th pin TFT_CS from the left after D/C on the TFT to digital pin 6. MOSI (seventh from the left) is connected to digital pin 5, and finally SCK (eighth from the left) is connected to digital pin 4.

After the connection is completed, if you want to change the connection, you can use any pin on the Arduino, but don't forget to modify the corresponding relationship at the beginning of the following program.


Detailed explanation of arduino connection method