Page 8 of 9
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 6:48 pm
by Jeff_HxC2001
XorA wrote:Yeah new exe is non optimised and probably with some debugging info.
One thing I have noticed is I really need to add some error checking, typoing the image here crashes badly

Yes i have made some changes in my side.
Code: Select all
void* OpenQLDevice(char *name, int mode)
{
int sectors, err;
hxcfe = hxcfe_init();
hxcfe_setOutputFunc(hxcfe, &CUI_affiche);
loaderid = hxcfe_autoSelectLoader(hxcfe, name, 0);
if(loaderid < 0)
{
hxcfe_deinit(hxcfe);
return -1;
}
rw_access = hxcfe_getLoaderAccess(hxcfe, loaderid);
floppy = hxcfe_floppyLoad(hxcfe, name, loaderid, &err);
hxcfe_getFloppySize(hxcfe, floppy, §ors);
//1600 -> 10Sectors per track : Ql trump board seems to put an unused sector at the head of the track...
if ((sectors != 1440) && (sectors != 2880) && (sectors != 1600)) {
hxcfe_floppyUnload(hxcfe, floppy);
hxcfe_deinit(hxcfe);
return -1;
}
ifmode = hxcfe_floppyGetInterfaceMode(hxcfe, floppy);
filename = name;
sector_written = 0;
return 0;
}
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 7:21 pm
by XorA
Thanks Jeff, I did not know about the extra sector, I incorporated your error checking as well.
Ian, will send you a PM asking for an email of your .HFE to test here as its slightly different than
my ones.
Attached new version of .exe
Code: Select all
C:\Users\graeme\Documents\hxcfe>qltools qlboot_img.hfe -d -w test3_bas -d
qlboot
1110/1440 sectors.
boot 74 29/11/101 11:32:15 v1
ipcextuk_bin 5558 22/02/114 23:02:02 v1
kbdgen_bas 28747 22/02/114 23:02:05 v1
kbd_UK_bas 7428 22/02/114 23:02:06 v1
IPCEXTUK_ROM 5600 22/02/114 23:02:06 v1
unzip E 111158 22/02/114 23:13:55 v1 (51810)
test_bas 31 21/03/114 19:08:53 v0
test2_bas 31 21/03/114 19:10:51 v0
qlboot
1107/1440 sectors.
boot 74 29/11/101 11:32:15 v1
ipcextuk_bin 5558 22/02/114 23:02:02 v1
kbdgen_bas 28747 22/02/114 23:02:05 v1
kbd_UK_bas 7428 22/02/114 23:02:06 v1
IPCEXTUK_ROM 5600 22/02/114 23:02:06 v1
unzip E 111158 22/02/114 23:13:55 v1 (51810)
test_bas 31 21/03/114 19:08:53 v0
test2_bas 31 21/03/114 19:10:51 v0
test3_bas 31 21/03/114 19:16:20 v0
C:\Users\graeme\Documents\hxcfe>qltools qlboot_img.hfe -d
qlboot
1107/1440 sectors.
boot 74 29/11/101 11:32:15 v1
ipcextuk_bin 5558 22/02/114 23:02:02 v1
kbdgen_bas 28747 22/02/114 23:02:05 v1
kbd_UK_bas 7428 22/02/114 23:02:06 v1
IPCEXTUK_ROM 5600 22/02/114 23:02:06 v1
unzip E 111158 22/02/114 23:13:55 v1 (51810)
test_bas 31 21/03/114 19:08:53 v0
test2_bas 31 21/03/114 19:10:51 v0
test3_bas 31 21/03/114 19:16:20 v0
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 7:32 pm
by IanJ
Same problem, could not open image.
Tried a different HFE same problem.
Tried this new HFE with original qltools and it does read the file ok.
Email sent with zip.
Ian.
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 7:56 pm
by XorA
This is really odd, I can read and write to all the .HFE files you sent to me!
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 8:06 pm
by IanJ
XorA wrote:This is really odd, I can read and write to all the .HFE files you sent to me!
I'm using Win7(64) but I also tried on an old WinXP laptop and same results, can't read the image. Only the org version of qltools works (in that respect).
Your DLL hasn't changed has it?
Ian.
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 8:08 pm
by XorA
Its possible I zipped up a stale copy of qltools, is is one I just tested. This works for me in wine (linux windows emulator) and on Win8.1
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 8:14 pm
by IanJ
Success.....and can confirm all is okay on the QL also.
Code: Select all
C:\Users\Ian\Desktop\qfe>qltools-hxcfe QLQuill.HFE -d -w C_BAS -d
test
984/1440 sectors.
clone 434 01/01/70 00:00:00 v0
314 01/01/70 00:00:00 v0
QUILL 1679427012 01/01/70 00:00:00 v0
QUIL_HOB 18944 01/01/70 00:00:00 v0
INSTALL_BAS 12305 01/01/70 00:00:00 v0
INSTALL_DAT 1301 01/01/70 00:00:00 v0
PRINTER_DAT 98 01/01/70 00:00:00 v0
CONVERT_BAS 2250 01/01/70 00:00:00 v0
C_BAS 66792 21/03/114 20:09:32 v0
file C_BAS exists, overwrite [Y/N/A/Q] : Y
test
984/1440 sectors.
clone 434 01/01/70 00:00:00 v0
314 01/01/70 00:00:00 v0
QUILL 1679427012 01/01/70 00:00:00 v0
QUIL_HOB 18944 01/01/70 00:00:00 v0
INSTALL_BAS 12305 01/01/70 00:00:00 v0
INSTALL_DAT 1301 01/01/70 00:00:00 v0
PRINTER_DAT 98 01/01/70 00:00:00 v0
CONVERT_BAS 2250 01/01/70 00:00:00 v0
C_BAS 66792 21/03/114 20:10:10 v1
C:\Users\Ian\Desktop\qfe>
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 8:19 pm
by XorA
Yay, I am not completely dumb then
The source probably now only compiles with gcc and mingw32 but I can live with that!
G
Re: Floppy emulator (SD card)
Posted: Fri Mar 21, 2014 8:23 pm
by IanJ
XorA wrote:Yay, I am not completely dumb then
The source probably now only compiles with gcc and mingw32 but I can live with that!
G
If the update to the Windows app is a long way off then I may create a wrapper for this DOS version. Should be doable.
Ian.
Re: Floppy emulator (SD card)
Posted: Sat Mar 22, 2014 7:10 pm
by IanJ
Hi,
Quick question......is there a wildcard for qltools.....I can't see one.
qltools images\QLA.HFE -w files\C_BAS
Would like to write a batch/folder full of files to an image instead of singles per above.
Ian.