Attiny : arduino's little brother Arduino is a very good card but if you need a very smaller card size or if you don't need alls pins and less memory, Attiny is a good alternative VCC =Voltage is 2.7-5.5 v Notice : Pins output high voltage is 4.3 volts with a Vcc of 5 volts. For 3.3 Vcc, pins o utput voltage is 2.5 V So be carefull, this is not 3.3 volts like Arduino How to program Attiny To program attiny, just use Arduino IDE. To do this, you will have to connevt Attiny to arduino. Arduino will now be used as bridge Initial step Upload ArduinoISP sketch on your arduino : Select card Arduino Uno Load sketch Samples > 11.ArduinoISP Tips : be sure to unplug all wires before to upload the sketch First step First time and only once, you have to write bootloader on Attiny : Choose 'Arduino as ISP' as the programmer prior to burning the Arduino bootloader onto the ATtiny Select card ATtinyXX Verify Board Properties...
Si7021 Sensor for measuring humidity and temperature The Si7021 Sensor integrates humidity and temperature sensor elements, an analog-to-digital converter, signal processing, calibration data, and an I2C Interface. The Si7021 offers an accurate, low-power, factory-calibrated digital solution ideal for measuring humidity and temperature Features Precision Relative Humidity Sensor ± 3% RH (max), 0–80% RH High Accuracy Temperature Sensor ±0.4 °C (max), –10 to 85 °C 0 to 100% RH operating range Up to –40 to +125 °C operating range Wide operating voltage – (1.9 to 3.6 V) Low Power Consumption – 150 μA active current How to wire https://learn.sparkfun.com/tutorials/si7021-humidity-and-temperature-sensor-hookup-guide/all Library https://github.com/adafruit/Adafruit_Si7021/blob/master/examples/si7021/si7021.ino#L36
I connected the 4 white ESC control wires to servos 0 to 3 (pins 7,11,12 and 13) and the black wires to ground (pin 9): Servo number GPIO number Pin in P1 header Moteur 0 4 P1-7 M1 1 17 P1-11 M2 2 18 P1-12 M3 3 21/27 P1-13 M4 Then I adjust the direction of rotation of the motors as below: In order for the quadcopter to be stable and not to turn on itself, the M1 / M3 motors must rotate in the same direction and M2 / M4 in the opposite direction. If a motor does not rotate in the desired direction, swap 2 of the 3 wires
Commentaires
Enregistrer un commentaire