FujiNetWIFI / fujinet-config

#FujiNet cross-platform CONFIG program
GNU General Public License v3.0
6 stars 19 forks source link

Determine which Disk II drives the FujiNet represents #101

Closed FozzTexx closed 1 month ago

FozzTexx commented 1 month ago

This adds the ability for CONFIG to determine which Disk II drive(s) the FujiNet is connected as. Requires the CONTROL/STATUS commands added to the firmware on diskii_drive_detect PR. https://github.com/FujiNetWIFI/fujinet-firmware/pull/805

During startup CONFIG will locate all the Disk II controllers in the Apple II and spin them quickly and query the FujiNet if it saw the drive spin. After determining which drives are connected to the FujiNet, the Disk II drives will display the slot & drive instead of a simple "1" or "2". If a drive is not detected then it will display as NA. If older firmware is installed which doesn't support IWM_CTRL_CLEAR_ENSEEN then the Disk II drives will use the simple "1" or "2".

Mainly intended for use on the IIc since many people are confused about which FujiNet Disk II drive represents the external drive, however the display of slot/drive for the Disk II drives is useful on all Apple IIs.

Tested on IIe with Disk II card, IIc as external drive, IIe with Dsub19 IO controller, and IIc+.

Note: I had to workaround an issue with sp_get_fuji_id() because for some reason it sometimes returns 1 instead of 8 and leaves sp_fuji_id == 0. (Lines 61-65 in diskii.c)

14C171C6-C678-4460-9D0E-2B3C855D3EB3_1_105_c 0FB4D361-37B2-409E-B5A6-77342F65B34D_1_105_c 835DE486-E919-40F5-97F3-0C58DC587E84_1_105_c FD20B2EE-20CA-4C9F-BB07-774B06D75F5A_1_105_c

tschak909 commented 1 month ago

Thank you!

dillera commented 1 month ago

THis worked as expected on my IIc and is very useful addition to CONFIG.