Jump to content
IGNORED

SDrive-MAX Question


MacRorie

Recommended Posts

i found a hex that reset my uno (optiboot_atmega328)

 

used that

here's what happens.

 

 

 SDrive-Max programmer

    Please enter the COM port number of the Arduino Uno (only numbers)
         Press enter for help


COM:3


                     Was chosen COM3

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "eeprom_writer.hex"
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: writing flash (3484 bytes):

Writing | ################################################## | 100% 0.77s

avrdude: 3484 bytes of flash written
avrdude: verifying flash memory against eeprom_writer.hex:
avrdude: load data flash data from input file eeprom_writer.hex:
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: input file eeprom_writer.hex contains 3484 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.60s

avrdude: verifying ...
avrdude: 3484 bytes of flash verified

avrdude: safemode: Fuses OK (E:00, H:00, L:00)

avrdude done.  Thank you.

             Remove the USB from the PC and plug it in again
                   RESET at the UNO is not enough!!!!!!
             wait until the COM is active on the PC again
                     then press the button


Press any key to continue . . .

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "SDrive.hex"
avrdude: input file SDrive.hex auto detected as Intel Hex
avrdude: writing flash (30928 bytes):

Writing | ##############################################     | 92% 5.10savrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding




getting closer

Link to comment
Share on other sites

5 minutes ago, gooner4life7 said:

i found a hex that reset my uno (optiboot_atmega328)

 

Have you tried one of the hex files included in the BigBen zip file that is TFT Screen specific?

 

Take that file out of the folder it is in and place in main folder with the bat file. See if that might work.

 

For example: I use the ILI934 TFT, so I used the eeprom_writer.hex and SDrive.hex files from the atmega328-ili9341 folder and copy them into the main SDrive-english folder I created when I unzipped the files. I then double click SDrive.bat.

  • Thanks 1
Link to comment
Share on other sites

9 minutes ago, NISMOPC said:

You should think about adding BigBen's zip file to your link. It's pretty easy to Windows use self executing bat.

I think I'll just stick to the XLoader way of doing it. It's more user friendly for people who have never flashed an Arduino before. 

  • Like 1
Link to comment
Share on other sites

5 hours ago, gooner4life7 said:

i found a hex that reset my uno (optiboot_atmega328)

 

used that

here's what happens.

 

 

 SDrive-Max programmer

    Please enter the COM port number of the Arduino Uno (only numbers)
         Press enter for help

 

.

.

.

avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding


getting closer

When I first started making them, I tried doing it via the ISCP since that is how I flash most of the others things.  Your experience mirrored mine.  I was able to rescue them by getting the original boot loader program and flashing that (as has been mentioned in this thread).  However, I think I also had to force a -D in the command line in order for it to work.  This is a hazy memory.  I had a few moments and was trying to rescue some members of my "fix me" pile, but could not recall the specifics.  If I get some time, I will try it again and document it step by step.

 

If you reach the point of "oh, I am *SO* done with this thing," send me the not working board and I will send you a flashed one that works.  I will put yours in the "fix me" bin and get to it soon enough.  

 

Good luck!

 

-M

  • Like 4
  • Thanks 1
Link to comment
Share on other sites

11 hours ago, MacRorie said:

When I first started making them, I tried doing it via the ISCP since that is how I flash most of the others things.  Your experience mirrored mine.  I was able to rescue them by getting the original boot loader program and flashing that (as has been mentioned in this thread).  However, I think I also had to force a -D in the command line in order for it to work.  This is a hazy memory.  I had a few moments and was trying to rescue some members of my "fix me" pile, but could not recall the specifics.  If I get some time, I will try it again and document it step by step.

 

If you reach the point of "oh, I am *SO* done with this thing," send me the not working board and I will send you a flashed one that works.  I will put yours in the "fix me" bin and get to it soon enough.  

 

Good luck!

 

-M

Right think i have sorted it (i hope)

i noticed it flashed the eeprom hex fine so i dumped it with my ISCP then i re flashed it again with my ISCP this time i flashed the Sdrive.hex from atmega328-ili9341 and then used the eeprom i dumped.
 

it now boots and shows Ready instead of sdrive.atr not found.

 

i will keep you updated if any thing changes.


 

  • Like 2
Link to comment
Share on other sites

  • 4 months later...
On 11/1/2018 at 9:17 AM, MacRorie said:

Sooo, apparently there is a LOT of difference when you flash via USB and via the ISCP. IN fact, the difference is so substantial that the new boot loader prevents you form re-flashing it via USB!

 

The only reason I was able to figure it put was I used a USB set up on a brand new, out of the package UNO. It flashed right away and loaded sdrive.atr without any complaint. So, I knew it was not the uSD card nor was it the UNO itself. So, I thought, maybe it was the hex files I was using. Nope, tried some fresh from a known good source and they failed as well via the ISCP.

 

So, I tried another blank via USB. No problem. Tried to erase the chip on an "old" one via USB. Nope. avrdude errored out trying to start. I eventually had to dig up the factory bootloader+an EEPROM blanker, compile it to hex, and then burn THAT via ISCP and then flash the SDrive stuff via USB.

 

