From d2284735eee14f2210d9ee1b77b6cecb02e0589b Mon Sep 17 00:00:00 2001 From: tcsullivan Date: Fri, 1 Mar 2019 07:32:32 -0500 Subject: sharp screen working --- source/controller.cpp | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'source/controller.cpp') diff --git a/source/controller.cpp b/source/controller.cpp index f6393e8..853e8fc 100755 --- a/source/controller.cpp +++ b/source/controller.cpp @@ -14,6 +14,8 @@ #include +#include "driverSharp.h" + BLEUart bleuart; // Function prototypes for packetparser.cpp @@ -31,8 +33,7 @@ void setup(void) Serial.begin(115200); while ( !Serial ) delay(10); // for nrf52840 with native usb - Serial.println(F("Adafruit Bluefruit52 Controller App Example")); - Serial.println(F("-------------------------------------------")); + Serial.println(F("Initializing...")); Bluefruit.begin(); // Set max power. Accepted values are: -40, -30, -20, -16, -12, -8, -4, 0, 4 @@ -45,9 +46,9 @@ void setup(void) // Set up and start advertising startAdv(); - Serial.println(F("Please use Adafruit Bluefruit LE app to connect in Controller mode")); - Serial.println(F("Then activate/use the sensors, color picker, game controller, etc!")); - Serial.println(); + Serial.println(F("Ready.")); + + sharpInit(); } void startAdv(void) @@ -85,6 +86,8 @@ void startAdv(void) /**************************************************************************/ void loop(void) { + sharpRefresh(300); + // Wait for new data to arrive uint8_t len = readPacket(&bleuart, 500); if (len == 0) return; -- cgit v1.2.3