diy:pagebastien
Ceci est une ancienne révision du document !
Table des matières
Quelques sites
Bazar
Tutoriels
Raspberry
- Installation Raspbian avec NOOBS Lien
- Bien extraire les fichiers du dossier “NOOBS…” dans la carte SD
- Possibilité de définir le réseau WIFI au lancement de l'installation
- Adresse IP de la Raspberry
- Tapez la commande ifconfig dans le terminal
- Visionner le réseau I2C avec les adresses utilisées
- Tapez dans le terminal sudo i2cdetect -y 1
- Se connecter via SSH à partir d'une machine Linux
- Tapez la commande ssh login@ip dans le terminal
- Exemple : ssh pi@192.168.2.20 pour se connecter à la Raspberry qui a l'adresse IP, 192.168.2.20
- Ensuite il faut entrer le mot de passe, raspberry d'origine
- Envoyer des fichiers d'un PC à la Raspberry par le réseau via SCP (Secure CoPy)
- Tapez la commande sudo scp fichier_origine copie_destination
- Exemple : je copie mon fichier code.py qui se trouve sur mon bureau vers le dossier Documents de la Raspberry
- scp /Users/labotim/Desktop/code.py pi@192.168.2.20:Documents
- A l'inverse : scp pi@192.168.2.20:Documents/code.py /Users/labotim/Desktop
- Il y a possibilité de changer le nom du fichier à l'arrivé
- scp /Users/labotim/Desktop/code.py pi@192.168.2.20:Documents/nouveau.py
- A l'inverse : scp pi@192.168.2.20:Documents/code.py /Users/labotim/Desktop/nouveau.py
- Exécuter un code python
- Tapez la commande sudo python nomfichier.py dans le terminal
- crtl+c pour arrêter le code
Librairies
C++/C
- WiringPi, librairie écrite en C permettant l'accès au GPIO de la Raspberry
- Visionner les PIN GPIO avec leurs correspondance
- Tapez la commande gpio readall dans le terminal
Python
- Kivy sur Raspberry Pi, une libraire pour faire une interface graphique. Possibilité de démarrer une raspberry directement sur Kivy
Logiciels
- TextWrangler
Composants
-
- humidity with ±3% accuracy, barometric pressure with ±1 hPa absolute accuraccy, and temperature with ±1.0°C accuracy, altimeter with ±1 meter
- Power Pins
- Vin - this is the power pin. Since the sensor chip uses 3 VDC, we have included a voltage regulator on board that will take 3-5VDC and safely convert it down. To power the board, give it the same power as the logic level of your microcontroller - e.g. for a 5V micro like Arduino, use 5V
- 3Vo - this is the 3.3V output from the voltage regulator, you can grab up to 100mA from this if you like
- GND - common ground for power and logic
- SPI Locgic Pins
- SCK - This is the SPI Clock pin, its an input to the chip
- SDO - this is the Serial Data Out / Master In Slave Out pin, for data sent from the BMP183 to your processor
- SDI - this is the Serial Data In / Master Out Slave In pin, for data sent from your processor to the BME280
- CS - this is the Chip Select pin, drop it low to start an SPI transaction. Its an input to the chip
- I2C Logic Pins
- SCK - this is also the I2C clock pin, connect to your microcontrollers I2C clock line.
- SDI - this is also the I2C data pin, connect to your microcontrollers I2C data line.
- default, the i2c address is 0x77. If you add a jumper from SDO to GND, the address will change to 0x76.
-
- Liste à puceanges from up to 188uLux up to 88,000 Lux on the fly
- the I2C address is 0x29 and you can't change it
- Power Pins
- Vin - this is the power pin. Since the chip uses 3 VDC, we have included a voltage regulator on board that will take 3-5VDC and safely convert it down. To power the board, give it the same power as the logic level of your microcontroller - e.g. for a 5V micro like Arduino, use 5V
- 3vo - this is the 3.3V output from the voltage regulator, you can grab up to 100mA from this if you like
- GND - common ground for power and logic
- I2C Logic Pins
- SCL - I2C clock pin, connect to your microcontrollers I2C clock line.
- SDA - I2C data pin, connect to your microcontrollers I2C data line.
- Other Pins
- INT - this is the INTerrupt pin from the sensor. It can be programmed to do a couple different things by noodling with the i2c registers. For example trigger when a conversion is done, or when the light level has changed a lot, etc. We don't have library support for this pin
-
- Power Pins
- VIN - power input, connect to 3-5VDC. It's important to connect to a clean and quiet power supply. GPS's are very sensitive, so you want a nice and quiet power supply. Don't connect to a switching supply if you can avoid it, an LDO will be less noisy!
- GND - power and signal ground. Connect to your power supply and microcontroller ground.
- Optionnels
- VBAT is an input pin - it is connected to the GPS real time clock battery backup. We suggest using the battery spot on the back but if you have a project with a coin cell or other kind of battery that you want to use (and its under 3.3V) you can connect it to the VBAT pin. For V1 and V2 modules: If you do this, be sure to cut the trace on the back between the RTC solder pads
- EN is the Enable pin, it is pulled high with a 10K resistor. When this pin is pulled to ground, it will turn off the GPS module. This can be handy for very low power projects where you want to easily turn the module off for long periods. You will lose your fix if you disable the GPS and it will also take a long time to get fix back if you dont have the backup battery installed.
- 3.3V is the output from the onboard 3.3V regulator. If you have a need for a clean 3.3V output, you can use this! It can provide at least 100mA output.
- Serial Data Pins
- TX - the pin that transmits data from the GPS module to your microcontroller or computer. It is 3.3V logic level. Data comes out at 9600 baud by default
- RX - the pin that you can use to send data to the GPS. You can use use 3.3V or 5V logic, there is a logic level shifter. By default it expects 9600 baud data, and remember you need to send it checksum'med NMEA sentences
- Others Pins
- FIX is an output pin - it is the same pin as the one that drives the red LED. When there is no fix, the FIX pin is going to pulse up and down once every second. When there is a fix, the pin is low (0V) for most of the time, once every 15 seconds it will pulse high for 200 milliseconds
- PPS is a new pin output on V3 modules. Its a “pulse per second” output. Most of the time it is at logic low (ground) and then it pulses high (3.3V) once a second, for 50-100ms, so it should be easy for a microcontroller to sync up to it
diy/pagebastien.1493047754.txt.gz · Dernière modification : 2017/04/24 15:29 de bbonte