Managed to get all of them working//seeing sdrive.atr.

 

tl;dr: DO NOT flash via the ISCP port. If you do, I have a file for you ?

Hi @MacRorie,

 

   I think I have a problem Arduino, I have flashed it via USB, but think I either flashed sdrive.atr too soon after the firmware, or something else has gone wrong, but it is just white screening now. Is there any chance you can upload the factory bootloader+EEPROM blanker - I have a friend who has the ICSP programming kit, and want to try resetting it, then reprogramming via USB. I've been trying to make a perf board as described on Mr. Robots page (link to the original mod by Bernd), but haven't had any luck though hopefully due to bad firmware, not bad hardware.

 

   TIA (hopefully)!

 

   

Link to comment
Share on other sites

1 hour ago, E474 said:

Hi @MacRorie,

 

   I think I have a problem Arduino, I have flashed it via USB, but think I either flashed sdrive.atr too soon after the firmware, or something else has gone wrong, but it is just white screening now. Is there any chance you can upload the factory bootloader+EEPROM blanker - I have a friend who has the ICSP programming kit, and want to try resetting it, then reprogramming via USB. I've been trying to make a perf board as described on Mr. Robots page (link to the original mod by Bernd), but haven't had any luck though hopefully due to bad firmware, not bad hardware.

 

   TIA (hopefully)!

 

   

When you say "flashed S-Drive.atr" what do you mean?

 

When you flash via the ICSP port, it does not set up the chip correctly and you need to take it to its factory defaults.  I have the file here somewhere.

Link to comment
Share on other sites

Hi MacRorie,

 

   Sorry, I meant SDrive.hex, not S-Drive.atr. The SDrive-Max that I am trying to build is shown in this post: 

 

 

but I have been having some problems with it. My first attempt at flashing it worked for eeprom_writer.hex, but gave an error for the second file, SDrive.hex. I saved the output of programming it (with the latest 1.1 firmware):

 

~/tmp/sdm/atmega328-ili9341$ ls
eeprom_writer.hex  SDrive.hex
~/tmp/sdm/atmega328-ili9341$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:eeprom_writer.hex 

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "eeprom_writer.hex"
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: writing flash (3484 bytes):

Writing | ################################################## | 100% 0.71s

avrdude: 3484 bytes of flash written
avrdude: verifying flash memory against eeprom_writer.hex:
avrdude: load data flash data from input file eeprom_writer.hex:
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: input file eeprom_writer.hex contains 3484 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.46s

avrdude: verifying ...
avrdude: 3484 bytes of flash verified

avrdude: safemode: Fuses OK (E:00, H:00, L:00)

avrdude done.  Thank you.

~/tmp/sdm/atmega328-ili9341$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:SDrive.hex 

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "SDrive.hex"
avrdude: input file SDrive.hex auto detected as Intel Hex
avrdude: writing flash (30928 bytes):

Writing | ################################################## | 100% 6.14s

avrdude: 30928 bytes of flash written
avrdude: verifying flash memory against SDrive.hex:
avrdude: load data flash data from input file SDrive.hex:
avrdude: input file SDrive.hex auto detected as Intel Hex
avrdude: input file SDrive.hex contains 30928 bytes
avrdude: reading on-chip flash data:

Reading |                                                    | 0% 0.00savrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avr_read(): error reading address 0x0000
    read operation not supported for memory "flash"
avrdude: failed to read all of flash memory, rc=-2

avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: safemode: Sorry, reading back fuses was unreliable. I have given up and exited programming mode
avrdude: stk500_recv(): programmer is not responding

avrdude done.  Thank you.

~/tmp/sdm/atmega328-ili9341$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:eeprom_writer.hex 
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
 

 

When I powered up the SDrive-Max using a USB connector it worked fine, at least the touchscreen display showed the normal D1 - D4 display, and the Ready prompt, etc. After that I put together the perfboard circuit for the SIO fixup, but then when I powered the SDrive Max from the Atari (not using the USB connector), I just got a white screen. When I disconnected the SIO power line, and used USB power, I got the SDrive touchscreen, but it would not serve ATRs to the Atari (with the remaining SIO pins connected). I figured I had messed up the perfboard upgrade, so I made another one using a different 7407 chip, but this one also gave me a white screen.

 

At this point I thought it was better to verify the SDrive Max would serve ATRs without the perfboard add-on, but when I removed the perfboard, and just did an original wire up of the Arduino, I also got a white screen when I connected it to the Atari. I also got a white screen when I removed the SIO power line pin, and powered it from USB. 

 

When I tried to update the Arduino, I got the following output when trying to program it via USB:

 

~/tmp/sdm/atmega328-ili9341$ ls
eeprom_writer.hex  SDrive.hex
~/tmp/sdm/atmega328-ili9341$ ls -l /dev/ttyUSB0 
crw-rw---- 1 root dialout 188, 0 Nov 21 18:39 /dev/ttyUSB0
~/tmp/sdm/atmega328-ili9341$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:eeprom_writer.hex
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 1 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 2 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 3 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 4 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 5 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 6 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 7 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 8 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 9 of 10: not in sync: resp=0x00
avrdude: stk500_recv(): programmer is not responding
avrdude: stk500_getsync() attempt 10 of 10: not in sync: resp=0x00

