6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Thu Nov 14, 2024 6:50 am

All times are UTC




Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2
Author Message
PostPosted: Fri Jan 29, 2021 3:35 pm 
Offline
User avatar

Joined: Mon May 12, 2014 6:18 pm
Posts: 365
I got one of these for very cheap though never got it going: https://datasheetspdf.com/pdf-file/5363 ... /EW32F50/1

The one I have requires -27v for contrast. How are you planning on generating the negative voltage? I see 8BIT is using an AA9090A running off 12v. Someone got one of the LCDs going using three 9v batteries, though I was hoping to generate it from the same 5v power source as everything else.

One thing, at least for the model I have, is that you need to start up the LCD first then apply the negative voltage after it's started. Not sure if that's something useful to try for yours.


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 4:04 pm 
Offline

Joined: Fri Dec 21, 2018 1:05 am
Posts: 1114
Location: Albuquerque NM USA
I'm using a separate adjustable bench power supply to provide the negative voltage right now. Once I got it working, I will need to figure out how to generate -16V from 5V, don't think a simple charge pump doubler will do, need a bona fide booster converter.
Bill


Top
 Profile  
Reply with quote  
PostPosted: Fri Jan 29, 2021 6:20 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 9:02 pm
Posts: 1746
Location: Sacramento, CA
The Z-80 has DMA capability which would increase efficiency for refreshing the display. I would not give up on that idea. I did do a composite video graphical display with an ATMega1284 which included the AVR doing Line, Box, and circle generation along with text. I cannot speak to the speed at this point as I don't recall, but it did work. It also had the option to output to an LCD.

Daryl

_________________
Please visit my website -> https://sbc.rictor.org/


Top
 Profile  
Reply with quote  
PostPosted: Sat Jan 30, 2021 1:30 pm 
Offline

Joined: Fri Dec 21, 2018 1:05 am
Posts: 1114
Location: Albuquerque NM USA
In the Z80 world I probably would use a Z280 which has 4 DMA channels built in. Since this is 6502 forum, I thought I'd try it again using my newly developed 6502 SBC with the help of a CPLD I/O board. The CPLD I/O board was a CF drive interface board re-purposed as LCD interface. I'll need to make some cuts and jumpers and reprogram the CPLD, but conceptually it looks like the attached photos.


Attachments:
File comment: CRC65 SBC with CPLD I/O board driving the UG-32F01 320x240 LCD display
DSC_63310130.jpg
DSC_63310130.jpg [ 1.25 MiB | Viewed 463 times ]
DSC_63320130.jpg
DSC_63320130.jpg [ 1.29 MiB | Viewed 463 times ]
Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 31, 2021 2:51 pm 
Offline

Joined: Fri Dec 21, 2018 1:05 am
Posts: 1114
Location: Albuquerque NM USA
Daryl,
Sometimes just KNOWING that I'm on the right track is enough to solve the problem. Before I dive into your ATmega program trying to understand yet another assembly language, I thought I take another fresh look at my LCD interface logic and software since I'm using a new CPLD board with 6502. I found a couple mistakes and fixed them. Now I can actually display a pattern on the LCD! This is very encouraging.


Attachments:
File comment: UG-32F01 displaying a pattern
image1.JPG
image1.JPG [ 835.84 KiB | Viewed 440 times ]
Top
 Profile  
Reply with quote  
PostPosted: Sun Jan 31, 2021 6:04 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 9:02 pm
Posts: 1746
Location: Sacramento, CA
I'm glad you are making headway! If it helps, the only file you need to focus on is "vidgen.asm" It does all of the refresh based on an interrupt.

In Vid-LCD.asm, I set up a timer interrupt to provide 1 interrupt every 55.6us (microseconds). This does a refresh of 1 line. Doing the math, it completes a frame every 13.3mS, which is a 74.9Hz frame rate.

I don't recall the time needed to generate 1 line, but counting cycles in the code would provide that data.

Hope that helps.

Daryl

_________________
Please visit my website -> https://sbc.rictor.org/


Top
 Profile  
Reply with quote  
PostPosted: Mon Feb 01, 2021 1:38 am 
Offline

Joined: Fri Dec 21, 2018 1:05 am
Posts: 1114
Location: Albuquerque NM USA
This is the program driving the display in my previous post. The display memory is 10K from 0xC000-0xE7FF. It started off with random display data and then filled it with one-byte pattern every frame. It took 2 minutes 10 seconds to fill the entire display this way. So that's 10K frames in 130 seconds or 74 frames per second, which is what I measured with a scope. This is 6502 is running flat out moving display data to the LCD display, not very good use of a 6502, but now I understand how it works, I can start to replace the software with hardware.


Attachments:
tstLCD.txt [2.07 KiB]
Downloaded 60 times
Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 22 posts ]  Go to page Previous  1, 2

All times are UTC


Who is online

Users browsing this forum: No registered users and 16 guests


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 post attachments in this forum

Search for:
Jump to: