View previous topic :: View next topic |
Author |
Message |
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Thu Dec 03, 2015 11:39 am Post subject: Display 40x4 (E2 not inicialized) + Atmega64L |
|
|
Good morning sir Mrshilov
In another project working with 40 x 4 display and ATmega88 perfectly it worked the E1 and E2. Now I'm on another project that uses the same display 40 x 4 and Atmega64L-8mU . I used the same library exchanging addresses as follows because I am using PORTC for display control :
.equ Lcdddr = $14
.equ Lcdport = $15
Lines 1 and 2 ( E1 ) works perfectly , but the lines 3 and 4 ( E2 ) do not function . I realize that the display does not correctly initialize the E2.
I have to change something more in the new library ?
Looking forward , thanks.
(BASCOM-AVR version : 2.0.7.8 , Latest : 2.0.7.8 ) |
|
Back to top |
|
|
kimmi
Joined: 24 Feb 2006 Posts: 1922 Location: Denmark
|
Posted: Thu Dec 03, 2015 5:27 pm Post subject: |
|
|
did you check if ATmega103 compatibility mode is on ? _________________ / Kim |
|
Back to top |
|
|
Juergen Bitzer
Joined: 03 Oct 2004 Posts: 25 Location: Reichshof
|
Posted: Thu Dec 03, 2015 5:42 pm Post subject: |
|
|
Maybe JTAG is enabled ? |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Thu Dec 03, 2015 7:43 pm Post subject: |
|
|
Already tested compatibility mode 103 enabled and disabled and also enabled JTAG and also disabled to continue writing only the first two lines. The third and fourth line does not write . I'm pretty sure that is the library file that must have some adjustment .
is attached library file " lcd4e2-64L - portc.lib "
I look forward opinions about what might be wrong with this bibioteca .
Looking forward , thanks.
@ Edit by Mod source code removed !!! |
|
Back to top |
|
|
MWS
Joined: 22 Aug 2009 Posts: 2262
|
Posted: Thu Dec 03, 2015 9:17 pm Post subject: |
|
|
Read the help how Config Lcdbus and especially in which combination with another statement it would be used.
Well, only if you would use bus mode at all. |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Thu Dec 03, 2015 10:32 pm Post subject: |
|
|
please someone can analyze what 's wrong in bibioteca $ lib " lcd4e2-64L - portc.lib " attached above. I started working now with AVR , three months , so I'm having these difficulties. by need for someone to analyze the library and help me . |
|
Back to top |
|
|
MWS
Joined: 22 Aug 2009 Posts: 2262
|
Posted: Thu Dec 03, 2015 11:14 pm Post subject: |
|
|
gilson163 wrote: | please someone can analyze what 's wrong in bibioteca $ lib " lcd4e2-64L - portc.lib " attached above. I started working now with AVR , three months , so I'm having these difficulties. by need for someone to analyze the library and help me . |
Do you even read the answers given to you? |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Fri Dec 04, 2015 9:33 am Post subject: |
|
|
I read congifbus , but I'm not working with BUS but with PORT to control the display . What's weird is that if I boot primiro E1 and E2 after , E1 and E2 works prefeitamente not. But if I boot first E2 and then E1 , E2 and not E1 works perfectly . May be the minimum times of E1 and E2 software in the Library ? |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Fri Dec 04, 2015 10:55 pm Post subject: |
|
|
Good afternoon
Below follows library, please can someone help me with the E2 startup lcd 40 x 4 that is not working properly. I have to finish an urgent development. Please have urgency.
tanks,
copyright = MCS Electronics
www = http://www.mcselec.com
email = avr@mcselec.com
comment = Optimized LCD library
libversion = 1.00
date = 2 februari 2001
statement = No SOURCE code from the library may be distributed in any form
statement = Of course this does not applie for the COMPILED code when you have a BASCOM-AVR license
history = No known bugs.
@ Edit by Mod source code removed !!! |
|
Back to top |
|
|
techknight
Joined: 21 Apr 2008 Posts: 231
|
Posted: Mon Dec 07, 2015 5:33 pm Post subject: |
|
|
Those displays have 2 chip select lines. the upper and lower half have their own select lines. The upper two lines work because that chipselect line is functioning. The lower does NOT work because you have an issue with the chip select for that half.
Check that connection, and make sure it is defined in your program to what port pin it is on. |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Tue Dec 08, 2015 9:53 am Post subject: |
|
|
yes I checked and is working. And the interesting, if I set $ crystal = 2000000 E1 and E2 work properly. and with $ crystal = 8000000 NOT Works E2. What should I check ? |
|
Back to top |
|
|
Paulvk
Joined: 28 Jul 2006 Posts: 1257 Location: SYDNEY
|
Posted: Tue Dec 08, 2015 10:35 am Post subject: |
|
|
Check your fuse bits the clock divided by 8 this is set in the chip from the factory!!
So its 2Mhz
Regards Paul |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Tue Dec 08, 2015 5:13 pm Post subject: |
|
|
The XDIV divider is configured not dividor , XDIV = 0 . What else could it be?
thank you |
|
Back to top |
|
|
albertsm
Joined: 09 Apr 2004 Posts: 5913 Location: Holland
|
Posted: Tue Dec 08, 2015 9:47 pm Post subject: |
|
|
add this to your code :
config clockdiv=1
or
CLOCKDIVISION= 1
depending on the used processor. _________________ Mark |
|
Back to top |
|
|
gilson163
Joined: 30 Sep 2015 Posts: 35
|
Posted: Wed Dec 09, 2015 9:54 am Post subject: |
|
|
added clockdivision = 1 and also did not enable E2. I've tried all possibilities as described above in the forum. Any more suggestions Mark?
Thanks, |
|
Back to top |
|
|
|