Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Unicorn GLCD demo.

Status
Not open for further replies.
Would you please explain me how Putchar works, i cannot get the small font you posted working properly

The characters are not readable , i think it needs some modification in the display function, but don't know what should be modified.
 
I don't have time right now or the setup to test it but, hopefully, I should be able to get around to it in the next few days.

Mike.
 
Hi Guys,

I am using this GLCD library (found on CCS forum) and it is working fine. But could I know, how can I change the font size from 8x5 to 32x20(or bigger than this). In order to do that I reckon, the other functions also need to be modified.

I got one function PutChar32x20 and I got the font for numeric value but I haven't got the alphabetic font for this function.Where Can I find the bigger font? I have tried yo use mickroElektronica GLCD font creator but output is completely different than the expected.

I have attached fonts_glcd and GLCD for your reference. I would also like mention that I .

Help is appreciated.
Cheers
 

Attachments

  • fonts_GLCD.h
    5.1 KB · Views: 417
  • GLCD.c
    16.8 KB · Views: 425
  • GLCD.h
    1.8 KB · Views: 440
Hello folks,

I have changed the size of font from 8x5 to 32x20 and everything working perfect. I have attached all the related file.

What I have done with the font of 8x5 size:

1. The code for Digit 1 is
0xFF,0xBD,0x80,0xBF,0xFF,0x55,0x55, // 49 1

2. As Mike mentioned in post #345 https://www.electro-tech-online.com/threads/unicorn-glcd-demo.30617/ that
The first character is the left hand column with the LSB at the top of the column. They're also stored inverted.
so the hex code for Digit 1 looks like as below:

1 1 0 1 1

1 0 0 1 1

1 1 0 1 1

1 1 0 1 1

1 1 0 1 1

1 1 0 1 1

1 0 0 0 1

1 1 1 1 1

3. write first bit 4 times in a row and column.

4. Final code will look like.

1 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1
2 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1
3 1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 1 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1 1 1 1 1 0 0 0 0 1 1 1 1 1 1 1 1
29 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
30 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
31 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1
32 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 1 1 1 1

5. The PutChar32x20 and PutMessage32x20 functions are defined to print the character on the display.

Cheers
 

Attachments

  • fonts_GLCD.h
    21.9 KB · Views: 414
  • GLCD.c
    18.1 KB · Views: 434
  • GLCD.h
    1.9 KB · Views: 411
  • photo (19).JPG
    photo (19).JPG
    1.6 MB · Views: 441
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top