HP3000-L Archives

October 2009, Week 2

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"Gribbin, Francis J." <[log in to unmask]>
Reply To:
Gribbin, Francis J.
Date:
Tue, 13 Oct 2009 10:17:12 -0400
Content-Type:
text/plain
Parts/Attachments:
text/plain (67 lines)
From the posix bag of goodies, you might also try FOLD.

:FOLD.HPBIN.SYS "-bs -w80 INFILE" >> OUTFILE

FOLD is also useful in CGI scripts. 
Omit the s if you do not want to break at spaces.

Regards,

Frank Gribbin
Potter Anderson & Corroon LLP
 

-----Original Message-----
From: HP-3000 Systems Discussion [mailto:[log in to unmask]] On Behalf Of Per Östberg
Sent: Tuesday, October 13, 2009 3:20 AM
To: [log in to unmask]
Subject: Re: [HP3000-L] Convenient way to dump a byte stream file?

greetings
posix might be your friend - specifically OD.HPBIN.SYS with the -j and -N flags.
as in (should of course be wrapped in a nice script):
:OD.HPBIN.SYS "-N80 FILE"
:OD.HPBIN.SYS "-j 80 -N80 FILE"
:OD.HPBIN.SYS "-j 160 -N80 FILE"
...etc...

hth
/per

2009/10/13 Walter J. Murray <[log in to unmask]>:
> Greetings,
>
> I am looking for a convenient way to dump a byte stream file that
> contains unknown data, data which may not be well behaved.
>
> With a file of fixed or variable length records, I often use something
> like this to see exactly what's there:
>
> FCOPY FROM=MYFILE;TO=;CHAR;HEX;NORECNUM
>
> With a byte stream file, however, the byte stream emulator gets in the
> way.  It insists on presenting the file as a collection of records,
> defined by the new-line character (ASCII 10, or '\n', or <LF>).  This
> may not be convenient if the file contains binary numbers.  Worse yet, I
> may have a 9000-byte file that doesn't contain any <LF> characters at
> all.
>
> None of the usual tricks, like using MR;NOBUF, seem to work.
>
> I know I can open the file with HPFOPEN and use item 77 to sidestep the
> emulator.  Does anybody know an easier way?
>
> Walter
>
> Walter J. Murray
>
> * To join/leave the list, search archives, change list settings, *
> * etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
>

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2