Tiny Arduino Pro Mini With Oled Display, Li-ion Battery & Mini Usb Charger.

US $29.00

  • New River, Arizona, United States
  • Feb 26th
(FTDI cable NOT included, 7th picture shows cable orientation for programming, 8th picture shows pinouts that are under the installed connector) I make these little smart displays for use in my BattSix products and they are such fun to work with I am offering them on ebay. This one includes a 150mah battery and a Mini USB charger board & cable, you'll need to add a switch to turn the computer ON/OFF.  Shrink your Arduino project to the size of a silver dollar!   /*   It consists of a Pro Mini with a 128 X 64 yellow/blue OLED display,   I program using an FTDI cable...sparkfunDOTcom/products/9718      This little demo is based on Addafruit's clock demo using the internal Arduino timer.   It shows the correct pin assignments for the display.   */   // you will need SPI, Wire, Adafruit_GFX, Adafruit_SSD1306 and RTClib in your library,   // follow the instructions in Adafruit_SSD1306.h to set the display height to 64.   #include <SPI.h>   #include <Wire.h>   #include <Adafruit_GFX.h>   #include <Adafruit_SSD1306.h>   #include "RTClib.h"      RTC_Millis rtc;      // software SPI   // use these settings for the OLED_Pro smart display...   // remove any other code that is controlling these pins.    #define OLED_DC    6   #define OLED_RESET 5   #define OLED_MOSI  4   #define OLED_CLK   3   #define OLED_CS    7      Adafruit_SSD1306 display(OLED_MOSI, OLED_CLK, OLED_DC, OLED_RESET, OLED_CS);      #if (SSD1306_LCDHEIGHT != 64)   #error("Height incorrect, please fix Adafruit_SSD1306.h!");   #endif      void setup()   {   // VCC for display   pinMode(2, OUTPUT);   digitalWrite(2, HIGH);      // following line sets the RTC to the date & time this sketch was compiled     rtc.begin(DateTime(F(__DATE__), F(__TIME__)));          /*     This line sets the RTC with an explicit date & time, you could add a couple pushbottons     and additional code to manually set date and time.     for example to set January 21, 2014 at 3am you would call:     rtc.adjust(DateTime(2014, 1, 21, 3, 0, 0));     */        // generate the high voltage internally   display.begin(SSD1306_SWITCHCAPVCC);      display.setTextColor(WHITE);   }      void loop() {     display.clearDisplay();     DateTime now = rtc.now();     display.setTextSize(4);     display.setCursor(6,16);     //to display 12 hour time...     if(now.hour()<10){display.print(" ");}     if(now.hour()-12<10 && now.hour()-12>0){display.print(" ");}     if(now.hour()>12){display.print(now.hour()-12,DEC);}     else{     display.print(now.hour(), DEC);}     display.print(':');     //     if(now.minute()<10){display.print("0");}     display.print(now.minute(), DEC);     display.setTextSize(2);     display.setCursor(53,49);     //     if(now.second()<10){display.print("0");}     display.print(now.second(), DEC);     display.setTextSize(2);     display.setCursor(6,0);     display.print(now.month(), DEC);     display.print('/');     display.print(now.day(), DEC);     display.print('/');     display.print(now.year(), DEC);     display.display();   }

Directions

Similar products from Display Modules & Monitors

People who viewed this item also vieved

By clicking "Accept All Cookies", you agree to the storing of cookies on your device to enhance site navigation, analyze site usage, and assist in our marketing efforts.

Accept All Cookies