View previous topic :: View next topic |
Author |
Message |
davemaster2000
Joined: 18 Dec 2005 Posts: 2 Location: Peru
|
|
|
king of swords
Joined: 18 Jun 2009 Posts: 7 Location: Türkiye
|
|
Posted: Sat Aug 08, 2009 4:12 am |
|
|
Hi,
Can we change the size of text that we write in glcd_putc() ?
Thank you. |
|
|
king of swords
Joined: 18 Jun 2009 Posts: 7 Location: Türkiye
|
|
Posted: Sun Aug 09, 2009 3:03 pm |
|
|
Hi friends,
I want use glcd_putc function like printf function.
I mean, we could send data with printf like this: printf("%d",varible);
how can I change and send variable to the glcd like glcd_putc("%d",variable);?
Thanks for help. |
|
|
king of swords
Joined: 18 Jun 2009 Posts: 7 Location: Türkiye
|
|
Posted: Mon Aug 10, 2009 4:03 am |
|
|
Founded=)
I've finally understood that I was dummy.
glcd_putc("qwerty");====>printf(glcd_putc,"qwertyu %d",variable); |
|
|
Raulsoft
Joined: 28 Jan 2010 Posts: 6
|
code for image 240x128 t6963c |
Posted: Thu Jan 28, 2010 7:21 am |
|
|
Hello guys I'm new in the forum.
I need to send an image to 240x128 bmp 240x128 LCD - t6963.
Someone have some example?
Thanks |
|
|
assaad
Joined: 09 Dec 2009 Posts: 37
|
|
Posted: Thu Oct 21, 2010 8:53 am |
|
|
Thank you for the driver, it works without problems. But I would ask about fonts. Does anyone have an example for big fonts, for example to show numbers or characters bigger, for example 16x16 ?
Thank you in advance. |
|
|
noyz
Joined: 31 Jan 2009 Posts: 59
|
|
Posted: Sun Feb 06, 2011 6:01 pm |
|
|
Code: |
//// Connections are as follows: ////
//// /WR - - C4 ////
//// /RD - - C5 ////
//// C//D- - C6 ////
//// /RST- - C7 ////
//// DATA0-7 PORTD0-7 ////
//// LCD's FS is tied low (FS = 0 is 8x8 font) ////
|
How can I change this?
I have a board already connected and need to redefine those.
For example the data pins from glcd are H0-H7 instead d0-d7 on pic.
Pic used is 18f8527. |
|
|
CeMiL_mktrnk
Joined: 21 Mar 2012 Posts: 4
|
|
Posted: Wed Mar 21, 2012 8:12 am |
|
|
noyz wrote: | Code: |
//// Connections are as follows: ////
//// /WR - - C4 ////
//// /RD - - C5 ////
//// C//D- - C6 ////
//// /RST- - C7 ////
//// DATA0-7 PORTD0-7 ////
//// LCD's FS is tied low (FS = 0 is 8x8 font) ////
|
How can I change this?
I have a board already connected and need to redefine those.
For example the data pins from glcd are H0-H7 instead d0-d7 on pic.
Pic used is 18f8527.
|
Data pins from glcd are B0-B7 instead d0-d7 on pic.
Pic used is 18f4620.
But control pins arent all any port. For example I use d3, d2, d1 and d7 pins for data write, data read, C/D and reset, I use d0, d4, d5 for SPI. Also I will connect MS2 to e1 and FS1 to e2.
Can you send me upgraded driver or explain where I have to change?
Please help me urgently. |
|
|
CeMiL_mktrnk
Joined: 21 Mar 2012 Posts: 4
|
|
Posted: Mon Mar 26, 2012 2:19 am |
|
|
Is there anybody who can help me? It is urgent. |
|
|
jeremiah
Joined: 20 Jul 2010 Posts: 1355
|
|
Posted: Mon Mar 26, 2012 7:00 am |
|
|
You're gonna have to do some upfront work then. This is the original code that used ports C and D:
Code: |
struct lcd_pin_def
{
BOOLEAN unused1; // C0
BOOLEAN unused2; // C1
BOOLEAN unused3; // C2
BOOLEAN unused4; // C3
BOOLEAN w_bar; // C4 Write bar active low
BOOLEAN r_bar; // C5 Read bar active low
BOOLEAN cd; // C6 Command/Data BAR 1=command 0=data
BOOLEAN reset_bar; // C7 Reset active low
int data : 8; // PortD=Data bus
};
struct lcd_pin_def LCD;
#byte LCD = 0xf82 // portC address on 18F452
|
The #byte LCD line is what sets the address of that variable to the port addresses.
Since all your control lines are on different ports, you can't do it this way.
You're gonna have to write your own low level write routines that handle the pins, go through the original code and replace the parts where he manages the data and control lines with functions that do the same, so instead of lines like LCD.w_bar = 0, you would have to make a function like lcd_set_write_bar(int1 value) and have it set whichever bit you have as the value you specify.
Since your data is all on one port, it is a bit easier, you just need to do a
#byte lcd_data = PORTB_ADDR
where you specify what PORTB_ADDR is for your chip. Then you can just do "lcd_data = some_value;" when you want to write to the port.
So basically you need to replace all the parts where the data structure is used directly and replace it with functions/macros that do the work using your pins.
If it makes your life easier, you can do some bit mapping by doing something like the following:
#bit lcd_w_bar = PORTD.1
this assumes your write latch is located on pin D1. You have to replace PORTD with whatever the port D address actually is. Note though that this is a standalone variable and not part of a structure.
If you do that, then you can either replace the structure accesses directly with the variable or do what I mentioned earlier and make functions like:
Code: |
void lcd_set_write_bar(int1 value){
lcd_w_bar = value;
}
|
|
|
|
carlos_marr
Joined: 11 Sep 2014 Posts: 1
|
|
Posted: Thu Sep 11, 2014 3:02 am |
|
|
Thank you all for the help, this post has been very useful for me!!
I have a 18f4550 and i could not use port C as command port therefore following Jeremiahs instructions i re-wrote the code as follows:
Code: |
struct lcd_pin_def
{
/*BOOLEAN unused1; // C0
BOOLEAN unused2; // C1
BOOLEAN unused3; // C2
BOOLEAN unused4; // C3 */
BOOLEAN w_bar; // A0 Write bar active low
BOOLEAN r_bar; // A1 Read bar active low
BOOLEAN cd; // A2 Command/Data BAR 1=command 0=data
BOOLEAN reset_bar; // A3 Reset active low
//int data : 8; // PortD=Data bus
};
struct lcd_pin_def LCD;
int LCD_data; // Data Bus
#byte LCD_data = 0xf83 // portD address on 18F4550
#byte LCD = 0xf80 // portA address on 18F4550 |
and replaced all the LCD.data by the new variable LCD_data in the rest of the program.
Now the port A is the command port and it works great with the 18f4550. |
|
|
techn0
Joined: 09 Jun 2011 Posts: 4
|
Not getting LCD to initialize. |
Posted: Tue Oct 07, 2014 8:11 am |
|
|
I am using a PIC18F4580 44 Pin running at 20 Mhz.
I have port d as data just like this code. The control pins are a little different but still on port c. Here is what I changed.
Code: |
struct lcd_pin_def
{
BOOLEAN reset_bar; // C0 RST Reset active low
BOOLEAN w_bar; // C1 WR Write bar active low
BOOLEAN cd; // C2 C/D Command/Data BAR 1=command 0=data
BOOLEAN unused1; // C3
BOOLEAN unused2; // C4
BOOLEAN r_bar; // C5 RD Read bar active low
BOOLEAN unused3; // C6
BOOLEAN unused4; // C7
int data : 8; // PortD=Data bus
};
|
I have confirmed that the program hangs during glcd_init during the following command.
Code: |
glcd_WriteCmd2(TextArea, 0x41);
|
I would like to use hardware rs232 on pins C6 & C7. Will that be possible while using this code and this lcd. I also need pins C3 & C4 for hardware I2C for external flash interface.
I am not able to get the LCD to do anything so far since it hangs during init.
The model lcd is a Lumex LCM-X240128GXX I purchased from digikey.
Any help anyone can provide would be greatly appreciated. |
|
|
techn0
Joined: 09 Jun 2011 Posts: 4
|
I got it working |
Posted: Fri Oct 10, 2014 9:43 am |
|
|
I replaced the MCU with a new one and it seemed to fix the problem. because I am using a TQFP I first installed the chip incorrectly because of the fact the reference dot and the microchip label are 90 degrees off. I assumed the chip was good because I was able to use serial and blink a (heartbeat) LED.
After further testing with an 8 channel logic analyzer I realized that not all of the data port was outputting data. |
|
|
horst
Joined: 10 Nov 2014 Posts: 1
|
|
Posted: Mon Nov 10, 2014 11:43 am |
|
|
Interesting, there's someone still struggling with this T6963 thing...
Hi guys,
I'm also using this controller in a 128x128 pixel LCD.
Did anybody got the Screen Peek function to work?
I'm experiencing some weird effects using Screen Peek.
Reading the graphic screen works as expected, but my application uses both text and graphic buffer in "OR" mode. The text buffer is empty except the upper line showing some pure text information, followed by a few graphs below.
Screen Peek delivers the very first scan line of the text, but then only zeroes until the graph area starts.
If only the text screen was filled for a test the data delivered by Screen Peek is somewhat skewed after the first scan line, as if the reading position would not correspond to the value sent with Set Address Pointer in every case.
Anyone here experiencing something similar?
Horst |
|
|
|