Arduino car entry-fourth day (sensor), arduino car
Hello everyone, I am a small Editor.
Record the content in the previous section and click "open link ".
Today we will talk about sensors.
Today we will talk about light and ultrasound.
Start with a chart:
There are three optical interfaces:
UCC, out, And GND.
Ultrasonic has four interfaces:
UCC, T, E, And GND.
sensor detects a move and the output is high, if the human body continues to move within the detection range, the sensor remains high, knowing that the person leaves before the delay turns the high level to low.differenceThe difference between the two detection modes, after detecting the movement trigger, if the human body continues to move, whether the continuous output high level. hc-sr501 simple functio
Today took out the home Arduino again out to play a bit, also looked at some recent online information. Feel the current online article still stay in this how to use, that how to use the stage. There are few examples of the combination. So, I will write the code today, for everyone to refer to the brick.
Arduino, after all, is the basis of C language. So the structure of the program is still very important.
Arduino Peripheral Modules: analog-to-digital conversion of sensor components (thermo-sensitive, photosensitive, wet-sensitive) ArduinoFor Arduino, it only knows digital, and the analogue is a "foreign language".Analog: Both time and value are continuous physical quantities.Digital quantity: Both time and value are discrete physical quantities.The analog-to-digit
Through the first two articles, we have become familiar with the basic GPIO programming of Arduino and the serial communication between PC and Arduino. Next we're going to start learning all kinds of sensor operations while delving into Arduino programming.
Before we start programming, we need to be familiar with the p
First Arduino default I²c address is 7-bit address, the manual is described, 7-bit address is 0x1e, read address is 0x3d = (7-bit address If you want to communicate with the hmc5883l, you need to hmc5883l power on the 5ms. Therefore, the general write configuration requires a delay of 5ms before communication. After connecting the device to test the sensor, identify the operation and identify register a,
Encapsulation: To-92, metal can, SOIC-8, to-220. The lm35d used in this article is the to-92 encapsulation.
The lm35d is powered by 5 V voltage on the Arduino uno board, and the signal output end is connected to the A0 pin.
Simple voltage reading and conversion
The conversion is implemented using the Arduino ADC function. The relationship between the voltage and the ad sample
Bh1750fvi is a digital ambient optical sensor IC produced by Rohm semiconductor in Japan. Its main features include:
I2C digital interface, supporting a maximum rate of 400 kHz
Measurement Range: 1 ~ 65535 Lux, minimum resolution
Shielding illumination variation interference caused by 50/60Hz Mains Frequency
Two I2C addresses are supported and selected through the ADDR pin.
Small measurement error (maximum precision err
AM2321 is a digital temperature and humidity sensor in Guangzhou ausone electronics production. Although it is a domestic brand, its precision can be comparable with foreign mainstream temperature and humidity sensing IC.
Size: 11.3x7.8x4mm (L x W x H)
Package: 0.05 pitch PTH
Operating voltage: 2.6~5v
Interface: i²c, maximum rate 100kbps, with special timing requirements
Resolution: Temperature 0.1°c, relative humidity 0.1%rh
SI7021 is a temperature and humidity sensor chip produced by Silicon Labs. Its main features:
Humidity accuracy: Error typ. +/-2%RH, Max +/-3%rh (0~80%RH), factory corrected
Temperature accuracy: Error typ. +/-0.3%°c, Max +/-0.4%°c ( -10°c~85°c), factory corrected
Measuring range: Temperature range 0~100%rh, maximum temperature range -40°c~125°c
Operating voltage: 1.9~3.6v
Low power consumption: Low 150μa at work, 60nA at stan
Arduino MQ135 Gas Sensor
first, the wiring
The MQ135 has 4 pins, VCC, GND, A0, D0, respectively, where VCC, GND, and A0 are required. The following diagram is a esp8266 wiring diagram. Due to the measurement of the gas value of PPM, it is related to the air temperature and humidity. So we've added a DHT22 here. DHT22 Portal
Second, MQ135 library
Download Address: https://github.com/zha
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
and provide relevant evidence. A staff member will contact you within 5 working days.