i think that if anyone wants to get this working for newer notebooks, they will have to try and figure out the grittier tech aspects of it. i myself have been trying, but lack the code savvy to draw any sound conclusions. i know that i could change the serial through the command line or through one of the various startup modes if i could find where it is and the format in which it is stored (probably a .string, but i dont know for sure). according to the original poster, the serial number is in NVRAM. as far as i can tell, this is not the case. perhaps other users will find this to be otherwise, but on my imac g5 (1gen) it is not here. you can derive conclusive evidence on this simply by opening terminal and entering
which will print the contents of NVRAM to the display. on my computer, the serial number is not among the items that show up.
it seems that the serial number is declared in the IOPlatformExpert header file in IOKit, but because it is a variable that will, well, vary depending on the computer, finding the actual value and storage location of such is something I don't quite understand. if anyone here has a deeper understanding of these things that me, please shed some light on this for us. i have a feeling that this is the only way that a functional means of doing this will be found.
edit: so in the IOKit.framework directory, there is a folder labeled serial. in this folder, there are two c header files. One is titled IOSerialKeys.h, the other ioss.h. The following tags contain their respective contents:
* 2000-10-21 gvdl Initial real change to IOKit serial family.
Sample Matching dictionary
IOProviderClass = kIOSerialBSDServiceValue;
kIOSerialBSDTypeKey = kIOSerialBSDAllTypes
kIOTTYDeviceKey = <Raw Unique Device Name>;
kIOTTYBaseNameKey = <Raw Unique Device Name>;
kIOTTYSuffixKey = <Raw Unique Device Name>;
kIOCalloutDeviceKey = <Callout Device Name>;
kIODialinDeviceKey = <Dialin Device Name>;
Note only the IOProviderClass is mandatory. The other keys allow the searcher to reduce the size of the set of matching devices.
/* Service Matching That is the 'IOProviderClass' */
#define kIOSerialBSDServiceValue "IOSerialBSDClient"
/* Matching keys */
#define kIOSerialBSDTypeKey "IOSerialBSDClientType"
/* Currently possible kIOSerialBSDTypeKey values. */
#define kIOSerialBSDAllTypes "IOSerialStream"
#define kIOSerialBSDModemType "IOModemSerialStream"
#define kIOSerialBSDRS232Type "IORS232SerialStream"
// Properties that resolve to a /dev device node to open for
// a particular service
#define kIOTTYDeviceKey "IOTTYDevice"
#define kIOTTYBaseNameKey "IOTTYBaseName"
#define kIOTTYSuffixKey "IOTTYSuffix"
#define kIOCalloutDeviceKey "IOCalloutDevice"
#define kIODialinDeviceKey "IODialinDevice"
// Property 'ioctl' wait for the tty device to go idle.
#define kIOTTYWaitForIdleKey "IOTTYWaitForIdle"
extern const OSSymbol *gIOSerialBSDServiceValue;
extern const OSSymbol *gIOSerialBSDTypeKey;
extern const OSSymbol *gIOSerialBSDAllTypes;
extern const OSSymbol *gIOSerialBSDModemType;
extern const OSSymbol *gIOSerialBSDRS232Type;
extern const OSSymbol *gIOTTYDeviceKey;
extern const OSSymbol *gIOTTYBaseNameKey;
extern const OSSymbol *gIOTTYSuffixKey;
extern const OSSymbol *gIOCalloutDeviceKey;
extern const OSSymbol *gIODialinDeviceKey;
#endif /* KERNEL */
/* Copyright © 1997 Apple Computer, Inc. All Rights Reserved */
/* ioctl's for all Apple IOSerialStream based streaming serial ports */
* External clock baud rates, for use with cfsetospeed
#define _MAKE_EXT(x) (((x) << 1) | 1)
#define BEXT1 _MAKE_EXT(1)
#define BEXT2 _MAKE_EXT(2)
#define BEXT4 _MAKE_EXT(4)
#define BEXT8 _MAKE_EXT(8)
#define BEXT16 _MAKE_EXT(16)
#define BEXT32 _MAKE_EXT(32)
#define BEXT64 _MAKE_EXT(64)
#define BEXT128 _MAKE_EXT(128)
#define BEXT256 _MAKE_EXT(256)
* Sets the receive latency (in microseconds) with the default
* value of 0 meaning a 256 / 3 character delay latency.
#define IOSSDATALAT _IOW('T', 0, unsigned long)
* Controls the pre-emptible status of IOSS based serial dial in devices
* (i.e. /dev/tty.* devices). If true an open tty.* device is pre-emptible by
* a dial out call. Once a dial in call is established then setting pre-empt
* to false will halt any further call outs on the cu device.
#define IOSSPREEMPT _IOW('T', 1, int)
* Sets the input speed and output speed to a non-traditional baud rate
#define IOSSIOSPEED _IOW('T', 2, speed_t)
#endif /*_POSIX_SOURCE */
* END OF PROTECTED INCLUDE.
#endif /* !_SYS_IOSS_H */
taking a break now but will be back.