How about something like this. If it works, could you post a picture?
Code:
#include <assert.h>
typedef unsigned char byte_t;
byte_t alpha[][8] = {
/* A */ { 0 },
/* B */ { 0 },
/* C */ { 0 },
/* D */ { 0 },
/* E */ { 0 },
/* F */ { 0 },
/* G */ { 0 },
/* H */ { 0x00, 0xFF, 0x08, 0x08, 0x08, 0x08, 0xFF, 0x00 },
/* I */ { 0x00, 0x81, 0x81, 0xFF, 0x81, 0x81, 0x00, 0x00 }
/* etc */
};
void sendLetter(char letter) {
int i;
assert(letter >= 'A' && letter <= 'Z');
letter -= 'A';
for (i = 0; i < 8; i++) {
SPI_DataSend(alpha[letter][i]);
// SPI_DataSend(alpha[letter][i]); // this may need to be done twice
}
}
int main() {
SystemInit(); //System Initialization
SetHT1632C_As3208(); //Set all HT1632s to work in 32*8 master mode
ChipSelect(1); //Chip select the corresponding HT1632C
// green H
AddressWriteHT1632C(0x00); //Get the selected start address of the chip
SPI_ModelConfigure(); //Open SPI mode, continuously send data to HT1632C
sendLetter('H');
SSPCON = 0x11; //Close SPI mode
// red I
AddressWriteHT1632C(0x30); //Get the selected start address of the chip
SPI_ModelConfigure(); //Open SPI mode, continuously send data to HT1632C
sendLetter('I');
SSPCON = 0x11; //Close SPI mode
while(1);
}