A new MENU system for MMC/Gotek

Got a programming project in mind? Tell everyone about it!
User avatar
SpaceFlightOrange
Posts: 154
Joined: Mon Jan 21, 2019 2:28 pm
Contact:

Re: A new MENU system for MMC/Gotek

Post by SpaceFlightOrange » Sat Feb 09, 2019 1:39 pm

Hey Tricky.

I tried this as recommended by you, and what can I say? It's brilliant!

I have noticed That I get a couple of not founds here and there and I have to kinda do a double shift-break to return to the menu, but apart from that, amazing work!

Thanks
James

BBC Model A Issue 3 (Upgraded to Model B, had it since I was a kid), Opus Dual 40/80 FDD, Watford Mouse, Voltmace delta 14/B, Gotek, IFEL ROMRAM-B4, Pi-Zero CoPro

Master 128, VideoNuLA, Gotek

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Sat Feb 09, 2019 2:03 pm

I seem to have broken something, but am now starting to feel better and taking a look.
I haven't worked out what I have done wrong, but I have added a bit of debugging code to mmbeeb.dll to make debugging it easier.
I have added some messages that print to DebugOutputStringA including where it is looking for files and which disc/track/sector it is trying to read/write. These can be viewed from the VisualStudio Output window or with the free SysInternals (now Microsoft) DBGVIEW app (untested).
PS
I also added an extra function to the DLL so that beebem can register a function for mmbeeb.dll to use to write text to the debug window. void SetOutputDebugString(void (__cdecl NewOutputDebugString)(const char * msg)) if called with a fuction, the dll will log to that, if called with NULL (the default) it will call OutputDebugStringA.
Attachments
mmbeeb.dll.zip
(4.65 KiB) Downloaded 35 times
Last edited by tricky on Sat Feb 09, 2019 3:35 pm, edited 1 time in total.

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Sat Feb 09, 2019 3:44 pm

I don't know what had happened with my previous upload, as it is different to my local copy, which, works correctly!
I have added an option to include only "Commercial Releases" and produced a new pair of downloads for them.
As a bonus, they now fit into a single BEEB.MMB and .SSD files for the GOTEK, are more compatible and work on any MMC ROM.
DropBox links should not require any login: bbcmicro.co.uk commercial releases: GOTEK and any MMC.

MadeGray
Posts: 75
Joined: Wed Dec 27, 2017 4:44 pm
Contact:

Re: A new MENU system for MMC/Gotek

Post by MadeGray » Sat Feb 09, 2019 3:57 pm

Will give it a try!

Thanks Tricky!
John Gray

BBC Master x2 with BeebSCSI, PI copro etc and lots of Goteks. A few Model B’s and a trusty Elk. Won’t mention the ZX80 and ZX81!

User avatar
jms2
Posts: 2276
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by jms2 » Sun Feb 10, 2019 7:17 pm

I have just tried this for the first time (Gotek version). It's great! :D Thanks very much for creating it!

I made a few observations while getting it set up which I thought were worth mentioning on here:

1) Flashfloppy version is now up to v.1.0. I don't think this makes any practical difference but you might as well install the latest version.

2) The update process is dead easy if you already have an earlier version of FF installed. You just put the .upd file into the root directory of your USB stick and power up the Gotek while holding down the two buttons. The OLED screen then shows various encouraging messages as it updates, and then after that it is ready to go.

3) I have now got my head around how the games collection can co-exist with my pre-existing Gotek USB stick (which was ordered in subfolders etc rather than using indexed mode). I have simply started a completely separate USB stick for the games collection, with non-games software kept on the "manually curated" stick. Now that I have realised how comprehensive the games set is, and how easy it will be to update in future, it's obvious that this is the way to go.

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Sun Feb 10, 2019 8:15 pm

Glad its working for you.

User avatar
jms2
Posts: 2276
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by jms2 » Sun Feb 10, 2019 9:18 pm

Playing with it a bit more, I love the way you've got it to re-insert the menu disk - if you boot any other disk directly, it inserts disk 0 and boots that instead! Very neat.

Got a few questions/comments from closer inspection:

1) I noticed that Boulderdash doesn't load - but I can't see why. It hangs with "at line 160", where line 160 is "*RUN CODE". This is using a Master, but BeebEm suggests that it should run on the Master.

2) I'm also a bit puzzled by which games are in the collection and which are not. For example, Repton: The Lost Realms and White Light are both downloadable from bbcmicro.co.uk, but there are not in the collection. Is this intentional or have they gone AWOL?

3) When the menu starts, it doesn't start on the first page, and pressing zero doesn't move it to the first page either. It starts on the page that has 3D snooker at the top, and pressing left arrow gets to what I believe is the actual first page (with your favourites on it).

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Sun Feb 10, 2019 10:24 pm

