Jump to content
IGNORED

Programming the Lynx for a living - blank carts


karri

Recommended Posts

  • 2 weeks later...

Karri should have blank carts for sale.

 

I'll have 5 of the new programmer boards completed shortly, just waiting for some standoffs to arrive from China. From this lot only 1 hasn't found a new owner yet, so it will be for sale at the same price as Karri's programmer board. I'll be updating the board design slightly and then ordering a larger batch for anyone interested. I might start a new thread to gauge interest later.

Link to comment
Share on other sites

Karri should have blank carts for sale.

 

I'll have 5 of the new programmer boards completed shortly, just waiting for some standoffs to arrive from China. From this lot only 1 hasn't found a new owner yet, so it will be for sale at the same price as Karri's programmer board. I'll be updating the board design slightly and then ordering a larger batch for anyone interested. I might start a new thread to gauge interest later.

 

I want them both - the programer and the carts! What should I do?

 

Also what will I need in order to use the programmer?

Link to comment
Share on other sites

 

I want them both - the programer and the carts! What should I do?

 

Also what will I need in order to use the programmer?

 

 

As Karri said, you need a Raspberry Pi. My version is a 'pi hat' which slots on top, Karri's version uses a ribbon cable. Software for reading/writing carts is here: https://bitbucket.org/atarilynx/lynx/src/cd1c78cf3a25b8e9cb22c930d6204fbe8c6bf3c6/contrib/blankcart/programmer/?at=master

 

I can't provide blank carts or shells.

 

Here's a comparison of the two programmer boards...

 

post-54616-0-04977300-1551819532_thumb.jpg

Link to comment
Share on other sites

Some flash chips require to flip the addresses back and forth in a way that is not possible on the Lynx.

 

void chipErase()
{
  setDataOutputs();
  writeAddrAndData(0x5555, 0xAA);
  writeAddrAndData(0x2AAA, 0x55);
  writeAddrAndData(0x5555, 0x80);
  writeAddrAndData(0x5555, 0xAA);
  writeAddrAndData(0x2AAA, 0x55);
  writeAddrAndData(0x5555, 0x10);
  delay(1000); // 100ms
}

How on earth do you do this on a Lynx?

 

int byteProgram(int addr, unsigned char data)
{
  writeAddrAndData(0x5555, 0xAA);
  writeAddrAndData(0x2AAA, 0x55);
  writeAddrAndData(0x5555, 0xA0);
  writeAddrAndData(addr, data);
  while (readByte(addr) != data) {
    delay20us();
    writeAddrAndData(0x5555, 0xAA);
    writeAddrAndData(0x2AAA, 0x55);
    writeAddrAndData(0x5555, 0xA0);
    writeAddrAndData(addr, (data & 0xf0) | 0x0f);
    delay20us();
    writeAddrAndData(0x5555, 0xAA);
    writeAddrAndData(0x2AAA, 0x55);
    writeAddrAndData(0x5555, 0xA0);
    writeAddrAndData(addr, (data & 0x0f) | 0xf0);
  }
  return 0;
}

If you wonder why I check the byte after programming and why I program it as two nybbles instead of as a byte there is a reason. Some of the flash chips just never work be programming the chip a byte at a time. But because of some reason that I don't know the chips always work with this algorithm.

 

I could of course try to jump the address space by doing lots of dummy reads. If the chip only looks at writes to enter the programming mode then this might work on a Lynx. But I doubt it.

Edited by karri
Link to comment
Share on other sites

We used to program the old flash card with an similar algorithm:

checkFlash:
	jsr set5555
	lda #$AA
	sta $fcb3

	jsr set2aaa
	lda #$55
	sta $fcb3

	jsr set5555
	lda #$90
	sta $fcb3

        ldy #250
	ldx #0
.4	dex
	bne .4
	dey
	bne .4

	lda #0
	jsr SelectBlock

	lda $fcb2
	pha
	lda $fcb2
	jsr PrintHex
	pla
	jsr PrintHex
	rts

set2aaa::
	lda #10
	jsr SelectBlock

	ldx #0
	ldy #2
.0	lda $fcb2
	  dex
	bne .0
	dey
	bne .0

	ldx #170
.1	lda $fcb2
	  dex
	bne .1
	rts

set5555::
	lda #21
	jsr SelectBlock

	ldx #0
.0	lda $fcb2
	  dex
	bne .0

	ldx #85
.1	lda $fcb2
	  dex
	bne .1
        rts


But I agree, it will take a lot of time to select the different addresses.

Does this Flash have no programming mode, where every byte written is directly programmed. The old Intel Strata flashes had this.

As for the nibble writing, it might be a power problem. IIRC these flash have to generate the 12V internally.

Link to comment
Share on other sites

  • 2 weeks later...

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...