Home  |  Contents 
Microcontroller and PC projects
  Forum Index : Microcontroller and PC projects         Section
Subject Topic: anyone have a real VT100 terminal? Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
robert.rozee
Guru
Guru


Joined: 31 December 2012
Location: New Zealand
Online Status: Offline
Posts: 1141
Posted: 09 September 2017 at 5:00pm | IP Logged Quote robert.rozee

does anyone out there have a real VT100 terminal hooked up to a micromite? i'm getting down to the finer details of implementing VT emulation, and am finding a fair bit of uncertainty in the existing sources of information. one big question regards the 'scrolling region'; when a region is set up what commands respect it, and what ones ignore it?

the below bit of mmbasic code checks to see if erase commands overflow the scrolling region or not (teraterm does overflow the region).


cheers,
rob


Const ESC=Chr$(27)

Print ESC "[2J";

setup(0)
Do: Loop Until Inkey$<>""
Print ESC "[0J";
Print at(15, 12) "  the bottom half of the screen should be blank   ";
Do: Loop Until Inkey$<>""

setup(0)
Do: Loop Until Inkey$<>""
Print ESC "[1J";
Print at(15, 12) "    the top half of the screen should be blank    ";
Do: Loop Until Inkey$<>""

setup(0)
Do: Loop Until Inkey$<>""
Print ESC "[2J";
Print at(15, 12) "        all of the screen should be blank         ";
Do: Loop Until Inkey$<>""


setup(1)
Do: Loop Until Inkey$<>""
Print ESC "[0J";
Print at(15, 12) "  the 3rd quarter of the screen should be blank   ";
Do: Loop Until Inkey$<>""

setup(1)
Do: Loop Until Inkey$<>""
Print ESC "[1J";
Print at(15, 12) "  the 2nd quarter of the screen should be blank   ";
Do: Loop Until Inkey$<>""

setup(1)
Do: Loop Until Inkey$<>""
Print ESC "[2J";
Print at(15, 12) "   the middle 50% of the screen should be blank   ";
Do: Loop Until Inkey$<>""

Print ESC "[1;24r";
End



Sub setup(flag)
  Print ESC "[2K";
  Print ESC "[1;24r";
  Print at(1, 1);
  For I=1 To 24
  Print I, "+", "+", "+", "+", "+", "+", "+", "+", I;
  If I<>24 Then Print
  Next I
  If flag<>0 Then Print ESC "[8;17r";
  Print at(40, 12);
End Sub


Function at(X,Y) As string
  at=ESC+ "[" + Str$(Y) + ";" + Str$(X) + "H"
End Function


Edited by robert.rozee on 09 September 2017 at 10:30pm



Back to Top View robert.rozee's Profile Search for other posts by robert.rozee
 
bigfix
Regular Member
Regular Member


Joined: 20 February 2014
Location: Austria
Online Status: Offline
Posts: 52
Posted: 09 September 2017 at 10:37pm | IP Logged Quote bigfix

Rob,
my "real" VT100 are deep buried in storage - would take hours to get them
I grabbed a VT420
Surprise - powered up after being 20 Years on shelf...
Put it into VT100 Mode in setup, even VT100 ID

Next challenge was to get a 3V TTL to V24 25 Pin Female converter done
After some hickups with undocumented chinese modules it finally worked

Even when I turned off smooth scroll the VT420 still showed some buffer overrun garbage with your program
DEC Terminals really depended on Xon/Xoff - which we do not have at MMites...
- had to set it to 9600 Baud - finally worked

MMite is a LCD Backpack, original Version, MMBasic 5.2

Some screens look different to the comments
I did not analyse the CSI sequences yet - just runned the program

I only post the first & the "failing" screens

cheers
Guenter








Back to Top View bigfix's Profile Search for other posts by bigfix
 
TassyJim
Guru
Guru


Joined: 07 August 2011
Location: Australia
Online Status: Offline
Posts: 2221
Posted: 09 September 2017 at 11:21pm | IP Logged Quote TassyJim

I just went to the shed to rescue a DEC VT510 terminal from my 'take to the tip' pile.
It has only sat in the shed for ~15 years.
I even have the original manual.

