PDA

View Full Version : Dos


billk80
2001/11/12, 05:40 PM
I just bought 20*4 LCD.

It is working under windows 2000.

I want to ask I can use under DOS.

If I can How can i do?

albataur
2003/05/31, 08:27 AM
I have the same question.
I would just display a message ("Loading ...") while windows load.
Is it possible under DOS ?
Thx

CF Tech
2003/05/31, 09:05 AM
Try this:

mode com1:19200,n,8,1
echo Loading . . . > COM1

I do not have a display here to test it on, but I think that should be pretty close.

The thread "send text from command line (http://www.crystalfontz.com/forum/showthread.php?&threadid=1153)" goes into more details.

albataur
2003/05/31, 09:39 AM
Originally posted by CF Tech
Try this:

mode com1:19200,n,8,1
echo Loading . . . > COM1

I do not have a display here to test it on, but I think that should be pretty close.

The thread "send text from command line (http://www.crystalfontz.com/forum/showthread.php?&threadid=1153)" goes into more details.

That's all ?!?
Thx ;)

I think for a LCD on parallel port it's just

mode com1:19200,n,8,1
MODE LPT1=COM1
echo Loading . . . > LPT1

No ?

CF Tech
2003/05/31, 10:35 PM
No, the parallel port is not that easy.

spock
2003/06/01, 02:05 AM
It isn't that hard, either, if you know a little bit about programming. If you have a parallel LCD module, perhaps I can make you a little DOS proggie to display a set message, if you'd like. Just give me the particulars of your LCD. ;)

albataur
2003/06/01, 03:18 AM
Originally posted by spock
It isn't that hard, either, if you know a little bit about programming. If you have a parallel LCD module, perhaps I can make you a little DOS proggie to display a set message, if you'd like. Just give me the particulars of your LCD. ;)

Thx a lot :D That would be nice.
I wait for receiving a CFAH2004A-TMI-JP (20x4 blue).
Are you able to do something ?

PS : sorry for my english, I'm french ;)

spock
2003/06/02, 08:52 AM
I will probably be needing your wiring layout, but I'll try to make it configurable through a txt file, as well as the message displayed.
Oh, I can also program a custom graphic, only it has to fit into 8 characters. If you have any idea, draw a black and white bitmap, not bigger than 8 characters, each 5x8, and send it over.
Wait up, for a while!

Au revoir !

albataur
2003/06/02, 10:03 AM
Originally posted by spock
I will probably be needing your wiring layout, but I'll try to make it configurable through a txt file, as well as the message displayed.
Oh, I can also program a custom graphic, only it has to fit into 8 characters. If you have any idea, draw a black and white bitmap, not bigger than 8 characters, each 5x8, and send it over.
Wait up, for a while!

Au revoir !

About the wiring layout, there will be something like this :
http://www.jackypc.com/articles/106/shema.gif

About the custom graphic I'm going to try to make one.

Can I give the code to other french (with your signature of course :D ) ?

Thank you again !

spock
2003/06/02, 01:59 PM
Do you want the sourcecode as well? I was thinking of giving you just the exe file! Can you find Turbo C++ DOS compiler? Anyway, if you really want it, I'll... think about it! ;)
About the wiring, the pic you linked does not work, so...
Anyway, draw what you want, fix the wiring and let me know... okay?

Adieu, mon ami !

CF Tech
2003/06/02, 10:53 PM
There is a common schematic in this thread (http://www.crystalfontz.com/forum/showthread.php?threadid=562).

albataur
2003/06/03, 09:51 AM
Originally posted by spock
Do you want the sourcecode as well? I was thinking of giving you just the exe file! Can you find Turbo C++ DOS compiler? Anyway, if you really want it, I'll... think about it! ;)
About the wiring, the pic you linked does not work, so...
Anyway, draw what you want, fix the wiring and let me know... okay?

Adieu, mon ami !

Yes it would perfect if you gave me the source ! :)
It isn't difficult to find a compiler I think ...
I will try to draw a sandglass and I will send it you
Sincerely thanks ;)

@++

