sy2002 / MiSTer2MEGA65

Framework to simplify porting MiSTer (and other) cores to the MEGA65
GNU General Public License v3.0
34 stars 8 forks source link

Officially allow sharing OPTM_G group IDs for single select menu items #40

Open sy2002 opened 3 months ago

sy2002 commented 3 months ago

In the VIC20 config.vhd we find something like this:

   OPTM_G_SUBMENU,                                          -- RAM: %s
   OPTM_G_TEXT          + OPTM_G_HEADLINE,                  -- RAM expansions
   OPTM_G_LINE,                                             --
   OPTM_G_EXP_PORT      + OPTM_G_SINGLESEL,                 -- $0400 (3KB)
   OPTM_G_EXP_PORT      + OPTM_G_SINGLESEL,                 -- $2000 (8KB)
   OPTM_G_EXP_PORT      + OPTM_G_SINGLESEL,                 -- $4000 (8KB)
   OPTM_G_EXP_PORT      + OPTM_G_SINGLESEL,                 -- $6000 (8KB)
   OPTM_G_EXP_PORT      + OPTM_G_SINGLESEL,                 -- $A000 (8KB)
   OPTM_G_LINE,                                             --
   OPTM_G_CLOSE         + OPTM_G_SUBMENU,                   -- Back to main menu

This works fine. But it was never "meant to work" like this. Instead, when the OSM code was written, I always assumed that you would have one ID per OPTM_G_SINGLESEL item. Interestingly enough, this way of using the system still works like a charme. At least in the VIC20 use case. And there are cases, like in the VIC20 case, where this is pretty elegant.

This task is about two things:

1) Research in the OSM code (I guess a focus is on M2M/rom/menu.asm), if this way of using the system is robustly implemented. Check all use cases.

2) If the research in (1) unveils challenges, then fix them and enhance the M2M framework so that this use case is officially covered