Number to Speech
Posted: Sun Jan 21, 2024 8:35 am
VTech PreComputer Prestige
The VTech PreComputer Prestige educational computer was manufactured in the 1990’s and came with a built in BASIC interpreter. This portable model is a great way to learn BASIC at a reasonably price. They can be obtained second-hand from eBay, thrift stores and yard sales. The Prestige model had a unique BASIC command that converted a text number or letter to spoken audio. The voice is a good quality female voice.
The command is:-
VOICE(n) n is the voice number.
n spoken word
0 zero
1 one
2 two
. .
. .
9 nine
10 ten
The program listed will accept a 10 digit telephone number including the two hyphen’s and will then read out the telephone number. When prompted to enter the telephone number type in the number in this format:-
652-309-4871
The VTech PreComputer Prestige educational computer was manufactured in the 1990’s and came with a built in BASIC interpreter. This portable model is a great way to learn BASIC at a reasonably price. They can be obtained second-hand from eBay, thrift stores and yard sales. The Prestige model had a unique BASIC command that converted a text number or letter to spoken audio. The voice is a good quality female voice.
The command is:-
VOICE(n) n is the voice number.
n spoken word
0 zero
1 one
2 two
. .
. .
9 nine
10 ten
The program listed will accept a 10 digit telephone number including the two hyphen’s and will then read out the telephone number. When prompted to enter the telephone number type in the number in this format:-
652-309-4871
Code: Select all
1 REM Number to Speech
2 DIM N$(12)
4 DIM N(12)
6 LET A = 0
8 INPUT “ENTER TELEPHONE NUMBER”;I$
10 LET B = LEN(I$)
12 IF B <> 12 THEN PRINT “INPUT ERROR – TRY AGAIN!” : GOTO 8
14 LET A = A + 1
16 LET N$(A) = MID$(I$,A,1)
18 IF A = 12 THEN GOTO 22
20 GOTO 14
22 FOR L = 1 TO 12
24 LET N(L) = VAL(N$(L))
26 NEXT L
28 FOR L = 1 TO 12
30 IF L = 4 OR L = 8 THEN GOTO 34
32 VOICE N(L)
34 FOR E = 1 TO 200
36 NEXT E
38 NEXT L
40 PRINT “>> END OF TRANSMISSION <<”
42 END