spock
2003/06/03, 05:42 PM
So, you want the source, eh...? I'm still thinking here...!
Oh, well, what the hell, besides, it's no big secret anyway! Just draw what you want (what's a sandglass anyway?), and I'll do the rest.

albataur
2003/06/04, 07:19 AM
Yes I want the source (if it's possible ;)). Like that I will be able to modify the program.
So, the message is "Chargement ..." with a pic of sand glass :


http://www.zone-cg.com/autres/lcd_loading.gif

Thanks :)

@+

spock
2003/06/04, 08:24 AM
Oh, that's what you meant with "sandglass"...! Riiight! Okay, no problem there! Most probably the message will be user-configurable, if I'm satisfied with the code. On the other hand, since you'll have the sourcecode, I don't need to make anything user-configurable...! Okay... I settled this with myself! Proggie coming right up !

albataur
2003/06/07, 02:10 AM
Originally posted by spock
Proggie coming right up !

Cool :D I wait that impatiently ;)

spock
2003/06/07, 11:42 AM
I hope it works! You'll find some remarks in the source, but I hope you'll understand it.
Anyway, get it here: http://skagon.teamfraud.com/pub/LCDWRITER.ZIP
We'll talk about the licence agreement later!

Appréciez !

albataur
2003/06/09, 06:04 AM
Thanks a lot :) :)
But ... it seems to do not run :(
It happens nothing when sb opens lcdwriter.exe in dos...
Do you know what is the problem ?

spock
2003/06/09, 03:31 PM
Well... heh... see... all the "happenings" are supposed to be taking place on the LCD and NOT on screen! That's why... Would you like it to show something on the computer screen?

albataur
2003/06/13, 09:01 AM
No no, it isn't useful because it's a message while the computer boots.
Three personnes have tested and they said that there is nothing on the LCD. But I will be able to say you exactely when I will have mine.

spock
2003/06/13, 10:03 AM
Well, that's bad... mine works perfectly. Do your friends have the same wiring, like the one you showed me? Oh, of course, it won't work if you run the program under Windows, especially NT-based, like XP or 2000.
I'll check again, maybe it's the speed of your systems. My DOS programming is done on a 386 system. Maybe I'll plug my little character LCD on my main computer (which now has a graphic 320x240 LCD), just to check!
By the way, have you found any DOS C++ compiler yet?

I'll get back to you!

albataur
2003/06/13, 10:26 AM
Originally posted by spock
Well, that's bad... mine works perfectly. Do your friends have the same wiring, like the one you showed me? Oh, of course, it won't work if you run the program under Windows, especially NT-based, like XP or 2000.
I'll check again, maybe it's the speed of your systems. My DOS programming is done on a 386 system. Maybe I'll plug my little character LCD on my main computer (which now has a graphic 320x240 LCD), just to check!
By the way, have you found any DOS C++ compiler yet?

I'll get back to you!

Hum ... hum ... I think that is the problem :cool:
About the compiler I have visual studio, but I believe it's only for win32 appli ? Or with gcc maybe :) ?

spock
2003/06/13, 06:25 PM
Actually, it should be possible with Visual C++, selecting console application, but I cannot be sure; have never tried gcc. I'm using Borland Turbo C++ and it works perfectly.
If you'd like to test the program, the way to go is make a boot disk, boot DOS, and run the program from there. Windows do not allow access of the ports without using special libraries (winio or dlportio, for example).
Oh, and if you do get it working, it'll have a small glitch in the display; I'll be posting a revised version tomorrow!

Au revoir !

spock
2003/06/17, 07:25 AM
Well... tomorrow was a little offset! So, the revised version of the program is http://skagon.teamfraud.com/pub/LCDWRITE.ZIP and it contains both source code in Turbo C++ and an executable, running perfectly in DOS, on my beloved 386. Sorry, but I don't have the time to disconnect my graphic LCD from my main system and connect the petite 4x20 character one!

Do tell me if it works!

Voyez-vous !

albataur
2003/06/17, 09:38 AM
Oki tanks :)

I wait my LCD and I tall you if it's run

@+

Lemming
2003/07/07, 02:53 PM
This piece of software was what I was looking for...

One 'but' though: how should the source be modified to use on a 40*4 display? Just make the strings longer, or isn't that going to work? Don't really know anything about the language...

Thanks...

spock
2003/07/07, 09:15 PM
There has to be serious modification for it to work properly on a 4x40 display. Would you be interested in a new program? The language is plain Turbo C++, nothing special.

Glad you liked my program!

Lemming
2003/07/08, 03:54 AM
I sure would be interested. Would be really cool to have. All of such programs I've found (two I guess) never reached beyond a 20*4 display.

spock
2003/07/08, 06:29 AM
I'm okay with that, just tell me the wiring scheme you followed -- not much space for innovation here, but you can never be too careful -- and I'll see what I can do.
By the way, what is the "other" program you found? ;)

Lemming
2003/07/08, 12:23 PM
I've used the 'standard' wiring scheme floating on the net: http://www.afsvlaanderen.be/temp/4x40_schaltplan.gif

The other program is also a small DOS utility called lcdprint. Don't know where I got it from, just found it on the web somewhere sometime...

WillGonz
2003/07/08, 12:44 PM
How would you do the hour glass graphic? Do you use custom chars. or can you control the indivual pixels?

WillGonz

spock
2003/07/15, 01:03 PM
Well, sorry for not having made that proggie yet. Have been kind of busy lately.
Anyway, yes, that graphic can only be done using custom characters, as the HD44780 does not allow direct pixel manipulation. Since that 4x40 LCD uses two HDs, there are 16 custom characters available, eight for the two top rows and eight for the two bottom.
So, if you need any bigger graphic, I'd be glad to make it happen! ;)

How about you, albataur, have you gotten your character LCD yet? Is it working? I'm still waiting!

LeFreak
2003/09/14, 05:47 PM
Hi I'm Italian, I don't speak english very well so I have a question.
My pc has win2K with service pack 4 and I'm waiting a 20x4 display, a CFAH2004A-YMC-JP, can you compile for me a program to do the same like DOS?
Thank you.
Bye.

LeFreak
2003/09/14, 05:47 PM
Hi I'm Italian, I don't speak english very well so I have a question.
My pc has win2K with service pack 4 and I'm waiting a 20x4 display, a CFAH2004A-YMC-JP, It's a parallel HD44780 Display, can you compile for me a program to do the same like DOS?
Thank you.
Bye.

spock
2003/09/14, 07:32 PM
Hi to all. Sorry for not hearing from me, summer came to Greece, and I promptly forgot everything and hit the beaches!
So, monsieur LeFreak (c'est chic?), if you're asking me to make a program that will do the same like DOS, do you mean a program that will run at boot and show a static screen? If that's your request, I'm very sorry but I cannot do that. For all I know, it cannot be done, but I'm not a windows programmer either. Good old DOS provided all the support for running programs at boot time, which feature got inherited by all Windows 9x and ME, but all Windows NT offsprings strictly prohibit that, as they load the device drivers and kernel at boot, and are very strict about that.
Sorry!

P.S. The proggie for 4x40 LCD will be coming shortly!

LeFreak
2003/09/15, 03:50 AM
aaaaaaaaaaaaa Freak out... LeFreak c'est chic... eheheheheheh
Cannot I pilot an LCD at boot event? Oh no!
Can you help me or I must change o.s.?
Thx.

spock
2003/09/15, 06:07 AM
Hi again. Yes, you have understood correctly, I (at least) cannot drive an LCD at Windows NT-based systems (NT, 2000, XP, 2003) at boot time. For all I know, Windows of that breed load the kernel and device drivers on boot, and there is no way that I know of that will make them run a plain program. Moreover, these Windows prohibit the use of all ports unless a special library is used. So, all ports are hidden by the HAL (Hardware Abstraction Layer) of the system by default.
Really, if it was possible, I would have already done it!

albataur
2004/02/19, 04:37 AM
I'm back !
I've just received my lcd today (after more than 1 year waiting...) !
I've tested your program. It's run perfectly under dos. But unfortunately I've just read the boot on win 2k/xp is not the same thing than win 98. So is it really impossible to run a program on boot ?
Thank you nevertheless, to have helped me ;)
Bye