Sure Electronics new 32x16 bi-color display: 3216 RG -Cont. from read only forum

I need to print "65" Instead of "A" (ASCII)

"65" is a string (that is, a sequence) of 2 characters: '6' and '5'.
To print the 2 characters, call function putchar twice, once for each character:

dotmatrix.putchar(1,  0, '6', GREEN);
dotmatrix.putchar(9,  0, '5', GREEN);

To define a character, either put it between single quotes or use its ASCII representation (look it up the ASCII table).
Hence

char c = 'A';

is equivalent to

char c = 65;

I hope to incorporate Evanrich's bluetooth/android idea in the future.

Take a look at this post:

I know that the library supports both 32x16 and 32x8 displays, but can you connect both types of displays in series and still have it work?

Also, I wrote some code to makes an isosceles triangle. I made my displays show some temperature data from the web and the arrow shows if it went up from the last time it was sampled. See below:

void triangle(int pointX, int pointY, int orientation, int color=1 ,int layers=2){
  int xPlus=0;
  int yPlus=0;
  int xMinus=0;
  int yMinus=0;
  switch(orientation){
    case 1: xPlus=1; yPlus=1; xMinus=1; yMinus=-1;  //left
      break;
    case 2: xPlus=-1; yPlus=1; xMinus=-1; yMinus=-1; //right
      break;
    case 3: xPlus=-1; yPlus=1; xMinus=1; yMinus=1; //up
      break;
    case 4: xPlus=-1; yPlus=-1; xMinus=1; yMinus=-1; //down
    default:
      break;
  }   
  for(int ii= 0; ii<layers; ii++){
    int startX = pointX+xPlus*ii;
    
    int startY = pointY+yPlus*ii;
    
    int endX = pointX+xMinus*ii;
    
    int endY = pointY+yMinus*ii;
    
    dotmatrix.line(startX, startY, endX,endY,color);
    dotmatrix.sendframe();
  }
}

It's pretty inefficient code. Anyone have a better idea? Am I reinventing the wheel here?

hi..

i'm quite new to this..

so far, i have managed to display character on my SE led display using the old library.. thanks for all the effort from all of you seniors..

btw, i have a question to ask.. is it possible if i want to display the RSS feed from a website such as tweets from Twitter using the SE led display? can anyone provide me with the coding to do so? for your information i have purchased the ethernet shield for my arduino and i have search on the internet to perform this task but the only code i have found is for display using lcd like this :

#include <Ethernet.h>
#include <EthernetDHCP.h>
#include <TextFinder.h>
#include <LiquidCrystal.h>

// initialize the library with the numbers of the interface pins

LiquidCrystal lcd(9, 8, 5, 4, 3, 2);

byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte server[] = {128,242,240,20}; // Twitter IP

char tweet[140];
Client client(server, 80);
TextFinder  finder( client );

void setup()

{
  
lcd.begin(20,4);
lcd.clear();
lcd.print("Twitter2LCD");
Serial.begin(9600);
EthernetDHCP.begin(mac);

}

void loop()

