Vidicode Argus Basic Programmers Reference Manual
Have a look at the manual Vidicode Argus Basic Programmers Reference Manual online for free. It’s possible to download the document as PDF or print. UserManuals.tech offer 9 Vidicode manuals and user’s guides for free. Share the user manual or guide on Facebook, Twitter or Google+.
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 48 CONNECT connect to remote modem CONNECT is identical to the modem command O (ATO). The modem will take the line, wait for an incoming carrier and try to connect to it. The connection will only be established, when the configuration of the relevant S-registers matches the remote carrier. The ON CONNECT event can be used to detect a successful connection. This can also be determined by reading DCD#3 on exit of the CONNECT command. The system variable RESULT can be read on exit to determine the status of the modem (NO CARRIER, CONNECT). Examples: CONNECT HOOK OFF : WAIT 20 : IF FREQ > 500 CONNECT Syntax: CONNECT See also: ANSWER, HANGUP
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 49 COPY copy files This command is used to copy one file on the disk to another file. The new file is identical to the original one. Using wildcards (* or ?) is not possible. Examples: COPY MYPROG , MYPROG.BAK COPY MYPROG TO MYPROG.BAK Syntax: COPY (FILE|!) [string] (TO|,) (FILE|!) [string] See also: LOAD, SAVE, SEND, RECEIVE, DIR
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 50 CTS Clear To Send CTS is one of the hardware handshaking signals defined in the RS232 standard, and each serial port on the modem is capable of controlling a CTS signal as an output. CTS is a signal provided by modems and other DCEs, to inform the terminal (DTE) that it is ready to accept data for transmission. It is used in conjunction with another signal, RTS (Ready To Send) as part of the RS232 handshaking sequence. When the CTS signal is taken low by the modem, a terminal or computer must respond by stopping further transmission of data until CTS goes high again. If the terminal does not respond, transmitted characters may be lost. After the HANDSHAKE CTS command has been issued, the modem will respond correctly to RTS and control CTS automatically. The CTS function is used to read or set the value of the CTS signal on the currently selected output port. When the CTS line is high, the CTS function will return the value 1; if it is low, the value 0 will be returned. If no port is specified, the output port defined by the last used OPORT command is assumed when writing (setting); and the last used IPORT is used when reading. If the modem is unable to handle any more incoming characters because its input buffer is nearly full, it will request the sending device to wait by taking its CTS output low. This feature can be switched on or off with the HANDSHAKE command. The modem also supports software handshaking using the XON/XOFF protocol. Refer to the commands XOFF, XON, and HANDSHAKE for more information. Examples: X=CTS SWITCH(1)=CTS#1 PRINT CTS#2 IF CTS PRINT READY CTS ON CTS OFF Syntax: [num-var] = CTS ( #[port] ) CTS (#[port])=[numeric 0...1] CTS ON/OFF See also: HANDSHAKE, XOFF, XON, RTS
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 51 DATA define constant data The DATA command is used to store numeric and string constants within a program. Such values may be read one or more times using the READ command. DATA commands may appear anywhere in the program, but must be the first and only command appearing on a line. As many data items as will fit on a line may be included, with individual data items being separated by commas. The following example contains 5 items (3 numbers and two strings): 70 DATA 5, 10, 50, Apple, Orange Where a program contains more than one DATA command, they should be thought of as comprising a single continuous list of data items; i.e. having read the last item of data on a particular line, the next READ command will take the first item of data from the next DATA command in the program. To include leading spaces within a string it must be enclosed in double quotes: 50 DATA This string contains leading spaces As the comma is used as a separator in DATA commands, you may only include a comma as an item of data by enclosing it within double quotes: 60 DATA ,?,,,/ To include a double quote mark in a DATA command you must use four sets: 80 DATA 90 READ x$ After line 90 has been executed x$ will have the value Examples: DATA 1,2,3,5,7,11,13,17,19 DATA Peter,15, Clare,12, Robert,13, James,18, Alison,15 Syntax: DATA [string] | [integer](,...) See also: READ, RESTORE
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 52 DATE$ read system date DATE$ is used to read the date from the internal clock/calendar, and format it into a text string in the form DD-MM-YY. When I wrote this text on the 23rd of July 1990, PRINT DATE$ reported 23-07-90. The date can also be obtained in integer format by using the individual functions DAY, DDAY, MONTH and YEAR. DATE$ can also be used to change the system date. Examples: D$(I)=DATE$ Today$=DATE$ PRINT DATE$ DATE$ = 23-07-90 Syntax: [string-var] = DATE$ DATE$ = [string] See also: CLOCK$, TIME$, DAY, DDAY, MONTH, HOUR, MIN, SEC, YEAR
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 53 DAY read/set day of week DAY is used to read or set the day of week on the internal clock/calendar. When reading it returns an integer from 1 to 7, day 1 being Sunday. Similarly, when setting the day of week, the day number from 1 to 7 must be specified. An incorrect value will cause the current setting to remain unchanged. Examples: DAY=5 IF DAY=1 THEN Day$=Sunday PRINT DAY Syntax: DAY = [integer 1..7] [num-var] = DAY See also: DATE$, DDAY, MONTH, YEAR
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 54 DCD Data Carrier Detect DCD is the RS232 signal used by modems to indicate that a connection has been established with a remote system. It is activated by the modem when a connection occurs, and is normally used as an output from the modem. However within the BASIC environment, it can also be used to read the connect status of modem port #3. With port #1 or #2 the DCD command is used by the modem to control or read the status of the DCD line on the specified port. If no port is specified, the default port defined by OPORT will be assumed. The DCD signals of port 1 and port 2 are connected via hardware; thus DCD signals on both ports will influence each other, and it is impossible to set them separately. With port #3 it is only possible to read the status. For example, the following command causes program execution to jump to the label %Connect2 if the DCD input on port 2 is active: IF DCD#3 GOTO %Connect2 However, in order to detect incoming calls correctly using the DCD function, a program must continuously check the appropriate DCD signal in a loop, until its status changes from FALSE to TRUE. This is because a single DCD call gives only a momentary reading of DCD status. For this reason it is more efficient to use the ON CONNECT and ON HANGUP event handlers to achieve the same result. It is sometimes necessary to control the use of DCD as an output from the modem - for example, where you have protected entry to your host computer by using auto-dial back from your modem. In this case, you would tell the computer that a connection has been established only after the user has been correctly identified and authorized to proceed. Before that you would keep DCD low, and your computer would not know that any communication was already going on. To keep DCD low on the ports while your modem is connected, AT&C has to be set first, and afterwards DCD has to be enabled by your program: DCD=1orDCDON will activate DCD DCD=0orDCDOFF will clear DCD Examples: IF DCD#3 GOTO %Connection PRINT DCD#3 DCD=1 DCD OFF Syntax: [num-var] = DCD(#[port]) DCD = [integer 0..1] DCD ON/OFF See also: DSR, ON CONNECT, ON HANGUP
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 55 DDAY read/set day in month DDAY is used to read or set the day within the month for the internal clock/calendar. When reading it returns an integer from 1 to 31. Similarly when setting, the day number from 1 to 31 must be specified; an incorrect value will cause the current setting to remain unchanged. Examples: DDAY=15 IF (DDAY=1 OR DDAY=21 OR DDAY=31) Suffix=st PRINT DDAY Syntax: DDAY = [integer 1..31] [num-var] = DDAY See also: DATE$, DDAY, MONTH, YEAR
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 56 DELETE / DEL delete program lines/files The DELETE command, in its various forms, is used to delete lines from a program and to delete files from the disk filing system. Deleting program lines DELETE may be followed by two line numbers which define the range of lines to be removed. The command: DELETE 50,100 or DELETE 50 TO 100 will remove all program lines from 50 to 100 (inclusive). If the first parameter is omitted all lines from the start of the program to the specified last line will be deleted: DELETE ,50 To delete a single line, just type the line number followed by [Return]. Labels can be used to specify the range in place of line numbers: DELETE %Dial, %Dialend Deleting files from the RAM-, FLASH- or Hard-disk DELETE can also be used to remove files from the disk filing system. In this case the command is followed by !,FILE and/or a string. To delete the program TEST.PROG you could alternatively use the following: DELETE !TEST.PROG DELETE TEST.PROG DELETE FILE TEST.PROG F$=TEST.PROG : DELETE F$ To delete multiple files the * may be used as a wildcard character. Note however, that unread files will not be deleted by this form of the command, and a report will be printed of the number of files deleted and unread. For example, if there were 7 files with the suffix MSG , two of which were unread, the command: DELETE *.MSG would result in the following report: 2 Unread 5 Deleted To delete unread messages the DELETE command must be followed by ,U : DELETE *.MESS,U After deleting files, the system variable MATCH holds the number of deleted files. Examples: DEL 10,200 DELETE %Search, 500 DEL *.JOHN
ARGUS Programmable Modem BASIC Programmers Reference Manual © 1990 - 1997 Vidicode Datacommunicatie BV 57 DELETE *.ANN,U Syntax: Program lines: DELETE [line-num | label] TO|, [line-num | label] RAM-, FLASH - or Hard-disk files: DELETE (!/FILE) [string] ( ,U ) See also: MATCH