It is what was on bbcmicro when I started this and the latest version is games that say "Commercial release".
The menu starts on the first (inc favourites) page for me on my compact.
I can't think why boulderdash might have been broken.
0 sets the page to the beginning of the data, so I don't understand that either, but I'll try it on my master.

strawberrytau
Posts: 43
Joined: Sun Mar 11, 2018 8:58 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by strawberrytau » Wed Feb 20, 2019 9:51 pm

Feature request:

It would be wonderful to toggle sound on/off in the launch menu. This setting would trigger a *FX210,1 as part of the boot sequence if "sound off" was selected.

I think this would be very useful/ 8)

chrisn
Posts: 487
Joined: Sat Apr 19, 2014 11:31 am
Location: UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by chrisn » Tue Jun 11, 2019 7:13 pm

Well done tricky, the menu is amazing, it really makes using the Gotek so much easier =D>
jms2 wrote:
Sun Feb 10, 2019 9:18 pm
I noticed that Boulderdash doesn't load - but I can't see why. It hangs with "at line 160", where line 160 is "*RUN CODE". This is using a Master, but BeebEm suggests that it should run on the Master.
I noticed that this particular disk image has two files named "CODE" on it. Could that be the issue?

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Wed Jun 12, 2019 1:29 pm

It should be using the directory and name, but can get caught out if the "main" program *RUNs itself by name as I think it will have been renamed - should be OK if it wasn't !BOOT.
Sorry, haven't looked at the sound yet, but it should be easy!

chrisn
Posts: 487
Joined: Sat Apr 19, 2014 11:31 am
Location: UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by chrisn » Wed Jun 12, 2019 5:58 pm

tricky wrote:
Wed Jun 12, 2019 1:29 pm
It should be using the directory and name, but can get caught out if the "main" program *RUNs itself by name as I think it will have been renamed - should be OK if it wasn't !BOOT.
I have just done a test with the disk in question (DSKA0052.SSD) - there are files named $.CODE and $.Code. If I delete $.CODE then Boulderdash loads and runs fine.

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Wed Jun 12, 2019 7:20 pm

Thanks, I thought that DFS was case sensitive, but apparently not!
I'll add a check to the ones that check if the current game can be added to the current disc.
I'll also try to add the sound option.
I've had no internet at home for a couple of days - upgrading to Fibre (well, fibre 1/2 a mile away!) and am off with some beebs to Revival this weekend, so it probably won't be until I get back.

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Tue Sep 17, 2019 7:43 pm

Sorry for the long delay, I was debugging a problem with my code that turned out to be beebaid stomping on my (user) memory!
latest versions are now available in the top post and here GOTEK.ZIP BEEB.ZIP via DropBox, no login should be required.
GOTEK.zip should be extracted to the root of your USB stick and contains an FF.CFG and a bunch of DSKA0000.ssd files.
BEEB.zip should be extracted to the root of your storage card and contains BEEB.MMB which should work with any MMC type device.
Backup you files first and please note that FF.CFG will set indexed mode, you can set this back on a different stick for file/folder browsing.
I have added a sound toggle for the games on TAB, this is represented in the bottom right by <) sound on and <X sound off.
This is the Commercial releases with a few favourites (well, currently of interest to me) added on the first page.

PS As usual, please let me know if you find any issues!
Last edited by tricky on Tue Sep 17, 2019 7:45 pm, edited 2 times in total.

User avatar
sweh
Posts: 2089
Joined: Sat Mar 10, 2012 12:05 pm
Location: New York, New York
Contact:

Re: A new MENU system for MMC/Gotek

Post by sweh » Wed Sep 18, 2019 1:05 am

Sorry if I missed this; the thread is growing...

Did you ever release the source and build processes for this? I don't _see_ it!

Also, I'm not sure the build process for the BEEB.MMB file is clean; some disks have "odd" names (eg 276, 277 have DELs; 456 has 0xff; 449 is just weird...)
Last edited by sweh on Wed Sep 18, 2019 1:10 am, edited 1 time in total.
Rgds
Stephen

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Wed Sep 18, 2019 5:27 am

I haven't released the build process yet, it needs a very specific folder layout and is windows command line only.
Each disc after the first uses the title from the first game's disc as its title and some do have "protected" titles. The strange thing is that the last change I made was to sanitize them, but maybe my if is backwards!
I think I still include my GOTEC run at any address:
*din [num] to insert (Disc INsert) disc num.
*dboot [num] to insert and (Disc BOOT) disc num.
*dbbot0 renamed to !BOOT on all but the first disc just *dboot 0

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Wed Sep 18, 2019 6:08 am

