# Inky Pack drivers/libraries

**URL:** https://forums.pimoroni.com/t/inky-pack-drivers-libraries/20909
**Category:** Support
**Created:** [December 6, 2022, 10:47pm UTC](https://forums.pimoroni.com/t/inky-pack-drivers-libraries/20909 "2022-12-06T22:47:41Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Bonedog](https://avatars.discourse-cdn.com/v4/letter/b/779978/32.png) [@Bonedog](https://forums.pimoroni.com/u/Bonedog)
#### Post date: [December 6, 2022, 10:47pm UTC](https://forums.pimoroni.com/t/inky-pack-drivers-libraries/20909/1 "2022-12-06T22:47:41Z")

</div>

First, I have successfully built the Pimoroni examples in C++, but my current interest is the inky\_pack example, which works fine after I reversed the pen colors, as I like a white background. Have been attempting to modify the demo code, but ran into a problem with partial\_update() from the uc8151 libraries. The end result is to use the inky\_pack as a weather station, as OLED displays are a bit small. So, to do this with the skinny documentation I have been able to find is a bit hard. While attempting to update a portion of the inky\_pack screen, I end with gibberish. The lines used below are modified directly from the demo.

```auto
int main() {
    graphics.set_pen(15);
    graphics.clear();

    graphics.set_pen(0);
    graphics.set_font("bitmap8");
    graphics.text("Large Text Here", {20, 0}, 296, 4);
    graphics.text(" What we have is by God's Grace!", {0, 38}, 296);
    graphics.text(" Another Line", {80, 64}, 296);
    graphics.text(" for address", {80, 80}, 296);
    graphics.text("And other stuff", {80, 96}, 296);
    graphics.text("---------------", {80, 112}, 296);
    uc8151.update(&graphics);

    sleep_ms(5000);
    
    graphics.text("Ye Gads ! ARGH", {0, 0}, 296, 4);
    uc8151.partial_update(&graphics, {0, 0, 296, 34});

    return 0;
}

```

Lines above the “sleep\_ms()” line work fine. The “partial\_update” was gleaned from the uc8151.hpp file in the drivers subdirectory. My ultimate goal is to get input from sensors (such as the bme280, etc.) and have the data display in a particular location on the e-ink display. Documentation on the Inky Pack is, for the most part, nonexistent. Any insight would be appreciated. I am not interested in Python, at least for the Pico, but see similarities in the coding.

---

<div class="post-metadata">

### Author: ![Bonedog](https://avatars.discourse-cdn.com/v4/letter/b/779978/32.png) [@Bonedog](https://forums.pimoroni.com/u/Bonedog)
#### Post date: [December 10, 2022, 4:04pm UTC](https://forums.pimoroni.com/t/inky-pack-drivers-libraries/20909/2 "2022-12-10T16:04:07Z")

</div>

It is interesting to note, given the “.clear()” function operation, that it would only make sense to have a corresponding “.partial\_clear()” along with a “.partial\_update()”. Otherwise a blob is created at the particular location updated. It seems at this point, the only workable solution may be refreshing the entire screen, with only changing the desired data, and re-including the rest of the screen again. Seems a bit cumbersome, but perhaps I have a poor understanding of how this works.
