Skip to content

Commit 85e4e1e

Browse files
committed
apple2: fuji: add lobby boot option
1 parent db82a5d commit 85e4e1e

File tree

1 file changed

+19
-1
lines changed

1 file changed

+19
-1
lines changed

lib/device/iwm/fuji.cpp

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include "led.h"
1515
#include "fnWiFi.h"
1616
#include "fsFlash.h"
17+
#include "fnFsTNFS.h"
1718
#include "utils.h"
1819
#include "string_utils.h"
1920

@@ -1238,10 +1239,18 @@ void iwmFuji::insert_boot_device(uint8_t d)
12381239
get_disk_dev(0)->mount(fBoot, config_atr, 143360, MEDIATYPE_PO);
12391240
break;
12401241
case 1:
1241-
12421242
fBoot = fsFlash.fnfile_open(mount_all_atr);
12431243
get_disk_dev(0)->mount(fBoot, mount_all_atr, 143360, MEDIATYPE_PO);
12441244
break;
1245+
case 2:
1246+
Debug_printf("Mounting lobby server\n");
1247+
if (fnTNFS.start("tnfs.fujinet.online"))
1248+
{
1249+
Debug_printf("opening lobby.\n");
1250+
fBoot = fnTNFS.fnfile_open("/APPLE2/_lobby.po");
1251+
get_disk_dev(0)->mount(fBoot, "/APPLE2/_lobby.po", 143360, MEDIATYPE_PO);
1252+
}
1253+
break;
12451254
}
12461255
#else
12471256
const char *boot_img;
@@ -1257,6 +1266,15 @@ void iwmFuji::insert_boot_device(uint8_t d)
12571266
boot_img = mount_all_atr;
12581267
fBoot = fsFlash.fnfile_open(boot_img);
12591268
break;
1269+
case 2:
1270+
Debug_printf("Mounting lobby server\n");
1271+
if (fnTNFS.start("tnfs.fujinet.online"))
1272+
{
1273+
Debug_printf("opening lobby.\n");
1274+
boot_img = "/APPLE2/_lobby.po";
1275+
fBoot = fnTNFS.fnfile_open(boot_img);
1276+
}
1277+
break;
12601278
default:
12611279
Debug_printf("Invalid boot mode: %d\n", d);
12621280
return;

0 commit comments

Comments
 (0)