ZIPs updated (hopefully for everyone), only the disc titles have changed an I have removed a couple of old SSD images from the GOTEK.zip
Having written a shiny new safe_title() function to go with the old disc_title() it helps if you call it!
The attached .zip contains an SSD which has din, dboot and dboot0 for GOTEKs with appropriate firmware.
Attachments
GOTEKMenu.zip
(14.04 KiB) Downloaded 20 times
Last edited by tricky on Wed Sep 18, 2019 6:11 am, edited 3 times in total.

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Fri Sep 20, 2019 7:57 pm

I think I am missing something. I copy all the files to a flash drive and plug into a gotek. and nothing happens. A shift D break and the gotek hangs for ever. Am I missing a setup step?

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Fri Sep 20, 2019 8:16 pm

Silly question, have you flashed the drive with the FlashFloppy firmware?
https://github.com/keirf/FlashFloppy/wi ... rogramming
You should have an FF.CFG and 450ish .SSD files in the root of the drive.

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Fri Sep 20, 2019 8:29 pm

Yes gotek works fine, used it all the time for last 18 months. Started on 0.9 firmware now up to something like v2.13 of firmware.

Yep as you say I have the ff.cfg and many ssds in the root of the drive. I will backup my normal USB flash stick I use in a minute and try that one. Just in case something odd with the other couple I tried. But was suspecting I had missed something.

Sounds like I have havent.

Edit: I may bring one of the sticks up on Sunday if I remember and try in another machine to see if stick or machine that isnt happy.
Last edited by Elminster on Fri Sep 20, 2019 8:31 pm, edited 1 time in total.

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Fri Sep 20, 2019 8:38 pm

Its the Flash stick. By some complete fluke the random stick I use in my gotek normally works, a couple of others dont. How odd. Fill look to see if they are formatted of partitioned any differently. Will try to dig up a few more sticks. I do actually need to buy a couple more.

The 'non working sticks' work fine on mac, linux and my rigol scope! Odd
Last edited by Elminster on Fri Sep 20, 2019 8:39 pm, edited 2 times in total.

User avatar
tricky
Posts: 3735
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: A new MENU system for MMC/Gotek

Post by tricky » Sat Sep 21, 2019 4:26 pm

That reminds me, I had the same problem with my first gotec, 8 out of 12 didn't work.

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Sat Sep 21, 2019 4:56 pm

Gotek must be more picky than others devices.

The ones that didn’t work were old, like 15 years old. Bought a new one to see if that works out of the box. I suspect it will.

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Sun Sep 22, 2019 7:32 am

Quick run through my usb sticks. All mine come from high street shops except a couple that came from companies I have worked for.

Both 16GB usb fails. One from pc world (10 years old), and one from Tesco (San disk, brand new).

All 3 usb in range 2 - 8 GB work.

Oldest 128 MB (15 years later old) does not work

Just have a 256MB left to test. I did have more but lost two, and two broke.

Then I will have a look at formats and partitioning to see if I can see why somework and sone don’t.

firthmj
Posts: 233
Joined: Tue May 26, 2009 8:37 am
Location: Ipswich, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by firthmj » Sun Sep 29, 2019 3:10 pm

Elminster wrote:
Sun Sep 22, 2019 7:32 am
Quick run through my usb sticks. All mine come from high street shops except a couple that came from companies I have worked for.

Both 16GB usb fails. One from pc world (10 years old), and one from Tesco (San disk, brand new).

All 3 usb in range 2 - 8 GB work.

Oldest 128 MB (15 years later old) does not work

Just have a 256MB left to test. I did have more but lost two, and two broke.

Then I will have a look at formats and partitioning to see if I can see why somework and sone don’t.
Just a thought: Is it possible that FlashFloppy only supports FAT32? The sticks smaller than 2G may well be FAT16, and it is possible the bigger ones have defaulted to exFAT.

M
Had fun at the
Image
Meeting 21st September 2019

User avatar
danielj
Posts: 7505
Joined: Thu Oct 02, 2008 4:51 pm
Location: Manchester
Contact:

Re: A new MENU system for MMC/Gotek

Post by danielj » Sun Sep 29, 2019 4:31 pm

I use 16GB sandisk sticks with flashfloppy and they work fine. It does FAT12,16,32 and exFAT:

https://github.com/keirf/FlashFloppy/bl ... fatfs/ff.c

User avatar
Elminster
Posts: 3919
Joined: Wed Jun 20, 2012 8:09 am
Location: Essex, UK
Contact:

Re: A new MENU system for MMC/Gotek

Post by Elminster » Sun Sep 29, 2019 7:16 pm

No idea why, but brand new out of the packet and didn’t work with gotek. Work fines on non gotek, and other usbs work fine. Not a huge issue as I can use ones that work.

Post Reply