comp41

NAME
SYNOPSIS
DESCRIPTION
OPTIONS
FILES
REFERENCES
EXAMPLES
BUGS
AUTHOR

NAME

comp41 - a filter to compile a HP41C user-language (FOCAL) program

SYNOPSIS

comp41 [-g] [-l] [-x xrom_file ] [-x xrom_file ] ... <input file>

comp41 [-g] [-l] [-x xrom_file ] [-x xrom_file ] ...

(last form reads source file from standard input)

comp41 -?

DESCRIPTION

comp41 is a filter which compiles a text file containing a HP-41 user program (FOCAL) and translates it to a binary raw file.

An xrom_file consists of a number of lines, each consisting of 2 decimal numbers and a string (containing no whitespace), in that order, separated by whitespace. The string gives a name to the function specified by the first number as rr and the second number as nn. A xrom_file is necessary to compile commands of module or peripheral functions.

OPTIONS

-g

Force global for[ "A..J", "a..e" ] with quotes: [ lbl "A" ]

-l

Skip line numbers

-x xrom_file

Use xrom_file to define names for functions in plug-in modules. This option may be repeated to load multiple xrom_files. The file name has to be specified either as a full pathname or as the filename without the extension .xrom in the default location that is specified with the environment variable LIFUTILSXROMDIR (see below).

-?

Print a message giving the program usage to standard error.

FILES

xroms/*

xrom function definition files. Use the environment variable LIFUTILSXROMDIR to point to the location of this directory. On Linux the default location is /usr/share/lifutils/xroms, if the variable is not specified.

REFERENCES

The format of an HP41C program is documented in many books. Amongst the most useful references are Extend Your HP41 (W. A. C. Mier-Jedrzejowicz) and The HP41 Synthetic Programming Quick Reference Guide (Jeremy Smith)

EXAMPLES

If prog1.txt is a text file with a FOCAL program that uses functions of the HP-IL and time module and hp41prog.dat is a LIF image file then

cat prog1.txt | comp41 -x hpil -x time | prog41hp PROG1 | lifput hp41prog.dat

will compile the file prog1.txt to a raw file that is transformed to a LIF file named PROG1 that is stored in the LIF image file hp41prog.dat

BUGS

Unknown.

AUTHOR

comp41 was written using code of the User-Code File Converter/Compiler/De-compiler/Bar-Code Generator Version 1.31 Copyright (c) Leo Duran, 2000-2007 and has been placed under the GNU Public License version 2.0