Hi Ken,
Hi Chris,

I just want to let you know that I could specify if the start up disk
is connected through firewire bus. Thank you for your information!

Sincerely,

Ryota

2008/9/10 Ryota Tsukiashi <[EMAIL PROTECTED]>:
> Hi Chris,
>
> Thank you. I will try FSMegaInfo as well.
>
> Ryota
>
> 2008/9/10 Ken Thomases <[EMAIL PROTECTED]>:
>> On Sep 9, 2008, at 10:23 PM, Chris Suter wrote:
>>
>>> On Wed, Sep 10, 2008 at 10:10 AM, Ryota Tsukiashi
>>> <[EMAIL PROTECTED]>wrote:
>>>
>>>> I am writing a cocoa application for our firweire device. I need to
>>>> know if the system is started up from firewire disk. For PowerPC with
>>>> Mac OSX 10.4/10.5, I have used information from "nvram boot-device".
>>>> For IntelMac with 10.4/10.5, I have used "nvram efi-boot-device". I am
>>>> not sure if it is a proper way, but it has been working OK.
>>>
>>>
>>> No, it's not the right way. That will only tell you what the start up disk
>>> is set to which isn't necessarily what you started from (for example, you
>>> could have booted by holding down the Option key).
>>>
>>> One way to do this is to use fsstat on "/" to get the BSD information and
>>> then use IOKit (IOServiceGetMatchingService) to find the device that
>>> refers
>>> to and then you might have to go up the hierarchy until you hit the level
>>> you want.
>>>
>>> There might be easier ways to do this; that's just the one I first thought
>>> of.
>>
>> The Disk Arbitration framework may be easier to use than IOKit.
>>
>> You might look at the FSMegaInfo sample code for inspiration regarding other
>> techniques:
>>
>> http://developer.apple.com/samplecode/FSMegaInfo/index.html
>>
>> Cheers,
>> Ken
>>
>>
>
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to