{
  lcd.clear();

  if (client.connect())
	{
         client.println("GET http://www.twitter.com/statuses/user_timeline/16297873.rss HTTP/1.0");  // twitter rss for fgranelli
         client.println();
	}
   else
 	{
         lcd.println("Connection failed");
         Serial.println("Connection failed");
	}
   if (client.connected())
	{
     // get the last tweet by simply parsing the item and title tags

   if ((finder.find("<item>")&&(finder.getString("<title>","</title>",tweet,140)!=0)))
   {
         Serial.println(tweet);

         for (int j=0; j<2; j++)
         {
           // first part of the tweet
           lcd.clear();
           lcd.setCursor(0,0);

           for (int i=0; i<20; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,1);

           for (int i=20; i<40; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,2);

           for (int i=40; i<60; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,3);

           for (int i=60; i<80; i++)
           lcd.print(tweet[i]);
           delay(10000);

           // second part of the tweet
           lcd.clear();
           lcd.setCursor(0,0);

           for (int i=60; i<80; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,1);

           for (int i=80; i<100; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,2);

           for (int i=100; i<120; i++)
           lcd.print(tweet[i]);
           lcd.setCursor(0,3);

           for (int i=120; i<140; i++)
           lcd.print(tweet[i]);

           delay(10000);
         }

   }
  else
   {
    lcd.println("Could not find item field");
   }
  else
   {
    lcd.println("Disconnected");
  }

  client.stop();
  client.flush();

 delay(60000); // wait a minute before next update
}

can anyone help me please with the coding? i would really appreciate your help.. thanks..

Looking like another extended hiatus from lonewolf. I hope he's busy working a new job and such, instead of unable to pay for his internet or power bills. :frowning:

From the looks of it (after reading EVERY post between both threads), there is still no solution to the >3 3216 boards? Interestingly, I came to the conclusion that one or more of my 3216's are bad, when I could only get 2 of them to work. After re-arranging them all, I was finally able to get 3 working together, but the 4th causes all other boards to misbehave. I was just about to order another 4 3216's to hedge my bets, when I finished reading the thread, and discovered the problems with more than 3 boards.

I'm pretty good with my C/C++, but the datasheets from Sure on the boards haven't been very helpful in determining the order in which memory is mapped onto the display (at least not helpful in me understanding it).

Could we maybe bring this discussion back a bit, and take it more on the "theory" side briefly? If I had a better understanding of how the memory maps, I might be able to lend some assistance with the code.

Btw, I'm really interested in evanrich's design 3x-wireless design. Personally, I'd like to have them with WiFi instead of Bluetooth though. I'm looking at putting a few of these around my house (theater, etc), with them polling the home server for information to display, such as time, date, temp, humidity, alarm status, etc. WiFi seems a little more accessible than bluetooth, plus my son would love to "have an [iphone] app for that", which Bluetooth limits.

Lonewolf, at such time as you return, can I make a modest donation to you, in the spirit of all your hard work?

--Kyle

@zifwat: It should be no problem to do an RSS feed with an ethernet shield (or arduino ethernet). Check out the reference pages on Ethernet class to get an idea, such sa this one on clients Ethernet - Arduino Reference Basically you're going to read in the web page as a stream and you'll have to figure out a way to parse the info. I'm currently doing something similar, but I have a PHP page hosted on my server that collects all the data and spits out a CSV. It's a lot easier to parse than a random web page.

@kylemallory: You can get the arduino boards an wifi shield. And then I'd say something similar to above for the wifi, in terms of aggregating the information on to one page that the boards query. You could get really fancy and build a database and tailor what you display to each board/display unit you have set up...and control it with an iPhone if you want.

I'll look into the 3+ boards problem, but as you said the SE data sheets are...lacking.

@doubledaffy :

thanks for the reply.. i have take a look at the ethernetclient that you suggested but didn't try it out yet.. now, i think i have got quite a view on how to get the RSS feed..

correct me if i'm wrong..
it is just simply edit this part under void setup()

from this:

  Serial.println("connecting...");

  if (client.connect(server, 80)) {
    Serial.println("connected");
    client.println("GET /search?q=arduino HTTP/1.0");
    client.println();
  } else {
    Serial.println("connection failed");
  }

and change it so that it become like this:

  Serial.println("connecting...");

  if (client.connect(server, 80)) {
    Serial.println("connected");
    client.println("GET http://twitter.com/statuses/user_timeline/41425390.rss HTTP/1.0");
    client.println();
  } else {
    Serial.println("connection failed");
  }

am i right @doubledaffy?

another question, can i just simply put the coding from the ethernetclient into the ht1632_2 coding?

thanks..

regards - zifwat

@kylemallory: I got a 4th board in and I haven't had any problems getting it to display properly. Are you sure you have the most recent library? Also, you might try giving the boards some external power if you're just powering them from the arduino.

Hello.

I am a noob with sure board, but I am running the board with the h1632c library. THANKS!!.

I only have an inconvenience,... I need the display to be read outside. Even if i set dotmatrix.pwm(15) I need more bright!!.

Someone of you know a similar ultrabrightness dotmatrix?. Maybe a way to hack the SE?.

Thanks, congratulations and hope to see new projects!!

I'm fairly certain that's as bright as the LED's go. If you have a lot of display module, and/or are using a lot of the LEDs at the same time, make sure you have an external power source otherwise they might dim.

Maybe you could try building an enclosure that shades the LEDs to reduce the direct light and glare to make it more visible outside.

I did just mixing a frame quite similar to this:

with a car laminating vynil like this:
http://www.ebay.es/itm/230747552687?ssPageName=STRK:MEWAX:IT&_trksid=p3984.m1438.l2649#ht_3147wt_952

just now is loooong better :wink:

I just noticed that the new Sure Electronics displays are brighter than the previous ones. They have frosted plastic which makes it look brighter and might reduce outdoor glare.

I've got 2 of these on the way, can't wait for them to arrive :slight_smile:

Here comes my mini rant: sure electronics just came up with a new revision of their 3216 display, and the distance between holes is changed! Any case you had made for the older display won't fit the new one! This sucks.

Thanks for the heads up.

Before I go mucking around in the code, does anyone know how to kern the fonts? Or at the very least adjust the tracking spacing? Sometimes the characters are too far away, and I can't fit everything I'd like on the display.

cracksmurf:

I am experiencing this problem regardless of usb in or out.

Ive tried with a Arduino Uno Rev3, and Arduino Nano 3.0.

using the code from GitHub - wildstray/ht1632c: HT1632C dotmatrix display library for Arduino (and AVR/ARM/PIC clones)

It seems like the upper left segment of the display to the right is a copy of lower right segment of the display to the left

so if this is a working display:
aabb1122
ccdd3344

then mine is like this:
aabbdd11
ccdd2233

images of the display running example sketches: geometry, line, fill and cirles:

any advice?

//eslin

Can you post the code you're using for one of those examples?

Swap the displays. Do you get the same thing?