Jump to content
IGNORED

Atari Lynx Programmer Pi Hat Orders


Igor

Recommended Posts

That's a long time! Turbo mode is quite safe to use, I think I will actually make it the default soon. Haven't had much time to add more features to the software.

Link to comment
Share on other sites

I just got my first ever Raspberry Pi Zero W. At the risk of exposing my total newbness, now what do I do? Does the Rasp Pi come with anything installed? If I need to install something on it, what do I install? I saw a little bit of information on https://atarigamer.com/pages/lynx-cart-programmer-pi-hat, but I'm really looking for a step-by-step guide. Thanks!

Link to comment
Share on other sites

56 minutes ago, Songbird said:

I just got my first ever Raspberry Pi Zero W. At the risk of exposing my total newbness, now what do I do? Does the Rasp Pi come with anything installed? If I need to install something on it, what do I install? I saw a little bit of information on https://atarigamer.com/pages/lynx-cart-programmer-pi-hat, but I'm really looking for a step-by-step guide. Thanks!

Does the rpi0 come with an sd card with Raspian preinstalled?

 

If yes, you have a full linux environment and have only to download and build some packages as described in the article you linked.

 

If not, buy a micro sd card and install on it Raspbian using one of the tutorial you can find online.

If you need more support PM me.

 

Edited by Nop90
Link to comment
Share on other sites

Well, that was painful. But maybe partly self-inflicted. ;)

 

I bought the Zero because I wanted WiFi and the ability to VNC into the desktop, instead of hooking up a separate monitor/mouse/keyboard. So I had to figure out which version of Raspian I wanted to install, which was non-obvious. I went with the full distribution but not the one with extra apps installed. It fit fine on my 4GB SD card, even though they recommended 8GB minimum.

 

I followed some tutorials to change the config to support SSH and WiFi on boot, but that took a number of tries and there were non-obvious steps, like the fact that the "ssh" file gets deleted after the first time it is detected, but then you don't need it. So I kept putting the ssh file back on the SD card because I didn't know that. Then my Win 7 PC would not recognize a RNDIS device, so I had to search for a driver that would support that. Finally, I could get Putty to recognize the Zero, but didn't know what the password was! Had to search for that, too. Then I had to enable the VNC server, because of course it's there but not activated by default. Got that working, figured out the IP address using the ifconfig command for wlan0, manually connected in the VNC client, then I got a "Cannot display desktop" message from VNC. Found out you need to change the default resolution if you don't have a physical monitor hooked up.

 

Three hours into it, I finally have the remote desktop displaying on VNC and I was able to download and install the Lynx tools. Maybe later I can actually connect a cartridge and try something. :)

 

I mention all this just to warn people this may not be a trivial process, especially if you've never used a Raspberry Pi before (like me). I looked for simple "follow these steps to get your Pi Zero working" online tutorials, but instead I found pieces here and there and had to figure out the missing pieces myself.

 

Onto the fun part!

Link to comment
Share on other sites

VNC setup can be frustrating. I prefer to connect an usb keyboard and my 32'' tv with an HDMI cable, login and voilla.

 

I use Sftp to tranfer files on the RPI0 only because my Win10 PC has write lock on external storages (Company security policy) otherwise I would use a micro sd to usb adapter.

 

 

Link to comment
Share on other sites

During the last week I burned a lot of carts with the -turbo mode and it's reliable. I'm going to use the slow mode only for final carts I want to give to friends.

 

But often I use the programmer for test programs of few kB and it's tedious to wait that all 256 blocks are written with dummy data.

 

Is it possible to add a -trim function that stops writing when the important data is written?

Link to comment
Share on other sites

2 hours ago, karri said:

In my original sw I always cut burning after the payload is written.

In   my SRAM card writer I build a CRC for every block and only write it when it was different from the one to be programmed.  But a Flash is certainly different to handle. I guess the blocksizes are different.

Link to comment
Share on other sites

13 minutes ago, 42bs said:

In   my SRAM card writer I build a CRC for every block and only write it when it was different from the one to be programmed.  But a Flash is certainly different to handle. I guess the blocksizes are different.

Yep. The flash is completely erased to '1' bits at start of the programming session. Then you can burn bits to zero until you reach the end of the file. You do not have to care about bits not read during gameplay. So if you burn a commercial cart that checks every bit you need to burn it all. If your game is only 1k - just burn 1k.

 

There is some kind of block erase available. My code does not use it. It uses erase chip instead. And burns a byte at a time.

Link to comment
Share on other sites

39 minutes ago, karri said:

Yep. The flash is completely erased to '1' bits at start of the programming session. Then you can burn bits to zero until you reach the end of the file. You do not have to care about bits not read during gameplay. So if you burn a commercial cart that checks every bit you need to burn it all. If your game is only 1k - just burn 1k.

 

There is some kind of block erase available. My code does not use it. It uses erase chip instead. And burns a byte at a time.

Why not use block erase? Sure for a complete write, chip erase is likely quicker, but during development one could store persistent data at the end and only change the program. Means, only erasing the modified blocks.

Link to comment
Share on other sites

Apologies for the long time to respond. I've been meaning to do a "For Dummies" article on how to set it all up. With wedding preparations my time has been very limited however. I will probably get around to writing one after a month's time. Also I want to check out how long each of the modes takes on different hardware, I have a Raspbery Pi Zero, 2b and 3b+ here so that will be a good starting base. I might get the model 4 at some point too.

 

Regarding software, the logic in my version hasn't changed vs what Karri's version has, so if he is trimming in his, so am I.

 

Not a bad idea on the block erase approach.

Link to comment
Share on other sites

There is a logical problem with block erase. The blocks used by the Lynx are very different from the blocks used by the chip. It is certainly doable and it will cut down on the programming time. But I don't really feel like twisting my head into this problem. So far my code was a feasibility study and necrocia has tuned it into an usable program.

  • Like 1
Link to comment
Share on other sites

Guess who just received a Pi4 with 4G RAM...?

Goodbye PiZero speeds for programming, compiling and emulating.

Eat your hearts out guys.

 

With this much power OnDuty could be ready for release later today.

 

  • Like 3
  • Haha 1
Link to comment
Share on other sites

On 6/30/2019 at 6:17 PM, karri said:

In my original sw I always cut burning after the payload is written.

Checking the code on your repository the write loop always writes 256 blocks

 

      while (blocknr < 256) {
        printf("Block %d\n", addr/2048);
        fread(block, blocksize, 1, fp);
        for (i = 0; i < 2048; i++) {
          if (i < blocksize) {
            if (byteProgram(addr, block[i])) {
              return 1;
            }
          }
          addr++;
        }
        blocknr++;
      }

To stop writing after the end of the input file, the line with the while instruction could be modified in:

 

      while (blocknr < 256 && !feof(fp)) {

 

 

 

 

 

Edited by Nop90
  • Like 1
Link to comment
Share on other sites

Hey thanks Nop90, I'll add that as an argument that can be passed in.

Karri - Pi4, nice! I'd like to see some timing information for programming a cart...

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

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