I would like to create an IR Beam-break personal agility timer application using a wearable wristwatch. Several of the watches mentioned they used an ESP8266 D1 mini for a WiFi controller
and an SH1106 OLED display.
I hacked a D1 mini and SH1106 together and have completed the programming using Arduino and it works in its expanded size. BUT... I tried using two different reprogrammable watches and none of them will display on the SH1106 (the rest of the functionality is working as printed out through the serial port.
I saw the adafruit Bangle js, but I don't know javascript so I would like another solution
if you've had any success programming a wristwatch and displaying to an OLED display, please respond to me.
I'm attaching the code I use to display on the components to see if I did anything wrong and can reprogram a watch.
/*
*/
#include <Wire.h> // Enable this line if using Arduino Uno, Mega, etc.#include <SPI.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SH110X.h>
#define i2c_Address 0x3c //initialize with the I2C addr 0x3C Typically eBay OLED's
#define SCREEN_WIDTH 128 // OLED display width, in pixels
#define SCREEN_HEIGHT 64 // OLED display height, in pixels
#define OLED_RESET -1 // QT-PY / XIAO
Adafruit_SH1106G display = Adafruit_SH1106G(SCREEN_WIDTH, SCREEN_HEIGHT, &Wire, OLED_RESET);
void setup() {
Serial.begin(9600);
display.begin(i2c_Address, true); // Address 0x3C default
display.clearDisplay();
display.display();
display.setCursor(48, 32);
display.setTextSize(6);
display.setTextColor(SH110X_WHITE);
display.print("H");
display.display();
pinMode(LED_BUILTIN, OUTPUT);
digitalWrite(LED_BUILTIN, LOW);
}
void loop() {
digitalWrite(LED_BUILTIN, HIGH);
display.setTextColor(SH110X_BLACK);
display.setCursor(48, 32);
display.setTextSize(6);
display.print("H");
display.display();
delay(1000); // wait for a second
digitalWrite(LED_BUILTIN, LOW); // turn the LED off by making the voltage LOW
display.setTextColor(SH110X_WHITE);
display.setCursor(48,32);
display.setTextSize(6);
display.print("H");
display.display();
delay(1000);
}
Thanks so much for your response. Yes, I already have a D1 and an SH1106 working. I’m not certain why the wristwatch version doesn’t work. That was my question. However, any suggestions are welcome
In response to the person who said it would be helpful to add pictures and links... Above is the schematic of the D1 mini board I've had manufactured showing the pinouts from the D1 mini and the pinouts from the header I used to connect to the SH1106 :
And, finally, if you are interested, here's a youtube link to my youtube channel showing a working prototype and what I'm trying to accomplish with the wristwatch: https://youtu.be/aL-4MRxkSlY