Sun-Spots Digest, v6n148

William LeFebvre Sun-Spots-Request at RICE.EDU
Fri Jul 22 15:48:33 AEST 1988


SUN-SPOTS DIGEST          Thursday, 21 July 1988        Volume 6 : Issue 148

Today's Topics:
                       Re: touchup - rasfilter8to1
                          Re: DB-15 slide latch
                         Re: "Fonts?  BIG FONTS?"
                     print selection .. an easier way
                  ViewData ... maybe you mean DataViews
                    getting physical interface address
                            FR device drivers
                        need SNA Peer-to-Peer info
                  Multiple Swapping:  three partitions?
                             Speech on a Sun?
                              NeWS Question
                        Question on Unused Client
                  Macpaint to raster converter (source)

Send contributions to:  sun-spots at rice.edu
Send subscription add/delete requests to:  sun-spots-request at rice.edu
Bitnet readers can subscribe directly with the CMS command:
    TELL LISTSERV AT RICE SUBSCRIBE SUNSPOTS My Full Name
Recent backissues are available via anonymous FTP from "titan.rice.edu".
For volume X, issue Y, "get sun-spots/vXnY".  They are also accessible
through the archive server:  mail the request "send sun-spots vXnY" to
"archive-server at rice.edu" or mail the word "help" to the same address
for more information.

----------------------------------------------------------------------

Date:    Tue, 12 Jul 88 13:45:47 EDT
From:    cmarin at cfisun.cfi.com (Carlos Marin -CFI-)
Subject: Re: touchup - rasfilter8to1
Reference: v6n133

In response to "touchup" and the printing of its output to a non-postcript
laserjet, we've been successful in saving touchup files via the raster
option and then printing them with "lpr", (/usr/ucb/lpr).

Carlos R. Marin
CFI/Price Waterhouse
Waltham Ma. 
e-mail to: harvard!cfisun!cmarin

------------------------------

Date:    Tue, 12 Jul 88 15:54:31 EDT
From:    beareq!quants9!rubin at wheaties.ai.mit.edu (Mike Rubin)
Subject: Re: DB-15 slide latch

Slide latches in general are a marginal technology, but Sun complicated
the problem by using cheap foreign parts to save a few cents.  Go to your
local parts supplier and order slide latches from a reputable connector
manufacturer such as AMP.  (The local ripoff joint, Cables & Chips, wanted
$3.20 for one; this means the real price should be a buck or so.) The AMP
latch is made of much better steel and has nearly a millimeter more length
in the smaller notch.  It holds PVC transciever cable securely and can
even deal with that $&#!@ Teflon cable most of the time.  I have the AMP
part number written down somewhere but can't find it right now....

--Mike Rubin
<rubin at topaz.rutgers.edu> <don't reply to the account this is posted from>

------------------------------

Date:    Tue, 12 Jul 88 16:38:29 EDT
From:    gfr%wolfgang at gateway.mitre.org (Glenn Roberts)
Subject: Re: "Fonts?  BIG FONTS?"
Reference: v6n135

> Does anyone have any vfont format (i.e., SunView-type) fonts that I could
> get my hands on?  Especially large ones.

The 1987 Sun User Group tape, available from Sun User Group c/o Sun for
$100, contains a program that converts Macintosh LaserWriter fonts to Sun
vfonts.  There are lots of fonts available for the Mac.

The program is in the directory 'sunview/suntroff/LaserWriterFonts'.  I
routinely use Helvetica 18 for my SunView pop-up menus - looks nice!

The tape also includes 176 fonts ranging in size from 10 to 24 points.
These are in the directory 'sunview/suntroff/LaserWriterFonts/VFont'.
Since these are, for the most part, proportional fonts, they're not of too
much use for screen applications.  The Helvetica is nice, however, for
menus.

- Glenn Roberts, MITRE Corp.
  gfr%wolfgang at gateway.mitre.org

------------------------------

Date:    Tue, 12 Jul 88 14:35:54 EDT
From:    gfr%wolfgang at gateway.mitre.org (Glenn Roberts)
Subject: print selection .. an easier way
Reference: v6n136

The following was proposed as a way to print the current selection:

#!/bin/csh -f -e
# print current text selection
echo "" | cat /tmp/winselection - | sed 1d | lpr -h

The preferred method, according to Sun, is to use their utility called
get_selection(1).  The man page recommends the following entry in the root
menu:

