r83.to.ap.3 Article/Article

r83.to.ap.3

Command r83.to.ap.3 Article/Article
Applicable release versions: AP
Category Article (24)
Description identifies differences between R83 and AP

Contributed by Ron Davis
(Original article ran in PickWorld Magazine)

The final installment of this series considers the fine points of moving an Advanced PICK system to a different Advanced PICK platform.

Differences Between R83 and Advanced PICK

Porting applications from one platform to another is a task which has brought a cold sweat to the brow of more than one software developer. PICK Systems has made Advanced PICK as hardware-independent as possible, but a few topics still remain. There are some minor differences between Advanced PICK platforms which must be considered.

Advanced PICK-To-Advanced PICK Considerations

In porting Advanced PICK applications to other sites and platforms, or in adding software to existing sites, you may wish to consider the following:

Operating System

* Different platforms may not support certain Host Operating System commands. If you use the '!' or 'shell' commands to execute Host OS functions, you may need to change them.

File System

* The frame size may be different (which will affect performance), unless the files are re-sized.

* Files may be designated as case sensitive, which may pose a problem.

Files

* There are several files and items in the 'dm' account which can affect system operation:

'dm > abs' (Custom abs files)
'dm > bp' (PICK/BASIC programs)
'dm > users' (User logon / password / permissions file)
'dm > devices' (Terminal / printer devices in the system)
'dm > fonts' (Printer fonts file)
'dm > iomap-file' (Keyboard definition)
'dm > kb.pc' (Keyboard definition)
'dm > kb.fk' (Function keys)
'dm > messages seq' (The method of sorting for the 'ms' correlative)
'dm > messages legend' (The legend printed at the bottom of reports)

Access / TCL

* There are a few verbs which affect system operation:

case, set-break, set-esc, brk-level, esc-level, legend
tcl-hdr

* There are several commands which are specific to the Hosted Unix platform. If you are changing to another platform, then those commands may work differently, or will be inoperative.

Some of those commands are:

!, .profile, add-font, alarm, cal, cai, cc, cd, config, cpio, disc, ecc, env, environ, exit, export, fuser, grep, import, kill, list-device, list-lines, listbi, ll, ls, pg, phantom, pick, pid, ppcp, ps, psh, psr, pwd, pxpcmd, pxpw, reset.port.unix, rmbi, set-8mm, set-batchdly, set-break, set-cmcm, set-device, set-esc, set-flush, set-func, sh, shell, shpstat, startshp, stty, su, trap, tty, unix, useralarm, vi

PICK/BASIC

* Different hosted platforms may not support certain Host Operating System commands. If you use the '!' or 'shell' commands within PICK/BASIC 'EXECUTE' statements to execute Host OS functions, you may need to change them.

* Hosted systems have the additional capability of extending PICK/BASIC by adding built-in C functions, using the 'addbi' command. You may have to port over those custom C functions.

* Basic's substring replacement feature has changed as of March 1992. The '[ ]' substring operator now works differently, although your programs will still compile.

substring = string[ start.position, no.of.chars ]

New Method:

If start.position < 1, the system will use "1".
If start.position > len( string ),the system will return an empty string.
If no.of.chars < 1, the system will return an empty string.
If no.of.chars > len( string ), it returns the remaining portion of the string.

string[ start.position, no.of.chars ] = substring

New Method:

If start.position < 1, the system will insert the absolute value of start.position spaces in front of the string.
If start.position = 0, the system will use "1".
If start.position > len( string ),the system will append spaces at the end of the string so that the string will be start.position characters long, and then the substring will be appended.
If no.of.chars <= 0, the system will insert the substring prior to the first character in the string.
If no.of.chars < len( substring ),it copies only those characters.
If no.of.chars > len( substring ),it copies the entire substring, and appends spaces for the remaining characters.
If no.of.chars > len( string ),it appends the additional characters to the end of the string.

string[ delimiter, start.field, no.of.fields ] = substring

New Method:

If start.position < 1, the system will use "1".
If start.position > no.of.fields,the system will add null fields (separated by the appropriate delimiters) so that the string will contain the proper number of fields.
If no.of.fields < 0, all the fields after the start.fieldth field are deleted from the string, and the substring is inserted at that point.
If no.of.fields = 0, no fields are deleted, and the substring is inserted in the string before the start.fieldth field.
If ( start.field + no.of.fields ) < ( the number of fields in string ), the specified fields are replaced, and any remaining fields are nulled.
If ( start.field + no.of.fields ) > ( the number of fields in string ), the system adds null fields (separated by the appropriate delimiters) so that the string will contain the proper number of fields. Please check your programs for its use.

Text Editing

* (See the note on the 'dm > devices' file.)
* (See the note on the 'dm > iomap-file' file.)
* (See the note on the 'dm > kb.pc' file.)
* (See the note on the 'dm > kb.fk' file.)

Document Processing

* (See the note on the 'dm > devices' file.)
* (See the note on the 'dm > fonts' file.)

The Spooler

* Some platforms do not support the 'startshp' command.

Tape

* Some platforms do not support the 'set-device' command. You may need to replace it with:

set-floppy, set-sct, set-half, set-8mm

Or vice-versa...

Assembly Language

* User-Exits may change from time to time, and from platform to platform. It would be wise to double-check any User-Exits that you use in processing codes and/or PICK/BASIC programs...

* As Advanced PICK goes through different moniotor revisions, some assembly language will have to be re-assembled. PICK Systems has promised that AP will be binary-compatible across hardware, and it someday will be. Until then, reassemble your code.

* If you are using custom-written software from a vendor company, you may not have the source code available. You will have to contact them for a run-time version of their software for Advanced PICK. As you have read, the primary differences between R83 and Advanced PICK deal with the new concepts that have been added, and the conflicts that may arise between different implementations of Advanced PICK is mainly due to the platform-specific extensions available. I hope this road map helps you to avoid most of the pitfalls.

At last we have come to the end of the series, but by no means the end of this topic. There will be discussions in the future about upgrades, conversions, data transfers, and offloading. PICKWORLD welcomes your comments on and contributions to these issues.
Syntax
Options
Example
Purpose
Related tcl.set-esc