[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
How do you call pgetappletalkinfo?
- To: email@example.com
- Subject: How do you call pgetappletalkinfo?
- From: Shannon V Spires <firstname.lastname@example.org>
- Date: Thu, 7 Apr 1994 17:10:56 -0600 (MDT)
- Cc: email@example.com (Shannon V Spires)
- In-reply-to: <9404070800.AA05298@cambridge.apple.com> from "firstname.lastname@example.org" at Apr 7, 94 04:00:04 am
Ok guys and gals, I'm at the end of my rope here.
I'm trying to create a globally-unique symbol name;
global across a network of Macs running MCL. Sort
of a global-gensym, if you will. One way to do this
is to just concatenating a local gensym onto some unique
identifier for my local Macintosh. The problem is
getting that unique identifier for my local Mac. The
way I'm trying to do this is to get the Appletalk
address of this machine, which is always unique. So
I'm trying to call pgetappletalkinfo to get the
Appletalk address of this machine. Here's the code:
; This deftrap definition is from the Appletalk.lisp
; interfaces file (it's Not in ROM).
(deftrap _pgetappletalkinfo ((thepbptr (:pointer :mppparamblock)) (async
; Here's my code:
(defun get-my-appletalk-address ()
"Returns my appletalk address."
(let ((address nil))
(rlet ((pb :MPPParamBlock
(#_PGetAppleTalkInfo pb nil)
(setq address (pref pb MPPParamBlock.ourAddr))
But when I try to eval the definition, I get this error:
> Error: value 0 is not of the expected type SEQUENCE.
> While executing: EXPAND-TRAP
> Type Command-. to abort.
We haven't even gotten to the point of actually calling
the function. If I ever do get there, what goes in the
csCode field of the MPPParamBlock? IM says "PGetAppleTalkInfo"
and then refuses to define what this constant is.
Any clues anybody?