PicBasic Pro serout question

Ok. I know I missed the answer somewhere in all the offline/online literature,so I will ask the question here. I am doing a simple serout program using PicBasic Pro on a PIC16F628A chip. Everything is working fine, but I need the serout instructions for clearing the screen and starting on a new line (linefeed) for Windows Hyperterminal program. I have tried all the LCD related instructions for clearing and new line, but hyperterminal doesn't seem to like them much. So, if anyone has that info, I would appreciate hearing from you. Thanks in advance.

Reply to
artswan
Loading thread data ...

Well -- ordinarily, most terminal emulators will give you a new line if you send them either a linefeed: 0xA (dec: 10), or a combination of carriage return and linefeed: 0xD(13) and 0xA (10). Occasionally you can just send a carriage return. The CR/LF sequence should always work.

As far as what character sequence will trigger a clear screen, this will depend on the terminal emulation mode you have hyperterminal set up for. The sequence for an ANSI terminal should be [2J, where is ascii character 0x1B (27 dec).

A complete list of ANSI escape sequences can be found at:

formatting link
In any case, the LCD sequences won't work -- hyperterminal is a different beast.

Hope that helps -- m

Reply to
The Artist Formerly Known as K

Thanks for the help! That was just the info I needed. Now I can cleanup my screen.

:)

Reply to
artswan

The Artist Formerly Known as Kap'n Salty wrote: : artswan wrote: : > Ok. I know I missed the answer somewhere in all the offline/online : > literature,so I will ask the question here. I am doing a simple serout [snip] : Well -- ordinarily, most terminal emulators will give you a new line if : you send them either a linefeed: 0xA (dec: 10), or a combination of : carriage return and linefeed: 0xD(13) and 0xA (10). Occasionally you can : just send a carriage return. The CR/LF sequence should always work.

: As far as what character sequence will trigger a clear screen, this will : depend on the terminal emulation mode you have hyperterminal set up : for. The sequence for an ANSI terminal should be [2J, where : is ascii character 0x1B (27 dec). [snip]

Wouldn't a ASCII FF (0x0C) work as well for a clear screen?

DLC

: -- : (Replies: cleanse my address of the Mark of the Beast!)

: Teleoperate a roving mobile robot from the web: :

formatting link
: Coauthor with Dennis Clark of "Building Robot Drive Trains". : Buy several copies today!

Reply to
Dennis Clark

I think this depends on the terminal emulation -- I just tried echoing this character over an ssh session with one of my machines, and it doesn't work, although ESC[2J works as expected.

Cheers -- m

Reply to
The Artist Formerly Known as K

PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.