LCD 4x20

General discussion forum - for all that doesn't fit in any other category.
Post Reply
skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

LCD 4x20

Post by skagon »

Hello to all!

I just got my SD HxC and I have a request:
I've got some very nice 4x20 VFDs here and a shitload of 4x20 LCDs. I know that the interface for HD44780 character LCDs is always the same, so they can be connected on the HxC. The only thing needed would be some code to support the extra characters from the firmware of the PIC. So, I was wondering whether you'd be willing to extend the code in the firmware to support a 4x20 LCD?
Actually, even the init routines are the same, the only thing needed to support a 4x20 instead of a 2x16 is, really, writing the extra characters. The 4x20 uses the same two addresses (0x0000 and 0x0040) on the HD44780, so the first 20 characters on the first address go to line 1, the next 20 characters wrap around to line 3, and the first 20 characters of the second address go to line 2 and the next 20 characters wrap to line 4. So that would be really easy to implement. The only thing needed would be to decide what to show in the 2 extra lines.
Oh, and... could you please turn the cursor off completely?

Cheers!
Live long and prosper...

skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

Re: LCD 4x20

Post by skagon »

Anything? No comments?
Live long and prosper...

Jeff
Site Admin
Posts: 8092
Joined: Fri Oct 20, 2006 12:12 am
Location: Paris
Contact:

Re: LCD 4x20

Post by Jeff »

skagon wrote:Anything? No comments?
mhm the problem is that we didn't plan to use 4*20 lcd screen. these screens are too big.

skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

Re: LCD 4x20

Post by skagon »

Jeff wrote:mhm the problem is that we didn't plan to use 4*20 lcd screen. these screens are too big.
Too big for what?
The extra horizontal characters are useful for a bigger portion of the filename being visible and the extra lines help looking at the next and previous filename. It's a win-win situation. Besides, I didn't ask you to make me a version with a 4x20 display, just the firmware so I can use the ones I have. I'm sure there are other people around here who would like to do the same.
Live long and prosper...

Jeff
Site Admin
Posts: 8092
Joined: Fri Oct 20, 2006 12:12 am
Location: Paris
Contact:

Re: LCD 4x20

Post by Jeff »

skagon wrote: Too big for what?
For a 3'1/2 front panel for example.
skagon wrote: The extra horizontal characters are useful for a bigger portion of the filename being visible and the extra lines help looking at the next and previous filename. It's a win-win situation. Besides, I didn't ask you to make me a version with a 4x20 display, just the firmware so I can use the ones I have. I'm sure there are other people around here who would like to do the same.
The modifications seems to be easy to do but in fact a large part of the user interface need to be rewriten to support the extra 2 lines.

A question : with with machine are you using the HxC ?

skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

Re: LCD 4x20

Post by skagon »

For the time being, I'm not using it with anything. The plan is to make an external enclosure and use it with a series of machines that I have: Amiga, Atari ST, Spectrum 48k, Spectrum +3, SAM Coupe, Amstrad 6128.
About the LCD, I was thinking that it might be possible, with some clever programming, to make a version which will be compatible with both 2x16 and 4x20. The 2x16 will simply not show the extra characters. The controller is the same, so there's no issue of 'compatibility'.
Anyway, it's up to you. I will be making the enclosure external with its own power supply, so I have lots of room for a 4x20 VFD, which I also want to place at an angle of around 30° so the display is better visible.
When I do that, I'll post some pictures here.
Cheers!
Live long and prosper...

pulkomandy
Posts: 132
Joined: Sun Mar 20, 2011 6:55 pm

Re: LCD 4x20

Post by pulkomandy »

The microcontroller is already very busy with handling the floppy drive (there's some rather crazy, insanely optimized code going on to do that). I think it's not wise to spend precious memory bytes on handling the screen ?

Remember that for most computer, it's possible to use host software support to make it easy to load floppies from the computer screen and keyboard. So the small screen isn't too much of a problem anymore.

skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

Re: LCD 4x20

Post by skagon »

pulkomandy wrote:The microcontroller is already very busy with handling the floppy drive (there's some rather crazy, insanely optimized code going on to do that). I think it's not wise to spend precious memory bytes on handling the screen ?
It's up to the creators to decide. In any case, I doubt that 48 bytes of RAM (which can be freed anyway) will make much of a difference. Besides, when the "drive" is working, there's no interaction with the display.
pulkomandy wrote:Remember that for most computer, it's possible to use host software support to make it easy to load floppies from the computer screen and keyboard. So the small screen isn't too much of a problem anymore.
If you bothered to check what I wrote, you'd see that at least half of my computers have no host software (Spectrums, SAM Coupe, Acorn BBC, Acorn A3000).
Live long and prosper...

pulkomandy
Posts: 132
Joined: Sun Mar 20, 2011 6:55 pm

Re: LCD 4x20

Post by pulkomandy »

Well then, write the software !

The Amstrad CPC version being z80 based (and open source), I think it shouldn't be too hard, little more than redirecting the text output to your OS routines and some FDC access code. Since this version is already a straight forward port of the Atari ST one, it should have all the nice module separation you need to do this easily.

skagon
Posts: 10
Joined: Wed Aug 01, 2012 4:06 am
Location: Athens, Greece
Contact:

Re: LCD 4x20

Post by skagon »

pulkomandy wrote:Well then, write the software !

The Amstrad CPC version being z80 based (and open source), I think it shouldn't be too hard, little more than redirecting the text output to your OS routines and some FDC access code. Since this version is already a straight forward port of the Atari ST one, it should have all the nice module separation you need to do this easily.
You know, I should have known there would be at least one "denialist" in here. It happens everywhere. You suggest a small improvement and immediately you get flamed by someone who doesn't agree, not because the suggestion is bad, but because the suggestion is not useful to them personally. And typically, they tell you to do it "their way" and stop suggesting something new.
Much like the chap above. Instead of improving the device itself, the answer is first "can't be done, too complicated, insanely optimised", then "do it like me, use the programme" and finally "write your own programme". Typical.

Well, sorry I suggested anything. If you don't want the LCD, disconnect it from the HxC and throw it away altogether. I don't want to use programmes for each computer and even more, I don't want to write them. The fact that the HxC comes with an LCD means that the guys who made it, think an LCD is useful. So do I. And I think that a slightly bigger LCD will be even better. And finally, I have written a lot of code for embedded LCDs and I know that what I ask is very easy (from the LCD side). I can't see a downside. A 4x20 LCD on eBay costs a few dollars so it's dirt cheap, and I believe it would enhance the usability of the HxC device.
That's all I had to say. If you want to sit there with your eyes closed, saying "no no no no no" to everything, be my guest.
Live long and prosper...

Post Reply