Strange Upload Behavior

Lately, my Arduino has had some strange upload pattern that I noticed.

-If I open any file and try uploading it, it says "uploading" and never uploads. -If I have the cord unplugged, it still says "uploading" rather than giving me an error message -It is not on a specific sketch; it does this if I do a blank sketch -I can only get it to upload if I close all my Arduino programs and then open the Arduino shortcut on my desktop, which opens the previously closed sketch.

My main suspect is that I downloaded a library for the DS1307 internal clock, and now every time I upload any sketch, it says

WARNING: Spurious .github folder in 'RTClib' library

It started doing this around the same time I downloaded this, but I don't know if it is the cause or not. I don't have reason to suspect that it is something else, but how if that folder if it is the problem how do I fix it?

There's a common problem when using IDE V1.6.10 that will not allow an upload if you open your sketch by clicking on it's *.ino file. Is that the version you're using?

If so, the best fix is to simply go back to IDE V1.6.9. V1.6.10 has a number of problems, and it sounds like you're tripping over one of them. :( 1.6.9 is more stable.

My main suspect is that I downloaded a library for the DS1307 internal clock, and now every time I upload any sketch, it says WARNING: Spurious .github folder in 'RTClib' library

Possibly you have the"RTCLib" library incorrectly installed. And it's not an internal clock, it's an external clock, an RTC module, (Real Time Clock).

OldSteve: There's a common problem when using IDE V1.6.10 that will not allow an upload if you open your sketch by clicking on it's *.ino file. Is that the version you're using?

If so, the best fix is to simply go back to IDE V1.6.9. V1.6.10 has a number of problems, and it sounds like you're tripping over one of them. :( 1.6.9 is more stable.

I currently have 1.6.9. I was thinking maybe I need to update it, but that doesn't look like the answer

nunofyourbusiness: I currently have 1.6.9. I was thinking maybe I need to update it, but that doesn't look like the answer

I haven't heard of that happening with 1.6.9. Still, if I were you I'd avoid updating to V1.6.10. Heaps of people are having problems with that release. (I'm using V1.6.9, but haven't had any similar issues.)

Edit: I wouldn't think that the library issue and your other problem are related. It sounds like two different things to me.

The issue OldSteve mentioned is caused by the new version of avrdude included with Arduino AVR Boards 1.6.12 so I suspect it might happen with any IDE version after upgrading to Arduino AVR Boards 1.6.12., though I haven’t yet seen a single report of that issue happening with any IDE version other than 1.6.10. Please do this:

  • File > Preferences > Show verbose output during > upload(check)
  • After the uploading process hangs up select ALL the text in the black console window at the bottom of the Arduino IDE window. Copy the text and paste it in a message here using code tags(</> button on the toolbar).

nunofyourbusiness:
My main suspect is that I downloaded a library for the DS1307 internal clock, and now every time I upload any sketch, it says

WARNING: Spurious .github folder in ‘RTClib’ library

It started doing this around the same time I downloaded this, but I don’t know if it is the cause or not.

That’s only a warning and shouldn’t cause your issue.

nunofyourbusiness:
how do I fix it?

If you do want to fix it do this:

  • File > Examples > DS1307 > select any example for the DS1307 library
  • Sketch > Show Sketch Folder - this will open the example sketch folder inside of something like DS1307/examples
  • Move up two folder levels so that you are in the DS1307 folder(it might have a slightly different name).
  • Delete the folder named .github. This folder is not necessary, it’s only used for storing templates used to get more information from people when they post a bug report on the GitHub repository for that library.
Sketch uses 444 bytes (1%) of program storage space. Maximum is 32,256 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2,039 bytes for local variables. Maximum is 2,048 bytes.
C:\Users\tim\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino2/bin/avrdude -CC:\Users\tim\AppData\Local\Arduino15\packages\arduino\tools\avrdude\6.3.0-arduino2/etc/avrdude.conf -v -patmega328p -carduino -PCOM5 -b115200 -D -Uflash:w:C:\Users\tim\AppData\Local\Temp\build8e5b27126422fba7aa23b96eb53dc27f.tmp/sketch_aug10a.ino.hex:i

I just took the . out of the .github folder name and that fixed the warning message

I saw that behavior on a 1.6.9 IDE that was updated to 1.6.12 of boards.

I was unable to ascertain why the problem was occurring nor fix it - I wound up building there (it was installed on a non-main computer, because I knew that 1.6.12 boards was a disaster, but I needed the -flto option from the new compiler) and exporting the .hex, putting it on a USB drive, and moving it over to upload from my main system.

Glad you got that warning fixed, those are annoying to see all the time.

From the output you posted I can see you are using Arduino AVR Boards 1.6.12. This may cause the bug when you start the IDE by opening a sketch(.ino) file(by double clicking on it, etc.). You can test it by doing this:

  • Close all Arduino IDE windows
  • Start the Arduino IDE, not by opening a sketch file.
  • Open the sketch file via File > Open, File > Sketchbook, or File > Examples

If that's the cause of your problem you can go back to the previous Arduino AVR Boards version:

  • Tools > Board > Boards Manager
  • Wait for the downloads to complete
  • Click on Arduino AVR Boards
  • Select 1.6.11 from the drop down menu
  • Click "Install"
  • Once installation is complete click "Close"

Then you just need to avoid upgrading your Arduino AVR Boards version until 1.6.13 comes out which will have this problem fixed.

DrAzzy: I saw that behavior on a 1.6.9 IDE that was updated to 1.6.12 of boards.

I was unable to ascertain why the problem was occurring nor fix it - I wound up building there (it was installed on a non-main computer, because I knew that 1.6.12 boards was a disaster, but I needed the -flto option from the new compiler) and exporting the .hex, putting it on a USB drive, and moving it over to upload from my main system.

Good to know. I've suspected that but have been unable to reproduce the issue on my computer, even with 1.6.10 so I couldn't test it. I noticed you're experimenting with using LTO in ATTinyCore and I have some thoughts on how that can be done without breaking backwards compatibility if you ever decide you want to go production with it.

pert: If that's the cause of your problem you can go back to the previous Arduino AVR Boards version

I had 1.6.12 for my boards, and I went back to 1.6.11, and now the issue is resolved. Thanks for your help, pert, DrAzzy, and OldSteve. I will try avoiding going past 1.6.9 and boards 1.6.11 until issues are resolved.

pert:
Good to know. I’ve suspected that but have been unable to reproduce the issue on my computer, even with 1.6.10 so I couldn’t test it. I noticed you’re experimenting with using LTO in ATTinyCore and I have some thoughts on how that can be done without breaking backwards compatibility if you ever decide you want to go production with it.

Yeah, I definitely want to get lto working as soon as the Arduino guys have a stable release that can use it. I’m already using it internally - it got me over 1400 bytes of flash space on a project I’m doing for the 1634 that had less than 100 bytes of flash free (this is the project where I already removed all the pinMode() calls to save space). It’s insane how much space -flto saves, and on attiny chips, you need space everywhere you can get it.