diff --git a/.github/workflows/mkdocs.yml b/.github/workflows/mkdocs.yml deleted file mode 100644 index 72816cd..0000000 --- a/.github/workflows/mkdocs.yml +++ /dev/null @@ -1,33 +0,0 @@ -name: Run mkdocs -on: - push: - branches: - - main -permissions: - contents: write -jobs: - deploy: - runs-on: ubuntu-latest - steps: - - name: Checkout repository - uses: actions/checkout@v3 - - - name: Set up Python runtime - uses: actions/setup-python@v4 - with: - python-version: 3.x - - - name: Install Python dependencies - run: pip install mkdocs-monorepo-plugin mkdocs-redirects mkdocs-with-pdf weasyprint mkdocs-git-authors-plugin mkdocs-git-revision-date-localized-plugin mkdocs-git-committers-plugin-2 setuptools - - - name: Set up build cache - uses: actions/cache@v2 - with: - key: ${{ github.ref }} - path: .cache - - - name: Install Insiders build - env: - GH_TOKEN: ${{ secrets.GH_TOKEN }} - run: pip install git+https://${GH_TOKEN}@github.com/squidfunk/mkdocs-material-insiders.git - - run: mkdocs gh-deploy --force diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 0000000..e69de29 diff --git a/404.html b/404.html new file mode 100644 index 0000000..eb89841 --- /dev/null +++ b/404.html @@ -0,0 +1,1513 @@ + + + +
+ + + + + + + + + + + + + + + + + + + + + +Methods used to support Arduino Print functionality.
+This method is called set the "cursor" position in the device. The library supports the Arduino Print interface, enabling the use of a print() and println() methods. The set cursor position defines where to start text output for this functionality.
| Parameter | +Type | +Description | +
|---|---|---|
| x | +uint8_t |
+The X coordinate of the cursor | +
| y | +uint8_t |
+The Y coordinate of the cursor | +
This method is called to set the current color of the system. This is used by the Arduino Print interface functionality
| Parameter | +Type | +Description | +
|---|---|---|
clr |
+uint8_t |
+The color to set. 0 = black, > 0 = white | +
This method is called to get the current color of the system. This is used by the Arduino Print interface functionality
| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The current color | +
Methods to setup the device, get device information and change display options.
+This method is called to initialize the OLED library and connection to the OLED device. This method must be called before calling any graphics methods.
+ +| Parameter | +Type | +Description | +
|---|---|---|
wirePort |
+TwoWire |
+optional. The Wire port. If not provided, the default port is used | +
address |
+uint8_t |
+optional. I2C Address. If not provided, the default address is used. | +
| return value | +bool |
+true on success, false on startup failure |
+
When called, this method reset the library state and OLED device to their intial state. Helpful to reset the OLED after waking up a system from a sleep state.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +bool |
+true on success, false on startup failure |
+
This method returns the width, in pixels, of the connected OLED device
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The width in pixels of the connected OLED device | +
This method returns the height, in pixels, of the connected OLED device
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The height in pixels of the connected OLED device | +
This method inverts the current graphics on the display. This results of this command happen immediatly.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bInvert |
+bool |
+true - the screen is inverted. false - the screen is set to normal |
+
When called, the screen contents are flipped vertically if the flip parameter is true, or restored to normal display if the flip parameter is false.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bFlip |
+bool |
+true - the screen is flipped vertically. false - the screen is set to normal |
+
When called, the screen contents are flipped horizontally if the flip parameter is true, or restored to normal display if the flip parameter is false.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bFlip |
+bool |
+true - the screen is flipped horizontally. false - the screen is set to normal |
+
Used to turn the OLED display on or off.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bEnable |
+bool |
+true - the OLED display is powered on (default). false - the OLED dsiplay is powered off. |
+
Methods for setting the drawing state of the library.
+This method is called to set the current font in the library. The current font is used when calling the text() method on this device.
The default font for the device is 5x7.
| Parameter | +Type | +Description | +
|---|---|---|
theFont |
+QwiicFont |
+The font to set as current in the device | +
theFont |
+QwiicFont* |
+Pointer to the font to set as current in the device. | +
For the library, fonts are added to your program by including them via include files which are part of this library.
+The following fonts are included:
+| Font | +Include File | +Font Variable | +Description | +
|---|---|---|---|
| 5x7 | +<res/qw_fnt_5x7.h> |
+QW_FONT_5X7 |
+A full, 5 x 7 font | +
| 31x48 | +<res/qw_fnt_31x48.h> |
+QW_FONT_31X48 |
+A full, 31 x 48 font | +
| Seven Segment | +<res/qw_fnt_7segment.h> |
+QW_FONT_7SEGMENT |
+Numbers only | +
| 8x16 | +<res/qw_fnt_8x16.h> |
+QW_FONT_8X16 |
+A full, 8 x 16 font | +
| Large Numbers | +<res/qw_fnt_largenum.h> |
+QW_FONT_LARGENUM |
+Numbers only | +
For each font, the font variables are objects with the following attributes:
+| Attribute | +Value | +
|---|---|
width |
+The font width in pixels | +
height |
+The font height in pixels | +
start |
+The font start character offset | +
n_chars |
+The number of characters | +
map_width |
+The width of the font map | +
Example use of a font object attribute: +
+This method returns the current font for the device.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +QwiicFont* |
+A pointer to the current font. See setFont() for font object details. |
+
This method returns the height in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +String | +The name of the current font. | +
This method returns the width in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| text | +String |
+The string used to determine width | +
| return value | +unsigned int |
+The width of the provide string, as determined using the current font. | +
This method returns the height in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| text | +String |
+The string used to determine height | +
| return value | +unsigned int |
+The height of the provide string, as determined using the current font. | +
This method sets the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| rop | +grRasterOp_t |
+The raster operation (ROP) to set the graphics system to. | +
Raster operations device how source (pixels to draw) are represented on the destination device. The available Raster Operation (ROP) codes are:
+| ROP Code | +Description | +
|---|---|
| grROPCopy | +default Drawn pixel values are copied to the device screen | +
| grROPNotCopy | +A not operation is applied to the source value before copying to screen | +
| grROPNot | +A not operation is applied to the destination (screen) value | +
| grROPXOR | +A XOR operation is performed between the source and destination values | +
| grROPBlack | +A value of 0, or black is drawn to the destination | +
| grROPWhite | +A value of 1, or black is drawn to the destination | +
This method returns the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +grRasterOp_t |
+The current aster operation (ROP) of the graphics system. | +
Methods used to draw and display graphics.
+When called, any pending display updates are sent to the connected OLED device. This includes drawn graphics and erase commands.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
Erases all graphics on the device, placing the display in a blank state. The erase update isn't sent to the device until the next display() call on the device.
| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
Set the value of a pixel on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x | +uint8_t |
+The X coordinate of the pixel to set | +
| y | +uint8_t |
+The Y coordinate of the pixel to set | +
| clr | +uint8_t |
+optional The color value to set the pixel. This defaults to white (1). | +
Draw a line on the screen.
+Note: If a line is horizontal (y0 = y1) or vertical (x0 = x1), optimized draw algorithms are used by the library.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the line | +
| y0 | +uint8_t |
+The start Y coordinate of the line | +
| x1 | +uint8_t |
+The end X coordinate of the line | +
| y1 | +uint8_t |
+The end Y coordinate of the line | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a rectangle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the rectangle - upper left corner | +
| y0 | +uint8_t |
+The start Y coordinate of the rectangle - upper left corner | +
| width | +uint8_t |
+The width of the rectangle | +
| height | +uint8_t |
+The height of the rectangle | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a filled rectangle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the rectangle - upper left corner | +
| y0 | +uint8_t |
+The start Y coordinate of the rectangle - upper left corner | +
| width | +uint8_t |
+The width of the rectangle | +
| height | +uint8_t |
+The height of the rectangle | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a circle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate of the circle center | +
| y0 | +uint8_t |
+The Y coordinate of the circle center | +
| radius | +uint8_t |
+The radius of the circle | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Draw a filled circle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate of the circle center | +
| y0 | +uint8_t |
+The Y coordinate of the circle center | +
| radius | +uint8_t |
+The radius of the circle | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Draws a bitmap on the screen.
+The bitmap should be 8 bit encoded - each pixel contains 8 y values.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| pBitmap | +uint8_t * |
+A pointer to the bitmap array | +
| bmp_width | +uint8_t |
+The width of the bitmap | +
| bmp_height | +uint8_t |
+The height of the bitmap | +
Draws a bitmap on the screen.
+The bitmap should be 8 bit encoded - each pixel contains 8 y values.
+The coordinate [x1,y1] allows for only a portion of bitmap to be drawn.
+void bitmap(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1,
+ uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )
+| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| x1 | +uint8_t |
+The end X coordinate of the bitmap - lower right corner | +
| y1 | +uint8_t |
+The end Y coordinate of the bitmap - lower right corner | +
| pBitmap | +uint8_t * |
+A pointer to the bitmap array | +
| bmp_width | +uint8_t |
+The width of the bitmap | +
| bmp_height | +uint8_t |
+The height of the bitmap | +
Draws a bitmap on the screen using a Bitmap object for the bitmap data.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| Bitmap | +QwiicBitmap |
+A bitmap object | +
Draws a string using the current font on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to start drawing the text | +
| y0 | +uint8_t |
+The Y coordinate to start drawing the text | +
| text | +const char* |
+The string to draw on the screen | +
| text | +String |
+The Arduino string to draw on the screen | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Methods for device scrolling
+If the device is in a scrolling mode, calling this method stops the scroll, and restores the device to normal display operation. This action is performed immediately.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
This method is called to start the device scrolling the displayed graphics to the right. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed below | +
Defined values for the interval parameter:
| Defined Symbol | +Time Interval Between Steps | +
|---|---|
SCROLL_INTERVAL_2_FRAMES |
+2 | +
SCROLL_INTERVAL_3_FRAMES |
+3 | +
SCROLL_INTERVAL_4_FRAMES |
+4 | +
SCROLL_INTERVAL_5_FRAMES |
+5 | +
SCROLL_INTERVAL_25_FRAMES |
+25 | +
SCROLL_INTERVAL_64_FRAMES |
+64 | +
SCROLL_INTERVAL_128_FRAMES |
+128 | +
SCROLL_INTERVAL_256_FRAMES |
+256 | +
This method is called to start the device scrolling the displayed graphics vertically and to the right. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
This method is called start to the device scrolling the displayed graphics to the left. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
This method is called to start the device scrolling the displayed graphics vertically and to the left. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
0&&i[i.length-1])&&(p[0]===6||p[0]===2)){r=0;continue}if(p[0]===3&&(!i||p[1]>i[0]&&p[1]=e.length&&(e=void 0),{value:e&&e[o++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function K(e,t){var r=typeof Symbol=="function"&&e[Symbol.iterator];if(!r)return e;var o=r.call(e),n,i=[],s;try{for(;(t===void 0||t-- >0)&&!(n=o.next()).done;)i.push(n.value)}catch(a){s={error:a}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(s)throw s.error}}return i}function B(e,t,r){if(r||arguments.length===2)for(var o=0,n=t.length,i;o Spot something wrong? Feel free to contribute our open-source design and documentation. All of this documentation can be modified by you! Please help us make it better. All of our designs are open-source! Please help us make it better. Our board design files are contained in the Let's provided some recognition to the contributors for this project! Spot something wrong? Please let us know. Attention This is not where customers should seek assistance on a product. If you require technical assistance or have questions about a product that is not working as expected, please head over to the SparkFun Technical Assistance page for some initial troubleshooting.
+ If you can't find what you need there, you'll need a Forum Account to search product forums and post questions. All of this documentation can be modified by you! Please help us make it better. If a section of the documentation is incorrect, please open an issue and let us know. All of our designs are open-source! Please help us make it better. Our board design files are contained in the If part of the design is confusing, please open an issue and let us know. The SparkFun Qwiic OLED Display can display up to four lines of text and features 128x32 pixels in a small 0.91” (diagonal) frame. As an OLED, this display does not have a back light layer (unlike LCDs) and therefore it’s thinner, consumes less power, and has higher contrast. In this section, we'll go over the hardware and how to hookup the breakout board. To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary. To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier. Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller. If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed: You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs. Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already. In this section, we will highlight the hardware and pins that are broken out on the SparkFun Qwiic OLED Display (0.91 in., 128x32). The OLED screen has a pixel resolution of 128x32, a panel size of 30.0mm x 11.5mm x 1.2mm, and an active area of 22.384mm x 5.584mm. The driver chip is the SSD1306. For information can be found in the datasheet linked in the Resources. Note The SparkFun Qwiic OLED Arduino Library works for multiple displays. However, there are some caveats in the size of the display with the text. While you can technically display all fonts in the narrow OLED display, some characters (numbers, letters, and/or symbols depending on the font) will be too big to fully display on the screen. For example, the fonts for the 31x48 (i.e. Using the OLED display (0.91", 128x32) we found that we were able to fit: Power is applied through the vertical Qwiic connectors on the back of the board. The recommended input voltage is 3.3V. The logic levels for the Qwiic OLED Display (0.9", 128x32) is 3.3V. There are two vertical Qwiic connectors populated on the back of the board. You can use either connectors to provide power and send data through I2C. The Qwiic ecosystem is made for fast prototyping by removing the need for soldering. All you need to do is plug a Qwiic cable into the Qwiic connector and voila! The address of the display is 0x3C. Note On the back of the board, the power and I2C pins are broken out to test points. These are used in our production department for quality control using custom testbeds. These could be an alternative option to connect to the pins. However, we recommend using the Qwiic connectors to easily connect to the OLED display. Note that the I2C pins are also in a different order compared to a standard I2C Qwiic connector should you decide to solder to the test points. Note If this is your first time working with jumpers, check out the How to Work with Jumper Pads and PCB Traces tutorial for more information. The board includes a 1x3 jumper on the back of the board. Version 1.1 is a bit smaller than previous versions since the board includes vertical Qwiic connectors on the back of the board. The overall board size is 1.75 in x 0.5 in. The mounting holes have also moved to toward the top of the board. In this section, we'll go over how to connect to the display. We will go just a bit further and talk about how to mount the display. Insert a Qwiic cable between your chosen microcontroller and Qwiic OLED. Then insert a USB cable between the microcontroller and your computer's COM port. For the scope of this tutorial, the USB cable provides power and allows us to upload code to the microcontroller. Of course, you can also debug the display by opening a Serial Terminal. Once you have finished prototyping, you could continue to use the USB cable and add a 5V power supply or battery pack. Grab the board dimensions and cut out a rectangle in the enclosure. For users that want to mount the board so that the OLED display is flush against the enclosure, you will need to look at the dimensions based on the OLED. You will need to add a little tolerance so that the display can fit through the rectangle. For users that need to quickly mount the board, you will could also cut out rectangles based on the vertical Qwiic connector so that the wires can lead into the enclosure. Then cut out the mounting holes so that the board is right side up. In this case, we used a cardboard box as a quick example to demonstrate the Qwiic wires connecting leading into the enclosure. Note To easily display text and graphics on the board, we recommend mounting the board right side up. There is an option in the example code to flip the text horizontally and vertically should you decide to mount the board upside down, but you would need to also determine the position of the text. For a more durable enclosure, you could use wood, metal, or plastic. However, you will need additional tools to cut into the material. The Qwiic OLED (0.91", 128x32) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED Library's Software Setup has instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide. Now that you've successfully got your OLED Display (0.9", 128x36) up and running, it's time to incorporate it into your own project! For more information, check out the resources below: The Qwiic OLED 1.3in has its own hook-up guide. The Qwiic Micro OLED is a Qwiic enabled version of our micro OLED display! This small monochrome, blue-on-black OLED display displays incredibly clear images. This hookup guide will show you how to get started drawing objects and characters on your OLED. To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary. To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier. Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller. If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed: You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs. Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already. If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview. We would also recommend taking a look at the following tutorials if you aren't familiar with them. Listed below are some of the operating ranges and characteristics of the Qwiic Micro OLED. Power and I2C pins are broken out to the 1x4 PTH pins as well as the two horizontal Qwiic connectors. There are several jumpers on board that can be changed to facilitate several different functions. The first of which is the I2C pull-up jumper to disable the 2.2kΩ pull up resistors on the I2C data and clock lines, highlighted below. If multiple boards are connected to the I2C bus, the equivalent resistance goes down, increasing your pull up strength. If multiple boards are connected on the same bus, make sure only one board has the pull-up resistors connected. The ADDR jumper (highlighted below) can be used to change the I2C address of the board. The default jumper is open by default, pulling the address pin high and giving us an I2C address of 0X3D. Closing this jumper will ground the address pin, giving us an I2C address of 0X3C. Revision Change For V11, we have optimized the two mounting hole locations to match the mounting holes located on a standard 1.0" x 1.0" Qwiic-sized board. The overall functionality of the Qwiic Micro OLED breakout board is the same as the previous version! The overall board size is 1.08" x 1.17". There is a v-score for users that want to remove the mounting holes. If you haven't yet assembled your Qwiic Shield, now would be the time to head on over to that tutorial. With the shield assembled, SparkFun's Qwiic environment means that connecting the screen could not be easier. Just plug one end of the Qwiic cable into the OLED display, the other into the Qwiic Shield and you'll be ready to start displaying images on your little display. If you have a built-in Qwiic connector, you can skip the hardware assembly of the Qwiic Shield and simply insert a Qwiic cable between the two boards. Have more than one Qwiic-enabled device? You can daisy chain it to the board as well! Below is an example with the SAM-M8Q and the Qwiic Micro OLED daisy chained together to the RedBoard Qwiic. Note The initial launch of the Qwiic micro OLED breakout board had the OLED loosely attached to the breakout board. For users that received those boards, be careful handling it! You can either use your own enclosure for the OLED display, or you can use some double sided foam tape for a less permanent solution. The current production of the boards includes the double sided foam tape. The SparkFun Micro OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide. Now that you've successfully got your OLED displaying things, it's time to incorporate it into your own project! For more on the Qwiic Micro OLED, check out the links below: The future is here! You asked and we delivered - our Qwiic Transparent Graphical OLED Breakout allows you to display custom images on a transparent screen using either I2C or SPI connections. With Qwiic connectors it's quick (ha ha) and easy to get started with your own images. However, we still have broken out 0.1"-spaced pins in case you prefer to use a breadboard. Brilliantly lit in the dark and still visible by daylight, this OLED sports a display area of 128x64 pixels, 128x56 of which are completely transparent. Control of the OLED is based on the HyperDisplay library or SparkFun Qwiic OLED Arduino Library! For the scope of this tutorial, we will be using the SparkFun Qwiic OLED Arduino Library. This hookup guide will show you how to get started drawing objects and characters on your OLED. To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary. To get started, you'll need a microcontroller to, well, control everything. We used the SparkFun Thing Plus - ESP32 WROOOM. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier. Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller. If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed: You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs. Of course, you will also need A Tranparent Graphical OLED Breakout if you have not added that to you cart already. If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview. We would also recommend taking a look at the following tutorials if you aren't familiar with them. Listed below are some of the operating ranges and characteristics of the Transparent Graphical OLED Breakout. The graphical display is where all the fun stuff happens. The glass itself measures 42mm x 27.16mm, with a pixel display that is 35.5 x 18mm. It houses 128x64 pixels, 128x56 of which are transparent. There are two Qwiic connectors on the board such that you can daisy-chain the boards should you choose to do so. If you're unfamiliar with our Qwiic Connect System, head on over to our Qwiic page to see the advantages! When you look at the GPIO pins, you'll notice that the labels are different from one side to the other. One side is labeled for I2C, the other side is labeled for SPI. This bad boy will light up when the board is powered up correctly. You can disable the power LED by cutting the LED jumpers on the back of the board. The JPX jumpers are used to either change the I2C address or configure the board to use SPI communications. The other two jumpers allow you to disconnect the power LED and to disconnect the I2C pull-up resistors when chaining several Qwiic devices. I2C devices contain open drains so we include resistors on our boards to allow these devices to pull pins high. This becomes a problem if you have a large number of I2C devices chained together. If you plan to daisy chain more than a few Qwiic boards together, you'll need to cut this I2C pull-up jumper. Now that you know what's available on your breakout board we can check out the options for connecting it to the brains of your project. There are two options to use - either I2C or SPI - and they each have their own advantages and drawbacks. Read on to choose the best option for your setup. Warning Reminder! This breakout can only handle up to 3.3V on the pins, so make sure to do some level shifting if you're using a 5V microcontroller. The easiest way to start using the Transparent Graphical OLED is to use a Qwiic Cable along with a Qwiic compatible microcontroller (such as the ESP32 Thing Plus). You can also use the Qwiic Breadboard Cable to attach any I2C capable microcontroller, or take the scenic route and solder in all the I2C wires to the plated-through connections on the board. So why use I2C? It's easy to connect with the Qwiic system, and you can put up to two of the Transparent Graphical Breakouts on the same bus without using any more microcontroller pins. That simplicity comes at a cost to performance though. The maximum clock speed of the I2C bus is 400 kHz, and there is additional overhead in data transmission to indicate which bytes are data and which are commands. This means that the I2C connection is best for showing static images. SPI solves the I2C speed problems. With SPI there is a control signal that indicates data or command and the maximum clock speed is 10 MHz -- giving SPI 50x more speed! However, it doesn't have the same conveniences of the polarized Qwiic connector and low pin usage. You'll need to solder to the pins. You can use SPI to connect as many breakouts as you want. For N displays you will need to use at least N + 3 data pins. That's because the MOSI, SCLK, and D/C pins can be shared between displays but each breakout needs its own dedicated Chip Select (CS) pin. Warning Make sure to cut jumpers JP1, JP2, JP3, and JP4 when using SPI mode! The Transparent OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide. For more information on the Transparent Graphical OLED Breakout, check out some of the links here: The SparkFun Qwiic OLED Arduino Library is a single graphics module that supports all SparkFun OLED boards based on the SSD1306 from Solomon Systech. Prior to this library, three different libraries were used to support our four different OLED boards. The SparkFun Qwiic OLED Library delivers a common implementation for all our Qwiic OLED products, delivering a unified, fast, and efficient solution that implements a familiar and easy to understand user experience. The Software Setup outlines library installation and the general use of the Qwiic OLED library. Detailed examples are included as part of the library installation process and available in the Arduino IDE menu: File > Examples > SparkFun Qwiic OLED Arduino Library. A walk-thru of key examples is contained in the Examples section of this documentation set. Note For v1.0.5 of the SparkFun Qwiic OLED Arduino Library, we named the library as SparkFun Qwiic OLED Graphics Library. After v1.0.6, we updated the name to say SparkFun Qwiic OLED Arduino Library. You may have multiple versions in your Arduino libraries folder if you installed the library more than once. To avoid confusion, issues compiling, and to use the latest version, we recommend removing the "SparkFun Qwiic OLED Graphics Library" folder should you decide to use the latest and greatest version. This will probably be located under ..Documents\Arduino\libraries, that is if you are using Windows. Note Note that we have more than one Arduino Library for the micro OLED. If you have the older Arduino Library, make sure to not confuse the two libraries. You will notice that the older library will be called "SparkFun Micro OLED Breakout". The example code will include the following line of code: A full API Reference is also provided for the library. The SparkFun Qwiic OLED Arduino Library supports the following SparkFun products. The following architectures are supported in the Arduino Library. Below are a few of those processors populated on Arduino boards from the SparkFun catalog. You will need to make sure to check the associated hookup guides for additional information about compatible cables, drivers, or board add-ons. Note Unfortunately, the ATmega32U4 is not supported under this library. We recommend either using a different microcontroller or rolling back to the previous library written for the display. The SparkFun Qwiic OLED Arduino Library is licensed using the Open Source MIT License: Placeholder file for index redirect functionality. Methods used to support Arduino Print functionality. This method is called set the \"cursor\" position in the device. The library supports the Arduino This method is called to set the current color of the system. This is used by the Arduino This method is called to get the current color of the system. This is used by the Arduino Methods to setup the device, get device information and change display options. This method is called to initialize the OLED library and connection to the OLED device. This method must be called before calling any graphics methods. When called, this method reset the library state and OLED device to their intial state. Helpful to reset the OLED after waking up a system from a sleep state. This method returns the width, in pixels, of the connected OLED device This method returns the height, in pixels, of the connected OLED device This method inverts the current graphics on the display. This results of this command happen immediatly. When called, the screen contents are flipped vertically if the flip parameter is true, or restored to normal display if the flip parameter is false. When called, the screen contents are flipped horizontally if the flip parameter is true, or restored to normal display if the flip parameter is false. Used to turn the OLED display on or off. Methods for setting the drawing state of the library. This method is called to set the current font in the library. The current font is used when calling the The default font for the device is For the library, fonts are added to your program by including them via include files which are part of this library. The following fonts are included: For each font, the font variables are objects with the following attributes: Example use of a font object attribute: =q){if(s=W.limit_backward,W.limit_backward=q,W.ket=W.cursor,e=W.find_among_b(P,7))switch(W.bra=W.cursor,e){case 1:if(l()){if(i=W.limit-W.cursor,!W.eq_s_b(1,"s")&&(W.cursor=W.limit-i,!W.eq_s_b(1,"t")))break;W.slice_del()}break;case 2:W.slice_from("i");break;case 3:W.slice_del();break;case 4:W.eq_s_b(2,"gu")&&W.slice_del()}W.limit_backward=s}}function b(){var e=W.limit-W.cursor;W.find_among_b(U,5)&&(W.cursor=W.limit-e,W.ket=W.cursor,W.cursor>W.limit_backward&&(W.cursor--,W.bra=W.cursor,W.slice_del()))}function d(){for(var e,r=1;W.out_grouping_b(F,97,251);)r--;if(r<=0){if(W.ket=W.cursor,e=W.limit-W.cursor,!W.eq_s_b(1,"é")&&(W.cursor=W.limit-e,!W.eq_s_b(1,"è")))return;W.bra=W.cursor,W.slice_from("e")}}function k(){if(!w()&&(W.cursor=W.limit,!f()&&(W.cursor=W.limit,!m())))return W.cursor=W.limit,void _();W.cursor=W.limit,W.ket=W.cursor,W.eq_s_b(1,"Y")?(W.bra=W.cursor,W.slice_from("i")):(W.cursor=W.limit,W.eq_s_b(1,"ç")&&(W.bra=W.cursor,W.slice_from("c")))}var p,g,q,v=[new r("col",-1,-1),new r("par",-1,-1),new r("tap",-1,-1)],h=[new r("",-1,4),new r("I",0,1),new r("U",0,2),new r("Y",0,3)],z=[new r("iqU",-1,3),new r("abl",-1,3),new r("Ièr",-1,4),new r("ièr",-1,4),new r("eus",-1,2),new r("iv",-1,1)],y=[new r("ic",-1,2),new r("abil",-1,1),new r("iv",-1,3)],C=[new r("iqUe",-1,1),new r("atrice",-1,2),new r("ance",-1,1),new r("ence",-1,5),new r("logie",-1,3),new r("able",-1,1),new r("isme",-1,1),new r("euse",-1,11),new r("iste",-1,1),new r("ive",-1,8),new r("if",-1,8),new r("usion",-1,4),new r("ation",-1,2),new r("ution",-1,4),new r("ateur",-1,2),new r("iqUes",-1,1),new r("atrices",-1,2),new r("ances",-1,1),new r("ences",-1,5),new r("logies",-1,3),new r("ables",-1,1),new r("ismes",-1,1),new r("euses",-1,11),new r("istes",-1,1),new r("ives",-1,8),new r("ifs",-1,8),new r("usions",-1,4),new r("ations",-1,2),new r("utions",-1,4),new r("ateurs",-1,2),new r("ments",-1,15),new r("ements",30,6),new r("issements",31,12),new r("ités",-1,7),new r("ment",-1,15),new r("ement",34,6),new r("issement",35,12),new r("amment",34,13),new r("emment",34,14),new r("aux",-1,10),new r("eaux",39,9),new r("eux",-1,1),new r("ité",-1,7)],x=[new r("ira",-1,1),new r("ie",-1,1),new r("isse",-1,1),new r("issante",-1,1),new r("i",-1,1),new r("irai",4,1),new r("ir",-1,1),new r("iras",-1,1),new r("ies",-1,1),new r("îmes",-1,1),new r("isses",-1,1),new r("issantes",-1,1),new r("îtes",-1,1),new r("is",-1,1),new r("irais",13,1),new r("issais",13,1),new r("irions",-1,1),new r("issions",-1,1),new r("irons",-1,1),new r("issons",-1,1),new r("issants",-1,1),new r("it",-1,1),new r("irait",21,1),new r("issait",21,1),new r("issant",-1,1),new r("iraIent",-1,1),new r("issaIent",-1,1),new r("irent",-1,1),new r("issent",-1,1),new r("iront",-1,1),new r("ît",-1,1),new r("iriez",-1,1),new r("issiez",-1,1),new r("irez",-1,1),new r("issez",-1,1)],I=[new r("a",-1,3),new r("era",0,2),new r("asse",-1,3),new r("ante",-1,3),new r("ée",-1,2),new r("ai",-1,3),new r("erai",5,2),new r("er",-1,2),new r("as",-1,3),new r("eras",8,2),new r("âmes",-1,3),new r("asses",-1,3),new r("antes",-1,3),new r("âtes",-1,3),new r("ées",-1,2),new r("ais",-1,3),new r("erais",15,2),new r("ions",-1,1),new r("erions",17,2),new r("assions",17,3),new r("erons",-1,2),new r("ants",-1,3),new r("és",-1,2),new r("ait",-1,3),new r("erait",23,2),new r("ant",-1,3),new r("aIent",-1,3),new r("eraIent",26,2),new r("èrent",-1,2),new r("assent",-1,3),new r("eront",-1,2),new r("ât",-1,3),new r("ez",-1,2),new r("iez",32,2),new r("eriez",33,2),new r("assiez",33,3),new r("erez",32,2),new r("é",-1,2)],P=[new r("e",-1,3),new r("Ière",0,2),new r("ière",0,2),new r("ion",-1,1),new r("Ier",-1,2),new r("ier",-1,2),new r("ë",-1,4)],U=[new r("ell",-1,-1),new r("eill",-1,-1),new r("enn",-1,-1),new r("onn",-1,-1),new r("ett",-1,-1)],F=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,128,130,103,8,5],S=[1,65,20,0,0,0,0,0,0,0,0,0,0,0,0,0,128],W=new s;this.setCurrent=function(e){W.setCurrent(e)},this.getCurrent=function(){return W.getCurrent()},this.stem=function(){var e=W.cursor;return n(),W.cursor=e,u(),W.limit_backward=e,W.cursor=W.limit,k(),W.cursor=W.limit,b(),W.cursor=W.limit,d(),W.cursor=W.limit_backward,o(),!0}};return function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}}(),e.Pipeline.registerFunction(e.fr.stemmer,"stemmer-fr"),e.fr.stopWordFilter=e.generateStopWordFilter("ai aie aient aies ait as au aura aurai auraient aurais aurait auras aurez auriez aurions aurons auront aux avaient avais avait avec avez aviez avions avons ayant ayez ayons c ce ceci celà ces cet cette d dans de des du elle en es est et eu eue eues eurent eus eusse eussent eusses eussiez eussions eut eux eûmes eût eûtes furent fus fusse fussent fusses fussiez fussions fut fûmes fût fûtes ici il ils j je l la le les leur leurs lui m ma mais me mes moi mon même n ne nos notre nous on ont ou par pas pour qu que quel quelle quelles quels qui s sa sans se sera serai seraient serais serait seras serez seriez serions serons seront ses soi soient sois soit sommes son sont soyez soyons suis sur t ta te tes toi ton tu un une vos votre vous y à étaient étais était étant étiez étions été étée étées étés êtes".split(" ")),e.Pipeline.registerFunction(e.fr.stopWordFilter,"stopWordFilter-fr")}});
\ No newline at end of file
diff --git a/assets/javascripts/lunr/min/lunr.he.min.js b/assets/javascripts/lunr/min/lunr.he.min.js
new file mode 100644
index 0000000..b863d3e
--- /dev/null
+++ b/assets/javascripts/lunr/min/lunr.he.min.js
@@ -0,0 +1 @@
+!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");e.he=function(){this.pipeline.reset(),this.pipeline.add(e.he.trimmer,e.he.stopWordFilter,e.he.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.he.stemmer))},e.he.wordCharacters="֑-״א-תa-zA-Za-zA-Z0-90-9",e.he.trimmer=e.trimmerSupport.generateTrimmer(e.he.wordCharacters),e.Pipeline.registerFunction(e.he.trimmer,"trimmer-he"),e.he.stemmer=function(){var e=this;return e.result=!1,e.preRemoved=!1,e.sufRemoved=!1,e.pre={pre1:"ה ו י ת",pre2:"ב כ ל מ ש כש",pre3:"הב הכ הל המ הש בש לכ",pre4:"וב וכ ול ומ וש",pre5:"מה שה כל",pre6:"מב מכ מל ממ מש",pre7:"בה בו בי בת כה כו כי כת לה לו לי לת",pre8:"ובה ובו ובי ובת וכה וכו וכי וכת ולה ולו ולי ולת"},e.suf={suf1:"ך כ ם ן נ",suf2:"ים ות וך וכ ום ון ונ הם הן יכ יך ינ ים",suf3:"תי תך תכ תם תן תנ",suf4:"ותי ותך ותכ ותם ותן ותנ",suf5:"נו כם כן הם הן",suf6:"ונו וכם וכן והם והן",suf7:"תכם תכן תנו תהם תהן",suf8:"הוא היא הם הן אני אתה את אנו אתם אתן",suf9:"ני נו כי כו כם כן תי תך תכ תם תן",suf10:"י ך כ ם ן נ ת"},e.patterns=JSON.parse('{"hebrewPatterns": [{"pt1": [{"c": "ה", "l": 0}]}, {"pt2": [{"c": "ו", "l": 0}]}, {"pt3": [{"c": "י", "l": 0}]}, {"pt4": [{"c": "ת", "l": 0}]}, {"pt5": [{"c": "מ", "l": 0}]}, {"pt6": [{"c": "ל", "l": 0}]}, {"pt7": [{"c": "ב", "l": 0}]}, {"pt8": [{"c": "כ", "l": 0}]}, {"pt9": [{"c": "ש", "l": 0}]}, {"pt10": [{"c": "כש", "l": 0}]}, {"pt11": [{"c": "בה", "l": 0}]}, {"pt12": [{"c": "וב", "l": 0}]}, {"pt13": [{"c": "וכ", "l": 0}]}, {"pt14": [{"c": "ול", "l": 0}]}, {"pt15": [{"c": "ומ", "l": 0}]}, {"pt16": [{"c": "וש", "l": 0}]}, {"pt17": [{"c": "הב", "l": 0}]}, {"pt18": [{"c": "הכ", "l": 0}]}, {"pt19": [{"c": "הל", "l": 0}]}, {"pt20": [{"c": "המ", "l": 0}]}, {"pt21": [{"c": "הש", "l": 0}]}, {"pt22": [{"c": "מה", "l": 0}]}, {"pt23": [{"c": "שה", "l": 0}]}, {"pt24": [{"c": "כל", "l": 0}]}]}'),e.execArray=["cleanWord","removeDiacritics","removeStopWords","normalizeHebrewCharacters"],e.stem=function(){var r=0;for(e.result=!1,e.preRemoved=!1,e.sufRemoved=!1;r
=a&&(r=w.limit_backward,w.limit_backward=a,w.ket=w.cursor,e=w.find_among_b(m,29),w.limit_backward=r,e))switch(w.bra=w.cursor,e){case 1:w.slice_del();break;case 2:n=w.limit-w.cursor,w.in_grouping_b(c,98,122)?w.slice_del():(w.cursor=w.limit-n,w.eq_s_b(1,"k")&&w.out_grouping_b(d,97,248)&&w.slice_del());break;case 3:w.slice_from("er")}}function t(){var e,r=w.limit-w.cursor;w.cursor>=a&&(e=w.limit_backward,w.limit_backward=a,w.ket=w.cursor,w.find_among_b(u,2)?(w.bra=w.cursor,w.limit_backward=e,w.cursor=w.limit-r,w.cursor>w.limit_backward&&(w.cursor--,w.bra=w.cursor,w.slice_del())):w.limit_backward=e)}function o(){var e,r;w.cursor>=a&&(r=w.limit_backward,w.limit_backward=a,w.ket=w.cursor,e=w.find_among_b(l,11),e?(w.bra=w.cursor,w.limit_backward=r,1==e&&w.slice_del()):w.limit_backward=r)}var s,a,m=[new r("a",-1,1),new r("e",-1,1),new r("ede",1,1),new r("ande",1,1),new r("ende",1,1),new r("ane",1,1),new r("ene",1,1),new r("hetene",6,1),new r("erte",1,3),new r("en",-1,1),new r("heten",9,1),new r("ar",-1,1),new r("er",-1,1),new r("heter",12,1),new r("s",-1,2),new r("as",14,1),new r("es",14,1),new r("edes",16,1),new r("endes",16,1),new r("enes",16,1),new r("hetenes",19,1),new r("ens",14,1),new r("hetens",21,1),new r("ers",14,1),new r("ets",14,1),new r("et",-1,1),new r("het",25,1),new r("ert",-1,3),new r("ast",-1,1)],u=[new r("dt",-1,-1),new r("vt",-1,-1)],l=[new r("leg",-1,1),new r("eleg",0,1),new r("ig",-1,1),new r("eig",2,1),new r("lig",2,1),new r("elig",4,1),new r("els",-1,1),new r("lov",-1,1),new r("elov",7,1),new r("slov",7,1),new r("hetslov",9,1)],d=[17,65,16,1,0,0,0,0,0,0,0,0,0,0,0,0,48,0,128],c=[119,125,149,1],w=new n;this.setCurrent=function(e){w.setCurrent(e)},this.getCurrent=function(){return w.getCurrent()},this.stem=function(){var r=w.cursor;return e(),w.limit_backward=r,w.cursor=w.limit,i(),w.cursor=w.limit,t(),w.cursor=w.limit,o(),!0}};return function(e){return"function"==typeof e.update?e.update(function(e){return i.setCurrent(e),i.stem(),i.getCurrent()}):(i.setCurrent(e),i.stem(),i.getCurrent())}}(),e.Pipeline.registerFunction(e.no.stemmer,"stemmer-no"),e.no.stopWordFilter=e.generateStopWordFilter("alle at av bare begge ble blei bli blir blitt både båe da de deg dei deim deira deires dem den denne der dere deres det dette di din disse ditt du dykk dykkar då eg ein eit eitt eller elles en enn er et ett etter for fordi fra før ha hadde han hans har hennar henne hennes her hjå ho hoe honom hoss hossen hun hva hvem hver hvilke hvilken hvis hvor hvordan hvorfor i ikke ikkje ikkje ingen ingi inkje inn inni ja jeg kan kom korleis korso kun kunne kva kvar kvarhelst kven kvi kvifor man mange me med medan meg meget mellom men mi min mine mitt mot mykje ned no noe noen noka noko nokon nokor nokre nå når og også om opp oss over på samme seg selv si si sia sidan siden sin sine sitt sjøl skal skulle slik so som som somme somt så sånn til um upp ut uten var vart varte ved vere verte vi vil ville vore vors vort vår være være vært å".split(" ")),e.Pipeline.registerFunction(e.no.stopWordFilter,"stopWordFilter-no")}});
\ No newline at end of file
diff --git a/assets/javascripts/lunr/min/lunr.pt.min.js b/assets/javascripts/lunr/min/lunr.pt.min.js
new file mode 100644
index 0000000..6c16996
--- /dev/null
+++ b/assets/javascripts/lunr/min/lunr.pt.min.js
@@ -0,0 +1,18 @@
+/*!
+ * Lunr languages, `Portuguese` language
+ * https://github.com/MihaiValentin/lunr-languages
+ *
+ * Copyright 2014, Mihai Valentin
+ * http://www.mozilla.org/MPL/
+ */
+/*!
+ * based on
+ * Snowball JavaScript Library v0.3
+ * http://code.google.com/p/urim/
+ * http://snowball.tartarus.org/
+ *
+ * Copyright 2010, Oleg Mazko
+ * http://www.mozilla.org/MPL/
+ */
+
+!function(e,r){"function"==typeof define&&define.amd?define(r):"object"==typeof exports?module.exports=r():r()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");e.pt=function(){this.pipeline.reset(),this.pipeline.add(e.pt.trimmer,e.pt.stopWordFilter,e.pt.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.pt.stemmer))},e.pt.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.pt.trimmer=e.trimmerSupport.generateTrimmer(e.pt.wordCharacters),e.Pipeline.registerFunction(e.pt.trimmer,"trimmer-pt"),e.pt.stemmer=function(){var r=e.stemmerSupport.Among,s=e.stemmerSupport.SnowballProgram,n=new function(){function e(){for(var e;;){if(z.bra=z.cursor,e=z.find_among(k,3))switch(z.ket=z.cursor,e){case 1:z.slice_from("a~");continue;case 2:z.slice_from("o~");continue;case 3:if(z.cursor>=z.limit)break;z.cursor++;continue}break}}function n(){if(z.out_grouping(y,97,250)){for(;!z.in_grouping(y,97,250);){if(z.cursor>=z.limit)return!0;z.cursor++}return!1}return!0}function i(){if(z.in_grouping(y,97,250))for(;!z.out_grouping(y,97,250);){if(z.cursor>=z.limit)return!1;z.cursor++}return g=z.cursor,!0}function o(){var e,r,s=z.cursor;if(z.in_grouping(y,97,250))if(e=z.cursor,n()){if(z.cursor=e,i())return}else g=z.cursor;if(z.cursor=s,z.out_grouping(y,97,250)){if(r=z.cursor,n()){if(z.cursor=r,!z.in_grouping(y,97,250)||z.cursor>=z.limit)return;z.cursor++}g=z.cursor}}function t(){for(;!z.in_grouping(y,97,250);){if(z.cursor>=z.limit)return!1;z.cursor++}for(;!z.out_grouping(y,97,250);){if(z.cursor>=z.limit)return!1;z.cursor++}return!0}function a(){var e=z.cursor;g=z.limit,b=g,h=g,o(),z.cursor=e,t()&&(b=z.cursor,t()&&(h=z.cursor))}function u(){for(var e;;){if(z.bra=z.cursor,e=z.find_among(q,3))switch(z.ket=z.cursor,e){case 1:z.slice_from("ã");continue;case 2:z.slice_from("õ");continue;case 3:if(z.cursor>=z.limit)break;z.cursor++;continue}break}}function w(){return g<=z.cursor}function m(){return b<=z.cursor}function c(){return h<=z.cursor}function l(){var e;if(z.ket=z.cursor,!(e=z.find_among_b(F,45)))return!1;switch(z.bra=z.cursor,e){case 1:if(!c())return!1;z.slice_del();break;case 2:if(!c())return!1;z.slice_from("log");break;case 3:if(!c())return!1;z.slice_from("u");break;case 4:if(!c())return!1;z.slice_from("ente");break;case 5:if(!m())return!1;z.slice_del(),z.ket=z.cursor,e=z.find_among_b(j,4),e&&(z.bra=z.cursor,c()&&(z.slice_del(),1==e&&(z.ket=z.cursor,z.eq_s_b(2,"at")&&(z.bra=z.cursor,c()&&z.slice_del()))));break;case 6:if(!c())return!1;z.slice_del(),z.ket=z.cursor,e=z.find_among_b(C,3),e&&(z.bra=z.cursor,1==e&&c()&&z.slice_del());break;case 7:if(!c())return!1;z.slice_del(),z.ket=z.cursor,e=z.find_among_b(P,3),e&&(z.bra=z.cursor,1==e&&c()&&z.slice_del());break;case 8:if(!c())return!1;z.slice_del(),z.ket=z.cursor,z.eq_s_b(2,"at")&&(z.bra=z.cursor,c()&&z.slice_del());break;case 9:if(!w()||!z.eq_s_b(1,"e"))return!1;z.slice_from("ir")}return!0}function f(){var e,r;if(z.cursor>=g){if(r=z.limit_backward,z.limit_backward=g,z.ket=z.cursor,e=z.find_among_b(S,120))return z.bra=z.cursor,1==e&&z.slice_del(),z.limit_backward=r,!0;z.limit_backward=r}return!1}function d(){var e;z.ket=z.cursor,(e=z.find_among_b(W,7))&&(z.bra=z.cursor,1==e&&w()&&z.slice_del())}function v(e,r){if(z.eq_s_b(1,e)){z.bra=z.cursor;var s=z.limit-z.cursor;if(z.eq_s_b(1,r))return z.cursor=z.limit-s,w()&&z.slice_del(),!1}return!0}function p(){var e;if(z.ket=z.cursor,e=z.find_among_b(L,4))switch(z.bra=z.cursor,e){case 1:w()&&(z.slice_del(),z.ket=z.cursor,z.limit-z.cursor,v("u","g")&&v("i","c"));break;case 2:z.slice_from("c")}}function _(){if(!l()&&(z.cursor=z.limit,!f()))return z.cursor=z.limit,void d();z.cursor=z.limit,z.ket=z.cursor,z.eq_s_b(1,"i")&&(z.bra=z.cursor,z.eq_s_b(1,"c")&&(z.cursor=z.limit,w()&&z.slice_del()))}var h,b,g,k=[new r("",-1,3),new r("ã",0,1),new r("õ",0,2)],q=[new r("",-1,3),new r("a~",0,1),new r("o~",0,2)],j=[new r("ic",-1,-1),new r("ad",-1,-1),new r("os",-1,-1),new r("iv",-1,1)],C=[new r("ante",-1,1),new r("avel",-1,1),new r("ível",-1,1)],P=[new r("ic",-1,1),new r("abil",-1,1),new r("iv",-1,1)],F=[new r("ica",-1,1),new r("ância",-1,1),new r("ência",-1,4),new r("ira",-1,9),new r("adora",-1,1),new r("osa",-1,1),new r("ista",-1,1),new r("iva",-1,8),new r("eza",-1,1),new r("logía",-1,2),new r("idade",-1,7),new r("ante",-1,1),new r("mente",-1,6),new r("amente",12,5),new r("ável",-1,1),new r("ível",-1,1),new r("ución",-1,3),new r("ico",-1,1),new r("ismo",-1,1),new r("oso",-1,1),new r("amento",-1,1),new r("imento",-1,1),new r("ivo",-1,8),new r("aça~o",-1,1),new r("ador",-1,1),new r("icas",-1,1),new r("ências",-1,4),new r("iras",-1,9),new r("adoras",-1,1),new r("osas",-1,1),new r("istas",-1,1),new r("ivas",-1,8),new r("ezas",-1,1),new r("logías",-1,2),new r("idades",-1,7),new r("uciones",-1,3),new r("adores",-1,1),new r("antes",-1,1),new r("aço~es",-1,1),new r("icos",-1,1),new r("ismos",-1,1),new r("osos",-1,1),new r("amentos",-1,1),new r("imentos",-1,1),new r("ivos",-1,8)],S=[new r("ada",-1,1),new r("ida",-1,1),new r("ia",-1,1),new r("aria",2,1),new r("eria",2,1),new r("iria",2,1),new r("ara",-1,1),new r("era",-1,1),new r("ira",-1,1),new r("ava",-1,1),new r("asse",-1,1),new r("esse",-1,1),new r("isse",-1,1),new r("aste",-1,1),new r("este",-1,1),new r("iste",-1,1),new r("ei",-1,1),new r("arei",16,1),new r("erei",16,1),new r("irei",16,1),new r("am",-1,1),new r("iam",20,1),new r("ariam",21,1),new r("eriam",21,1),new r("iriam",21,1),new r("aram",20,1),new r("eram",20,1),new r("iram",20,1),new r("avam",20,1),new r("em",-1,1),new r("arem",29,1),new r("erem",29,1),new r("irem",29,1),new r("assem",29,1),new r("essem",29,1),new r("issem",29,1),new r("ado",-1,1),new r("ido",-1,1),new r("ando",-1,1),new r("endo",-1,1),new r("indo",-1,1),new r("ara~o",-1,1),new r("era~o",-1,1),new r("ira~o",-1,1),new r("ar",-1,1),new r("er",-1,1),new r("ir",-1,1),new r("as",-1,1),new r("adas",47,1),new r("idas",47,1),new r("ias",47,1),new r("arias",50,1),new r("erias",50,1),new r("irias",50,1),new r("aras",47,1),new r("eras",47,1),new r("iras",47,1),new r("avas",47,1),new r("es",-1,1),new r("ardes",58,1),new r("erdes",58,1),new r("irdes",58,1),new r("ares",58,1),new r("eres",58,1),new r("ires",58,1),new r("asses",58,1),new r("esses",58,1),new r("isses",58,1),new r("astes",58,1),new r("estes",58,1),new r("istes",58,1),new r("is",-1,1),new r("ais",71,1),new r("eis",71,1),new r("areis",73,1),new r("ereis",73,1),new r("ireis",73,1),new r("áreis",73,1),new r("éreis",73,1),new r("íreis",73,1),new r("ásseis",73,1),new r("ésseis",73,1),new r("ísseis",73,1),new r("áveis",73,1),new r("íeis",73,1),new r("aríeis",84,1),new r("eríeis",84,1),new r("iríeis",84,1),new r("ados",-1,1),new r("idos",-1,1),new r("amos",-1,1),new r("áramos",90,1),new r("éramos",90,1),new r("íramos",90,1),new r("ávamos",90,1),new r("íamos",90,1),new r("aríamos",95,1),new r("eríamos",95,1),new r("iríamos",95,1),new r("emos",-1,1),new r("aremos",99,1),new r("eremos",99,1),new r("iremos",99,1),new r("ássemos",99,1),new r("êssemos",99,1),new r("íssemos",99,1),new r("imos",-1,1),new r("armos",-1,1),new r("ermos",-1,1),new r("irmos",-1,1),new r("ámos",-1,1),new r("arás",-1,1),new r("erás",-1,1),new r("irás",-1,1),new r("eu",-1,1),new r("iu",-1,1),new r("ou",-1,1),new r("ará",-1,1),new r("erá",-1,1),new r("irá",-1,1)],W=[new r("a",-1,1),new r("i",-1,1),new r("o",-1,1),new r("os",-1,1),new r("á",-1,1),new r("í",-1,1),new r("ó",-1,1)],L=[new r("e",-1,1),new r("ç",-1,2),new r("é",-1,1),new r("ê",-1,1)],y=[17,65,16,0,0,0,0,0,0,0,0,0,0,0,0,0,3,19,12,2],z=new s;this.setCurrent=function(e){z.setCurrent(e)},this.getCurrent=function(){return z.getCurrent()},this.stem=function(){var r=z.cursor;return e(),z.cursor=r,a(),z.limit_backward=r,z.cursor=z.limit,_(),z.cursor=z.limit,p(),z.cursor=z.limit_backward,u(),!0}};return function(e){return"function"==typeof e.update?e.update(function(e){return n.setCurrent(e),n.stem(),n.getCurrent()}):(n.setCurrent(e),n.stem(),n.getCurrent())}}(),e.Pipeline.registerFunction(e.pt.stemmer,"stemmer-pt"),e.pt.stopWordFilter=e.generateStopWordFilter("a ao aos aquela aquelas aquele aqueles aquilo as até com como da das de dela delas dele deles depois do dos e ela elas ele eles em entre era eram essa essas esse esses esta estamos estas estava estavam este esteja estejam estejamos estes esteve estive estivemos estiver estivera estiveram estiverem estivermos estivesse estivessem estivéramos estivéssemos estou está estávamos estão eu foi fomos for fora foram forem formos fosse fossem fui fôramos fôssemos haja hajam hajamos havemos hei houve houvemos houver houvera houveram houverei houverem houveremos houveria houveriam houvermos houverá houverão houveríamos houvesse houvessem houvéramos houvéssemos há hão isso isto já lhe lhes mais mas me mesmo meu meus minha minhas muito na nas nem no nos nossa nossas nosso nossos num numa não nós o os ou para pela pelas pelo pelos por qual quando que quem se seja sejam sejamos sem serei seremos seria seriam será serão seríamos seu seus somos sou sua suas são só também te tem temos tenha tenham tenhamos tenho terei teremos teria teriam terá terão teríamos teu teus teve tinha tinham tive tivemos tiver tivera tiveram tiverem tivermos tivesse tivessem tivéramos tivéssemos tu tua tuas tém tínhamos um uma você vocês vos à às éramos".split(" ")),e.Pipeline.registerFunction(e.pt.stopWordFilter,"stopWordFilter-pt")}});
\ No newline at end of file
diff --git a/assets/javascripts/lunr/min/lunr.ro.min.js b/assets/javascripts/lunr/min/lunr.ro.min.js
new file mode 100644
index 0000000..7277140
--- /dev/null
+++ b/assets/javascripts/lunr/min/lunr.ro.min.js
@@ -0,0 +1,18 @@
+/*!
+ * Lunr languages, `Romanian` language
+ * https://github.com/MihaiValentin/lunr-languages
+ *
+ * Copyright 2014, Mihai Valentin
+ * http://www.mozilla.org/MPL/
+ */
+/*!
+ * based on
+ * Snowball JavaScript Library v0.3
+ * http://code.google.com/p/urim/
+ * http://snowball.tartarus.org/
+ *
+ * Copyright 2010, Oleg Mazko
+ * http://www.mozilla.org/MPL/
+ */
+
+!function(e,i){"function"==typeof define&&define.amd?define(i):"object"==typeof exports?module.exports=i():i()(e.lunr)}(this,function(){return function(e){if(void 0===e)throw new Error("Lunr is not present. Please include / require Lunr before this script.");if(void 0===e.stemmerSupport)throw new Error("Lunr stemmer support is not present. Please include / require Lunr stemmer support before this script.");e.ro=function(){this.pipeline.reset(),this.pipeline.add(e.ro.trimmer,e.ro.stopWordFilter,e.ro.stemmer),this.searchPipeline&&(this.searchPipeline.reset(),this.searchPipeline.add(e.ro.stemmer))},e.ro.wordCharacters="A-Za-zªºÀ-ÖØ-öø-ʸˠ-ˤᴀ-ᴥᴬ-ᵜᵢ-ᵥᵫ-ᵷᵹ-ᶾḀ-ỿⁱⁿₐ-ₜKÅℲⅎⅠ-ↈⱠ-ⱿꜢ-ꞇꞋ-ꞭꞰ-ꞷꟷ-ꟿꬰ-ꭚꭜ-ꭤff-stA-Za-z",e.ro.trimmer=e.trimmerSupport.generateTrimmer(e.ro.wordCharacters),e.Pipeline.registerFunction(e.ro.trimmer,"trimmer-ro"),e.ro.stemmer=function(){var i=e.stemmerSupport.Among,r=e.stemmerSupport.SnowballProgram,n=new function(){function e(e,i){L.eq_s(1,e)&&(L.ket=L.cursor,L.in_grouping(W,97,259)&&L.slice_from(i))}function n(){for(var i,r;;){if(i=L.cursor,L.in_grouping(W,97,259)&&(r=L.cursor,L.bra=r,e("u","U"),L.cursor=r,e("i","I")),L.cursor=i,L.cursor>=L.limit)break;L.cursor++}}function t(){if(L.out_grouping(W,97,259)){for(;!L.in_grouping(W,97,259);){if(L.cursor>=L.limit)return!0;L.cursor++}return!1}return!0}function a(){if(L.in_grouping(W,97,259))for(;!L.out_grouping(W,97,259);){if(L.cursor>=L.limit)return!0;L.cursor++}return!1}function o(){var e,i,r=L.cursor;if(L.in_grouping(W,97,259)){if(e=L.cursor,!t())return void(h=L.cursor);if(L.cursor=e,!a())return void(h=L.cursor)}L.cursor=r,L.out_grouping(W,97,259)&&(i=L.cursor,t()&&(L.cursor=i,L.in_grouping(W,97,259)&&L.cursor=e;r--){var n=this.uncheckedNodes[r],i=n.child.toString();i in this.minimizedNodes?n.parent.edges[n.char]=this.minimizedNodes[i]:(n.child._str=i,this.minimizedNodes[i]=n.child),this.uncheckedNodes.pop()}};t.Index=function(e){this.invertedIndex=e.invertedIndex,this.fieldVectors=e.fieldVectors,this.tokenSet=e.tokenSet,this.fields=e.fields,this.pipeline=e.pipeline},t.Index.prototype.search=function(e){return this.query(function(r){var n=new t.QueryParser(e,r);n.parse()})},t.Index.prototype.query=function(e){for(var r=new t.Query(this.fields),n=Object.create(null),i=Object.create(null),s=Object.create(null),o=Object.create(null),a=Object.create(null),u=0;u
-
-## Improve our Documentation
-All of this documentation can be modified by you! Please help us make it better.
-
-* These pages are contained in the [`docs` folder of the SparkFun Qwiic OLED Arduino Library repository](https://github.com/sparkfun/SparkFun_Qwiic_OLED_Arduino_Library/tree/main/docs).
-
-### Submit a Correction
-1. Fork this repo
-2. Add your corrections or improvements to the markdown file
-3. File a pull request with your changes, and enjoy making the ~~words~~ ~~worlds~~ world a better place.
- * Once received, the documentation specialist will automatically be notified.
- * We will review your suggested improvements to make sure they are correct and fit within our documentation standards.
-
-## Improve our Hardware Design
-All of our designs are open-source! Please help us make it better.
-
-* Our board design files are contained in the `Hardware` folder of their respective repositories:
-
-* [SparkFun Micro OLED Breakout (Qwiic)](https://github.com/sparkfun/Qwiic_Micro_OLED/tree/main/Hardware)
-* [SparkFun Qwiic OLED Display (0.91 in, 128x32)](https://github.com/sparkfun/SparkFun_Qwiic_OLED-0.91/tree/main/Hardware)
-* [SparkFun Transparent Graphical OLED Breakout (Qwiic)](https://github.com/sparkfun/Qwiic_Transparent_Graphical_OLED/tree/main/Hardware)
-* [SparkFun Qwiic OLED - (1.3in., 128x64)](https://github.com/sparkfun/SparkFun_Qwiic_OLED_Arduino_Library/tree/main/Hardware)
-
-### Submit a Design Improvement
-1. Fork this repo
-2. Add your design improvements
-3. File a pull request with your changes, and enjoy making the ~~words~~ ~~worlds~~ world a better place.
- * Once received, the engineer in charge of the original design will automatically be notified.
- * We will review your suggested improvements, if they are within our board design standards and meet our product design requirements, we will flag these changes for our next board revision. *(Please note, that even if your suggestion is accepted, these changes may not be immediate. We may have to cycle through our current product inventory first.)*
-
-## Contributors
-Let's provided some recognition to the contributors for this project!
-
-
-
-
diff --git a/docs/github/file_issue.md b/docs/github/file_issue.md
deleted file mode 100644
index 9407e2a..0000000
--- a/docs/github/file_issue.md
+++ /dev/null
@@ -1,52 +0,0 @@
-# Did we make a mistake?
-
-Spot something wrong? Please let us know.
-
-!!! attention
- This is not where customers should seek assistance on a product. If you require technical assistance or have questions about a product that is not working as expected, please head over to the [SparkFun Technical Assistance](https://www.sparkfun.com/technical_assistance) page for some initial troubleshooting.
-
-
- LCD-24606
-
-
-
-
- LCD-22495
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Characteristic
-
- Range
-
-
-
- Voltage
-
- 3.3V
-
-
-
- Temperature
-
- -40°C to 85°C
-
-
-
- I2C Address
-
- 0X3D (Default) or 0X3C (Closed Jumper)
-
-
-
-
-
- Pin
-
- Description
-
- Direction
-
-
-
- GND
-
- Ground
-
- In
-
-
-
- 3.3V
-
- Power
-
- In
-
-
-
- SDA
-
- I2C Data
-
- In
-
-
-
- SCL
-
- I2C Clock
-
- In
-
-
-
- LCD-15173
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Characteristic
-
- Range
-
-
-
- Voltage
-
- 1.65V-3.3V,
-
typically 3.3V via the Qwiic Cable
-
-
- Supply Current
-
- 400 mA
-
-
-
- I2C Address
-
- 0X3C (Default), 0X3D (Closed Jumper)
-
-
-
-
-
- Jumper
-
- Function
-
-
-
- JP1
-
- Holds the Chip Select line low when closed. Close for I2C, open for SPI
-
-
-
- JP2
-
- Selects the address in I2C mode. Closed for 0x30 by default and open for 0x31. Open for SPI mode to release the D/C pin
-
-
-
- JP3
-
- Used to select I2C or SPI mode. Close for I2C, open for SPI
-
-
-
- JP4
-
- This jumper should be closed for I2C and open for SPI. This connection allows SDA to be bi-directional
-
-
-
-
-
- Breakout Pin
-
- Microcontroller Pin Requirements
-
-
-
- GND
-
- Ground pin. Connect these so the two devices agree on voltages
-
-
-
- 3V3
-
- 3.3V supply pin, capable of up to 400 mA output
-
-
-
- SDA
-
- SDA - the bi-directional data line of your chosen I2C port
-
-
-
- SCL
-
- SCL - the clock line of your chosen I2C port
-
-
-
- SA0
-
- Optional : change the I2C address of the breakout. Make sure to cut JP2
-
-
-
- RST
-
- Optional : reset the breakout to a known state by pulsing this low
-
-
-
-
-
- Breakout Pin
-
- Microcontroller Pin Requirements
-
-
-
- CS
-
- A GPIO pin, set low when talking to the breakout
-
-
-
- D/C
-
- A GPIO pin, indicates if bytes are data or commands
-
-
-
- SCLK
-
- The clock output of your chosen SPI port
-
-
-
- MOSI
-
- The data output of your chosen SPI port
-
-
-
- 3V3
-
- 3.3V supply pin, capable of up to 400 mA output
-
-
-
- GND
-
- Ground pin. Connect these so the two devices agree on voltages
-
-
-
- LCD-22495
-
-
--
-
-
- LCD-24606
-
-
--
-
-
- LCD-15173
-
-
--
-
-
- LCD-23453
-
-
-
-
- WRL-15574
-
-
--
-
-
- DEV-14713
-
-
--
-
-
- WRL-20168
-
-
--
-
-
- DEV-17712
-
-
--
-
-
- DEV-14812
-
-
--
-
-
- DEV-15025
-
-
--
-
-
- DEV-16402
-
-
--
-
-
- DEV-18158
-
-
-
-
- If you need technical assistance and more information on a product that is not working as you expected, we recommend heading on over to the SparkFun Technical Assistance page for some initial troubleshooting.
-
-
-
- If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.
-
-
diff --git a/examples/Example-01_Hello/Example-01_Hello.ino b/examples/Example-01_Hello/Example-01_Hello.ino
deleted file mode 100644
index e130d21..0000000
--- a/examples/Example-01_Hello/Example-01_Hello.ino
+++ /dev/null
@@ -1,79 +0,0 @@
-/*
-
- Example-01_Hello.ino
-
- This demo shows the basic setup of the OLED library, generating simple graphics and displaying
- the results on the target device.
-
- Micro OLED https://www.sparkfun.com/products/14532
- Transparent OLED https://www.sparkfun.com/products/15173
- "Narrow" OLED https://www.sparkfun.com/products/24606
- Qwiic OLED 1.3in https://www.sparkfun.com/products/23453
-
- Written by Kirk Benell @ SparkFun Electronics, March 2022
-
- Repository:
- https://github.com/sparkfun/SparkFun_Qwiic_OLED_Arduino_Library
-
- Documentation:
- https://sparkfun.github.io/SparkFun_Qwiic_OLED_Arduino_Library/
-
- SparkFun code, firmware, and software is released under the MIT License(http://opensource.org/licenses/MIT).
-*/
-
-#include
-
-
-
- Class
-
- Qwiic OLED Device
-
-
-
-
- QwiicMicroOLED
- SparkFun Qwiic Micro OLED
-
-
-
-
- QwiicTransparentOLED
- SparkFun Transparent Graphical OLED
-
-
-
-
- QwiicNarrowOLED
- SparkFun Qwiic OLED Display (128x32)
-
-
-
-
- Qwiic1in3OLED
- SparkFun Qwiic OLED 1.3" Display (128x32)
-
-
-
-
-
- Class
-
- Qwiic OLED Device
-
-
-
-
- QwiicMicroOLED
- SparkFun Qwiic Micro OLED
-
-
-
-
- QwiicTransparentOLED
- SparkFun Transparent Graphical OLED
-
-
-
-
- QwiicNarrowOLED
- SparkFun Qwiic OLED Display (128x32)
-
-
-
-
- Qwiic1in3OLED
- SparkFun Qwiic OLED 1.3" Display (128x32)
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Contribute: Help Fix our Mistake!
+Improve our Documentation
+
+
+docs folder of the SparkFun Qwiic OLED Arduino Library repository.Submit a Correction
+
+
+words worlds world a better place.
+
+Improve our Hardware Design
+
+
+Hardware folder of their respective repositories:Submit a Design Improvement
+
+
+words worlds world a better place.
+
+Contributors
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Did we make a mistake?
+Discrepancies in the Documentation
+
+
+docs folder of the SparkFun Qwiic OLED Arduino Library repository.Spot something wrong?
+Do you have a suggested correction?
+
+
+words worlds world a better place.
+
+Problems in the Hardware Design
+Hardware folder of their respective repositories:
+
+Does something not make sense?
+Did we forget to include an important function of the board?
+
+
+Do you wish to contribute directly to improving the board design?
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ words worlds world a better place.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Qwiic OLED (0.91", 128x32)
+
+Introduction
+Required Materials
+
+
+
+
+Microcontroller
+USB Cable
+Qwiic
+Hardware Overview
+OLED Display (0.91", 128x32)
+&QW_FONT_31X48) and large numbers (i.e. &QW_FONT_LARGENUM) are too big to fit within the display.
+
+&QW_FONT_5X7)&QW_FONT_8X16)&QW_FONT_7SEGMENT)Power
+Qwiic and I2C
+
+
+
+
+Jumpers
+
+
+
+
+Board Dimensions
+Hardware Hookup
+Connecting via Qwiic Connector
+Mounting the Qwiic OLED (0.9", 128x32)
+Software
+Resources
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Qwiic OLED (1.3", 128x64)
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Qwiic Micro OLED (0.66", 64x48)
+
+Introduction
+Required Materials
+
+
+
+
+Microcontroller
+USB Cable
+Qwiic
+Suggested Reading
+
+
+
+
+
+
+
+
+
+
+ Hardware Overview
+
+
+
+
+ Characteristic
+
+ Range
+
+
+
+ Voltage
+
+ 3.3V
+
+
+
+ Temperature
+
+ -40°C to 85°C
+
+
+
+ I2C Address
+
+ 0X3D (Default) or 0X3C (Closed Jumper)
+
+ Pins
+
+
+
+
+ Pin
+
+ Description
+
+ Direction
+
+
+
+ GND
+
+ Ground
+
+ In
+
+
+
+ 3.3V
+
+ Power
+
+ In
+
+
+
+ SDA
+
+ I2C Data
+
+ In
+
+
+
+ SCL
+
+ I2C Clock
+
+ In
+
+ Jumpers
+Board Dimensions
+Hardware Assembly
+Software
+Resources
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Qwiic Transparent Graphical OLED (1.51", 128x56)
+
+Introduction
+Required Materials
+
+
+
+
+Microcontroller
+USB Cable
+Qwiic
+Suggested Reading
+
+
+
+
+
+
+
+
+
+
+ Hardware Overview
+
+
+
+
+ Characteristic
+
+ Range
+
+
+
+ Voltage
+
+ 1.65V-3.3V,
+
typically 3.3V via the Qwiic Cable
+
+
+ Supply Current
+
+ 400 mA
+
+
+
+ I2C Address
+
+ 0X3C (Default), 0X3D (Closed Jumper)
+
+ Graphical Display
+Qwiic Connectors
+GPIO Pins
+Power LED
+JPX Jumpers
+
+
+
+
+ Jumper
+
+ Function
+
+
+
+ JP1
+
+ Holds the Chip Select line low when closed. Close for I2C, open for SPI
+
+
+
+ JP2
+
+ Selects the address in I2C mode. Closed for 0x30 by default and open for 0x31. Open for SPI mode to release the D/C pin
+
+
+
+ JP3
+
+ Used to select I2C or SPI mode. Close for I2C, open for SPI
+
+
+
+ JP4
+
+ This jumper should be closed for I2C and open for SPI. This connection allows SDA to be bi-directional
+
+ I2C Pull-Up Jumper
+Hardware Hookup
+I2C (Qwiic)
+
+
+
+
+ Breakout Pin
+
+ Microcontroller Pin Requirements
+
+
+
+ GND
+
+ Ground pin. Connect these so the two devices agree on voltages
+
+
+
+ 3V3
+
+ 3.3V supply pin, capable of up to 400 mA output
+
+
+
+ SDA
+
+ SDA - the bi-directional data line of your chosen I2C port
+
+
+
+ SCL
+
+ SCL - the clock line of your chosen I2C port
+
+
+
+ SA0
+
+ Optional : change the I2C address of the breakout. Make sure to cut JP2
+
+
+
+ RST
+
+ Optional : reset the breakout to a known state by pulsing this low
+
+ SPI
+
+
+
+
+ Breakout Pin
+
+ Microcontroller Pin Requirements
+
+
+
+ CS
+
+ A GPIO pin, set low when talking to the breakout
+
+
+
+ D/C
+
+ A GPIO pin, indicates if bytes are data or commands
+
+
+
+ SCLK
+
+ The clock output of your chosen SPI port
+
+
+
+ MOSI
+
+ The data output of your chosen SPI port
+
+
+
+ 3V3
+
+ 3.3V supply pin, capable of up to 400 mA output
+
+
+
+ GND
+
+ Ground pin. Connect these so the two devices agree on voltages
+
+ Software
+Resources
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Introduction
+
+
Key Features
+
+
+Getting Started
+#include <SFE_MicroOLED.h>.Supported Products
+Supported Microcontrollers - Arduino Environment
+
+
+
+
+
+
+
+
+
+
+
+
+
+License
+The MIT License (MIT)
+
+Copyright (c) 2015 SparkFun Electronics
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ =m[t]&&t
- 6333 Dry Creek Parkway, Niwot, Colorado 80503
-
-# Default edit/view actions to "main" branch, instead of "master"
-edit_uri: blob/main/docs/
-
- #logo: img/sfe_logo_sm.png
-
-# Configuration for webpage theme
-theme:
- # Theme: https://squidfunk.github.io/mkdocs-material/
- name: material
-
- # Icon in Browser Tab (must be square img - i.e. 32x32 pixels)
- favicon: assets/sfe_favicon.png
-
- # Page Font
- font:
- text: Roboto
- code: Roboto Mono
-
- # Features to Include (ref. theme documentation)
- features:
-
- # Enable copy button on code blocks
- - content.code.copy
-
- # Enable annotations in code blocks
- - content.code.annotate
-
- # Enable "view source" and "edit this page" buttons
- - content.action.edit
- # - content.action.view
-
- # Enable Navigation buttons in the footer (i.e. previous/next)
- - navigation.footer
-
- # Enables anchor tracking (updates page url with the section user is on)
- # i.e. https://docs.sparkfun.com/
- {% for nav_item in nav %}
- {% set path = "__nav_" ~ loop.index %}
- {{ item.render(nav_item, path, 1) }}
- {% endfor %}
-
-
-
-
-
- {% endif %}
-
-
-
- {% for nav_item in nav %}
- {{ item.render(nav_item) }}
- {% endfor %}
-
-
- {% for toc_item in toc %}
- {% include "partials/toc-item.html" %}
- {% endfor %}
-
-
-
-
- {% endif %}
-Print interface, enabling the use of a print() and println() methods. The set cursor position defines where to start text output for this functionality.
Parameter Type Description x void setCursor(uint8_t x, uint8_t y)\nuint8_t The X coordinate of the cursor y uint8_t The Y coordinate of the cursor"},{"location":"api_arduino/#setcolor","title":"setColor()","text":"Print interface functionality
Parameter Type Description void setColor(uint8_t clr)\nclr uint8_t The color to set. 0 = black, > 0 = white"},{"location":"api_arduino/#getcolor","title":"getColor()","text":"Print interface functionality
Parameter Type Description return value uint8_t getColor(void)\nuint8_t The current color"},{"location":"api_device/","title":"Device Operations","text":"
Parameter Type Description bool begin(TwoWire &wirePort, uint8_t address)\nwirePort TwoWire optional. The Wire port. If not provided, the default port is used address uint8_t optional. I2C Address. If not provided, the default address is used. return value bool true on success, false on startup failure"},{"location":"api_device/#reset","title":"reset()","text":"
Parameter Type Description return value void reset()\nbool true on success, false on startup failure"},{"location":"api_device/#geometry","title":"Geometry","text":""},{"location":"api_device/#getwidth","title":"getWidth()","text":"
Parameter Type Description return value uint8_t getWidth(void)\nuint8_t The width in pixels of the connected OLED device"},{"location":"api_device/#getheight","title":"getHeight()","text":"
Parameter Type Description return value uint8_t getHeight(void)\nuint8_t The height in pixels of the connected OLED device"},{"location":"api_device/#display-modes","title":"Display Modes","text":""},{"location":"api_device/#invert","title":"invert()","text":"
Parameter Type Description void invert(bool bInvert)\nbInvert bool true - the screen is inverted. false - the screen is set to normal"},{"location":"api_device/#flipvertical","title":"flipVertical()","text":"
Parameter Type Description void flipVertical(bool bFlip)\nbFlip bool true - the screen is flipped vertically. false - the screen is set to normal"},{"location":"api_device/#fliphorizontal","title":"flipHorizontal()","text":"
Parameter Type Description void flipHorizontal(bool bFlip)\nbFlip bool true - the screen is flipped horizontally. false - the screen is set to normal"},{"location":"api_device/#displaypower","title":"displayPower()","text":"
Parameter Type Description void displayPower(bool bEnable)\nbEnable bool true - the OLED display is powered on (default). false - the OLED dsiplay is powered off."},{"location":"api_draw/","title":"Drawing Settings/State","text":"text() method on this device. 5x7.
Parameter Type Description void setFont(QwiicFont& theFont)\nvoid setFont(const QwiicFont * theFont)\ntheFont QwiicFont The font to set as current in the device theFont QwiicFont* Pointer to the font to set as current in the device. <res/qw_fnt_5x7.h> QW_FONT_5X7 A full, 5 x 7 font 31x48 <res/qw_fnt_31x48.h> QW_FONT_31X48 A full, 31 x 48 font Seven Segment <res/qw_fnt_7segment.h> QW_FONT_7SEGMENT Numbers only 8x16 <res/qw_fnt_8x16.h> QW_FONT_8X16 A full, 8 x 16 font Large Numbers <res/qw_fnt_largenum.h> QW_FONT_LARGENUM Numbers only width The font width in pixels height The font height in pixels start The font start character offset n_chars The number of characters map_width The width of the font map #include <res/qw_fnt_31x48.h>\n\nint myFontWidth = QW_FONT_31X48.width;\n
This method returns the current font for the device.
QwiicFont * getFont(void)\n Parameter Type Description return value QwiicFont* A pointer to the current font. See setFont() for font object details."},{"location":"api_draw/#getfontname","title":"getFontName()","text":"This method returns the height in pixels of a provided String based on the current device font.
String getFontName(void)\n Parameter Type Description return value String The name of the current font."},{"location":"api_draw/#getstringwidth","title":"getStringWidth()","text":"This method returns the width in pixels of a provided String based on the current device font.
unsigned int getStringWidth(String text)\n Parameter Type Description text String The string used to determine width return value unsigned int The width of the provide string, as determined using the current font."},{"location":"api_draw/#getstringheight","title":"getStringHeight()","text":"This method returns the height in pixels of a provided String based on the current device font.
unsigned int getStringHeight(String text)\n Parameter Type Description text String The string used to determine height return value unsigned int The height of the provide string, as determined using the current font."},{"location":"api_draw/#setdrawmode","title":"setDrawMode()","text":"This method sets the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
void setDrawMode(grRasterOp_t rop)\n Parameter Type Description rop grRasterOp_t The raster operation (ROP) to set the graphics system to. Raster operations device how source (pixels to draw) are represented on the destination device. The available Raster Operation (ROP) codes are:
ROP Code Description grROPCopy default Drawn pixel values are copied to the device screen grROPNotCopy A not operation is applied to the source value before copying to screen grROPNot A not operation is applied to the destination (screen) value grROPXOR A XOR operation is performed between the source and destination values grROPBlack A value of 0, or black is drawn to the destination grROPWhite A value of 1, or black is drawn to the destination"},{"location":"api_draw/#getdrawmode","title":"getDrawMode()","text":"This method returns the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
grRasterOp_t getDrawMode(void)\n Parameter Type Description return value grRasterOp_t The current aster operation (ROP) of the graphics system."},{"location":"api_graphics/","title":"Graphics Methods","text":"Methods used to draw and display graphics.
"},{"location":"api_graphics/#display","title":"display()","text":"When called, any pending display updates are sent to the connected OLED device. This includes drawn graphics and erase commands.
void display(void)\n Parameter Type Description NONE"},{"location":"api_graphics/#erase","title":"erase()","text":"Erases all graphics on the device, placing the display in a blank state. The erase update isn't sent to the device until the next display() call on the device.
void erase(void)\n Parameter Type Description NONE"},{"location":"api_graphics/#pixel","title":"pixel()","text":"Set the value of a pixel on the screen.
void pixel(uint8_t x, uint8_t y, uint8_t clr)\n Parameter Type Description x uint8_t The X coordinate of the pixel to set y uint8_t The Y coordinate of the pixel to set clr uint8_t optional The color value to set the pixel. This defaults to white (1)."},{"location":"api_graphics/#line","title":"line()","text":"Draw a line on the screen.
Note: If a line is horizontal (y0 = y1) or vertical (x0 = x1), optimized draw algorithms are used by the library.
void line(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the line y0 uint8_t The start Y coordinate of the line x1 uint8_t The end X coordinate of the line y1 uint8_t The end Y coordinate of the line clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"api_graphics/#rectangle","title":"rectangle()","text":"Draw a rectangle on the screen.
void rectangle(uint8_t x0, uint8_t y0, uint8_t width, uint8_t height, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the rectangle - upper left corner y0 uint8_t The start Y coordinate of the rectangle - upper left corner width uint8_t The width of the rectangle height uint8_t The height of the rectangle clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"api_graphics/#rectanglefill","title":"rectangleFill()","text":"Draw a filled rectangle on the screen.
void rectangleFill(uint8_t x0, uint8_t y0, uint8_t width, uint8_t height, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the rectangle - upper left corner y0 uint8_t The start Y coordinate of the rectangle - upper left corner width uint8_t The width of the rectangle height uint8_t The height of the rectangle clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"api_graphics/#circle","title":"circle()","text":"Draw a circle on the screen.
void circle(uint8_t x0, uint8_t y0, uint8_t radius, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate of the circle center y0 uint8_t The Y coordinate of the circle center radius uint8_t The radius of the circle clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"api_graphics/#circlefill","title":"circleFill()","text":"Draw a filled circle on the screen.
void circleFill(uint8_t x0, uint8_t y0, uint8_t radius, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate of the circle center y0 uint8_t The Y coordinate of the circle center radius uint8_t The radius of the circle clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"api_graphics/#bitmap","title":"bitmap()","text":"Draws a bitmap on the screen.
The bitmap should be 8 bit encoded - each pixel contains 8 y values.
void bitmap(uint8_t x0, uint8_t y0, uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner pBitmap uint8_t * A pointer to the bitmap array bmp_width uint8_t The width of the bitmap bmp_height uint8_t The height of the bitmap"},{"location":"api_graphics/#bitmap_1","title":"bitmap()","text":"Draws a bitmap on the screen.
The bitmap should be 8 bit encoded - each pixel contains 8 y values.
The coordinate [x1,y1] allows for only a portion of bitmap to be drawn.
void bitmap(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, \n uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner x1 uint8_t The end X coordinate of the bitmap - lower right corner y1 uint8_t The end Y coordinate of the bitmap - lower right corner pBitmap uint8_t * A pointer to the bitmap array bmp_width uint8_t The width of the bitmap bmp_height uint8_t The height of the bitmap"},{"location":"api_graphics/#bitmap_2","title":"bitmap()","text":"Draws a bitmap on the screen using a Bitmap object for the bitmap data.
void bitmap(uint8_t x0, uint8_t y0, QwiicBitmap& bitmap)\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner Bitmap QwiicBitmap A bitmap object"},{"location":"api_graphics/#text","title":"text()","text":"Draws a string using the current font on the screen.
void text(uint8_t x0, uint8_t y0, const char * text, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate to start drawing the text y0 uint8_t The Y coordinate to start drawing the text text const char* The string to draw on the screen text String The Arduino string to draw on the screen clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"api_scroll/","title":"Scrolling","text":"Methods for device scrolling
"},{"location":"api_scroll/#scrollstop","title":"scrollStop()","text":"If the device is in a scrolling mode, calling this method stops the scroll, and restores the device to normal display operation. This action is performed immediately.
void scrollStop(void)\n Parameter Type Description NONE"},{"location":"api_scroll/#scrollright","title":"scrollRight()","text":"This method is called to start the device scrolling the displayed graphics to the right. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrollRight(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed below Defined values for the interval parameter:
SCROLL_INTERVAL_2_FRAMES 2 SCROLL_INTERVAL_3_FRAMES 3 SCROLL_INTERVAL_4_FRAMES 4 SCROLL_INTERVAL_5_FRAMES 5 SCROLL_INTERVAL_25_FRAMES 25 SCROLL_INTERVAL_64_FRAMES 64 SCROLL_INTERVAL_128_FRAMES 128 SCROLL_INTERVAL_256_FRAMES 256"},{"location":"api_scroll/#scrollvertright","title":"scrollVertRight()","text":"This method is called to start the device scrolling the displayed graphics vertically and to the right. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrolVertlRight(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"api_scroll/#scrollleft","title":"scrollLeft()","text":"This method is called start to the device scrolling the displayed graphics to the left. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrollLeft(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"api_scroll/#scrollvertleft","title":"scrollVertLeft()","text":"This method is called to start the device scrolling the displayed graphics vertically and to the left. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrolVertlLeft(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"hug_0p91/","title":"Qwiic OLED (0.91\", 128x32)","text":""},{"location":"hug_0p91/#introduction","title":"Introduction","text":"The SparkFun Qwiic OLED Display can display up to four lines of text and features 128x32 pixels in a small 0.91\u201d (diagonal) frame. As an OLED, this display does not have a back light layer (unlike LCDs) and therefore it\u2019s thinner, consumes less power, and has higher contrast.
SparkFun Qwiic OLED Display (0.91 in., 128x32) LCD-24606 Purchase from SparkFun
In this section, we'll go over the hardware and how to hookup the breakout board.
"},{"location":"hug_0p91/#required-materials","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
SparkFun Qwiic OLED Display (0.91 in., 128x32) LCD-24606
In this section, we will highlight the hardware and pins that are broken out on the SparkFun Qwiic OLED Display (0.91 in., 128x32).
Top View Bottom View"},{"location":"hug_0p91/#oled-display-091-128x32","title":"OLED Display (0.91\", 128x32)","text":"The OLED screen has a pixel resolution of 128x32, a panel size of 30.0mm x 11.5mm x 1.2mm, and an active area of 22.384mm x 5.584mm. The driver chip is the SSD1306. For information can be found in the datasheet linked in the Resources.
OLED HighlightedNote
The SparkFun Qwiic OLED Arduino Library works for multiple displays. However, there are some caveats in the size of the display with the text. While you can technically display all fonts in the narrow OLED display, some characters (numbers, letters, and/or symbols depending on the font) will be too big to fully display on the screen. For example, the fonts for the 31x48 (i.e. &QW_FONT_31X48) and large numbers (i.e. &QW_FONT_LARGENUM) are too big to fit within the display.
Using the OLED display (0.91\", 128x32) we found that we were able to fit:
&QW_FONT_5X7)&QW_FONT_8X16)&QW_FONT_7SEGMENT)Power is applied through the vertical Qwiic connectors on the back of the board. The recommended input voltage is 3.3V. The logic levels for the Qwiic OLED Display (0.9\", 128x32) is 3.3V.
Power"},{"location":"hug_0p91/#qwiic-and-i2c","title":"Qwiic and I2C","text":"There are two vertical Qwiic connectors populated on the back of the board. You can use either connectors to provide power and send data through I2C. The Qwiic ecosystem is made for fast prototyping by removing the need for soldering. All you need to do is plug a Qwiic cable into the Qwiic connector and voila!
The address of the display is 0x3C.
Note
On the back of the board, the power and I2C pins are broken out to test points. These are used in our production department for quality control using custom testbeds. These could be an alternative option to connect to the pins. However, we recommend using the Qwiic connectors to easily connect to the OLED display. Note that the I2C pins are also in a different order compared to a standard I2C Qwiic connector should you decide to solder to the test points.
I2C Test Points
"},{"location":"hug_0p91/#jumpers","title":"Jumpers","text":"Note
If this is your first time working with jumpers, check out the How to Work with Jumper Pads and PCB Traces tutorial for more information.
The board includes a 1x3 jumper on the back of the board.
Version 1.1 is a bit smaller than previous versions since the board includes vertical Qwiic connectors on the back of the board. The overall board size is 1.75 in x 0.5 in. The mounting holes have also moved to toward the top of the board.
Board Dimensions"},{"location":"hug_0p91/#hardware-hookup","title":"Hardware Hookup","text":"In this section, we'll go over how to connect to the display. We will go just a bit further and talk about how to mount the display.
"},{"location":"hug_0p91/#connecting-via-qwiic-connector","title":"Connecting via Qwiic Connector","text":"Insert a Qwiic cable between your chosen microcontroller and Qwiic OLED. Then insert a USB cable between the microcontroller and your computer's COM port. For the scope of this tutorial, the USB cable provides power and allows us to upload code to the microcontroller. Of course, you can also debug the display by opening a Serial Terminal.
USB Cable, RedBoard Plus (ATMega328P), Qwiic Cable, Qwiic OLED (0.9 in., 12x32)Once you have finished prototyping, you could continue to use the USB cable and add a 5V power supply or battery pack.
"},{"location":"hug_0p91/#mounting-the-qwiic-oled-09-128x32","title":"Mounting the Qwiic OLED (0.9\", 128x32)","text":"Grab the board dimensions and cut out a rectangle in the enclosure. For users that want to mount the board so that the OLED display is flush against the enclosure, you will need to look at the dimensions based on the OLED. You will need to add a little tolerance so that the display can fit through the rectangle. For users that need to quickly mount the board, you will could also cut out rectangles based on the vertical Qwiic connector so that the wires can lead into the enclosure. Then cut out the mounting holes so that the board is right side up. In this case, we used a cardboard box as a quick example to demonstrate the Qwiic wires connecting leading into the enclosure.
Qwiic OLED Display Mounted in an EnclosureNote
To easily display text and graphics on the board, we recommend mounting the board right side up. There is an option in the example code to flip the text horizontally and vertically should you decide to mount the board upside down, but you would need to also determine the position of the text.
For a more durable enclosure, you could use wood, metal, or plastic. However, you will need additional tools to cut into the material.
"},{"location":"hug_0p91/#software","title":"Software","text":"The Qwiic OLED (0.91\", 128x32) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED Library's Software Setup has instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"hug_0p91/#resources","title":"Resources","text":"Now that you've successfully got your OLED Display (0.9\", 128x36) up and running, it's time to incorporate it into your own project! For more information, check out the resources below:
The Qwiic OLED 1.3in has its own hook-up guide.
"},{"location":"hug_micro_view/","title":"Qwiic Micro OLED (0.66\", 64x48)","text":""},{"location":"hug_micro_view/#introduction","title":"Introduction","text":"The Qwiic Micro OLED is a Qwiic enabled version of our micro OLED display! This small monochrome, blue-on-black OLED display displays incredibly clear images.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495 Purchase from SparkFun
This hookup guide will show you how to get started drawing objects and characters on your OLED.
"},{"location":"hug_micro_view/#required-materials","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495
If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
Qwiic Connection SystemWe would also recommend taking a look at the following tutorials if you aren't familiar with them.
I2C
Qwiic Shield for Arduino & Photon Hookup Guide
Listed below are some of the operating ranges and characteristics of the Qwiic Micro OLED.
Characteristic Range Voltage 3.3V Temperature -40\u00b0C to 85\u00b0C I2C Address 0X3D (Default) or 0X3C (Closed Jumper)"},{"location":"hug_micro_view/#pins","title":"Pins","text":"Power and I2C pins are broken out to the 1x4 PTH pins as well as the two horizontal Qwiic connectors.
Pin Description Direction GND Ground In 3.3V Power In SDA I2C Data In SCL I2C Clock In"},{"location":"hug_micro_view/#jumpers","title":"Jumpers","text":"There are several jumpers on board that can be changed to facilitate several different functions. The first of which is the I2C pull-up jumper to disable the 2.2k\u03a9 pull up resistors on the I2C data and clock lines, highlighted below. If multiple boards are connected to the I2C bus, the equivalent resistance goes down, increasing your pull up strength. If multiple boards are connected on the same bus, make sure only one board has the pull-up resistors connected.
I2C Pull-Up JumperThe ADDR jumper (highlighted below) can be used to change the I2C address of the board. The default jumper is open by default, pulling the address pin high and giving us an I2C address of 0X3D. Closing this jumper will ground the address pin, giving us an I2C address of 0X3C.
Address Jumper"},{"location":"hug_micro_view/#board-dimensions","title":"Board Dimensions","text":"Revision Change
For V11, we have optimized the two mounting hole locations to match the mounting holes located on a standard 1.0\" x 1.0\" Qwiic-sized board. The overall functionality of the Qwiic Micro OLED breakout board is the same as the previous version!
The overall board size is 1.08\" x 1.17\". There is a v-score for users that want to remove the mounting holes.
Board Dimensions"},{"location":"hug_micro_view/#hardware-assembly","title":"Hardware Assembly","text":"If you haven't yet assembled your Qwiic Shield, now would be the time to head on over to that tutorial. With the shield assembled, SparkFun's Qwiic environment means that connecting the screen could not be easier. Just plug one end of the Qwiic cable into the OLED display, the other into the Qwiic Shield and you'll be ready to start displaying images on your little display.
If you have a built-in Qwiic connector, you can skip the hardware assembly of the Qwiic Shield and simply insert a Qwiic cable between the two boards. Have more than one Qwiic-enabled device? You can daisy chain it to the board as well! Below is an example with the SAM-M8Q and the Qwiic Micro OLED daisy chained together to the RedBoard Qwiic.
Note
The initial launch of the Qwiic micro OLED breakout board had the OLED loosely attached to the breakout board. For users that received those boards, be careful handling it! You can either use your own enclosure for the OLED display, or you can use some double sided foam tape for a less permanent solution.
The current production of the boards includes the double sided foam tape.
"},{"location":"hug_micro_view/#software","title":"Software","text":"The SparkFun Micro OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"hug_micro_view/#resources","title":"Resources","text":"Now that you've successfully got your OLED displaying things, it's time to incorporate it into your own project!
For more on the Qwiic Micro OLED, check out the links below:
The future is here! You asked and we delivered - our Qwiic Transparent Graphical OLED Breakout allows you to display custom images on a transparent screen using either I2C or SPI connections.
With Qwiic connectors it's quick (ha ha) and easy to get started with your own images. However, we still have broken out 0.1\"-spaced pins in case you prefer to use a breadboard. Brilliantly lit in the dark and still visible by daylight, this OLED sports a display area of 128x64 pixels, 128x56 of which are completely transparent. Control of the OLED is based on the HyperDisplay library or SparkFun Qwiic OLED Arduino Library! For the scope of this tutorial, we will be using the SparkFun Qwiic OLED Arduino Library.
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173 Purchase from SparkFun
This hookup guide will show you how to get started drawing objects and characters on your OLED.
"},{"location":"hug_transparent/#required-materials","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the SparkFun Thing Plus - ESP32 WROOOM. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need A Tranparent Graphical OLED Breakout if you have not added that to you cart already.
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173
If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
Qwiic Connection SystemWe would also recommend taking a look at the following tutorials if you aren't familiar with them.
I2C
Qwiic Shield for Arduino & Photon Hookup Guide
Listed below are some of the operating ranges and characteristics of the Transparent Graphical OLED Breakout.
Characteristic Range Voltage 1.65V-3.3V,typically 3.3V via the Qwiic Cable Supply Current 400 mA I2C Address 0X3C (Default), 0X3D (Closed Jumper)"},{"location":"hug_transparent/#graphical-display","title":"Graphical Display","text":"The graphical display is where all the fun stuff happens. The glass itself measures 42mm x 27.16mm, with a pixel display that is 35.5 x 18mm. It houses 128x64 pixels, 128x56 of which are transparent.
Graphical Display"},{"location":"hug_transparent/#qwiic-connectors","title":"Qwiic Connectors","text":"There are two Qwiic connectors on the board such that you can daisy-chain the boards should you choose to do so. If you're unfamiliar with our Qwiic Connect System, head on over to our Qwiic page to see the advantages!
Qwiic Connectors"},{"location":"hug_transparent/#gpio-pins","title":"GPIO Pins","text":"When you look at the GPIO pins, you'll notice that the labels are different from one side to the other. One side is labeled for I2C, the other side is labeled for SPI.
I2C Labels SPI Labels"},{"location":"hug_transparent/#power-led","title":"Power LED","text":"This bad boy will light up when the board is powered up correctly.
Power LEDYou can disable the power LED by cutting the LED jumpers on the back of the board.
Power LED Jumpers"},{"location":"hug_transparent/#jpx-jumpers","title":"JPX Jumpers","text":"The JPX jumpers are used to either change the I2C address or configure the board to use SPI communications. The other two jumpers allow you to disconnect the power LED and to disconnect the I2C pull-up resistors when chaining several Qwiic devices.
Jumper Function JP1 Holds the Chip Select line low when closed. Close for I2C, open for SPI JP2 Selects the address in I2C mode. Closed for 0x30 by default and open for 0x31. Open for SPI mode to release the D/C pin JP3 Used to select I2C or SPI mode. Close for I2C, open for SPI JP4 This jumper should be closed for I2C and open for SPI. This connection allows SDA to be bi-directional JPX Jumper"},{"location":"hug_transparent/#i2c-pull-up-jumper","title":"I2C Pull-Up Jumper","text":"I2C devices contain open drains so we include resistors on our boards to allow these devices to pull pins high. This becomes a problem if you have a large number of I2C devices chained together. If you plan to daisy chain more than a few Qwiic boards together, you'll need to cut this I2C pull-up jumper.
I2C PU Jumper"},{"location":"hug_transparent/#hardware-hookup","title":"Hardware Hookup","text":"Now that you know what's available on your breakout board we can check out the options for connecting it to the brains of your project. There are two options to use - either I2C or SPI - and they each have their own advantages and drawbacks. Read on to choose the best option for your setup.
Warning
Reminder! This breakout can only handle up to 3.3V on the pins, so make sure to do some level shifting if you're using a 5V microcontroller.
"},{"location":"hug_transparent/#i2c-qwiic","title":"I2C (Qwiic)","text":"The easiest way to start using the Transparent Graphical OLED is to use a Qwiic Cable along with a Qwiic compatible microcontroller (such as the ESP32 Thing Plus). You can also use the Qwiic Breadboard Cable to attach any I2C capable microcontroller, or take the scenic route and solder in all the I2C wires to the plated-through connections on the board.
Top View I2C Pinout/i>So why use I2C? It's easy to connect with the Qwiic system, and you can put up to two of the Transparent Graphical Breakouts on the same bus without using any more microcontroller pins. That simplicity comes at a cost to performance though. The maximum clock speed of the I2C bus is 400 kHz, and there is additional overhead in data transmission to indicate which bytes are data and which are commands. This means that the I2C connection is best for showing static images.
Breakout Pin Microcontroller Pin Requirements GND Ground pin. Connect these so the two devices agree on voltages 3V3 3.3V supply pin, capable of up to 400 mA output SDA SDA - the bi-directional data line of your chosen I2C port SCL SCL - the clock line of your chosen I2C port SA0 Optional : change the I2C address of the breakout. Make sure to cut JP2 RST Optional : reset the breakout to a known state by pulsing this low"},{"location":"hug_transparent/#spi","title":"SPI","text":"SPI solves the I2C speed problems. With SPI there is a control signal that indicates data or command and the maximum clock speed is 10 MHz -- giving SPI 50x more speed! However, it doesn't have the same conveniences of the polarized Qwiic connector and low pin usage. You'll need to solder to the pins.
SPI PinoutYou can use SPI to connect as many breakouts as you want. For N displays you will need to use at least N + 3 data pins. That's because the MOSI, SCLK, and D/C pins can be shared between displays but each breakout needs its own dedicated Chip Select (CS) pin.
Breakout Pin Microcontroller Pin Requirements CS A GPIO pin, set low when talking to the breakout D/C A GPIO pin, indicates if bytes are data or commands SCLK The clock output of your chosen SPI port MOSI The data output of your chosen SPI port 3V3 3.3V supply pin, capable of up to 400 mA output GND Ground pin. Connect these so the two devices agree on voltagesWarning
Make sure to cut jumpers JP1, JP2, JP3, and JP4 when using SPI mode!
Cut Jumpers for SPI Mode
"},{"location":"hug_transparent/#software","title":"Software","text":"The Transparent OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"hug_transparent/#resources","title":"Resources","text":"For more information on the Transparent Graphical OLED Breakout, check out some of the links here:
The SparkFun Qwiic OLED Arduino Library is a single graphics module that supports all SparkFun OLED boards based on the SSD1306 from Solomon Systech. Prior to this library, three different libraries were used to support our four different OLED boards.
The SparkFun Qwiic OLED Library delivers a common implementation for all our Qwiic OLED products, delivering a unified, fast, and efficient solution that implements a familiar and easy to understand user experience.
"},{"location":"introduction/#key-features","title":"Key Features","text":"The Software Setup outlines library installation and the general use of the Qwiic OLED library.
Detailed examples are included as part of the library installation process and available in the Arduino IDE menu: File > Examples > SparkFun Qwiic OLED Arduino Library. A walk-thru of key examples is contained in the Examples section of this documentation set.
Note
For v1.0.5 of the SparkFun Qwiic OLED Arduino Library, we named the library as SparkFun Qwiic OLED Graphics Library. After v1.0.6, we updated the name to say SparkFun Qwiic OLED Arduino Library. You may have multiple versions in your Arduino libraries folder if you installed the library more than once. To avoid confusion, issues compiling, and to use the latest version, we recommend removing the \"SparkFun Qwiic OLED Graphics Library\" folder should you decide to use the latest and greatest version. This will probably be located under ..Documents\\Arduino\\libraries, that is if you are using Windows.
Note
Note that we have more than one Arduino Library for the micro OLED. If you have the older Arduino Library, make sure to not confuse the two libraries. You will notice that the older library will be called \"SparkFun Micro OLED Breakout\". The example code will include the following line of code: #include <SFE_MicroOLED.h>.
A full API Reference is also provided for the library.
SparkFun Qwiic OLED Arduino Library: API Reference"},{"location":"introduction/#supported-products","title":"Supported Products","text":"The SparkFun Qwiic OLED Arduino Library supports the following SparkFun products.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495
SparkFun Qwiic OLED Display (0.91 in, 128x32) LCD-24606
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173
SparkFun Qwiic OLED (1.3in., 128x64) LCD-23453
The following architectures are supported in the Arduino Library.
Below are a few of those processors populated on Arduino boards from the SparkFun catalog. You will need to make sure to check the associated hookup guides for additional information about compatible cables, drivers, or board add-ons.
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - SAMD51 DEV-14713
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - STM32 DEV-17712
SparkFun RedBoard Turbo - SAMD21 Development Board DEV-14812
SparkFun Pro nRF52840 Mini - Bluetooth Development Board DEV-15025
SparkFun MicroMod Teensy Processor DEV-16402
SparkFun RedBoard Plus (ATmega328P) DEV-18158
Note
Unfortunately, the ATmega32U4 is not supported under this library. We recommend either using a different microcontroller or rolling back to the previous library written for the display.
"},{"location":"introduction/#license","title":"License","text":"The SparkFun Qwiic OLED Arduino Library is licensed using the Open Source MIT License:
The MIT License (MIT)\n\nCopyright (c) 2015 SparkFun Electronics\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n"},{"location":"single_page/","title":"Getting Started","text":""},{"location":"single_page/#introduction","title":"Introduction","text":"The SparkFun Qwiic OLED Arduino Library is a single graphics module that supports all SparkFun OLED boards based on the SSD1306 from Solomon Systech. Prior to this library, three different libraries were used to support our four different OLED boards.
The SparkFun Qwiic OLED Library delivers a common implementation for all our Qwiic OLED products, delivering a unified, fast, and efficient solution that implements a familiar and easy to understand user experience.
"},{"location":"single_page/#key-features","title":"Key Features","text":"The Software Setup outlines library installation and the general use of the Qwiic OLED library.
Detailed examples are included as part of the library installation process and available in the Arduino IDE menu: File > Examples > SparkFun Qwiic OLED Arduino Library. A walk-thru of key examples is contained in the Examples section of this documentation set.
Note
For v1.0.5 of the SparkFun Qwiic OLED Arduino Library, we named the library as SparkFun Qwiic OLED Graphics Library. After v1.0.6, we updated the name to say SparkFun Qwiic OLED Arduino Library. You may have multiple versions in your Arduino libraries folder if you installed the library more than once. To avoid confusion, issues compiling, and to use the latest version, we recommend removing the \"SparkFun Qwiic OLED Graphics Library\" folder should you decide to use the latest and greatest version. This will probably be located under ..Documents\\Arduino\\libraries, that is if you are using Windows.
Note
Note that we have more than one Arduino Library for the micro OLED. If you have the older Arduino Library, make sure to not confuse the two libraries. You will notice that the older library will be called \"SparkFun Micro OLED Breakout\". The example code will include the following line of code: #include <SFE_MicroOLED.h>.
A full API Reference is also provided for the library.
SparkFun Qwiic OLED Arduino Library: API Reference"},{"location":"single_page/#supported-products","title":"Supported Products","text":"The SparkFun Qwiic OLED Arduino Library supports the following SparkFun products.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495
SparkFun Qwiic OLED Display (0.91 in, 128x32) LCD-24606
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173
SparkFun Qwiic OLED (1.3in., 128x64) LCD-23453
The following architectures are supported in the Arduino Library.
Below are a few of those processors populated on Arduino boards from the SparkFun catalog. You will need to make sure to check the associated hookup guides for additional information about compatible cables, drivers, or board add-ons.
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - SAMD51 DEV-14713
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - STM32 DEV-17712
SparkFun RedBoard Turbo - SAMD21 Development Board DEV-14812
SparkFun Pro nRF52840 Mini - Bluetooth Development Board DEV-15025
SparkFun MicroMod Teensy Processor DEV-16402
SparkFun RedBoard Plus (ATmega328P) DEV-18158
Note
Unfortunately, the ATmega32U4 is not supported under this library. We recommend either using a different microcontroller or rolling back to the previous library written for the display.
"},{"location":"single_page/#license","title":"License","text":"The SparkFun Qwiic OLED Arduino Library is licensed using the Open Source MIT License:
The MIT License (MIT)\n\nCopyright (c) 2015 SparkFun Electronics\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction, including without limitation the rights\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\ncopies of the Software, and to permit persons to whom the Software is\nfurnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all\ncopies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,\nFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE\nAUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER\nLIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,\nOUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE\nSOFTWARE.\n"},{"location":"single_page/#qwiic-micro-oled-066-64x48","title":"Qwiic Micro OLED (0.66\", 64x48)","text":""},{"location":"single_page/#introduction_1","title":"Introduction","text":"The Qwiic Micro OLED is a Qwiic enabled version of our micro OLED display! This small monochrome, blue-on-black OLED display displays incredibly clear images.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495 Purchase from SparkFun
This hookup guide will show you how to get started drawing objects and characters on your OLED.
"},{"location":"single_page/#required-materials","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
SparkFun Micro OLED Breakout (Qwiic) LCD-22495
If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
Qwiic Connection SystemWe would also recommend taking a look at the following tutorials if you aren't familiar with them.
I2C
Qwiic Shield for Arduino & Photon Hookup Guide
Listed below are some of the operating ranges and characteristics of the Qwiic Micro OLED.
Characteristic Range Voltage 3.3V Temperature -40\u00b0C to 85\u00b0C I2C Address 0X3D (Default) or 0X3C (Closed Jumper)"},{"location":"single_page/#pins","title":"Pins","text":"Power and I2C pins are broken out to the 1x4 PTH pins as well as the two horizontal Qwiic connectors.
Pin Description Direction GND Ground In 3.3V Power In SDA I2C Data In SCL I2C Clock In"},{"location":"single_page/#jumpers","title":"Jumpers","text":"There are several jumpers on board that can be changed to facilitate several different functions. The first of which is the I2C pull-up jumper to disable the 2.2k\u03a9 pull up resistors on the I2C data and clock lines, highlighted below. If multiple boards are connected to the I2C bus, the equivalent resistance goes down, increasing your pull up strength. If multiple boards are connected on the same bus, make sure only one board has the pull-up resistors connected.
I2C Pull-Up JumperThe ADDR jumper (highlighted below) can be used to change the I2C address of the board. The default jumper is open by default, pulling the address pin high and giving us an I2C address of 0X3D. Closing this jumper will ground the address pin, giving us an I2C address of 0X3C.
Address Jumper"},{"location":"single_page/#board-dimensions","title":"Board Dimensions","text":"Revision Change
For V11, we have optimized the two mounting hole locations to match the mounting holes located on a standard 1.0\" x 1.0\" Qwiic-sized board. The overall functionality of the Qwiic Micro OLED breakout board is the same as the previous version!
The overall board size is 1.08\" x 1.17\". There is a v-score for users that want to remove the mounting holes.
Board Dimensions"},{"location":"single_page/#hardware-assembly","title":"Hardware Assembly","text":"If you haven't yet assembled your Qwiic Shield, now would be the time to head on over to that tutorial. With the shield assembled, SparkFun's Qwiic environment means that connecting the screen could not be easier. Just plug one end of the Qwiic cable into the OLED display, the other into the Qwiic Shield and you'll be ready to start displaying images on your little display.
If you have a built-in Qwiic connector, you can skip the hardware assembly of the Qwiic Shield and simply insert a Qwiic cable between the two boards. Have more than one Qwiic-enabled device? You can daisy chain it to the board as well! Below is an example with the SAM-M8Q and the Qwiic Micro OLED daisy chained together to the RedBoard Qwiic.
Note
The initial launch of the Qwiic micro OLED breakout board had the OLED loosely attached to the breakout board. For users that received those boards, be careful handling it! You can either use your own enclosure for the OLED display, or you can use some double sided foam tape for a less permanent solution.
The current production of the boards includes the double sided foam tape.
"},{"location":"single_page/#software","title":"Software","text":"The SparkFun Micro OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"single_page/#resources","title":"Resources","text":"Now that you've successfully got your OLED displaying things, it's time to incorporate it into your own project!
For more on the Qwiic Micro OLED, check out the links below:
The future is here! You asked and we delivered - our Qwiic Transparent Graphical OLED Breakout allows you to display custom images on a transparent screen using either I2C or SPI connections.
With Qwiic connectors it's quick (ha ha) and easy to get started with your own images. However, we still have broken out 0.1\"-spaced pins in case you prefer to use a breadboard. Brilliantly lit in the dark and still visible by daylight, this OLED sports a display area of 128x64 pixels, 128x56 of which are completely transparent. Control of the OLED is based on the HyperDisplay library or SparkFun Qwiic OLED Arduino Library! For the scope of this tutorial, we will be using the SparkFun Qwiic OLED Arduino Library.
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173 Purchase from SparkFun
This hookup guide will show you how to get started drawing objects and characters on your OLED.
"},{"location":"single_page/#required-materials_1","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the SparkFun Thing Plus - ESP32 WROOOM. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need A Tranparent Graphical OLED Breakout if you have not added that to you cart already.
SparkFun Transparent Graphical OLED Breakout (Qwiic) LCD-15173
If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
Qwiic Connection SystemWe would also recommend taking a look at the following tutorials if you aren't familiar with them.
I2C
Qwiic Shield for Arduino & Photon Hookup Guide
Listed below are some of the operating ranges and characteristics of the Transparent Graphical OLED Breakout.
Characteristic Range Voltage 1.65V-3.3V,typically 3.3V via the Qwiic Cable Supply Current 400 mA I2C Address 0X3C (Default), 0X3D (Closed Jumper)"},{"location":"single_page/#graphical-display","title":"Graphical Display","text":"The graphical display is where all the fun stuff happens. The glass itself measures 42mm x 27.16mm, with a pixel display that is 35.5 x 18mm. It houses 128x64 pixels, 128x56 of which are transparent.
Graphical Display"},{"location":"single_page/#qwiic-connectors","title":"Qwiic Connectors","text":"There are two Qwiic connectors on the board such that you can daisy-chain the boards should you choose to do so. If you're unfamiliar with our Qwiic Connect System, head on over to our Qwiic page to see the advantages!
Qwiic Connectors"},{"location":"single_page/#gpio-pins","title":"GPIO Pins","text":"When you look at the GPIO pins, you'll notice that the labels are different from one side to the other. One side is labeled for I2C, the other side is labeled for SPI.
I2C Labels SPI Labels"},{"location":"single_page/#power-led","title":"Power LED","text":"This bad boy will light up when the board is powered up correctly.
Power LEDYou can disable the power LED by cutting the LED jumpers on the back of the board.
Power LED Jumpers"},{"location":"single_page/#jpx-jumpers","title":"JPX Jumpers","text":"The JPX jumpers are used to either change the I2C address or configure the board to use SPI communications. The other two jumpers allow you to disconnect the power LED and to disconnect the I2C pull-up resistors when chaining several Qwiic devices.
Jumper Function JP1 Holds the Chip Select line low when closed. Close for I2C, open for SPI JP2 Selects the address in I2C mode. Closed for 0x30 by default and open for 0x31. Open for SPI mode to release the D/C pin JP3 Used to select I2C or SPI mode. Close for I2C, open for SPI JP4 This jumper should be closed for I2C and open for SPI. This connection allows SDA to be bi-directional JPX Jumper"},{"location":"single_page/#i2c-pull-up-jumper","title":"I2C Pull-Up Jumper","text":"I2C devices contain open drains so we include resistors on our boards to allow these devices to pull pins high. This becomes a problem if you have a large number of I2C devices chained together. If you plan to daisy chain more than a few Qwiic boards together, you'll need to cut this I2C pull-up jumper.
I2C PU Jumper"},{"location":"single_page/#hardware-hookup","title":"Hardware Hookup","text":"Now that you know what's available on your breakout board we can check out the options for connecting it to the brains of your project. There are two options to use - either I2C or SPI - and they each have their own advantages and drawbacks. Read on to choose the best option for your setup.
Warning
Reminder! This breakout can only handle up to 3.3V on the pins, so make sure to do some level shifting if you're using a 5V microcontroller.
"},{"location":"single_page/#i2c-qwiic","title":"I2C (Qwiic)","text":"The easiest way to start using the Transparent Graphical OLED is to use a Qwiic Cable along with a Qwiic compatible microcontroller (such as the ESP32 Thing Plus). You can also use the Qwiic Breadboard Cable to attach any I2C capable microcontroller, or take the scenic route and solder in all the I2C wires to the plated-through connections on the board.
Top View I2C Pinout/i>So why use I2C? It's easy to connect with the Qwiic system, and you can put up to two of the Transparent Graphical Breakouts on the same bus without using any more microcontroller pins. That simplicity comes at a cost to performance though. The maximum clock speed of the I2C bus is 400 kHz, and there is additional overhead in data transmission to indicate which bytes are data and which are commands. This means that the I2C connection is best for showing static images.
Breakout Pin Microcontroller Pin Requirements GND Ground pin. Connect these so the two devices agree on voltages 3V3 3.3V supply pin, capable of up to 400 mA output SDA SDA - the bi-directional data line of your chosen I2C port SCL SCL - the clock line of your chosen I2C port SA0 Optional : change the I2C address of the breakout. Make sure to cut JP2 RST Optional : reset the breakout to a known state by pulsing this low"},{"location":"single_page/#spi","title":"SPI","text":"SPI solves the I2C speed problems. With SPI there is a control signal that indicates data or command and the maximum clock speed is 10 MHz -- giving SPI 50x more speed! However, it doesn't have the same conveniences of the polarized Qwiic connector and low pin usage. You'll need to solder to the pins.
SPI PinoutYou can use SPI to connect as many breakouts as you want. For N displays you will need to use at least N + 3 data pins. That's because the MOSI, SCLK, and D/C pins can be shared between displays but each breakout needs its own dedicated Chip Select (CS) pin.
Breakout Pin Microcontroller Pin Requirements CS A GPIO pin, set low when talking to the breakout D/C A GPIO pin, indicates if bytes are data or commands SCLK The clock output of your chosen SPI port MOSI The data output of your chosen SPI port 3V3 3.3V supply pin, capable of up to 400 mA output GND Ground pin. Connect these so the two devices agree on voltagesWarning
Make sure to cut jumpers JP1, JP2, JP3, and JP4 when using SPI mode!
Cut Jumpers for SPI Mode
"},{"location":"single_page/#software_1","title":"Software","text":"The Transparent OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"single_page/#resources_1","title":"Resources","text":"For more information on the Transparent Graphical OLED Breakout, check out some of the links here:
The SparkFun Qwiic OLED Display can display up to four lines of text and features 128x32 pixels in a small 0.91\u201d (diagonal) frame. As an OLED, this display does not have a back light layer (unlike LCDs) and therefore it\u2019s thinner, consumes less power, and has higher contrast.
SparkFun Qwiic OLED Display (0.91 in., 128x32) LCD-24606 Purchase from SparkFun
In this section, we'll go over the hardware and how to hookup the breakout board.
"},{"location":"single_page/#required-materials_2","title":"Required Materials","text":"To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
SparkFun RedBoard Plus (ATmega328P) DEV-18158
SparkFun Thing Plus - Artemis WRL-15574
SparkFun Thing Plus - ESP32 WROOM (USB-C) WRL-20168
SparkFun Thing Plus - SAMD51 DEV-14713
Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
SparkFun 4-in-1 Multi-USB Cable - USB-A Host CAB-21272
Reversible USB A to C Cable - 0.8m CAB-15425
Reversible USB A to Reversible Micro-B Cable - 0.8m CAB-15428
If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
SparkFun Qwiic Shield for Arduino DEV-14352
SparkFun Qwiic Shield for Teensy DEV-17119
SparkFun Qwiic Shield for Arduino Nano DEV-16789
You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
Flexible Qwiic Cable - 50mm PRT-17260
Flexible Qwiic Cable - 100mm PRT-17259
Flexible Qwiic Cable - 200mm PRT-17258
Flexible Qwiic Cable - 500mm PRT-17257
Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
SparkFun Qwiic OLED Display (0.91 in., 128x32) LCD-24606
In this section, we will highlight the hardware and pins that are broken out on the SparkFun Qwiic OLED Display (0.91 in., 128x32).
Top View Bottom View"},{"location":"single_page/#oled-display-091-128x32","title":"OLED Display (0.91\", 128x32)","text":"The OLED screen has a pixel resolution of 128x32, a panel size of 30.0mm x 11.5mm x 1.2mm, and an active area of 22.384mm x 5.584mm. The driver chip is the SSD1306. For information can be found in the datasheet linked in the Resources.
OLED HighlightedNote
The SparkFun Qwiic OLED Arduino Library works for multiple displays. However, there are some caveats in the size of the display with the text. While you can technically display all fonts in the narrow OLED display, some characters (numbers, letters, and/or symbols depending on the font) will be too big to fully display on the screen. For example, the fonts for the 31x48 (i.e. &QW_FONT_31X48) and large numbers (i.e. &QW_FONT_LARGENUM) are too big to fit within the display.
Using the OLED display (0.91\", 128x32) we found that we were able to fit:
&QW_FONT_5X7)&QW_FONT_8X16)&QW_FONT_7SEGMENT)Power is applied through the vertical Qwiic connectors on the back of the board. The recommended input voltage is 3.3V. The logic levels for the Qwiic OLED Display (0.9\", 128x32) is 3.3V.
Power"},{"location":"single_page/#qwiic-and-i2c","title":"Qwiic and I2C","text":"There are two vertical Qwiic connectors populated on the back of the board. You can use either connectors to provide power and send data through I2C. The Qwiic ecosystem is made for fast prototyping by removing the need for soldering. All you need to do is plug a Qwiic cable into the Qwiic connector and voila!
The address of the display is 0x3C.
Note
On the back of the board, the power and I2C pins are broken out to test points. These are used in our production department for quality control using custom testbeds. These could be an alternative option to connect to the pins. However, we recommend using the Qwiic connectors to easily connect to the OLED display. Note that the I2C pins are also in a different order compared to a standard I2C Qwiic connector should you decide to solder to the test points.
I2C Test Points
"},{"location":"single_page/#jumpers_1","title":"Jumpers","text":"Note
If this is your first time working with jumpers, check out the How to Work with Jumper Pads and PCB Traces tutorial for more information.
The board includes a 1x3 jumper on the back of the board.
Version 1.1 is a bit smaller than previous versions since the board includes vertical Qwiic connectors on the back of the board. The overall board size is 1.75 in x 0.5 in. The mounting holes have also moved to toward the top of the board.
Board Dimensions"},{"location":"single_page/#hardware-hookup_1","title":"Hardware Hookup","text":"In this section, we'll go over how to connect to the display. We will go just a bit further and talk about how to mount the display.
"},{"location":"single_page/#connecting-via-qwiic-connector","title":"Connecting via Qwiic Connector","text":"Insert a Qwiic cable between your chosen microcontroller and Qwiic OLED. Then insert a USB cable between the microcontroller and your computer's COM port. For the scope of this tutorial, the USB cable provides power and allows us to upload code to the microcontroller. Of course, you can also debug the display by opening a Serial Terminal.
USB Cable, RedBoard Plus (ATMega328P), Qwiic Cable, Qwiic OLED (0.9 in., 12x32)Once you have finished prototyping, you could continue to use the USB cable and add a 5V power supply or battery pack.
"},{"location":"single_page/#mounting-the-qwiic-oled-09-128x32","title":"Mounting the Qwiic OLED (0.9\", 128x32)","text":"Grab the board dimensions and cut out a rectangle in the enclosure. For users that want to mount the board so that the OLED display is flush against the enclosure, you will need to look at the dimensions based on the OLED. You will need to add a little tolerance so that the display can fit through the rectangle. For users that need to quickly mount the board, you will could also cut out rectangles based on the vertical Qwiic connector so that the wires can lead into the enclosure. Then cut out the mounting holes so that the board is right side up. In this case, we used a cardboard box as a quick example to demonstrate the Qwiic wires connecting leading into the enclosure.
Qwiic OLED Display Mounted in an EnclosureNote
To easily display text and graphics on the board, we recommend mounting the board right side up. There is an option in the example code to flip the text horizontally and vertically should you decide to mount the board upside down, but you would need to also determine the position of the text.
For a more durable enclosure, you could use wood, metal, or plastic. However, you will need additional tools to cut into the material.
"},{"location":"single_page/#software_2","title":"Software","text":"The Qwiic OLED (0.91\", 128x32) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED Library's Software Setup has instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
SparkFun Qwiic OLED Library API Reference Guide"},{"location":"single_page/#resources_2","title":"Resources","text":"Now that you've successfully got your OLED Display (0.9\", 128x36) up and running, it's time to incorporate it into your own project! For more information, check out the resources below:
The Qwiic OLED 1.3in has its own hook-up guide.
"},{"location":"single_page/#software-setup","title":"Software Setup","text":""},{"location":"single_page/#software-setup_1","title":"Software Setup","text":""},{"location":"single_page/#installation","title":"Installation","text":"Arduino
This guide assumes you are using the latest version of the Arduino IDE on your desktop. The following resources available at SparkFun provide the details on setting up and configuring Arduino to use this library.
The SparkFun Qwiic OLED Arduino Library is available within in the Arduino library manager, which is launched via the Sketch > Include Libraries > Manage Libraries \u2026 menu option in the Arduino IDE. Just search for SparkFun Qwiic OLED Library.
Note
If you've never connected a USB-to-serial converter to your computer before, you may need to install drivers. The drivers will depend on what is populated on your Arduino development board. Check out the following tutorials for help with the installation.
After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) QwiicTransparentOLED SparkFun Transparent Graphical OLED Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) For this example, the Qwiic Micro OLED is used.
QwiicMicroOLED myOLED;\n In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
int width, height; // global variables for use in the sketch\nvoid setup()\n{\n Serial.begin(115200);\n if(!myOLED.begin()){\n Serial.println(\"Device failed to initialize\");\n while(1); // halt execution\n }\n Serial.println(\"Device is initialized\");\n\n}\n Now that the library is initialized, the desired graphics are drawn. Here we erase the screen and draw simple series of lines that originate at the screen origin and fan out across the height of the display.
Note
Graphics are not send to the OLED device when drawn. Updates are only sent to the device when the display() method is called. This minimizes data transfers to the OLED device, delivering a responsive display response.
myOLED.erase(); // Erase the screen\n myOLED.display(); // Send erase to device\n\n delay(1000); // Slight pause\n\n // Draw our lines from point (0,0) to (i, screen height)\n\n for(int i=0; i < width; i+= 6){\n myOLED.line(0, 0, i, height-1); // draw the line\n myOLED.display(); // Send the new line to the device for display\n }\n"},{"location":"single_page/#library-provided-examples","title":"Library Provided Examples","text":"The SparkFun Qwiic OLED Arduino Library, includes a wide variety of examples. These are available from the Examples menu of the Arduino IDE, and in the examplesfolder of this repository.
For a detailed description of the examples, see the Examples section of the documentation.
"},{"location":"single_page/#api-reference","title":"API Reference","text":""},{"location":"single_page/#device","title":"Device","text":""},{"location":"single_page/#device-operations","title":"Device Operations","text":"Methods to setup the device, get device information and change display options.
"},{"location":"single_page/#initialization","title":"Initialization","text":""},{"location":"single_page/#begin","title":"begin()","text":"This method is called to initialize the OLED library and connection to the OLED device. This method must be called before calling any graphics methods.
bool begin(TwoWire &wirePort, uint8_t address)\n Parameter Type Description wirePort TwoWire optional. The Wire port. If not provided, the default port is used address uint8_t optional. I2C Address. If not provided, the default address is used. return value bool true on success, false on startup failure"},{"location":"single_page/#reset","title":"reset()","text":"When called, this method reset the library state and OLED device to their intial state. Helpful to reset the OLED after waking up a system from a sleep state.
void reset()\n Parameter Type Description return value bool true on success, false on startup failure"},{"location":"single_page/#geometry","title":"Geometry","text":""},{"location":"single_page/#getwidth","title":"getWidth()","text":"This method returns the width, in pixels, of the connected OLED device
uint8_t getWidth(void)\n Parameter Type Description return value uint8_t The width in pixels of the connected OLED device"},{"location":"single_page/#getheight","title":"getHeight()","text":"This method returns the height, in pixels, of the connected OLED device
uint8_t getHeight(void)\n Parameter Type Description return value uint8_t The height in pixels of the connected OLED device"},{"location":"single_page/#display-modes","title":"Display Modes","text":""},{"location":"single_page/#invert","title":"invert()","text":"This method inverts the current graphics on the display. This results of this command happen immediatly.
void invert(bool bInvert)\n Parameter Type Description bInvert bool true - the screen is inverted. false - the screen is set to normal"},{"location":"single_page/#flipvertical","title":"flipVertical()","text":"When called, the screen contents are flipped vertically if the flip parameter is true, or restored to normal display if the flip parameter is false.
void flipVertical(bool bFlip)\n Parameter Type Description bFlip bool true - the screen is flipped vertically. false - the screen is set to normal"},{"location":"single_page/#fliphorizontal","title":"flipHorizontal()","text":"When called, the screen contents are flipped horizontally if the flip parameter is true, or restored to normal display if the flip parameter is false.
void flipHorizontal(bool bFlip)\n Parameter Type Description bFlip bool true - the screen is flipped horizontally. false - the screen is set to normal"},{"location":"single_page/#displaypower","title":"displayPower()","text":"Used to turn the OLED display on or off.
void displayPower(bool bEnable)\n Parameter Type Description bEnable bool true - the OLED display is powered on (default). false - the OLED dsiplay is powered off."},{"location":"single_page/#scrolling","title":"Scrolling","text":""},{"location":"single_page/#scrolling_1","title":"Scrolling","text":"Methods for device scrolling
"},{"location":"single_page/#scrollstop","title":"scrollStop()","text":"If the device is in a scrolling mode, calling this method stops the scroll, and restores the device to normal display operation. This action is performed immediately.
void scrollStop(void)\n Parameter Type Description NONE"},{"location":"single_page/#scrollright","title":"scrollRight()","text":"This method is called to start the device scrolling the displayed graphics to the right. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrollRight(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed below Defined values for the interval parameter:
SCROLL_INTERVAL_2_FRAMES 2 SCROLL_INTERVAL_3_FRAMES 3 SCROLL_INTERVAL_4_FRAMES 4 SCROLL_INTERVAL_5_FRAMES 5 SCROLL_INTERVAL_25_FRAMES 25 SCROLL_INTERVAL_64_FRAMES 64 SCROLL_INTERVAL_128_FRAMES 128 SCROLL_INTERVAL_256_FRAMES 256"},{"location":"single_page/#scrollvertright","title":"scrollVertRight()","text":"This method is called to start the device scrolling the displayed graphics vertically and to the right. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrolVertlRight(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"single_page/#scrollleft","title":"scrollLeft()","text":"This method is called start to the device scrolling the displayed graphics to the left. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrollLeft(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"single_page/#scrollvertleft","title":"scrollVertLeft()","text":"This method is called to start the device scrolling the displayed graphics vertically and to the left. This action is performed immediately.
The screen will scroll until the scrollStop() method is called.
void scrolVertlLeft(uint8_t start, uint8_t stop, uint8_t interval)\n Parameter Type Description start uint8_t The start page address of the scroll - valid values are 0 thru 7 stop uint8_t The stop/end page address of the scroll - valid values are 0 thru 7 interval uint8_t The time interval between scroll step - values listed in scrollRight"},{"location":"single_page/#drawing-state","title":"Drawing State","text":""},{"location":"single_page/#drawing-settingsstate","title":"Drawing Settings/State","text":"Methods for setting the drawing state of the library.
"},{"location":"single_page/#setfont","title":"setFont()","text":"This method is called to set the current font in the library. The current font is used when calling the text() method on this device.
The default font for the device is 5x7.
void setFont(QwiicFont& theFont)\nvoid setFont(const QwiicFont * theFont)\n Parameter Type Description theFont QwiicFont The font to set as current in the device theFont QwiicFont* Pointer to the font to set as current in the device. For the library, fonts are added to your program by including them via include files which are part of this library.
The following fonts are included:
Font Include File Font Variable Description 5x7<res/qw_fnt_5x7.h> QW_FONT_5X7 A full, 5 x 7 font 31x48 <res/qw_fnt_31x48.h> QW_FONT_31X48 A full, 31 x 48 font Seven Segment <res/qw_fnt_7segment.h> QW_FONT_7SEGMENT Numbers only 8x16 <res/qw_fnt_8x16.h> QW_FONT_8X16 A full, 8 x 16 font Large Numbers <res/qw_fnt_largenum.h> QW_FONT_LARGENUM Numbers only For each font, the font variables are objects with the following attributes:
Attribute Valuewidth The font width in pixels height The font height in pixels start The font start character offset n_chars The number of characters map_width The width of the font map Example use of a font object attribute:
#include <res/qw_fnt_31x48.h>\n\nint myFontWidth = QW_FONT_31X48.width;\n"},{"location":"single_page/#getfont","title":"getFont()","text":"This method returns the current font for the device.
QwiicFont * getFont(void)\n Parameter Type Description return value QwiicFont* A pointer to the current font. See setFont() for font object details."},{"location":"single_page/#getfontname","title":"getFontName()","text":"This method returns the height in pixels of a provided String based on the current device font.
String getFontName(void)\n Parameter Type Description return value String The name of the current font."},{"location":"single_page/#getstringwidth","title":"getStringWidth()","text":"This method returns the width in pixels of a provided String based on the current device font.
unsigned int getStringWidth(String text)\n Parameter Type Description text String The string used to determine width return value unsigned int The width of the provide string, as determined using the current font."},{"location":"single_page/#getstringheight","title":"getStringHeight()","text":"This method returns the height in pixels of a provided String based on the current device font.
unsigned int getStringHeight(String text)\n Parameter Type Description text String The string used to determine height return value unsigned int The height of the provide string, as determined using the current font."},{"location":"single_page/#setdrawmode","title":"setDrawMode()","text":"This method sets the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
void setDrawMode(grRasterOp_t rop)\n Parameter Type Description rop grRasterOp_t The raster operation (ROP) to set the graphics system to. Raster operations device how source (pixels to draw) are represented on the destination device. The available Raster Operation (ROP) codes are:
ROP Code Description grROPCopy default Drawn pixel values are copied to the device screen grROPNotCopy A not operation is applied to the source value before copying to screen grROPNot A not operation is applied to the destination (screen) value grROPXOR A XOR operation is performed between the source and destination values grROPBlack A value of 0, or black is drawn to the destination grROPWhite A value of 1, or black is drawn to the destination"},{"location":"single_page/#getdrawmode","title":"getDrawMode()","text":"This method returns the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
grRasterOp_t getDrawMode(void)\n Parameter Type Description return value grRasterOp_t The current aster operation (ROP) of the graphics system."},{"location":"single_page/#graphics","title":"Graphics","text":""},{"location":"single_page/#graphics-methods","title":"Graphics Methods","text":"Methods used to draw and display graphics.
"},{"location":"single_page/#display","title":"display()","text":"When called, any pending display updates are sent to the connected OLED device. This includes drawn graphics and erase commands.
void display(void)\n Parameter Type Description NONE"},{"location":"single_page/#erase","title":"erase()","text":"Erases all graphics on the device, placing the display in a blank state. The erase update isn't sent to the device until the next display() call on the device.
void erase(void)\n Parameter Type Description NONE"},{"location":"single_page/#pixel","title":"pixel()","text":"Set the value of a pixel on the screen.
void pixel(uint8_t x, uint8_t y, uint8_t clr)\n Parameter Type Description x uint8_t The X coordinate of the pixel to set y uint8_t The Y coordinate of the pixel to set clr uint8_t optional The color value to set the pixel. This defaults to white (1)."},{"location":"single_page/#line","title":"line()","text":"Draw a line on the screen.
Note: If a line is horizontal (y0 = y1) or vertical (x0 = x1), optimized draw algorithms are used by the library.
void line(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the line y0 uint8_t The start Y coordinate of the line x1 uint8_t The end X coordinate of the line y1 uint8_t The end Y coordinate of the line clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"single_page/#rectangle","title":"rectangle()","text":"Draw a rectangle on the screen.
void rectangle(uint8_t x0, uint8_t y0, uint8_t width, uint8_t height, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the rectangle - upper left corner y0 uint8_t The start Y coordinate of the rectangle - upper left corner width uint8_t The width of the rectangle height uint8_t The height of the rectangle clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"single_page/#rectanglefill","title":"rectangleFill()","text":"Draw a filled rectangle on the screen.
void rectangleFill(uint8_t x0, uint8_t y0, uint8_t width, uint8_t height, uint8_t clr)\n Parameter Type Description x0 uint8_t The start X coordinate of the rectangle - upper left corner y0 uint8_t The start Y coordinate of the rectangle - upper left corner width uint8_t The width of the rectangle height uint8_t The height of the rectangle clr uint8_t optional The color value to draw the line. This defaults to white (1)."},{"location":"single_page/#circle","title":"circle()","text":"Draw a circle on the screen.
void circle(uint8_t x0, uint8_t y0, uint8_t radius, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate of the circle center y0 uint8_t The Y coordinate of the circle center radius uint8_t The radius of the circle clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"single_page/#circlefill","title":"circleFill()","text":"Draw a filled circle on the screen.
void circleFill(uint8_t x0, uint8_t y0, uint8_t radius, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate of the circle center y0 uint8_t The Y coordinate of the circle center radius uint8_t The radius of the circle clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"single_page/#bitmap","title":"bitmap()","text":"Draws a bitmap on the screen.
The bitmap should be 8 bit encoded - each pixel contains 8 y values.
void bitmap(uint8_t x0, uint8_t y0, uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner pBitmap uint8_t * A pointer to the bitmap array bmp_width uint8_t The width of the bitmap bmp_height uint8_t The height of the bitmap"},{"location":"single_page/#bitmap_1","title":"bitmap()","text":"Draws a bitmap on the screen.
The bitmap should be 8 bit encoded - each pixel contains 8 y values.
The coordinate [x1,y1] allows for only a portion of bitmap to be drawn.
void bitmap(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1, \n uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner x1 uint8_t The end X coordinate of the bitmap - lower right corner y1 uint8_t The end Y coordinate of the bitmap - lower right corner pBitmap uint8_t * A pointer to the bitmap array bmp_width uint8_t The width of the bitmap bmp_height uint8_t The height of the bitmap"},{"location":"single_page/#bitmap_2","title":"bitmap()","text":"Draws a bitmap on the screen using a Bitmap object for the bitmap data.
void bitmap(uint8_t x0, uint8_t y0, QwiicBitmap& bitmap)\n Parameter Type Description x0 uint8_t The X coordinate to place the bitmap - upper left corner y0 uint8_t The Y coordinate to place the bitmap - upper left corner Bitmap QwiicBitmap A bitmap object"},{"location":"single_page/#text","title":"text()","text":"Draws a string using the current font on the screen.
void text(uint8_t x0, uint8_t y0, const char * text, uint8_t clr)\n Parameter Type Description x0 uint8_t The X coordinate to start drawing the text y0 uint8_t The Y coordinate to start drawing the text text const char* The string to draw on the screen text String The Arduino string to draw on the screen clr uint8_t optional The color value to draw the circle. This defaults to white (1)."},{"location":"single_page/#arduino-print","title":"Arduino Print","text":""},{"location":"single_page/#arduino-print_1","title":"Arduino Print","text":"Methods used to support Arduino Print functionality.
"},{"location":"single_page/#setcursor","title":"setCursor()","text":"This method is called set the \"cursor\" position in the device. The library supports the Arduino Print interface, enabling the use of a print() and println() methods. The set cursor position defines where to start text output for this functionality.
void setCursor(uint8_t x, uint8_t y)\n Parameter Type Description x uint8_t The X coordinate of the cursor y uint8_t The Y coordinate of the cursor"},{"location":"single_page/#setcolor","title":"setColor()","text":"This method is called to set the current color of the system. This is used by the Arduino Print interface functionality
void setColor(uint8_t clr)\n Parameter Type Description clr uint8_t The color to set. 0 = black, > 0 = white"},{"location":"single_page/#getcolor","title":"getColor()","text":"This method is called to get the current color of the system. This is used by the Arduino Print interface functionality
uint8_t getColor(void)\n Parameter Type Description return value uint8_t The current color"},{"location":"single_page/#arduino-examples","title":"Arduino Examples","text":""},{"location":"single_page/#example-1-hello","title":"Example 1 - Hello","text":"--8<-- \"./docs/ex_01_hello.md
"},{"location":"single_page/#example-2-shapes","title":"Example 2 - Shapes","text":"--8<-- \"./docs/ex_02_lines.md
"},{"location":"single_page/#example-3-bitmaps","title":"Example 3 - Bitmaps","text":"--8<-- \"./docs/ex_03_bitmaps.md
"},{"location":"single_page/#example-4-text","title":"Example 4 - Text","text":"--8<-- \"./docs/ex_04_text.md
"},{"location":"single_page/#other-examples","title":"Other Examples","text":"--8<-- \"./docs/ex_other.md
"},{"location":"single_page/#troubleshooting","title":"Troubleshooting","text":""},{"location":"single_page/#general-troubleshooting-help","title":"General Troubleshooting Help","text":"Note
Not working as expected and need help?
If you need technical assistance and more information on a product that is not working as you expected, we recommend heading on over to the SparkFun Technical Assistance page for some initial troubleshooting.
SparkFun Technical Assistance Page
If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.
Create New Forum Account Log Into SparkFun Forums
"},{"location":"software/","title":"Software Setup","text":""},{"location":"software/#installation","title":"Installation","text":"Arduino
This guide assumes you are using the latest version of the Arduino IDE on your desktop. The following resources available at SparkFun provide the details on setting up and configuring Arduino to use this library.
The SparkFun Qwiic OLED Arduino Library is available within in the Arduino library manager, which is launched via the Sketch > Include Libraries > Manage Libraries \u2026 menu option in the Arduino IDE. Just search for SparkFun Qwiic OLED Library.
Note
If you've never connected a USB-to-serial converter to your computer before, you may need to install drivers. The drivers will depend on what is populated on your Arduino development board. Check out the following tutorials for help with the installation.
After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) QwiicTransparentOLED SparkFun Transparent Graphical OLED Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) For this example, the Qwiic Micro OLED is used.
QwiicMicroOLED myOLED;\n In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
int width, height; // global variables for use in the sketch\nvoid setup()\n{\n Serial.begin(115200);\n if(!myOLED.begin()){\n Serial.println(\"Device failed to initialize\");\n while(1); // halt execution\n }\n Serial.println(\"Device is initialized\");\n\n}\n Now that the library is initialized, the desired graphics are drawn. Here we erase the screen and draw simple series of lines that originate at the screen origin and fan out across the height of the display.
Note
Graphics are not send to the OLED device when drawn. Updates are only sent to the device when the display() method is called. This minimizes data transfers to the OLED device, delivering a responsive display response.
myOLED.erase(); // Erase the screen\n myOLED.display(); // Send erase to device\n\n delay(1000); // Slight pause\n\n // Draw our lines from point (0,0) to (i, screen height)\n\n for(int i=0; i < width; i+= 6){\n myOLED.line(0, 0, i, height-1); // draw the line\n myOLED.display(); // Send the new line to the device for display\n }\n"},{"location":"software/#library-provided-examples","title":"Library Provided Examples","text":"The SparkFun Qwiic OLED Arduino Library, includes a wide variety of examples. These are available from the Examples menu of the Arduino IDE, and in the examplesfolder of this repository.
For a detailed description of the examples, see the Examples section of the documentation.
"},{"location":"troubleshooting/","title":"Troubleshooting","text":""},{"location":"troubleshooting/#general-troubleshooting-help","title":"General Troubleshooting Help","text":"Note
Not working as expected and need help?
If you need technical assistance and more information on a product that is not working as you expected, we recommend heading on over to the SparkFun Technical Assistance page for some initial troubleshooting.
SparkFun Technical Assistance Page
If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.
Create New Forum Account Log Into SparkFun Forums
"},{"location":"github/contribute/","title":"Contribute: Help Fix our Mistake!","text":"Spot something wrong? Feel free to contribute our open-source design and documentation.
"},{"location":"github/contribute/#improve-our-documentation","title":"Improve our Documentation","text":"All of this documentation can be modified by you! Please help us make it better.
docs folder of the SparkFun Qwiic OLED Arduino Library repository.All of our designs are open-source! Please help us make it better.
Our board design files are contained in the Hardware folder of their respective repositories:
SparkFun Micro OLED Breakout (Qwiic)
Let's provided some recognition to the contributors for this project!
"},{"location":"github/file_issue/","title":"Did we make a mistake?","text":"
Spot something wrong? Please let us know.
Attention
This is not where customers should seek assistance on a product. If you require technical assistance or have questions about a product that is not working as expected, please head over to the SparkFun Technical Assistance page for some initial troubleshooting. SparkFun Technical Assistance Page
If you can't find what you need there, you'll need a Forum Account to search product forums and post questions.
"},{"location":"github/file_issue/#discrepancies-in-the-documentation","title":"Discrepancies in the Documentation","text":"All of this documentation can be modified by you! Please help us make it better.
docs folder of the SparkFun Qwiic OLED Arduino Library repository.If a section of the documentation is incorrect, please open an issue and let us know.
"},{"location":"github/file_issue/#do-you-have-a-suggested-correction","title":"Do you have a suggested correction?","text":"All of our designs are open-source! Please help us make it better.
Our board design files are contained in the Hardware folder of their respective repositories:
If part of the design is confusing, please open an issue and let us know.
"},{"location":"github/file_issue/#did-we-forget-to-include-an-important-function-of-the-board","title":"Did we forget to include an important function of the board?","text":"This folder should contain the files for the custom javascript that is enabled in the product documentation
"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/","title":"Example 1 - Hello","text":"A simple example to show the basic setup and use of the SparkFun Qwiic OLED Library.
Key Demo Features
After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun Qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun Qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicTransparentOLED SparkFun Transparent Graphical OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) The example code supports all of the SparkFun Qwiic OLED boards. By default, the Qwiic Micro OLED is selected. To select a different board being used, add a single line comment (i.e. //) in front of \"QwiicMicroOLED myOLED;\" and uncomment the device being used for the demo board.
QwiicMicroOLED myOLED;\n//QwiicTransparentOLED myOLED;\n//QwiicNarrowOLED myOLED;\n//Qwiic1in3OLED myOLED;\n Note
As of version 1.0.2+, users will need to use the class as explained above instead of using a #define.
#define MICRO\n//#define NARROW\n//#define TRANSPARENT\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/#initialization","title":"Initialization","text":"In the setup() function of this sketch, like all of the SparkFun Qwiic Arduino libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()\n{\n\n delay(500); //Give display time to power on\n\n // Serial on!\n Serial.begin(115200);\n\n Serial.println(\"\\n\\r-----------------------------------\");\n\n Serial.print(\"Running Example 01 on: \");\n Serial.println(String(deviceName));\n\n // Initalize the OLED device and related graphics system\n if(!myOLED.begin()){\n\n Serial.println(\" - Device Begin Failed\");\n while(1);\n }\n\n Serial.println(\"- Begin Success\");\n\n // Do a simple test - fill a rectangle on the screen and then print hello!...\n\n}\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/#drawing-graphics","title":"Drawing Graphics","text":"Once the device is enabled, the rest of the setup() function is devoted to drawing a simple graphic on the target device.
First, draw a filled rectangle on the screen - leave a 4 pixel boarder at the end of the screen. Note that the getWidth() and getHeight() method are used to get the devices screen size.
// Fill a rectangle on the screen that has a 4 pixel board\n myOLED.rectangleFill(4, 4, myOLED.getWidth() - 8, myOLED.getHeight() - 8);\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/#centered-text","title":"Centered Text","text":"The next part of our graphic is a message centered in the drawn rectangle. To do the centering, the current font is accessed from the device, and the size of a character in the font is used to calculate the text position on the screen. Once the position is determined, the message is drawn on the display in black (0 for a color value).
String hello = \"hello\"; // our message\n\n // Center our message on the screen. Get the screen size of the \"hello\" string,\n // calling the getStringWidth() and getStringHeight() methods on the oled\n\n // starting x position - screen width minus string width / 2\n int x0 = (myOLED.getWidth() - myOLED.getStringWidth(hello)) / 2;\n\n // starting y position - screen height minus string height / 2\n int y0 = (myOLED.getHeight() - myOLED.getStringHeight(hello)) / 2;\n\n // Draw the text - color of black (0)\n myOLED.text(x0, y0, hello, 0);\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/#displaying-the-graphics","title":"Displaying the Graphics","text":"The last step is sending the graphics to the device. This is accomplished by calling the display() method.
// There's nothing on the screen yet - Now send the graphics to the device\n myOLED.display();\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_01_hello/#what-you-should-see","title":"What You Should See","text":"And that's it! Select the board and COM port for your development board. Then upload the code! The graphic should display on the OLED device.
"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_02_lines/","title":"Example 2 - Shapes","text":"An example that shows drawing simple shapes using the SparkFun Qwiic OLED Library.
Key Demo Features
After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun Qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun Qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicTransparentOLED SparkFun Transparent Graphical OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) The example code supports all of the SparkFun Qwiic OLED boards. By default, the Qwiic Micro OLED is selected. To select a different board being used, add a single line comment (i.e. //) in front of \"QwiicMicroOLED myOLED;\" and uncomment the device being used for the demo board.
QwiicMicroOLED myOLED;\n//QwiicTransparentOLED myOLED;\n//QwiicNarrowOLED myOLED;\n//Qwiic1in3OLED myOLED;\n Note
As of version 1.0.2+, users will need to use the class as explained above instead of using a #define.
#define MICRO\n//#define NARROW\n//#define TRANSPARENT\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_02_lines/#drawing-shapes","title":"Drawing Shapes","text":"Note
As of version 1.0.2+, the modular functions have a slightly different name. Some functions defined in the example code will have the _ removed or words spelled out. For example, version v1.0.1 and below defined the function to test the line as line_test_1() while version v1.0.2+ defined the function as lineTest1().
The shapes drawn are broken into a set of functions that perform one test, which is part of the overall example.
"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_02_lines/#lines","title":"Lines","text":"This test starts with a short, horizontal line that is animated from the top to bottom of the display. After each iteration, the line size is increased and the animating sequence repeated.
To animate the line, the display is erased, then the line drawn. Once the line is draw, the updated graphics is sent to the OLED device by calling the display() method.
Note
When display() is called, only the range of modified pixels is sent to the OLED device, greatly reducing the data transferred for small graphic changes.
This is demonstrated by this test. When small lines are drawn, the update rate is fast, but as the line length increases, the update rate of the device is noticeably slower. A longer line requires more data to be sent to the device.
void lineTest1(void)\n{\n int x, y, i;\n\n int mid = width / 2;\n int delta = mid / 8;\n\n for (int j = 1; j < 8; j++)\n {\n\n x = delta * j;\n\n for (i = 0; i < height * 2; i++)\n {\n\n y = i % height;\n myOLED.erase();\n myOLED.line(mid - x, y, mid + x, y);\n myOLED.display();\n }\n }\n}\n This test is followed up with a series of lines that span from a single point to the bottom of the screen, showing the flexibility of the line to raster algorithm used by the library.
void lineTest2(void)\n{\n for (int i = 0; i < width; i += 6)\n {\n myOLED.line(0, 0, i, height - 1);\n myOLED.display();\n }\n delay(200);\n myOLED.erase();\n for (int i = width - 1; i >= 0; i -= 6)\n {\n myOLED.line(width - 1, 0, i, height - 1);\n myOLED.display();\n }\n}\n And the last line test draws a series of lines to test all three internal line drawing algorithms. Specifically:
The test animates to show a growing box, giving an idea of the speed and flexibility of the system.
void lineTestVerticalIterative(uint8_t y0, uint8_t y1)\n{\n for (int i = 0; i < width; i += 8)\n myOLED.line(i, y0, i, y1);\n\n // end off the vertical lines\n myOLED.line(width - 1, y0, width - 1, y1);\n\n // End lines and cross lines\n myOLED.line(0, y0, width - 1, y0);\n myOLED.line(0, y1, width - 1, y1);\n myOLED.line(0, y0, width - 1, y1);\n myOLED.line(0, y1, width - 1, y0);\n}\n\n// Entry point for test\nvoid lineTestVertical(void)\n{\n int mid = height / 2;\n\n for (int i = 0; i < height; i += 4)\n {\n\n myOLED.erase();\n lineTestVerticalIterative(mid - i / 2, mid + i / 2);\n myOLED.display();\n delay(10);\n }\n}\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_02_lines/#rectangles","title":"Rectangles","text":"Several rectangle routines are shown in this example. A key test is a fast drawing routine which animates a small rectangle being drawn diagonally across the screen.
In this test, the rectangle is drawn, sent to the device via using display(), then the rectangle is drawn again, but this time in black. This effectively erases the rectangle. The position is incremented and the process loops, causing the rectangle to appear to fly across the screen.
The animation is quick, since only the portions of the screen that need updated are actually updated.
The animation algorithm is listed in the `rectangleTestMove() function.
void rectangleTestMove(void)\n{\n float steps = height;\n float xinc = width / steps;\n float yinc = height / steps;\n int side = 10;\n float x = 0;\n float y = 0;\n\n for (int i = 0; i < steps; i++)\n {\n // Draw the rectangle and send it to device\n myOLED.rectangle(x, y, side, side);\n myOLED.display(); // sends erased rect and new rect pixels to device\n\n // Erase the that rect, increment and loop\n myOLED.rectangle(x, y, side, side, 0);\n\n x += xinc;\n y += yinc;\n }\n}\n The next rectangle test draws a series of filled rectangles on the screen. The unique aspect of this test is that is uses the XOR functionally to overlay a rectangle on the device, presenting a alternating color pattern.
The XOR raster operation is set by calling the setDrawMode() method on the OLED device, and providing the grROPXOR code. This switch the device into a XOR drawing mode. Graphic operations are restored to normal by calling setDrawMode() and providing the grROPCopy code, which copies the new pixel value to the destination.
Filled rectangles and XOR operations:
void rectangleFillTest(void)\n{\n myOLED.rectangleFill(4, 4, width / 2 - 8, height - 8);\n\n myOLED.rectangleFill(width / 2 + 4, 4, width / 2 - 8, height - 8);\n\n myOLED.setDrawMode(grROPXOR); // xor\n myOLED.rectangleFill(width / 4, 8, width / 2, height - 16);\n myOLED.setDrawMode(grROPCopy); // back to copy op (default)\n}\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_02_lines/#circles","title":"Circles","text":"The final shape drawn by this example is a series of circles and filled circles. Using the geometry of the screen, a set of circles are drawn and displayed.
void circleTest(void)\n{\n // Let's draw some circles that fit on the device\n myOLED.circle(width / 4, height / 2, height / 3);\n\n myOLED.circleFill(width - width / 4, height / 2, height / 3);\n\n myOLED.circle(4, height / 2, height / 3);\n\n myOLED.circleFill(width - width / 2, height / 2, height / 4);\n}\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_03_bitmaps/","title":"Example 3 - Bitmaps","text":"An example that shows drawing bitmaps using the SparkFun Qwiic OLED Library.
Key Demo Features
After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions. The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) QwiicTransparentOLED SparkFun Transparent Graphical OLED Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) The Example code supports all of the SparkFun Qwiic OLED boards. To select the board being used, uncomment the #define for the demo board.
For this example, the Qwiic Micro OLED is used.
#define MICRO\n//#define NARROW\n//#define TRANSPARENT\n Which results in myOLED being declared as: QwiicMicroOLED myOLED;\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_03_bitmaps/#initialization","title":"Initialization","text":"In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()\n{\n\n delay(500); //Give display time to power on\n\n // Serial on!\n Serial.begin(115200);\n\n Serial.println(\"\\n\\r-----------------------------------\");\n\n Serial.print(\"Running Example 01 on: \");\n Serial.println(String(deviceName));\n\n // Initalize the OLED device and related graphics system\n if(!myOLED.begin()){\n\n Serial.println(\" - Device Begin Failed\");\n while(1);\n }\n\n Serial.println(\"- Begin Success\");\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_03_bitmaps/#drawing-bitmaps","title":"Drawing Bitmaps","text":""},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_04_text/","title":"Example 4 - Text","text":"An example that shows drawing bitmaps using the SparkFun Qwiic OLED Library.
Key Demo Features
Print functionalityAfter installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
// Include the SparkFun qwiic OLED Library\n#include <SparkFun_Qwiic_OLED.h>\n The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions. The user selects from one of the following classes:
Class Qwiic OLED DeviceQwiicMicroOLED SparkFun Qwiic Micro OLED QwiicNarrowOLED SparkFun Qwiic OLED Display (128x32) QwiicTransparentOLED SparkFun Transparent Graphical OLED Qwiic1in3OLED SparkFun Qwiic OLED 1.3\" Display (128x32) The Example code supports all of the SparkFun Qwiic OLED boards. To select the board being used, uncomment the #define for the demo board.
For this example, the Qwiic Micro OLED is used.
#define MICRO\n//#define NARROW\n//#define TRANSPARENT\n Which results in myOLED being declared as: QwiicMicroOLED myOLED;\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_04_text/#initialization","title":"Initialization","text":"In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()\n{\n\n delay(500); //Give display time to power on\n\n // Serial on!\n Serial.begin(115200);\n\n Serial.println(\"\\n\\r-----------------------------------\");\n\n Serial.print(\"Running Example 01 on: \");\n Serial.println(String(deviceName));\n\n // Initalize the OLED device and related graphics system\n if(!myOLED.begin()){\n\n Serial.println(\" - Device Begin Failed\");\n while(1);\n }\n\n Serial.println(\"- Begin Success\");\n"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_04_text/#drawing-text","title":"Drawing Text","text":""},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_other/","title":"Other Examples","text":"Descriptions of the other demos that are provided as part of the SparkFun Qwiic OLED Library.
"},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_other/#scroll-flip","title":"Scroll-Flip","text":""},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_other/#clock","title":"Clock","text":""},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_other/#cube","title":"Cube","text":""},{"location":"sparkfun-qwiic-oled-arduino-library-examples/ex_other/#multi","title":"Multi","text":""}]} \ No newline at end of file diff --git a/single_page/index.html b/single_page/index.html new file mode 100644 index 0000000..207aa9f --- /dev/null +++ b/single_page/index.html @@ -0,0 +1,5637 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
The SparkFun Qwiic OLED Arduino Library is a single graphics module that supports all SparkFun OLED boards based on the SSD1306 from Solomon Systech. Prior to this library, three different libraries were used to support our four different OLED boards.
+The SparkFun Qwiic OLED Library delivers a common implementation for all our Qwiic OLED products, delivering a unified, fast, and efficient solution that implements a familiar and easy to understand user experience.
+The Software Setup outlines library installation and the general use of the Qwiic OLED library.
+Detailed examples are included as part of the library installation process and available in the Arduino IDE menu: File > Examples > SparkFun Qwiic OLED Arduino Library. A walk-thru of key examples is contained in the Examples section of this documentation set.
+Note
+For v1.0.5 of the SparkFun Qwiic OLED Arduino Library, we named the library as SparkFun Qwiic OLED Graphics Library. After v1.0.6, we updated the name to say SparkFun Qwiic OLED Arduino Library. You may have multiple versions in your Arduino libraries folder if you installed the library more than once. To avoid confusion, issues compiling, and to use the latest version, we recommend removing the "SparkFun Qwiic OLED Graphics Library" folder should you decide to use the latest and greatest version. This will probably be located under ..Documents\Arduino\libraries, that is if you are using Windows.
+Note
+Note that we have more than one Arduino Library for the micro OLED. If you have the older Arduino Library, make sure to not confuse the two libraries. You will notice that the older library will be called "SparkFun Micro OLED Breakout". The example code will include the following line of code: #include <SFE_MicroOLED.h>.
A full API Reference is also provided for the library.
+ + +The SparkFun Qwiic OLED Arduino Library supports the following SparkFun products.
+The following architectures are supported in the Arduino Library.
+ +Below are a few of those processors populated on Arduino boards from the SparkFun catalog. You will need to make sure to check the associated hookup guides for additional information about compatible cables, drivers, or board add-ons.
+Note
+Unfortunately, the ATmega32U4 is not supported under this library. We recommend either using a different microcontroller or rolling back to the previous library written for the display.
+The SparkFun Qwiic OLED Arduino Library is licensed using the Open Source MIT License:
+The MIT License (MIT)
+
+Copyright (c) 2015 SparkFun Electronics
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
+The Qwiic Micro OLED is a Qwiic enabled version of our micro OLED display! This small monochrome, blue-on-black OLED display displays incredibly clear images.
+This hookup guide will show you how to get started drawing objects and characters on your OLED.
+To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
+To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
+ +Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
+ +If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
+ +You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
+ +Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
+If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
+| + + | +
| + |
We would also recommend taking a look at the following tutorials if you aren't familiar with them.
+ +Listed below are some of the operating ranges and characteristics of the Qwiic Micro OLED.
+| Characteristic + | +Range + | +
|---|---|
| Voltage + | +3.3V + | +
| Temperature + | +-40°C to 85°C + | +
| I2C Address + | +0X3D (Default) or 0X3C (Closed Jumper) + | +
Power and I2C pins are broken out to the 1x4 PTH pins as well as the two horizontal Qwiic connectors.
+| Pin + | +Description + | +Direction + | +
|---|---|---|
| GND + | +Ground + | +In + | +
| 3.3V + | +Power + | +In + | +
| SDA + | +I2C Data + | +In + | +
| SCL + | +I2C Clock + | +In + | +
There are several jumpers on board that can be changed to facilitate several different functions. The first of which is the I2C pull-up jumper to disable the 2.2kΩ pull up resistors on the I2C data and clock lines, highlighted below. If multiple boards are connected to the I2C bus, the equivalent resistance goes down, increasing your pull up strength. If multiple boards are connected on the same bus, make sure only one board has the pull-up resistors connected.
+ + +The ADDR jumper (highlighted below) can be used to change the I2C address of the board. The default jumper is open by default, pulling the address pin high and giving us an I2C address of 0X3D. Closing this jumper will ground the address pin, giving us an I2C address of 0X3C.
+ + +Revision Change
+For V11, we have optimized the two mounting hole locations to match the mounting holes located on a standard 1.0" x 1.0" Qwiic-sized board. The overall functionality of the Qwiic Micro OLED breakout board is the same as the previous version!
+The overall board size is 1.08" x 1.17". There is a v-score for users that want to remove the mounting holes.
+ + +If you haven't yet assembled your Qwiic Shield, now would be the time to head on over to that tutorial. With the shield assembled, SparkFun's Qwiic environment means that connecting the screen could not be easier. Just plug one end of the Qwiic cable into the OLED display, the other into the Qwiic Shield and you'll be ready to start displaying images on your little display.
+ + +If you have a built-in Qwiic connector, you can skip the hardware assembly of the Qwiic Shield and simply insert a Qwiic cable between the two boards. Have more than one Qwiic-enabled device? You can daisy chain it to the board as well! Below is an example with the SAM-M8Q and the Qwiic Micro OLED daisy chained together to the RedBoard Qwiic.
+ + +Note
+The initial launch of the Qwiic micro OLED breakout board had the OLED loosely attached to the breakout board. For users that received those boards, be careful handling it! You can either use your own enclosure for the OLED display, or you can use some double sided foam tape for a less permanent solution.
+ +The current production of the boards includes the double sided foam tape.
+The SparkFun Micro OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
+ + +Now that you've successfully got your OLED displaying things, it's time to incorporate it into your own project!
+For more on the Qwiic Micro OLED, check out the links below:
+The future is here! You asked and we delivered - our Qwiic Transparent Graphical OLED Breakout allows you to display custom images on a transparent screen using either I2C or SPI connections.
+With Qwiic connectors it's quick (ha ha) and easy to get started with your own images. However, we still have broken out 0.1"-spaced pins in case you prefer to use a breadboard. Brilliantly lit in the dark and still visible by daylight, this OLED sports a display area of 128x64 pixels, 128x56 of which are completely transparent. Control of the OLED is based on the HyperDisplay library or SparkFun Qwiic OLED Arduino Library! For the scope of this tutorial, we will be using the SparkFun Qwiic OLED Arduino Library.
+This hookup guide will show you how to get started drawing objects and characters on your OLED.
+To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
+To get started, you'll need a microcontroller to, well, control everything. We used the SparkFun Thing Plus - ESP32 WROOOM. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
+ +Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
+ +If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
+ +You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
+ +Of course, you will also need A Tranparent Graphical OLED Breakout if you have not added that to you cart already.
+If you aren't familiar with the Qwiic Connection System, we recommend reading here for an overview.
+| + + | +
| + |
We would also recommend taking a look at the following tutorials if you aren't familiar with them.
+ +Listed below are some of the operating ranges and characteristics of the Transparent Graphical OLED Breakout.
+| Characteristic + | +Range + | +
|---|---|
| Voltage + | +1.65V-3.3V, typically 3.3V via the Qwiic Cable + |
+
| Supply Current + | +400 mA + | +
| I2C Address + | +0X3C (Default), 0X3D (Closed Jumper) + | +
The graphical display is where all the fun stuff happens. The glass itself measures 42mm x 27.16mm, with a pixel display that is 35.5 x 18mm. It houses 128x64 pixels, 128x56 of which are transparent.
+ + +There are two Qwiic connectors on the board such that you can daisy-chain the boards should you choose to do so. If you're unfamiliar with our Qwiic Connect System, head on over to our Qwiic page to see the advantages!
+ + +When you look at the GPIO pins, you'll notice that the labels are different from one side to the other. One side is labeled for I2C, the other side is labeled for SPI.
+ + +This bad boy will light up when the board is powered up correctly.
+ + +You can disable the power LED by cutting the LED jumpers on the back of the board.
+ + +The JPX jumpers are used to either change the I2C address or configure the board to use SPI communications. The other two jumpers allow you to disconnect the power LED and to disconnect the I2C pull-up resistors when chaining several Qwiic devices.
+| Jumper + | +Function + | +
|---|---|
| JP1 + | +Holds the Chip Select line low when closed. Close for I2C, open for SPI + | +
| JP2 + | +Selects the address in I2C mode. Closed for 0x30 by default and open for 0x31. Open for SPI mode to release the D/C pin + | +
| JP3 + | +Used to select I2C or SPI mode. Close for I2C, open for SPI + | +
| JP4 + | +This jumper should be closed for I2C and open for SPI. This connection allows SDA to be bi-directional + | +
I2C devices contain open drains so we include resistors on our boards to allow these devices to pull pins high. This becomes a problem if you have a large number of I2C devices chained together. If you plan to daisy chain more than a few Qwiic boards together, you'll need to cut this I2C pull-up jumper.
+ + +Now that you know what's available on your breakout board we can check out the options for connecting it to the brains of your project. There are two options to use - either I2C or SPI - and they each have their own advantages and drawbacks. Read on to choose the best option for your setup.
+Warning
+Reminder! This breakout can only handle up to 3.3V on the pins, so make sure to do some level shifting if you're using a 5V microcontroller.
+The easiest way to start using the Transparent Graphical OLED is to use a Qwiic Cable along with a Qwiic compatible microcontroller (such as the ESP32 Thing Plus). You can also use the Qwiic Breadboard Cable to attach any I2C capable microcontroller, or take the scenic route and solder in all the I2C wires to the plated-through connections on the board.
+ + +So why use I2C? It's easy to connect with the Qwiic system, and you can put up to two of the Transparent Graphical Breakouts on the same bus without using any more microcontroller pins. That simplicity comes at a cost to performance though. The maximum clock speed of the I2C bus is 400 kHz, and there is additional overhead in data transmission to indicate which bytes are data and which are commands. This means that the I2C connection is best for showing static images.
+| Breakout Pin + | +Microcontroller Pin Requirements + | +
|---|---|
| GND + | +Ground pin. Connect these so the two devices agree on voltages + | +
| 3V3 + | +3.3V supply pin, capable of up to 400 mA output + | +
| SDA + | +SDA - the bi-directional data line of your chosen I2C port + | +
| SCL + | +SCL - the clock line of your chosen I2C port + | +
| SA0 + | +Optional : change the I2C address of the breakout. Make sure to cut JP2 + | +
| RST + | +Optional : reset the breakout to a known state by pulsing this low + | +
SPI solves the I2C speed problems. With SPI there is a control signal that indicates data or command and the maximum clock speed is 10 MHz -- giving SPI 50x more speed! However, it doesn't have the same conveniences of the polarized Qwiic connector and low pin usage. You'll need to solder to the pins.
+ + +You can use SPI to connect as many breakouts as you want. For N displays you will need to use at least N + 3 data pins. That's because the MOSI, SCLK, and D/C pins can be shared between displays but each breakout needs its own dedicated Chip Select (CS) pin.
+| Breakout Pin + | +Microcontroller Pin Requirements + | +
|---|---|
| CS + | +A GPIO pin, set low when talking to the breakout + | +
| D/C + | +A GPIO pin, indicates if bytes are data or commands + | +
| SCLK + | +The clock output of your chosen SPI port + | +
| MOSI + | +The data output of your chosen SPI port + | +
| 3V3 + | +3.3V supply pin, capable of up to 400 mA output + | +
| GND + | +Ground pin. Connect these so the two devices agree on voltages + | +
Warning
+Make sure to cut jumpers JP1, JP2, JP3, and JP4 when using SPI mode!
+ +The Transparent OLED Breakout (Qwiic) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED library Getting Started guide has library setup instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
+ + +For more information on the Transparent Graphical OLED Breakout, check out some of the links here:
+ +The SparkFun Qwiic OLED Display can display up to four lines of text and features 128x32 pixels in a small 0.91” (diagonal) frame. As an OLED, this display does not have a back light layer (unlike LCDs) and therefore it’s thinner, consumes less power, and has higher contrast.
+In this section, we'll go over the hardware and how to hookup the breakout board.
+To follow along with this tutorial, you will need the following materials. You may not need everything though depending on what you have. Add it to your cart, read through the guide, and adjust the cart as necessary.
+To get started, you'll need a microcontroller to, well, control everything. We used the RedBoard with the ATmega328P for the Qwiic micro OLED. However, any of the other microcontrollers that are compatible with the Qwiic OLED Arduino Library will work as well. Below are a few from the list that we provided earlier.
+ +Below are a few USB cables from the SparkFun catalog. Make sure to grab the associated USB cable that is compatible with your microcontroller.
+ +If the controller you choose doesn't have a built-in Qwiic connector, one of the following Qwiic shields that matches your preference of microcontroller is needed:
+ +You will also need a Qwiic cable to connect the shield to your OLED, choose a length that suits your needs.
+ +Of course, you will also need a Qwiic Micro OLED if you have not added that to you cart already.
+In this section, we will highlight the hardware and pins that are broken out on the SparkFun Qwiic OLED Display (0.91 in., 128x32).
+ + +The OLED screen has a pixel resolution of 128x32, a panel size of 30.0mm x 11.5mm x 1.2mm, and an active area of 22.384mm x 5.584mm. The driver chip is the SSD1306. For information can be found in the datasheet linked in the Resources.
+ + +Note
+The SparkFun Qwiic OLED Arduino Library works for multiple displays. However, there are some caveats in the size of the display with the text. While you can technically display all fonts in the narrow OLED display, some characters (numbers, letters, and/or symbols depending on the font) will be too big to fully display on the screen. For example, the fonts for the 31x48 (i.e. &QW_FONT_31X48) and large numbers (i.e. &QW_FONT_LARGENUM) are too big to fit within the display.
Using the OLED display (0.91", 128x32) we found that we were able to fit:
+&QW_FONT_5X7)&QW_FONT_8X16)&QW_FONT_7SEGMENT)Power is applied through the vertical Qwiic connectors on the back of the board. The recommended input voltage is 3.3V. The logic levels for the Qwiic OLED Display (0.9", 128x32) is 3.3V.
+ + +There are two vertical Qwiic connectors populated on the back of the board. You can use either connectors to provide power and send data through I2C. The Qwiic ecosystem is made for fast prototyping by removing the need for soldering. All you need to do is plug a Qwiic cable into the Qwiic connector and voila!
+The address of the display is 0x3C.
+Note
+On the back of the board, the power and I2C pins are broken out to test points. These are used in our production department for quality control using custom testbeds. These could be an alternative option to connect to the pins. However, we recommend using the Qwiic connectors to easily connect to the OLED display. Note that the I2C pins are also in a different order compared to a standard I2C Qwiic connector should you decide to solder to the test points.
+ +Note
+If this is your first time working with jumpers, check out the How to Work with Jumper Pads and PCB Traces tutorial for more information.
+The board includes a 1x3 jumper on the back of the board.
+Version 1.1 is a bit smaller than previous versions since the board includes vertical Qwiic connectors on the back of the board. The overall board size is 1.75 in x 0.5 in. The mounting holes have also moved to toward the top of the board.
+ + +In this section, we'll go over how to connect to the display. We will go just a bit further and talk about how to mount the display.
+Insert a Qwiic cable between your chosen microcontroller and Qwiic OLED. Then insert a USB cable between the microcontroller and your computer's COM port. For the scope of this tutorial, the USB cable provides power and allows us to upload code to the microcontroller. Of course, you can also debug the display by opening a Serial Terminal.
+ + +Once you have finished prototyping, you could continue to use the USB cable and add a 5V power supply or battery pack.
+Grab the board dimensions and cut out a rectangle in the enclosure. For users that want to mount the board so that the OLED display is flush against the enclosure, you will need to look at the dimensions based on the OLED. You will need to add a little tolerance so that the display can fit through the rectangle. For users that need to quickly mount the board, you will could also cut out rectangles based on the vertical Qwiic connector so that the wires can lead into the enclosure. Then cut out the mounting holes so that the board is right side up. In this case, we used a cardboard box as a quick example to demonstrate the Qwiic wires connecting leading into the enclosure.
+ + +Note
+To easily display text and graphics on the board, we recommend mounting the board right side up. There is an option in the example code to flip the text horizontally and vertically should you decide to mount the board upside down, but you would need to also determine the position of the text.
+For a more durable enclosure, you could use wood, metal, or plastic. However, you will need additional tools to cut into the material.
+The Qwiic OLED (0.91", 128x32) uses the SparkFun QWIIC OLED Arduino Library. The SparkFun Qwiic OLED Library's Software Setup has instructions and usage examples. Additionally, the full library API documentation is available in the SparkFun Qwiic OLED Library API Reference guide.
+ + +Now that you've successfully got your OLED Display (0.9", 128x36) up and running, it's time to incorporate it into your own project! For more information, check out the resources below:
+The Qwiic OLED 1.3in has its own hook-up guide.
+Arduino
+This guide assumes you are using the latest version of the Arduino IDE on your desktop. The following resources available at SparkFun provide the details on setting up and configuring Arduino to use this library.
+ +The SparkFun Qwiic OLED Arduino Library is available within in the Arduino library manager, which is launched via the Sketch > Include Libraries > Manage Libraries … menu option in the Arduino IDE. Just search for SparkFun Qwiic OLED Library.
+Note
+If you've never connected a USB-to-serial converter to your computer before, you may need to install drivers. The drivers will depend on what is populated on your Arduino development board. Check out the following tutorials for help with the installation.
+ +After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
+ +The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
+| Class | +Qwiic OLED Device | +
|---|---|
QwiicMicroOLED |
+SparkFun Qwiic Micro OLED | +
QwiicNarrowOLED |
+SparkFun Qwiic OLED Display (128x32) | +
QwiicTransparentOLED |
+SparkFun Transparent Graphical OLED | +
Qwiic1in3OLED |
+SparkFun Qwiic OLED 1.3" Display (128x32) | +
For this example, the Qwiic Micro OLED is used.
+ +In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
int width, height; // global variables for use in the sketch
+void setup()
+{
+ Serial.begin(115200);
+ if(!myOLED.begin()){
+ Serial.println("Device failed to initialize");
+ while(1); // halt execution
+ }
+ Serial.println("Device is initialized");
+
+}
+Now that the library is initialized, the desired graphics are drawn. Here we erase the screen and draw simple series of lines that originate at the screen origin and fan out across the height of the display.
+Note
+Graphics are not send to the OLED device when drawn. Updates are only sent to the device when the display() method is called. This minimizes data transfers to the OLED device, delivering a responsive display response.
myOLED.erase(); // Erase the screen
+ myOLED.display(); // Send erase to device
+
+ delay(1000); // Slight pause
+
+ // Draw our lines from point (0,0) to (i, screen height)
+
+ for(int i=0; i < width; i+= 6){
+ myOLED.line(0, 0, i, height-1); // draw the line
+ myOLED.display(); // Send the new line to the device for display
+ }
+The SparkFun Qwiic OLED Arduino Library, includes a wide variety of examples. These are available from the Examples menu of the Arduino IDE, and in the examplesfolder of this repository.
For a detailed description of the examples, see the Examples section of the documentation.
+Methods to setup the device, get device information and change display options.
+This method is called to initialize the OLED library and connection to the OLED device. This method must be called before calling any graphics methods.
+ +| Parameter | +Type | +Description | +
|---|---|---|
wirePort |
+TwoWire |
+optional. The Wire port. If not provided, the default port is used | +
address |
+uint8_t |
+optional. I2C Address. If not provided, the default address is used. | +
| return value | +bool |
+true on success, false on startup failure |
+
When called, this method reset the library state and OLED device to their intial state. Helpful to reset the OLED after waking up a system from a sleep state.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +bool |
+true on success, false on startup failure |
+
This method returns the width, in pixels, of the connected OLED device
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The width in pixels of the connected OLED device | +
This method returns the height, in pixels, of the connected OLED device
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The height in pixels of the connected OLED device | +
This method inverts the current graphics on the display. This results of this command happen immediatly.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bInvert |
+bool |
+true - the screen is inverted. false - the screen is set to normal |
+
When called, the screen contents are flipped vertically if the flip parameter is true, or restored to normal display if the flip parameter is false.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bFlip |
+bool |
+true - the screen is flipped vertically. false - the screen is set to normal |
+
When called, the screen contents are flipped horizontally if the flip parameter is true, or restored to normal display if the flip parameter is false.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bFlip |
+bool |
+true - the screen is flipped horizontally. false - the screen is set to normal |
+
Used to turn the OLED display on or off.
+ +| Parameter | +Type | +Description | +
|---|---|---|
bEnable |
+bool |
+true - the OLED display is powered on (default). false - the OLED dsiplay is powered off. |
+
Methods for device scrolling
+If the device is in a scrolling mode, calling this method stops the scroll, and restores the device to normal display operation. This action is performed immediately.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
This method is called to start the device scrolling the displayed graphics to the right. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed below | +
Defined values for the interval parameter:
| Defined Symbol | +Time Interval Between Steps | +
|---|---|
SCROLL_INTERVAL_2_FRAMES |
+2 | +
SCROLL_INTERVAL_3_FRAMES |
+3 | +
SCROLL_INTERVAL_4_FRAMES |
+4 | +
SCROLL_INTERVAL_5_FRAMES |
+5 | +
SCROLL_INTERVAL_25_FRAMES |
+25 | +
SCROLL_INTERVAL_64_FRAMES |
+64 | +
SCROLL_INTERVAL_128_FRAMES |
+128 | +
SCROLL_INTERVAL_256_FRAMES |
+256 | +
This method is called to start the device scrolling the displayed graphics vertically and to the right. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
This method is called start to the device scrolling the displayed graphics to the left. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
This method is called to start the device scrolling the displayed graphics vertically and to the left. This action is performed immediately.
+The screen will scroll until the scrollStop() method is called.
| Parameter | +Type | +Description | +
|---|---|---|
start |
+uint8_t |
+The start page address of the scroll - valid values are 0 thru 7 | +
stop |
+uint8_t |
+The stop/end page address of the scroll - valid values are 0 thru 7 | +
interval |
+uint8_t |
+The time interval between scroll step - values listed in scrollRight |
+
Methods for setting the drawing state of the library.
+This method is called to set the current font in the library. The current font is used when calling the text() method on this device.
The default font for the device is 5x7.
| Parameter | +Type | +Description | +
|---|---|---|
theFont |
+QwiicFont |
+The font to set as current in the device | +
theFont |
+QwiicFont* |
+Pointer to the font to set as current in the device. | +
For the library, fonts are added to your program by including them via include files which are part of this library.
+The following fonts are included:
+| Font | +Include File | +Font Variable | +Description | +
|---|---|---|---|
| 5x7 | +<res/qw_fnt_5x7.h> |
+QW_FONT_5X7 |
+A full, 5 x 7 font | +
| 31x48 | +<res/qw_fnt_31x48.h> |
+QW_FONT_31X48 |
+A full, 31 x 48 font | +
| Seven Segment | +<res/qw_fnt_7segment.h> |
+QW_FONT_7SEGMENT |
+Numbers only | +
| 8x16 | +<res/qw_fnt_8x16.h> |
+QW_FONT_8X16 |
+A full, 8 x 16 font | +
| Large Numbers | +<res/qw_fnt_largenum.h> |
+QW_FONT_LARGENUM |
+Numbers only | +
For each font, the font variables are objects with the following attributes:
+| Attribute | +Value | +
|---|---|
width |
+The font width in pixels | +
height |
+The font height in pixels | +
start |
+The font start character offset | +
n_chars |
+The number of characters | +
map_width |
+The width of the font map | +
Example use of a font object attribute: +
+This method returns the current font for the device.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +QwiicFont* |
+A pointer to the current font. See setFont() for font object details. |
+
This method returns the height in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +String | +The name of the current font. | +
This method returns the width in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| text | +String |
+The string used to determine width | +
| return value | +unsigned int |
+The width of the provide string, as determined using the current font. | +
This method returns the height in pixels of a provided String based on the current device font.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| text | +String |
+The string used to determine height | +
| return value | +unsigned int |
+The height of the provide string, as determined using the current font. | +
This method sets the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| rop | +grRasterOp_t |
+The raster operation (ROP) to set the graphics system to. | +
Raster operations device how source (pixels to draw) are represented on the destination device. The available Raster Operation (ROP) codes are:
+| ROP Code | +Description | +
|---|---|
| grROPCopy | +default Drawn pixel values are copied to the device screen | +
| grROPNotCopy | +A not operation is applied to the source value before copying to screen | +
| grROPNot | +A not operation is applied to the destination (screen) value | +
| grROPXOR | +A XOR operation is performed between the source and destination values | +
| grROPBlack | +A value of 0, or black is drawn to the destination | +
| grROPWhite | +A value of 1, or black is drawn to the destination | +
This method returns the current draw mode for the library. The draw mode determines how pixels are set on the screen during drawing operations.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| return value | +grRasterOp_t |
+The current aster operation (ROP) of the graphics system. | +
Methods used to draw and display graphics.
+When called, any pending display updates are sent to the connected OLED device. This includes drawn graphics and erase commands.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
Erases all graphics on the device, placing the display in a blank state. The erase update isn't sent to the device until the next display() call on the device.
| Parameter | +Type | +Description | +
|---|---|---|
| NONE | ++ | + |
Set the value of a pixel on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x | +uint8_t |
+The X coordinate of the pixel to set | +
| y | +uint8_t |
+The Y coordinate of the pixel to set | +
| clr | +uint8_t |
+optional The color value to set the pixel. This defaults to white (1). | +
Draw a line on the screen.
+Note: If a line is horizontal (y0 = y1) or vertical (x0 = x1), optimized draw algorithms are used by the library.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the line | +
| y0 | +uint8_t |
+The start Y coordinate of the line | +
| x1 | +uint8_t |
+The end X coordinate of the line | +
| y1 | +uint8_t |
+The end Y coordinate of the line | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a rectangle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the rectangle - upper left corner | +
| y0 | +uint8_t |
+The start Y coordinate of the rectangle - upper left corner | +
| width | +uint8_t |
+The width of the rectangle | +
| height | +uint8_t |
+The height of the rectangle | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a filled rectangle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The start X coordinate of the rectangle - upper left corner | +
| y0 | +uint8_t |
+The start Y coordinate of the rectangle - upper left corner | +
| width | +uint8_t |
+The width of the rectangle | +
| height | +uint8_t |
+The height of the rectangle | +
| clr | +uint8_t |
+optional The color value to draw the line. This defaults to white (1). | +
Draw a circle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate of the circle center | +
| y0 | +uint8_t |
+The Y coordinate of the circle center | +
| radius | +uint8_t |
+The radius of the circle | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Draw a filled circle on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate of the circle center | +
| y0 | +uint8_t |
+The Y coordinate of the circle center | +
| radius | +uint8_t |
+The radius of the circle | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Draws a bitmap on the screen.
+The bitmap should be 8 bit encoded - each pixel contains 8 y values.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| pBitmap | +uint8_t * |
+A pointer to the bitmap array | +
| bmp_width | +uint8_t |
+The width of the bitmap | +
| bmp_height | +uint8_t |
+The height of the bitmap | +
Draws a bitmap on the screen.
+The bitmap should be 8 bit encoded - each pixel contains 8 y values.
+The coordinate [x1,y1] allows for only a portion of bitmap to be drawn.
+void bitmap(uint8_t x0, uint8_t y0, uint8_t x1, uint8_t y1,
+ uint8_t *pBitmap, uint8_t bmp_width, uint8_t bmp_height )
+| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| x1 | +uint8_t |
+The end X coordinate of the bitmap - lower right corner | +
| y1 | +uint8_t |
+The end Y coordinate of the bitmap - lower right corner | +
| pBitmap | +uint8_t * |
+A pointer to the bitmap array | +
| bmp_width | +uint8_t |
+The width of the bitmap | +
| bmp_height | +uint8_t |
+The height of the bitmap | +
Draws a bitmap on the screen using a Bitmap object for the bitmap data.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to place the bitmap - upper left corner | +
| y0 | +uint8_t |
+The Y coordinate to place the bitmap - upper left corner | +
| Bitmap | +QwiicBitmap |
+A bitmap object | +
Draws a string using the current font on the screen.
+ +| Parameter | +Type | +Description | +
|---|---|---|
| x0 | +uint8_t |
+The X coordinate to start drawing the text | +
| y0 | +uint8_t |
+The Y coordinate to start drawing the text | +
| text | +const char* |
+The string to draw on the screen | +
| text | +String |
+The Arduino string to draw on the screen | +
| clr | +uint8_t |
+optional The color value to draw the circle. This defaults to white (1). | +
Methods used to support Arduino Print functionality.
+This method is called set the "cursor" position in the device. The library supports the Arduino Print interface, enabling the use of a print() and println() methods. The set cursor position defines where to start text output for this functionality.
| Parameter | +Type | +Description | +
|---|---|---|
| x | +uint8_t |
+The X coordinate of the cursor | +
| y | +uint8_t |
+The Y coordinate of the cursor | +
This method is called to set the current color of the system. This is used by the Arduino Print interface functionality
| Parameter | +Type | +Description | +
|---|---|---|
clr |
+uint8_t |
+The color to set. 0 = black, > 0 = white | +
This method is called to get the current color of the system. This is used by the Arduino Print interface functionality
| Parameter | +Type | +Description | +
|---|---|---|
| return value | +uint8_t |
+The current color | +
--8<-- "./docs/ex_01_hello.md
+--8<-- "./docs/ex_02_lines.md
+--8<-- "./docs/ex_03_bitmaps.md
+--8<-- "./docs/ex_04_text.md
+--8<-- "./docs/ex_other.md
+Note
+
+ Not working as expected and need help?
If you need technical assistance and more information on a product that is not working as you expected, we recommend heading on over to the SparkFun Technical Assistance page for some initial troubleshooting.
If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.
Arduino
+This guide assumes you are using the latest version of the Arduino IDE on your desktop. The following resources available at SparkFun provide the details on setting up and configuring Arduino to use this library.
+ +The SparkFun Qwiic OLED Arduino Library is available within in the Arduino library manager, which is launched via the Sketch > Include Libraries > Manage Libraries … menu option in the Arduino IDE. Just search for SparkFun Qwiic OLED Library.
+Note
+If you've never connected a USB-to-serial converter to your computer before, you may need to install drivers. The drivers will depend on what is populated on your Arduino development board. Check out the following tutorials for help with the installation.
+ +After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
+ +The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
+| Class | +Qwiic OLED Device | +
|---|---|
QwiicMicroOLED |
+SparkFun Qwiic Micro OLED | +
QwiicNarrowOLED |
+SparkFun Qwiic OLED Display (128x32) | +
QwiicTransparentOLED |
+SparkFun Transparent Graphical OLED | +
Qwiic1in3OLED |
+SparkFun Qwiic OLED 1.3" Display (128x32) | +
For this example, the Qwiic Micro OLED is used.
+ +In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
int width, height; // global variables for use in the sketch
+void setup()
+{
+ Serial.begin(115200);
+ if(!myOLED.begin()){
+ Serial.println("Device failed to initialize");
+ while(1); // halt execution
+ }
+ Serial.println("Device is initialized");
+
+}
+Now that the library is initialized, the desired graphics are drawn. Here we erase the screen and draw simple series of lines that originate at the screen origin and fan out across the height of the display.
+Note
+Graphics are not send to the OLED device when drawn. Updates are only sent to the device when the display() method is called. This minimizes data transfers to the OLED device, delivering a responsive display response.
myOLED.erase(); // Erase the screen
+ myOLED.display(); // Send erase to device
+
+ delay(1000); // Slight pause
+
+ // Draw our lines from point (0,0) to (i, screen height)
+
+ for(int i=0; i < width; i+= 6){
+ myOLED.line(0, 0, i, height-1); // draw the line
+ myOLED.display(); // Send the new line to the device for display
+ }
+The SparkFun Qwiic OLED Arduino Library, includes a wide variety of examples. These are available from the Examples menu of the Arduino IDE, and in the examplesfolder of this repository.
For a detailed description of the examples, see the Examples section of the documentation.
+ + + + + + + + + + + + + + + + + + + + + + + + + +A simple example to show the basic setup and use of the SparkFun Qwiic OLED Library.
+Key Demo Features
+After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
+ +The next step is to declare the object for the SparkFun Qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
+| Class + | +Qwiic OLED Device + | +
|---|---|
QwiicMicroOLED
+ |
+ SparkFun Qwiic Micro OLED + | +
QwiicTransparentOLED
+ |
+ SparkFun Transparent Graphical OLED + | +
QwiicNarrowOLED
+ |
+ SparkFun Qwiic OLED Display (128x32) + | +
Qwiic1in3OLED
+ |
+ SparkFun Qwiic OLED 1.3" Display (128x32) + | +
The example code supports all of the SparkFun Qwiic OLED boards. By default, the Qwiic Micro OLED is selected. To select a different board being used, add a single line comment (i.e. //) in front of "QwiicMicroOLED myOLED;" and uncomment the device being used for the demo board.
QwiicMicroOLED myOLED;
+//QwiicTransparentOLED myOLED;
+//QwiicNarrowOLED myOLED;
+//Qwiic1in3OLED myOLED;
+Note
+As of version 1.0.2+, users will need to use the class as explained above instead of using a #define.
In the setup() function of this sketch, like all of the SparkFun Qwiic Arduino libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()
+{
+
+ delay(500); //Give display time to power on
+
+ // Serial on!
+ Serial.begin(115200);
+
+ Serial.println("\n\r-----------------------------------");
+
+ Serial.print("Running Example 01 on: ");
+ Serial.println(String(deviceName));
+
+ // Initalize the OLED device and related graphics system
+ if(!myOLED.begin()){
+
+ Serial.println(" - Device Begin Failed");
+ while(1);
+ }
+
+ Serial.println("- Begin Success");
+
+ // Do a simple test - fill a rectangle on the screen and then print hello!...
+
+}
+Once the device is enabled, the rest of the setup() function is devoted to drawing a simple graphic on the target device.
First, draw a filled rectangle on the screen - leave a 4 pixel boarder at the end of the screen. Note that the getWidth() and getHeight() method are used to get the devices screen size.
// Fill a rectangle on the screen that has a 4 pixel board
+ myOLED.rectangleFill(4, 4, myOLED.getWidth() - 8, myOLED.getHeight() - 8);
+The next part of our graphic is a message centered in the drawn rectangle. To do the centering, the current font is accessed from the device, and the size of a character in the font is used to calculate the text position on the screen. Once the position is determined, the message is drawn on the display in black (0 for a color value).
+ String hello = "hello"; // our message
+
+ // Center our message on the screen. Get the screen size of the "hello" string,
+ // calling the getStringWidth() and getStringHeight() methods on the oled
+
+ // starting x position - screen width minus string width / 2
+ int x0 = (myOLED.getWidth() - myOLED.getStringWidth(hello)) / 2;
+
+ // starting y position - screen height minus string height / 2
+ int y0 = (myOLED.getHeight() - myOLED.getStringHeight(hello)) / 2;
+
+ // Draw the text - color of black (0)
+ myOLED.text(x0, y0, hello, 0);
+The last step is sending the graphics to the device. This is accomplished by calling the display() method.
And that's it! Select the board and COM port for your development board. Then upload the code! The graphic should display on the OLED device.
+
An example that shows drawing simple shapes using the SparkFun Qwiic OLED Library.
+Key Demo Features
+After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library.
+ +The next step is to declare the object for the SparkFun Qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within the setup() or loop() functions.
The user selects from one of the following classes:
+| Class + | +Qwiic OLED Device + | +
|---|---|
QwiicMicroOLED
+ |
+ SparkFun Qwiic Micro OLED + | +
QwiicTransparentOLED
+ |
+ SparkFun Transparent Graphical OLED + | +
QwiicNarrowOLED
+ |
+ SparkFun Qwiic OLED Display (128x32) + | +
Qwiic1in3OLED
+ |
+ SparkFun Qwiic OLED 1.3" Display (128x32) + | +
The example code supports all of the SparkFun Qwiic OLED boards. By default, the Qwiic Micro OLED is selected. To select a different board being used, add a single line comment (i.e. //) in front of "QwiicMicroOLED myOLED;" and uncomment the device being used for the demo board.
QwiicMicroOLED myOLED;
+//QwiicTransparentOLED myOLED;
+//QwiicNarrowOLED myOLED;
+//Qwiic1in3OLED myOLED;
+Note
+As of version 1.0.2+, users will need to use the class as explained above instead of using a #define.
Note
+As of version 1.0.2+, the modular functions have a slightly different name. Some functions defined in the example code will have the _ removed or words spelled out. For example, version v1.0.1 and below defined the function to test the line as line_test_1() while version v1.0.2+ defined the function as lineTest1().
The shapes drawn are broken into a set of functions that perform one test, which is part of the overall example.
+This test starts with a short, horizontal line that is animated from the top to bottom of the display. After each iteration, the line size is increased and the animating sequence repeated.
+To animate the line, the display is erased, then the line drawn. Once the line is draw, the updated graphics is sent to the OLED device by calling the display() method.
Note
+When display() is called, only the range of modified pixels is sent to the OLED device, greatly reducing the data transferred for small graphic changes.
This is demonstrated by this test. When small lines are drawn, the update rate is fast, but as the line length increases, the update rate of the device is noticeably slower. A longer line requires more data to be sent to the device.
+void lineTest1(void)
+{
+ int x, y, i;
+
+ int mid = width / 2;
+ int delta = mid / 8;
+
+ for (int j = 1; j < 8; j++)
+ {
+
+ x = delta * j;
+
+ for (i = 0; i < height * 2; i++)
+ {
+
+ y = i % height;
+ myOLED.erase();
+ myOLED.line(mid - x, y, mid + x, y);
+ myOLED.display();
+ }
+ }
+}
+This test is followed up with a series of lines that span from a single point to the bottom of the screen, showing the flexibility of the line to raster algorithm used by the library.
+void lineTest2(void)
+{
+ for (int i = 0; i < width; i += 6)
+ {
+ myOLED.line(0, 0, i, height - 1);
+ myOLED.display();
+ }
+ delay(200);
+ myOLED.erase();
+ for (int i = width - 1; i >= 0; i -= 6)
+ {
+ myOLED.line(width - 1, 0, i, height - 1);
+ myOLED.display();
+ }
+}
+And the last line test draws a series of lines to test all three internal line drawing algorithms. Specifically:
+The test animates to show a growing box, giving an idea of the speed and flexibility of the system.
+void lineTestVerticalIterative(uint8_t y0, uint8_t y1)
+{
+ for (int i = 0; i < width; i += 8)
+ myOLED.line(i, y0, i, y1);
+
+ // end off the vertical lines
+ myOLED.line(width - 1, y0, width - 1, y1);
+
+ // End lines and cross lines
+ myOLED.line(0, y0, width - 1, y0);
+ myOLED.line(0, y1, width - 1, y1);
+ myOLED.line(0, y0, width - 1, y1);
+ myOLED.line(0, y1, width - 1, y0);
+}
+
+// Entry point for test
+void lineTestVertical(void)
+{
+ int mid = height / 2;
+
+ for (int i = 0; i < height; i += 4)
+ {
+
+ myOLED.erase();
+ lineTestVerticalIterative(mid - i / 2, mid + i / 2);
+ myOLED.display();
+ delay(10);
+ }
+}
+Several rectangle routines are shown in this example. A key test is a fast drawing routine which animates a small rectangle being drawn diagonally across the screen.
+In this test, the rectangle is drawn, sent to the device via using display(), then the rectangle is drawn again, but this time in black. This effectively erases the rectangle. The position is incremented and the process loops, causing the rectangle to appear to fly across the screen.
The animation is quick, since only the portions of the screen that need updated are actually updated.
+The animation algorithm is listed in the `rectangleTestMove() function.
+void rectangleTestMove(void)
+{
+ float steps = height;
+ float xinc = width / steps;
+ float yinc = height / steps;
+ int side = 10;
+ float x = 0;
+ float y = 0;
+
+ for (int i = 0; i < steps; i++)
+ {
+ // Draw the rectangle and send it to device
+ myOLED.rectangle(x, y, side, side);
+ myOLED.display(); // sends erased rect and new rect pixels to device
+
+ // Erase the that rect, increment and loop
+ myOLED.rectangle(x, y, side, side, 0);
+
+ x += xinc;
+ y += yinc;
+ }
+}
+The next rectangle test draws a series of filled rectangles on the screen. The unique aspect of this test is that is uses the XOR functionally to overlay a rectangle on the device, presenting a alternating color pattern.
+The XOR raster operation is set by calling the setDrawMode() method on the OLED device, and providing the grROPXOR code. This switch the device into a XOR drawing mode. Graphic operations are restored to normal by calling setDrawMode() and providing the grROPCopy code, which copies the new pixel value to the destination.
Filled rectangles and XOR operations:
+void rectangleFillTest(void)
+{
+ myOLED.rectangleFill(4, 4, width / 2 - 8, height - 8);
+
+ myOLED.rectangleFill(width / 2 + 4, 4, width / 2 - 8, height - 8);
+
+ myOLED.setDrawMode(grROPXOR); // xor
+ myOLED.rectangleFill(width / 4, 8, width / 2, height - 16);
+ myOLED.setDrawMode(grROPCopy); // back to copy op (default)
+}
+The final shape drawn by this example is a series of circles and filled circles. Using the geometry of the screen, a set of circles are drawn and displayed.
+void circleTest(void)
+{
+ // Let's draw some circles that fit on the device
+ myOLED.circle(width / 4, height / 2, height / 3);
+
+ myOLED.circleFill(width - width / 4, height / 2, height / 3);
+
+ myOLED.circle(4, height / 2, height / 3);
+
+ myOLED.circleFill(width - width / 2, height / 2, height / 4);
+}
+An example that shows drawing bitmaps using the SparkFun Qwiic OLED Library.
+Key Demo Features
+After installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library. +
+The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within thesetup() or loop() functions.
+The user selects from one of the following classes:
+| Class | +Qwiic OLED Device | +
|---|---|
QwiicMicroOLED |
+SparkFun Qwiic Micro OLED | +
QwiicNarrowOLED |
+SparkFun Qwiic OLED Display (128x32) | +
QwiicTransparentOLED |
+SparkFun Transparent Graphical OLED | +
Qwiic1in3OLED |
+SparkFun Qwiic OLED 1.3" Display (128x32) | +
The Example code supports all of the SparkFun Qwiic OLED boards. To select the board being used, uncomment the #define for the demo board.
For this example, the Qwiic Micro OLED is used.
+ +Which results in myOLED being declared as: + +In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()
+{
+
+ delay(500); //Give display time to power on
+
+ // Serial on!
+ Serial.begin(115200);
+
+ Serial.println("\n\r-----------------------------------");
+
+ Serial.print("Running Example 01 on: ");
+ Serial.println(String(deviceName));
+
+ // Initalize the OLED device and related graphics system
+ if(!myOLED.begin()){
+
+ Serial.println(" - Device Begin Failed");
+ while(1);
+ }
+
+ Serial.println("- Begin Success");
+An example that shows drawing bitmaps using the SparkFun Qwiic OLED Library.
+Key Demo Features
+Print functionalityAfter installing this library in your local Arduino environment, begin with a standard Arduino sketch, and include the header file for this library. +
+The next step is to declare the object for the SparkFun qwiic OLED device used. Like most Arduino sketches, this is done at a global scope (after the include file declaration), not within thesetup() or loop() functions.
+The user selects from one of the following classes:
+| Class | +Qwiic OLED Device | +
|---|---|
QwiicMicroOLED |
+SparkFun Qwiic Micro OLED | +
QwiicNarrowOLED |
+SparkFun Qwiic OLED Display (128x32) | +
QwiicTransparentOLED |
+SparkFun Transparent Graphical OLED | +
Qwiic1in3OLED |
+SparkFun Qwiic OLED 1.3" Display (128x32) | +
The Example code supports all of the SparkFun Qwiic OLED boards. To select the board being used, uncomment the #define for the demo board.
For this example, the Qwiic Micro OLED is used.
+ +Which results in myOLED being declared as: + +In the setup() function of this sketch, like all of the SparkFun qwiic libraries, the device is initialized by calling the begin() method. This method returns a value of true on success, or false on failure.
void setup()
+{
+
+ delay(500); //Give display time to power on
+
+ // Serial on!
+ Serial.begin(115200);
+
+ Serial.println("\n\r-----------------------------------");
+
+ Serial.print("Running Example 01 on: ");
+ Serial.println(String(deviceName));
+
+ // Initalize the OLED device and related graphics system
+ if(!myOLED.begin()){
+
+ Serial.println(" - Device Begin Failed");
+ while(1);
+ }
+
+ Serial.println("- Begin Success");
+Note
+
+ Not working as expected and need help?
If you need technical assistance and more information on a product that is not working as you expected, we recommend heading on over to the SparkFun Technical Assistance page for some initial troubleshooting.
If you don't find what you need there, the SparkFun Forums are a great place to find and ask for help. If this is your first visit, you'll need to create a Forum Account to search product forums and post questions.