HT16K33 Issues

EL Wire/Tape/Panels, LEDs, pixels and strips, LCDs and TFTs, etc products from Adafruit

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
malleymom
 
Posts: 4
Joined: Thu Feb 28, 2013 2:58 pm

HT16K33 Issues

Post by malleymom »

Hello,

I'm using the 0.56 7-seg backpack on an Feather Huzzah ESP8266. Following the tutorial here I've run into an issue. While the demo code works great and flashes all the segments, when I try to use matrix.print() or matrix.writeDigitNum() I get this error:

Code: Select all

class Adafruit_LEDBackpack' has no member named 'writeDigitNum'
I'm using the base code from the HT16K33 example, except my main is:

Code: Select all

void loop() {
  matrix.print(0000);
  matrix.writeDisplay();
  delay(100);
}
I first installed the backpack and GFX libraries using the built-in Arduino library manager, then also tried deleting them and installing straight from GitHub as the tutorial instructs. What am I missing?

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: HT16K33 Issues

Post by adafruit_support_bill »

Please post your complete code.

malleymom
 
Posts: 4
Joined: Thu Feb 28, 2013 2:58 pm

Re: HT16K33 Issues

Post by malleymom »

Here:

Code: Select all

/*************************************************** 
  This is a library for our I2C LED Backpacks

  Designed specifically to work with the Adafruit LED Matrix backpacks 
  ----> http://www.adafruit.com/products/872
  ----> http://www.adafruit.com/products/871
  ----> http://www.adafruit.com/products/870

  These displays use I2C to communicate, 2 pins are required to 
  interface. There are multiple selectable I2C addresses. For backpacks
  with 2 Address Select pins: 0x70, 0x71, 0x72 or 0x73. For backpacks
  with 3 Address Select pins: 0x70 thru 0x77

  Adafruit invests time and resources providing this open source code, 
  please support Adafruit and open-source hardware by purchasing 
  products from Adafruit!

  Written by Limor Fried/Ladyada for Adafruit Industries.  
  BSD license, all text above must be included in any redistribution
 ****************************************************/

#include <Wire.h>
#include <Adafruit_GFX.h>
#include "Adafruit_LEDBackpack.h"

#ifndef _BV
  #define _BV(bit) (1<<(bit))
#endif


Adafruit_LEDBackpack matrix = Adafruit_LEDBackpack();

uint8_t counter = 0;

void setup() {
  Serial.begin(9600);
  Serial.println("HT16K33 test");
  
  matrix.begin(0x70);  // pass in the address
}

void loop() {
  matrix.print(0000);
  matrix.writeDisplay();
  delay(100);
}

User avatar
adafruit_support_bill
 
Posts: 88093
Joined: Sat Feb 07, 2009 10:11 am

Re: HT16K33 Issues

Post by adafruit_support_bill »

Code: Select all

Adafruit_LEDBackpack matrix = Adafruit_LEDBackpack();
Adafruit_LEDBackpack is just the generic HT16K33 base-class. You need to tell it what kind of backpack you are using.

See the 7 segment example: https://github.com/adafruit/Adafruit_LE ... venseg.ino

Code: Select all

Adafruit_7segment matrix = Adafruit_7segment();

malleymom
 
Posts: 4
Joined: Thu Feb 28, 2013 2:58 pm

Re: HT16K33 Issues

Post by malleymom »

That did it! Thank you so much.

Locked
Please be positive and constructive with your questions and comments.

Return to “Glowy things (LCD, LED, TFT, EL) purchased at Adafruit”