8x8 game system on a LCD

Post here to discuss the original 8x8 Game System.

Moderators: Chuckt, Garth, bitfogav

Post Reply
User avatar
captalex
decided to stick around...
decided to stick around...
Posts: 28
Joined: Mon Mar 21, 2011 3:00 am
Contact:

8x8 game system on a LCD

Post by captalex » Fri Mar 25, 2011 11:50 pm

Was wondering, if anyone else was up for creating the LCD version of the 8x8 matrix game system.( maybe using a 128x64 LCD)!

User avatar
brad
Site Admin
Site Admin
Posts: 2578
Joined: Fri Mar 26, 2010 10:30 pm

Re: 8x8 game system on a LCD

Post by brad » Sat Mar 26, 2011 10:07 pm

I have always wondered about a game system with an LCD - but at the moment my heart is set on LED's still!

Having said that, I would certainly show a keen interest if anyone were to venture into the world of LCD based games. Especially since you can get those LCD displays for quite cheap!

Are you looking at making one?

What language would you program it in?

User avatar
bitfogav
Moderator
Moderator
Posts: 915
Joined: Sun Mar 28, 2010 9:03 pm
Location: United Kingdom
Contact:

Re: 8x8 game system on a LCD

Post by bitfogav » Sun Mar 27, 2011 10:23 pm

Sound like a good idea, sure electronics do a board that I brought some time ago but I have haven't got round to experimenting with it yet?

http://www.sureelectronics.net/goods.php?id=978

They say its a clone of PIC24F Starter Kit by Microchip. With the introduction of a128x64 LCD screen and five tactile switches.

it comes with MPLAB C30 Compiler, so I guess you would have to programme it using C language?.
sureelcd.jpg
sureelcd.jpg (37.63 KiB) Viewed 12891 times

User avatar
brad
Site Admin
Site Admin
Posts: 2578
Joined: Fri Mar 26, 2010 10:30 pm

Re: 8x8 game system on a LCD

Post by brad » Mon Mar 28, 2011 4:58 am

Quite an interesting piece of kit there bitfogav.

I guess that once you know basic, it wouldn't be too much of a hard transition moving over to C.

Any idea of the refresh rate with these displays? because the 16x2 LCD displays seem to be really slow which means they are not very practical for animations.

User avatar
bitfogav
Moderator
Moderator
Posts: 915
Joined: Sun Mar 28, 2010 9:03 pm
Location: United Kingdom
Contact:

Re: 8x8 game system on a LCD

Post by bitfogav » Mon Mar 28, 2011 5:29 am

well heres a refresh rate example of a 128x64, but on the system above the refresh rate seems a little bit slower..


User avatar
brad
Site Admin
Site Admin
Posts: 2578
Joined: Fri Mar 26, 2010 10:30 pm

Re: 8x8 game system on a LCD

Post by brad » Tue Mar 29, 2011 10:10 pm

I have actually thought about interfacing to an old nintendo gameboy LCD screen. They have three shades of grey, are cheap and there's quite a bit of content available out there in order to get them to work. Since the screen was designed for games - it has a great refresh rate. (as long as the microcontroller can keep up)

User avatar
captalex
decided to stick around...
decided to stick around...
Posts: 28
Joined: Mon Mar 21, 2011 3:00 am
Contact:

Re: 8x8 game system on a LCD

Post by captalex » Wed Mar 30, 2011 2:37 am

Yes, i was planning on making one using a pic 18f4550 microcontroller and programming it in C, to save time,
but the thing is although LCD consumes less power compared to their LED brethren, they seem abit harder to code for, especially when it comes to custom character creation which is only limited to 8 characters. Any way any one that has such an expertise could surely step in.!

User avatar
brad
Site Admin
Site Admin
Posts: 2578
Joined: Fri Mar 26, 2010 10:30 pm

Re: 8x8 game system on a LCD

Post by brad » Sat Apr 02, 2011 6:58 am

Sorry for the late reply, I've been so busy with other projects!

I have never actually experimented with Graphics on an lcd display before but they are designed to interface with microcontrollers quite easily.

You will then need to come up with a sub routine that takes care of sending the data out to the LCD display. I don't imagine that would be too hard, but it will be a little bit of a learning curve. Once you have that - you then want to look at manipulating your data / updating your data before copying it to the graphics registers (which will then get sent out to your LCD)

Here is my code for a 32 x 32 pixel display to actually draw the graphics. Before I get to this routine - I have already copied the updated graphics data in to the outputdata variables.

Code: Select all

Sub DisplayGraphics()
    row = 0
    For x = 0 To 29
        PORTD = OutputData(x)
        PORTB.bits(0) = 1
        PORTB.bits(0) = 0
        PORTD = OutputData(x) >> 8
        PORTB.bits(1) = 1 
        PORTB.bits(1) = 0
        PORTD = OutputData(x) >> 16
        PORTB.bits(2) = 1 
        PORTB.bits(2) = 0
        PORTD = OutputData(x) >> 24
        PORTB.bits(3) = 1 
        PORTB.bits(3) = 0
        PORTD = %00000001 << row
        If x < 8 Then
           PORTB.bits(4) = 1
           PORTB.bits(4) = 0
           PORTD = 0              ' we need to clear the other 74373's otherwise we get ghosting!
           PORTB.bits(5) = 1
           PORTB.bits(5) = 0
           PORTB.bits(6) = 1
           PORTB.bits(6) = 0
           PORTB.bits(7) = 1
           PORTB.bits(7) = 0
        ElseIf x > 7 And x < 16 Then
            PORTB.bits(5) = 1
            PORTB.bits(5) = 0
           PORTD = 0
           PORTB.bits(4) = 1
           PORTB.bits(4) = 0
           PORTB.bits(6) = 1
           PORTB.bits(6) = 0
           PORTB.bits(7) = 1
           PORTB.bits(7) = 0
        ElseIf x > 15 And x < 24 Then
            PORTB.bits(6) = 1 
            PORTB.bits(6) = 0
           PORTD = 0
           PORTB.bits(4) = 1
           PORTB.bits(4) = 0
           PORTB.bits(5) = 1
           PORTB.bits(5) = 0
           PORTB.bits(7) = 1
           PORTB.bits(7) = 0 
        ElseIf x > 23 Then
            PORTB.bits(7) = 1 
            PORTB.bits(7) = 0
           PORTD = 0
           PORTB.bits(4) = 1
           PORTB.bits(4) = 0
           PORTB.bits(6) = 1
           PORTB.bits(6) = 0
           PORTB.bits(5) = 1
           PORTB.bits(5) = 0
        EndIf
        PORTE.bits(0) = 0       'Turn the LED's on (by enabling the 74373 outputs)
        DelayUS(500) 
        PORTE.bits(0) = 1
        Inc(row)
        If row = 8 Then
            row = 0
        EndIf
        PORTD = 0
        PORTB = %11111111
        PORTB = %00000000
    Next
End Sub    
Hopefully this helps a bit :)

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests