Clearing the screen
-
- Posts: 17
- Joined: Sat Jan 12, 2013 7:37 am
Clearing the screen
I need a simple function to clear the screen of inputs and outputs. something that works like MS-DOS CLS command does anyone know how to implement one. I need to do it in either assembly or C/C++. Also it would be nice to know what it is doing so if you give me code can it be commented?
REAL programmers aren't afraid to use goto's
Re: Clearing the screen
So you have a screen that is full of characters, which presumes that you can print a character. And you want to fill it with blanks - space characters. And you can't see how to do that?
I think you should try something simpler than OS development.
I think you should try something simpler than OS development.
Re: Clearing the screen
If that screen is also capable of input, is that some kind of multi-touch screen?JamesParsons wrote:I need a simple function to clear the screen of inputs and outputs.
Yes, I think many people know how to implement one, but instead of MS-DOS CLS it's probably a terminal emulator instead.JamesParsons wrote:something that works like MS-DOS CLS command does anyone know how to implement one.
No. Your requirement is ambiguous (do you want to clear the VGA, or virtual terminal buffer, or something exotic?) How does your OS deal with the target device (VGA or virtual), Give us a brief description of your OS (real mode, protected mode, design model, etc), Dos you want a clear-screen function used by kernel/driver, or solely for debugging purpose, or you actually want an CLS application that can be called by shell?JamesParsons wrote:I need to do it in either assembly or C/C++. Also it would be nice to know what it is doing so if you give me code can it be commented?
Furthermore, the chance that somebody bored enough to spend his own time doing your work is infinitesimally small; but if you show us what effort you have done you can probably get more help - it's just easier for you and the helper.
With none information given, the best you could get maybe:
Code: Select all
memset ( p, 0, 80*25*2 );
-
- Posts: 17
- Joined: Sat Jan 12, 2013 7:37 am
Re: Clearing the screen
I think iansjack is right. I've been around this forum asking stupid questions. The problem is this OS-Dev stuff takes a lot of general Computer Knowledge and a basic understanding of how the entire computer works. I've been doing general programming for a while not focusing on other computer topics. I'm going to do something simpler than OS-Dev. I'm going back to writing general software.
ps. is there some way I can remove these posts
ps. is there some way I can remove these posts
REAL programmers aren't afraid to use goto's
- xenos
- Member
- Posts: 1121
- Joined: Thu Aug 11, 2005 11:00 pm
- Libera.chat IRC: xenos1984
- Location: Tartu, Estonia
- Contact:
Re: Clearing the screen
JamesParsons wrote:ps. is there some way I can remove these posts
Same problem again?JamesParsons wrote:I need a simple function to clear the screen of inputs and outputs.
iansjack wrote:So you have a screen that is full of characters, which presumes that you can print a character. And you want to fill it with blanks - space characters. And you can't see how to do that?
-
- Posts: 17
- Joined: Sat Jan 12, 2013 7:37 am
Re: Clearing the screen
all I can find on the programmers hardware database is specification on a bunch of ARM processors. At that I have to click the random page to get to anything with content
REAL programmers aren't afraid to use goto's
- Brynet-Inc
- Member
- Posts: 2426
- Joined: Tue Oct 17, 2006 9:29 pm
- Libera.chat IRC: brynet
- Location: Canada
- Contact:
Re: Clearing the screen
It's his forum signature.JamesParsons wrote:all I can find on the programmers hardware database is specification on a bunch of ARM processors. At that I have to click the random page to get to anything with content
EDIT: Removed 2015: Imageshack replaced all links with spam.
Last edited by Brynet-Inc on Fri Aug 28, 2015 8:39 pm, edited 1 time in total.
-
- Posts: 17
- Joined: Sat Jan 12, 2013 7:37 am
Re: Clearing the screen
oh I was being a little slow for a moment
REAL programmers aren't afraid to use goto's