Raspberry Pi Sense HAT - For the Pi 3 / 2 / B+ / A+

From Wiki
Revision as of 09:29, 9 April 2020 by Root (Talk | contribs) (Software Operation)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search


Rpi005 1.png
Control the same hardware as used in space...build your very own Astro Pi with the new Raspberry Pi Sense HAT! The Raspberry Pi Sense HAT is attached on top of the Raspberry Pi via the 40 GPIO pins to create an 'Astro Pi'. The Sense HAT has several integrated circuit based sensors that can be used for many different types of experiments, applications, and even games. And it's being used in conjunction with the Raspberry Pi Foundation to perform science experiments aboard the International Space Station (ISS)!

The sensors enable you to read

  • Orientation (yaw, pitch & roll) via an accelerometer, 3D gyroscope, and magnetometer
  • Pressure
  • Humidity
  • Temperature

The Sense HAT supports a whole host of projects for the Raspberry Pi, it can measure how fast is the Pi itself travelling (i.e. measure your speed), how hot is it? how humid is it? (air humidity), which direction is the Raspberry Pi facing? And more. The 8x8 LED Matrix enables you to display the data from the various sensors, it can show you which way is geomagnetic North by programming a compass using the magnetometer, or simply be used to play games like Tetris, Pong and Snake with the joystick. The joystick can also be used to enable a human user to interact with the programs running on the Raspberry Pi Sense HAT.
Writing programs for the Sense HAT is very simple with a Python library available to get started quickly and easily. For a truly out of world projects check out the AstroPi website, containing a host of ideas and instructions.

Technical Specification

  • Gyroscope – angular rate sensor: +/-245/500/2000dps
  • Accelerometer - Linear acceleration sensor: +/-2/4/8/16 g
  • Magnetometer - Magnetic Sensor: +/- 4/8/12/16 gauss
  • Barometer: 260 – 1260 hPa absolute range (accuracy depends on the temperature and pressure, +/- 0.1 hPa under normal conditions)
  • Temperature sensor (Temperature accurate to +/- 2 degC in the 0-65 degC range)
  • Relative Humidity sensor (accurate to +/- 4.5% in the 20-80%rH range, accurate to +/- 0.5 degC in 15-40 degC range)
  • 8x8 LED matrix display
  • Small 5 button joystick

Package Including

  • 1 x Raspberry Pi Sensehat
  • 4 x Mounting Screws
  • 4 x Mounting Nylon Standoffs

Software Operation

Hook up RPi power supply
Open the RPi terminal and type in the following commands
Rpi005 2.png

  1. sudo apt-get update
  2. sudo apt-get install sense-hat
  3. sudo reboot

Restart and create a file named test.py to start the test.

  1. nano test.py

The contents of the file are as follows

  1. from sense_hat import SenseHat
  2. sense = SenseHat()
  3. sense.show_message("Hello world!")

You can also go to the RPi official website to download more examples.

  1. git clone https://github.com/astro-pi/python-sense-hat.git
  2. cd python-sense-hat/examples
  3. python3 rainbow.py

Final Effect

Rpi005 1.png