"Print It"   csh -c "get_selection 1 | lpr"

Counting on Sun always using /tmp/winselection is probably a mistake (note
the radical changes in the file system structure that came about in Sun OS
4.0).  Besides, get_selection has some nice features (can get secondary
and shelf selections; has built-in timeout and debuging features).  Look
it up!

If you think about it, there are a number of useful commands you can build
into your SunView menus using 'get_selection'.  Pipe the output through
spell and you have an instant spell-checker! (caveat: I haven't tried
this).

- Glenn Roberts, MITRE Corp
  gfr%wolfgang at gateway.mitre.org

------------------------------

Date:    Tue, 12 Jul 88 15:17:10 EDT
From:    gfr%wolfgang at gateway.mitre.org (Glenn Roberts)
Subject: ViewData ... maybe you mean DataViews
Reference: v6n136

> Does anyone know of a system called Viewdata, a prototyping package for
> SUNs? We have heard it mentioned but our local supplier has neverr heard
> of it, nor is it listed in the SUN catalogue.  }i We'd like to know what
> it does, what it costs and whether it is useful for prototyping in HCI.

Perhaps you're referring to DataViews from V.I. Corporation, Amherst MA.

DataViews is a (sort-of) object-oriented package consisting of a drawing
tool (DVdraw) and a library of subroutines (DVtools) for developing
interactive graphic programs.  Their main customers are people who want to
interface to process control systems (run your nuclear reactor from your
Sun's console!, etc.).  The package is nice for developing interactive
demonstrations too.  You can associate drawing characteristics, e.g.
color, with live or canned data.  The package also has a nice selection of
'graph formatters' which let you put bar-charts, dials, knobs, meters,
clocks, etc. on the screen, and tie these to variables.

The package is useful for some types of prototyping, but is really not a
generalized prototyping package.  For that you may want to go to something
like Virtual Prototypes Inc's (Montreal, Canada) VAPS product, if you've
got the bucks.

(The usual disclaimer:  I am not associated in any way with V.I. Corp.  or
Virtual Prototypes, etc ...)

- Glenn Roberts, MITRE Corp.
  gfr%wolfgang at gateway.mitre.org

------------------------------

Date:    Tue, 12 Jul 88 15:02:33 EDT
From:    gfr%wolfgang at gateway.mitre.org (Glenn Roberts)
Subject: getting physical interface address
Reference: v6n136

> Does anyone out there know how one retrieves the ethernet address of a
> physical interface under SunOS 3.x or 4.0?  (Actually, most interested in
> an answer about 4.0).

The command arp -a lists the entries in the Internet-to-Ethernet address
translation tables.  Unfortunately, these entries are volatile.  One trick
may be to rlogin to your computer.  This seems to put an arp entry in the
table, so arp -a should report the information you want.

This is a klunky way I admit... perhaps some arp expert will show us the
'right' way to do this.

- Glenn Roberts, MITRE Corp.
  gfr%wolfgang at gateway.mitre.org

------------------------------

Date:    Tue, 12 Jul 88 17:54:38 EDT
From:    rich%sendai.uucp at umix.cc.umich.edu
Subject: FR device drivers

Does anyone have a freely redistributatble device driver for sync ports?
Our problem is that we need to read something almost but not quite
standard and we don't have a source liscence.

On a seperate but related note, does anyone have a standard tty device
driver they can share?

------------------------------

Date:    Tue, 12 Jul 88 16:09:43 PDT
From:    celeste at coherent.com (Celeste C. Stokely)
Subject: need SNA Peer-to-Peer info

I'm looking for info on Sun's SNA Peer-to-Peer product. Has anyone out
there used it? Is it robust? Did good, hard use of it bog down your Sun 3?
How was the support? Is there another 3rd party product for this protocol
that you liked better?

Email replies to me, please, and I'll summarize to sun-spots if there is
enough interest. All war stories accepted.

..Celeste Stokely
Coherent Thought Inc.
UUCP:	...!{ames,sun,uunet}!coherent!celeste   Domain: celeste at coherent.com
Internet: coherent!celeste at ames.arpa or ... at sun.com or ... at uunet.uu.net
VOX:  415-493-8805
SNAIL:3350 W. Bayshore Rd. #205, Palo Alto CA  94303

------------------------------

Date:    Tue, 12 Jul 88 10:52:26 PDT
From:    Steve Blair <spar!ascway!scb at decwrl.dec.com>
Subject: Multiple Swapping:  three partitions?

I as most of know that one can swap on 2 drives(e.g.: sd0b & sd1b).  This
is great and really will in some cases enhance the performance of your
machine(s). I won't go into the details here of how to do this since it's
already been discussed here before.

My question: Is it possible to swap on THREE partitions? I wonder this
since I have several machines with 2 swaps(xy0b & xy1b), and I now have an
Interphase 4200 w/a CDC9772-858mb drive. This drive is faster than all get
out. I would like to also swap on it. A usual configuration line in your
kernel for 2 drives looks like this:

root on xy0a swap on xy0b and xy1b
fstab:
/dev/xy1b     /swap                   swap rw 0 0

So why couldn't I do this??
root on xy0a swap on xy0b and xy1b and ip0b
fstab:
/dev/xy1b     /swap                   swap rw 0 0
/dev/ip0b     /swap2		      swap rw 0 0

Seems like this should work. Anyone have any experience with this
configuration? Anyone have any concerns that they'd like to voice
regarding this??

Steve Blair
Unix System Administrator
Austin Systems Center
Schlumberger Well Services

uucp:{backbone}!sun!decwrl!spar!ascway!scb
internet: spar!ascway!scb at decwrl.dec.com

------------------------------

Date:    Tue, 12 Jul 88 14:46:01 EDT
From:    fkuhl at amadeus.mitre.org (F. S. Kuhl)
Subject: Speech on a Sun?

A recent question entitled, "Sound on a Sun" prompts me to ask a similar
question: does anybody know sw/hw for digitizing and playing back speech
on a Sun?  The application involves generating audio messages from a set
of pre-recorded phrases.  I know half an answer already:  there is an OEM
voice board available from MicroVoice in Calif. for VME bus that looks like
it would do nicely, but they have no software for it.
Please respond to fkuhl%amadeus at gateway.mitre.org.
Thanks--Fred Kuhl

------------------------------

Date:    12 Jul 88 16:34:14 GMT
From:    ssc-vax!dmg at beaver.cs.washington.edu (David Geary)
Subject: NeWS Question

I've just received NeWS 1.1 for my Sun 3/60.  Right now I'm wading through
the documentation that I recieved with the software.  However, before I've
even started, I have a question that I cannot find an answer for in the
documentation:

If I write a NeWS-based application, can I run the application on another
Sun that does NOT have NeWS loaded on it?  If not, how much of the ~16
Megs of NeWS software must be loaded on the workstation?

NeWS looks like interesting stuff to develop applications in, but my
workstations do not have 16 Megs free just to support a couple of *neat*
application programs.

Thanx for the help...

David Geary, Boeing Aerospace

------------------------------

Date:    Tue, 12 Jul 88 15:45:18 EDT
From:    kodak!dennett at cs.rochester.edu (charlie dennett)
Subject: Question on Unused Client

Recently, my group here at Kodak purchased a 3/260 and a 3/50.  The 260 is
the server and the 50 is a diskless client.  When we initially installed
the 260, we actually specified 2 clients in the setup program just in case
we ever got another workstation.  I don't know if that will ever be the
case.  My question is this:  does this unused client take up any
substantial amount of disk space on the server?  I only have a single 280
Meg disk and I'll take all the extra free space I can get.

If the information I seek is somewhere in a manual, could some please let
me know where?  I've looked and all I can find is info on adding a client.
I found nothing about removing one.

Thanks for any help.

Charlie Dennett - Eastman Kodak Company
UUCP: ...rutgers!rochester!kodak!dennett 
      ...rutgers!rochester!kodak!cygnus!dennett

------------------------------

Date:    Tue, 12 Jul 88 08:26:57 EDT
From:    gfr%wolfgang at gateway.mitre.org (Glenn Roberts)
Subject: Macpaint to raster converter (source)

After seeing two requests for a macpaint to raster converter, here is my
contribution.  I wrote this program a year and a half ago and haven't used
it much since, but I just recompiled and it does work.  It was designed to
display Macintosh screen dump images, but can be modified for larger
images by changing NROWS and NCOLS.  This version was written before there
was a Mac II, hence it does not support color.  It should be compiled with
the -lpixrect flag.

- Glenn Roberts, MITRE Corp
  gfr%wolfgang at gateway.mitre.org

------------------------------ cut here --------------------
/* 
** convert.c
**
** Program to convert MacPaint files to pixrect format
** on the Sun 3 Workstation.
**
** usage:   convert mac_filename pix_filename
**
** Author:  Dr. Glenn F. Roberts
**          MITRE corp., Dept. W49.
**          January 30, 1987
**
** Version 1.0
**
*/
#include <stdio.h>
#include <pixrect/pixrect_hs.h>

#define FALSE	0
#define TRUE	!FALSE

/* size of MacIntosh screen */
#define NROWS 342
#define NCOLS 512

/* MacPaint file and picture attributes */
#define LINE_LEN 72
#define BLOCK_SIZE 512
#define SRC_SIZE 2*BLOCK_SIZE

/* Working storage for image conversion */
char src_buf[SRC_SIZE];
char scan_line[LINE_LEN];


main (argc, argv)
int argc;
char *argv[];
{
   struct pixrect *picture;
   int j;
   FILE *fh, *fh2;
   colormap_t *colormap = NULL;
   int type = RT_STANDARD;
   int copy_flag = 0;

   int i, row, col;
   unsigned char val;
   char ch, *src, *dest;

   /* open the input file */
   if (--argc > 0) {
      if ((fh = fopen(*++argv, "r")) != NULL) {
         fseek(fh, 512L, 0);
         fread(src_buf, SRC_SIZE, 1, fh);
         src = src_buf;
      }
      else {
	 printf("Error opening input file\n");
	 exit(1);
      }
   }
   else {
      printf("usage: convert infile outfile\n");
      exit(1);
   }

   /* open the output file */
   if (--argc > 0) {
      if ((fh2 = fopen(*++argv, "w")) == NULL) {
	 printf("Error opening output file\n");
	 exit(1);
      }
   }
   else {
      printf("usage: showmac infile outfile\n");
      exit(1);
   }


   /* create memory pixrect */
   picture = mem_create(NCOLS, NROWS, 1); 

   /* loop over scan lines */
   printf("Building image, ...\n");
   for (row=0; row<NROWS; row++) {
      dest = scan_line;
      unpack_bits(&src, &dest, LINE_LEN);
      if (src > src_buf+SRC_SIZE-BLOCK_SIZE) {
         memcpy(src_buf, src_buf+SRC_SIZE-BLOCK_SIZE, BLOCK_SIZE);
         fread(src_buf+BLOCK_SIZE, SRC_SIZE-BLOCK_SIZE, 1, fh);
         src -= SRC_SIZE-BLOCK_SIZE;
      }
      display_line(row, scan_line, LINE_LEN, picture);
   }

   /* done ... */
   printf("Saving image ...\n");
   if ((pr_dump(picture, fh2, colormap, type, copy_flag)) != 0) {
      printf("Error outputing image with pr_dump\n");
      exit(1);
   }
   fclose(fh2);
   exit (0);
}



/*
  display_line - displays one MacPaint line (unpacked)
  contained in the array line at the specified row on
  the Sun's screen.
*/
display_line(row, line, length, screen)
char line[LINE_LEN];
int row, length;
struct pixrect *screen;
{
   int i, j, col;
   char ich;

   /* loop over bytes per line */
   for (col=0, i=0; i<length; i++) {
      ich = line[i];
      /* loop over 8 bits per byte */
      for (j=col+7; j>=col; j--) {
         pr_put(screen, j, row, (ich & 1));
	 ich = ich >> 1;
      }
      col += 8;
   }
}



/*
  unpack_bits - converts a MacPaint line from packed
  format to unpacked format.  The resulting line should
  be of length len bytes.  Echoes the function of the
  equivalent routine in the Macintosh ROM.
*/
unpack_bits(source, dest, len)
char *(*source), *(*dest);
int len;
{
  char *d, count, ch;

  for (d=(*dest); (*dest)-d<len;)
    if ((count = *(*source)++) < 0) { /* it's a repeat count */
      ch = *(*source)++;
      for (count=1-count; count>0; count--)
        *(*dest)++ = ch;
    }
    else                              /* it's a byte count */
      for (count+=1; count>0; count--)
        *(*dest)++ = *(*source)++;
}

------------------------------

End of SUN-Spots Digest
***********************



More information about the Comp.sys.sun mailing list