English Amiga Board


Go Back   English Amiga Board > Coders > Coders. System

 
 
Thread Tools
Old 16 February 2013, 19:30   #1
mark_k
Registered User
 
Join Date: Aug 2004
Location:
Posts: 3,333
How to find Exec device name and unit number for boot drive

I'm going to (try to) put together a custom "combo" CD image which auto-boots on any Amiga with a SCSI controller, as well as CDTV/CD32.

To do that I'll create an FFS partition after the ISO 9660 partition. Amigas with SCSI controllers will boot from the FFS partition. I'll have a CD filesystem in that partition, and mount the ISO 9660 partition from the startup-sequence.

But in order to mount the ISO 9660 partition, I need to know the Exec device name and unit number of the boot drive. Obviously those will vary depending on the make of SCSI card and the CD drive SCSI ID. How can I determine the device and unit for the boot drive, in a way which works with both Kickstart 1.3 and 2.0+?
mark_k is online now  
Old 16 February 2013, 19:43   #2
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,502
Quick and short answer:

Find boot dos device's DeviceNode in DosList (DosLibrary->dl_Root->rn_Info->di_DevInfo). DeviceNode->dn_Startup points to FileSysStartupMsg which has pointers to device name and unit number. (Note that all pointers are BPTR and strings are BSTR as usual)

OS 2.0+ has functions for finding DeviceNodes. 1.3 requires manual enumeration.
Toni Wilen is offline  
Old 16 February 2013, 19:49   #3
mark_k
Registered User
 
Join Date: Aug 2004
Location:
Posts: 3,333
Thanks. Do I need to know the DOS device name (CDBOOT: or whatever I choose) or can I find the DeviceNode from "SYS:" somehow?
mark_k is online now  
Old 16 February 2013, 19:52   #4
Toni Wilen
WinUAE developer
 
Join Date: Aug 2001
Location: Hämeenlinna/Finland
Age: 49
Posts: 26,502
Yes, it is possible.

Find SYS: assign in DosList, save dol_Task. Find DLT_DEVICE DosList node which has same dol_Task.
Toni Wilen is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Analogic's CD32 disk drive expander unit mini review. Paul_s Hardware pics 100 27 August 2013 08:21
After creating OS 3.9 Emergency Disk: Cannot open "cd.device" unit 2 Snowwie support.Other 2 31 March 2012 14:44
Where would I find a floppy power supply unit? Narf the Mouse support.Hardware 3 22 January 2012 00:00
change the cd-rom unit number(sorry wrong place if a moderator can change) turrican3 support.OtherUAE 19 04 May 2007 23:27
Can't get unit device # for CD-ROMs MobbyG support.WinUAE 5 26 November 2003 09:52

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 15:50.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.08293 seconds with 13 queries