Skip to content

eon-com/SenseHatDriverForAndroidThings

Repository files navigation

SenseHat Driver for AndroidThings

HINT: Project use GitFlow (https://www.atlassian.com/git/tutorials/comparing-workflows/gitflow-workflow) Short: Current development is done in "develop" branch and "master" includes the current release!

"Another" Sense Hat driver for Android Things

This driver connects the "SenseHat" with AndroidThings environment.

It includes the following features:

  • LED 8x8 Matrix: draw pixels in differnt colors; draw text in differnt colors
  • Joystick: detects movement and button press
  • Temperature and Humidity: reads temperature and humidity
  • OPEN: other sensors

How to use

Include the "SenseHatDriverLibrary" to your AndroidThings project.

settings.gradle

   include ':sensehatdriverdemo', ':sensehatdriverlibrary'

HomeActivity.java

    SensorManager sensorManager = (SensorManager) this.getSystemService(Context.SENSOR_SERVICE);

    SenseHat senseHat = SenseHat.init(sensorManager);
    LedMatrix ledMatrix = senseHat.getLedMatrix();
    ledMatrix.draw(Color.RED);   

    senseHat.addJoystickListener(new JoystickListener() {
        @Override
        public void stickMoved(JoystickDirectionEnum direction) throws IOException {
        ...
        }
    });

Version overview

see Release-Page: https://github.com/EON-COM/SenseHatDriverForAndroidThings/releases

Other resources

About

"Another" Sense Hat driver for Android Things

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages