Bsc is a program which creates BinSCII files on UNIX systems. COMPILING --------- First, examine the makefile. For some systems, you may need to add some of the -Dxxx flags to CFLAGS. These flags are briefly described in the comments in the makefile. Once you have CFLAGS set up to match your system, type "make". This should build the bsc executable. If it doesn't, you might want to write to the author (at the one of the addresses listed at the end of this file) and tell him he goofed. You get extra credit if you can describe the reasons for the failure in sufficient detail for me to correct the problem. Once you have bsc successfully compiled, move it to your favorite directory. It doesn't really matter where you put it, as long as you can find it when you need it. EXECUTING --------- To run bsc, use: bsc [] The following options are available: -t type Sets the ProDOS filetype stored in the BinSCII header to "type". The type may be specified in any of several ways: Type Meaning ---- ----------- LLL 3-letter abbreviation dd decimal 0xdd hexadecimal $dd hexadecimal 0dd octal Note that a 3-letter abbreviation must be specified in lowercase, and that if you use a hex number in $dd format you will have to quote or escape the $ to protect it from the shell. If no "-t" option is present, the filetype will default to 6 (BIN). (See the file "pftypes.h" for a complete list of recognized 3-letter ProDOS filetype abbreviations.) -a auxtype Sets the stored ProDOS auxiliary filetype to "auxtype". The auxiliary type may specified in any of the following forms: Syntax Base ------ ----------- dd decimal $dd hexadecimal 0xdd hexadecimal 0dd octal If no "-a" options is present, the auxiliary filetype will default to 0. -m mode Sets the stored ProDOS access mode to "mode" The mode may be one or more of the following: Mode Meaning ---- --------- d destroy n rename b backup-needed i invisible w write r read If no "-m" option is present, the access mode defaults to "dnwr", which corresponds to an "unlocked" ProDOS file. To create a "locked" file, use "-m r". -n name Sets the ProDOS filename stored in the BinSCII header. If this option is omitted, the ProDOS filename will be the same as the UNIX filename. -s num Sets the number of BinSCII segments per output file to "num". As above, the number may be specified in decimal, hex, or octal. If no "-s" option is present, or if "num" is 0, then all BinSCII segments will be written to a single output file. To cause each segment to go into its own output file (like the Apple II BINSCII program), use "-s 1". See below for an explanation of output files. -b On those computer systems that treat ASCII files differently from binary files, this flag causes bsc to open its input file in binary mode instead of ASCII mode. This flag will probably never be needed on UNIX...it is included primarily for use on other operating systems. -h Print a short summary of bsc's options on the standard output. These options, if present, may appear in any order, provided that they appear before the filename. Spaces may appear between an option letter and its value, but are not necessary. The filename is the name of the UNIX file to be BinSCII'd. The stored ProDOS filename will be taken from the UNIX name, or from the -n option if one was supplied, with lowercase letters converted to uppercase. Additionally, characters that are not valid in ProDOS filenames will be translated into periods (unless the invalid character is the first character in the name, in which case it gets translated into an "X"). The ProDOS name will be truncated to 15 characters if necessary. The stored ProDOS creation and modification times will be taken from the UNIX input file. The output of bsc is a set of one or more files, each containing one or more BinSCII segments. By default, all BinSCII segments are written to a single output file, which has the same name as the input file with a ".0" appended to the end. If the "-s" option is given on the command line with a value greater than zero, then the number of segments per output file will be limited to the specified value, and if more than one output file is needed, the second file will have ".1" appended to the name, the third will have ".2" appended, and so forth. For example, if "foo" is a large UNIX file, the command "bsc -s3 foo" will create files "foo.0", "foo.1", "foo.2", etc., each containing 3 BinSCII segments. WARNING: IF A FILE WITH THE SAME NAME AS A BSC OUTPUT FILE ALREADY EXISTS, THE PRE-EXISTING FILE WILL BE SILENTLY OVERWRITTEN BY THE BSC OUTPUT FILE. Before typing "bsc foo", it is probably a good idea to make sure you don't already have an important data file called "foo.0". Bsc will refuse to BinSCII a file larger than 16777216 bytes (16 meg), since that is the maximum size of a ProDOS file. An example: Suppose a UNIX file called "picture" contains a standard Apple IIGS super-hires screen image. The command bsc -tpic picture will create the file "picture.0" in a format suitable for downloading to an Apple II and un-BinSCIIing, or for posting to comp.binaries.apple2. When un-BinSCII'd on an Apple II, it will automatically be converted to a PIC ($C1) file. INFORMATION ----------- This program is freeware. It comes with no warranty of any kind--in particular, I cannot guarantee that it is free of bugs. Use it at your own risk. When the inevitable bugs DO appear, send e-mail to one of the addresses below. I welcome bug reports, comments, complaints, and suggestions for improvement. Thanks to Marcel J. E. Mol, whose sciibin program was a valuable source of technical information on BinSCII. - Neil Parker parker@corona.uoregon.edu nparker@cie.uoregon.edu parkern@jacobs.cs.orst.edu Version 1.1