CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

KS0108 problem with the initialization

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
MegatroniC



Joined: 08 Dec 2009
Posts: 35

View user's profile Send private message ICQ Number

KS0108 problem with the initialization
PostPosted: Wed Jun 27, 2012 7:12 am     Reply with quote

Hi there.
I have a problem with initialization.
I use driver HDM64GS12.

Sometimes after the start, missing pixels in the image, sometimes it's okay.

After initialization glcd_init (ON), I put a timeout of 200ms.
PIC18F4620 chip is to 8MHz
fuses:

Code:
#FUSES NOWDT                    //No Watch Dog Timer
#FUSES WDT128                   //Watch Dog Timer uses 1:128 Postscale
#FUSES INTRC_IO                 //Internal RC Osc, no CLKOUT
#FUSES PUT                      //Power Up Timer
#FUSES BORV27                   //Brownout reset at 2.7V
#FUSES NOPBADEN                 //PORTB pins are configured as digital I/O on RESET
#FUSES NOLPT1OSC                //Timer1 configured for higher power operation
#FUSES MCLR                     //Master Clear pin used for I/O
#FUSES NOLVP                    //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O
#FUSES NOXINST                  //Extended set extension and Indexed Addressing mode disabled (Legacy mode)
#FUSES PROTECT                  //Code protected from reads
#FUSES CPD                      //Data EEPROM Code Protected
#FUSES NOWRTD                   //NO Data EEPROM write protected


Do not use the reset signal for display, it is connected to 5V

What can you explain that?

thanks Smile
Ttelmah



Joined: 11 Mar 2010
Posts: 19368

View user's profile Send private message

PostPosted: Wed Jun 27, 2012 8:36 am     Reply with quote

I'd put the delay _before_ you try to initialise the display.
Manufacturers data sheet for your unit, will specify how long is needed after power-on, before it is ready to work. It'll also specify what the unit considers to be 'power on'. It is quite common for these units to need 75mSec or more after the PIC wakes, before they are ready to start working.

Best Wishes
MegatroniC



Joined: 08 Dec 2009
Posts: 35

View user's profile Send private message ICQ Number

PostPosted: Thu Jun 28, 2012 12:19 am     Reply with quote

Thanks for the reply. Smile

in the datasheet says to wait more than 30ms after power on.

I put a delay before initialization - 100ms, but has no effect.

Here's the problem:

when it works well




when there is a problem




regards Smile


edit:
display - VATRONIX TG12864D0-02WA0_A00
temtronic



Joined: 01 Jul 2010
Posts: 9174
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Thu Jun 28, 2012 6:10 am     Reply with quote

How 'solid' is the 5 volt supply ? Good for 1 amp or more?
Do you have bypass caps + filter caps near the PIC and the LCD ?
Is this a PCB or breadboard?
Are connections to LCD soldered or jumpers?
It _might_ still be a timing issue, try pwrup-delay500ms-initLCD-delay500ms-rest of program.

try 'things' ,see what happens, report back,

hth
jay
MegatroniC



Joined: 08 Dec 2009
Posts: 35

View user's profile Send private message ICQ Number

PostPosted: Fri Jun 29, 2012 6:33 am     Reply with quote

temtronic wrote:
How 'solid' is the 5 volt supply ? Good for 1 amp or more?


The scheme is fed through the stabilizer 5 volts.
I put the transformer that provides up to 2 amps, but has no effect.

temtronic wrote:

It _might_ still be a timing issue, try pwrup-delay500ms-initLCD-delay500ms-rest of program.


It also does not help :(

temtronic wrote:

Is this a PCB or breadboard?
Are connections to LCD soldered or jumpers?


Use a breadboard.





I try to put filter capacitors ...

The problem occurs most often in rapidly switching the power, and very rarely in the power when it was a long time off.

Greetings to all. Smile
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group