Being the same brand as Guenter's I would expect it to behave the same in VT100 mode.

It might take me some time to test it and get it connected to a 'mite but at least it's not going to the tip - this week.


Jim

__________________
It all started with the ZX81....
VK7JH
http://www.c-com.com.au/MMedit.htm
Back to Top View TassyJim's Profile Search for other posts by TassyJim Visit TassyJim's Homepage
 
GoodToGo!
Senior Member
Senior Member
Avatar

Joined: 23 April 2017
Location: Australia
Online Status: Offline
Posts: 104
Posted: 10 September 2017 at 12:41am | IP Logged Quote GoodToGo!

TassyJim wrote:
I just went to the shed to rescue a DEC VT510 terminal from my 'take to the tip' pile.
It has only sat in the shed for ~15 years.
I even have the original manual.

Being the same brand as Guenter's I would expect it to behave the same in VT100 mode.

It might take me some time to test it and get it connected to a 'mite but at least it's not going to the tip - this week.


Jim


The day after you take it to the tip will be the day you realise you need it.....
Don't risk it!

My mancave and garden shed are rapidly filling with stuff because of my reasoning.
Eg. I have a fully working 1970's era Sunbeam Toastamatic (you know, the one's that automatically lower and raise the bread purely mechanically?) sitting in my garage in case the Sunbeam Toastamatic in everyday use in the house keels over.
10 years it's sat there waiting. But I bet the day I get rid of it.......

Cheers!
GTG!

__________________
...... Don't worry mate, it'll be GoodToGo!
Back to Top View GoodToGo!'s Profile Search for other posts by GoodToGo!
 
robert.rozee
Guru
Guru


Joined: 31 December 2012
Location: New Zealand
Online Status: Offline
Posts: 1141
Posted: 10 September 2017 at 1:15am | IP Logged Quote robert.rozee

TassyJim wrote:
I just went to the shed to rescue a DEC VT510 terminal from my 'take to the tip' pile. [...] It might take me some time to test it and get it connected to a 'mite but at least it's not going to the tip - this week.
Jim


oh no, don't throw it out! looking online, it looks like the VT510 even works with a standard PS2 keyboard. there must be someone nearby you who can provide it with a new home, and even if the tube was flat it could still likely be repowered with a modern LCD.

bigfix wrote:
Some screens look different to the comments
cheers
Guenter


excellent, that shows that i don't need to modify the erase functions to respect the scroll region, though i am a little surprised at this behaviour. none of the online material i looked at made it clear about what the expected behaviour was.

the next test is this somewhat shorter one:
Const ESC=Chr$(27)

For I=1 To 24
  Print I, "+", "+", "+", "+", "+", "+", "+", "+", I;
  If I<>24 Then Print
Next I
Print ESC "[12;40H";

Do
  Do: A$=Inkey$: Loop Until A$<>""
  If A$="w" Then Print ESC "[A";
  If A$="z" Then Print ESC "[B";
  If A$="a" Then Print ESC "[D";
  If A$="s" Then Print ESC "[C";
  If A$="1" Then Print "full screen"; ESC "[1;24r";
  If A$="2" Then Print "8;17 region"; ESC "[8;17r";

Loop Until A$="0"
Print ESC "[1;24r"
End


this is an interactive test. to start with, you should be able to navigate the cursor around the screen using kets 'w','a','s','z'. make sure it can move to the full extremes top, bottom, left and right. when the cursor hits the edge, it should stop.

next press '2' to set the scroll region to be from line 8 to line 17. verify if the cursor returns to the top left of the screen when you press this key.

now try motoring around the screen again. the new bottom margin should be line 17, and once you have moved down to line 8 it should not be possible to move back above line 8. you can restore the scroll region to the full screen by pressing '1', and can exit the program by pressing '0'.


cheers,
rob :-)
Back to Top View robert.rozee's Profile Search for other posts by robert.rozee
 
TassyJim
Guru
Guru


Joined: 07 August 2011
Location: Australia
Online Status: Offline
Posts: 2221
Posted: 10 September 2017 at 7:15am | IP Logged Quote TassyJim