avrdude done.  Thank you.

~/tmp/sdm/atmega328-ili9341$ 

 

All the programming has been done via USB, not ICSP, my understanding is that the Arduino can be reset by uploading a new firmware, and then reprogrammed, but the new firmware has to be uploaded via ICSP. This is the file I am hoping you can dig out.

 

I think the Arduino should be good, I built another SDrive-Max last year and the one I am working on now used the same make/manufacturer (I ordered 2 Arduinos at the time), I actually built the first one before BigBen figured out the fix, but I thought I would leave that one alone, as it works, and I was not sure I could upgrade my original without breaking it. On the other hand, the working SDrive-Max is still on the 0.9 firmware, so it is not exactly the same, but I don't think the problem comes from the version of the SDrive-Max firmware.

 

Any help would be appreciated!

Link to comment
Share on other sites

On 11/21/2019 at 11:30 AM, E474 said:

Hi MacRorie,

 

   Sorry, I meant SDrive.hex, not S-Drive.atr. The SDrive-Max that I am trying to build is shown in this post: 

 

 

Any help would be appreciated!

 

Sorry for the delay.  At first I couldn't find it and then had an epiphany as I was writing an email explaining that I couldn't find it!

 

There are two files, one blanks the eeprom, the other blanks it and puts the original bootloader back on the arduino.

 

Use at your own risk, not responsible for quantum time fluctuations, bricking of arduinos, I am not a lawyer and I do not play one on television, etc etc etc

 

 

eeprom_clear.ino.standard.hex eeprom_clear.ino.with_bootloader.standard.hex

  • Like 1
Link to comment
Share on other sites

  • 1 month later...

Hi @MacRorie,

 

    These files reset the Arduino correctly, but I had made a mistake soldering the SIO wires to the Arduino, but once this was fixed, the SDrive Max worked correctly. On Linux (Ubuntu), I reset the Arduino with:

 

$ sudo avrdude -c usbasp -pm328p -P usb -U flash:w:eeprom_clear.ino.with_bootloader.standard.hex 

avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: reading input file "eeprom_clear.ino.with_bootloader.standard.hex"
avrdude: input file eeprom_clear.ino.with_bootloader.standard.hex auto detected as Intel Hex
avrdude: writing flash (32768 bytes):

Writing | ################################################## | 100% 0.53s

avrdude: 32768 bytes of flash written
avrdude: verifying flash memory against eeprom_clear.ino.with_bootloader.standard.hex:
avrdude: load data flash data from input file eeprom_clear.ino.with_bootloader.standard.hex:
avrdude: input file eeprom_clear.ino.with_bootloader.standard.hex auto detected as Intel Hex
avrdude: input file eeprom_clear.ino.with_bootloader.standard.hex contains 32768 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.46s

avrdude: verifying ...
avrdude: 32768 bytes of flash verified

avrdude: safemode: Fuses OK (E:FD, H:DA, L:FF)

avrdude done.  Thank you.

And then reprogrammed the Arduino with:

$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:eeprom_writer.hex

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "eeprom_writer.hex"
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: writing flash (3534 bytes):

Writing | ################################################## | 100% 0.59s

avrdude: 3534 bytes of flash written
avrdude: verifying flash memory against eeprom_writer.hex:
avrdude: load data flash data from input file eeprom_writer.hex:
avrdude: input file eeprom_writer.hex auto detected as Intel Hex
avrdude: input file eeprom_writer.hex contains 3534 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.46s

avrdude: verifying ...
avrdude: 3534 bytes of flash verified

avrdude: safemode: Fuses OK (E:00, H:00, L:00)

avrdude done.  Thank you.

and finally:

$ sudo avrdude -carduino -pm328p -P /dev/ttyUSB0 -U flash:w:SDrive.hex

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: NOTE: "flash" memory has been specified, an erase cycle will be performed
         To disable this feature, specify the -D option.
avrdude: erasing chip
avrdude: reading input file "SDrive.hex"
avrdude: input file SDrive.hex auto detected as Intel Hex
avrdude: writing flash (30182 bytes):

Writing | ################################################## | 100% 5.02s

avrdude: 30182 bytes of flash written
avrdude: verifying flash memory against SDrive.hex:
avrdude: load data flash data from input file SDrive.hex:
avrdude: input file SDrive.hex auto detected as Intel Hex
avrdude: input file SDrive.hex contains 30182 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 3.89s

avrdude: verifying ...
avrdude: 30182 bytes of flash verified

avrdude: safemode: Fuses OK (E:00, H:00, L:00)

avrdude done.  Thank you.

 

I would have posted this info earlier, but only figured out the soldering error recently, and couldn't be sure the Arduino had been fixed until I could test it working as an SDrive Max (which it now does). Incidentally, it seems to be running fine on an 800XL +5V SIO power supply (not USB). I haven't got the perfboard mod up and running yet for fixing SIO drive contention, that's the next step, now that I am sure it works as is.

 

Thanks again!

 

 

  • Like 1
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...