Jump to content
IGNORED

Help me save variables in flash


atari2600land

Recommended Posts

I'm not sure why it doesn't work for you. I tried it just now, and it worked for me.

 

If you use the "Download and Play" option (that is, don't add it to the menu, but rather just play immediately), it will only save your flash image until you Download and Play a new game, or download a new menu layout.

 

If you add it to the menu layout and download to cart that way, LTO Flash will associate a save area with the menu entry. In fact, if you make multiple copies of the game in the menu, each copy will get its own save area. The size of the save area is determined by the jlpflash flag in the CFG file.

 

And, as nanochess said, use the BIN+CFG version. That combination is supported across the entire toolchain.

Link to comment
Share on other sites

I should add, I just tested it locally, and it "Works For Me."

 

Double check that your CFG file looks something like this:

[mapping]
$0000 - $0827 = $5000

[vars]
jlp = 1
jlpflash = 100

(The exact address range in the first part may be slightly different.)

 

If it looks different than that, upgrade to the latest IntyBASIC 1.2.9 and try again.

Edited by intvnut
Link to comment
Share on other sites

OK, everything works good now. I guess my link to jzINTV in one of the batch files I use to compile was going to an older version of jzINTV I had.

 

Keep a single copy, delete all other instances, and set the JZINTV_ROM_PATH environment variable. That way you always use the one.

Link to comment
Share on other sites

  • 9 months later...

I've got JLP Flash working in my current project too now, and I created a modified version of FLASH.BAS that uses all the available rows instead of the first one. Hopefully it helps to illustrate the difference between sectors and rows, and how the FLASH functions work. If anybody is having trouble working with JLP Flash, I can make it available.

  • Like 2
Link to comment
Share on other sites

  • 1 month later...

Here is the file I developed with modifications to flash.bas. It's designed mainly for illustration purposes. The code could be more robust, but it works.

 

It is designed to be compiled and run using IntyBASIC 1.4.0, which has you specify how many sectors you want. In this example, I use 3 sectors. You get 16 by default. Earlier versions gave you 100 sectors. I haven't tested this code with earlier versions.

 

The limitation of the original flash.bas is that it keeps erasing and rewriting the same row of data, leaving all the other rows untouched. Because EEPROM can only be rewritten so many times (at least 100,000 times guaranteed, which is probably more than will realistically be used), even with only one sector you can write to all 8 rows on a rotating basis. With 3 sectors, that gives us 24 rows, multiplying by that factor the number of rewrites in the life of an actual JLP-enhanced Intellivision cartridge.

 

The code itself probably leaves room for improvement, so feel free to tweak away and offer any suggestions.

flash2.bas

  • Like 2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...