Well my DEC terminal passed the selftest OK so I will class it working.
I also tested a Terminal Box which was sold in Aussie by Alloy. It uses a PC keyboard and monitor and seems to emulate a long list of terminal types.

I used to sell these instead of full terminals when the buyer knew that he would be changing over to PC based in the near future. This one came back to me after about 6 months in the field.

I won't put the terminal box on the tip pile. There is room inside for a micromite or two and would make a nice free standing 'mite.

I need to wait for another rainy day before I can test your program. There is too much work to do in the garden this time of the year and I seem to take twice as long to do things compared to a year or two ago.

Jim

__________________
It all started with the ZX81....
VK7JH
http://www.c-com.com.au/MMedit.htm
Back to Top View TassyJim's Profile Search for other posts by TassyJim Visit TassyJim's Homepage
 
CaptainBoing
Guru
Guru
Avatar

Joined: 07 September 2016
Location: United Kingdom
Online Status: Offline
Posts: 300
Posted: 10 September 2017 at 10:32am | IP Logged Quote CaptainBoing

itis a long-term plan of mine to find an old VT100 (or similar) and mount my MMX board inside the case... bring the pins out to a connector(s) on the back and have a free-standing uM

well done on the "dumpster dive"

__________________

all you need is duct tape and WD40 (if it moves and shouldn't, use duct tape; if it doesn't move and should, use WD40)
Back to Top View CaptainBoing's Profile Search for other posts by CaptainBoing
 
bigfix
Regular Member
Regular Member


Joined: 20 February 2014
Location: Austria
Online Status: Offline
Posts: 52
Posted: 11 September 2017 at 8:31am | IP Logged Quote bigfix

Rob,
works exactly as you described on the VT420 at 9600 Baud





(Video on request only )

I also tried it with ESPTerm - works with 230 kBit

cheers
Guenter
Back to Top View bigfix's Profile Search for other posts by bigfix
 
robert.rozee
Guru
Guru


Joined: 31 December 2012
Location: New Zealand
Online Status: Offline
Posts: 1141
Posted: 11 September 2017 at 12:54pm | IP Logged Quote robert.rozee

excellent, that has enabled me to now finalize how i handle cursor movement commands.

btw, how well does the following work with ESPTerm?

Const ESC=Chr$(27)

Print ESC "[?9h";              ' enable mouse reporting
Print ESC "[?1015h";           ' select URXVT encoding (if available)
Print ESC "[?1006h";           ' select SGR encoding (if available)

Do
  Do: A$=Inkey$: Loop Until A$<>""
  If A$=Chr$(27) Then Print
  If Asc(A$)<32 Then Print "<" Str$(Asc(A$)) ">"; Else Print A$;
Loop Until A$=Chr$(26)

Print ESC "[?1006l";           ' disable SGR encoding
Print ESC "[?1015l";           ' disable URXVT encoding
Print ESC "[?9l";              ' disable mouse reporting


it makes use of alternative encoding for the mouse location reporting - SGR (1006) is the preferred reporting method, URXVT (1015) is ok but not great, while the default encoding can not encode beyond column 95 if using 7-bit characters.


cheers,
rob :-)

Edited by robert.rozee on 11 September 2017 at 1:59pm
Back to Top View robert.rozee's Profile Search for other posts by robert.rozee
 
bigfix
Regular Member
Regular Member


Joined: 20 February 2014
Location: Austria
Online Status: Offline
Posts: 52
Posted: 11 September 2017 at 9:11pm | IP Logged Quote bigfix

Tested it on 1.01 ESPTerm

One issue I found - Mouse stays enabled ??
Need to investigate

Anyhow, this is the output clicking on the 4 Corners & Center
When I use the right mousebutton then first number changes from 0 to 2

It also works excellent on an Android tablet with touch




Wide Terminal with 120 Characters:






Edited by bigfix on 11 September 2017 at 9:25pm
Back to Top View bigfix's Profile Search for other posts by bigfix
 


If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Search the forums using Google.
In the news...
 
Post ReplyPost New Topic
Printable version Printable version
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum

Powered by Web Wiz Forums version 7.8
Copyright ©2001-2004 Web Wiz Guide

This page was generated in 0.0781 seconds.
Privacy Policy     Process times : 0, 0, 0, 0.08