Welcome! Log In Create A New Profile

Advanced

Gen7 - Impossible to upload firmware

Posted by Tibow 
Gen7 - Impossible to upload firmware
May 19, 2013 11:57AM
Hi !

I've started building a RepRap Prusa Mendel, and i'm using Gen7 for the electronic...

My trouble is that I can't upload a firmware to the Gen7... The upload takes a long time and in about 10 minutes there are a couple of error (e.g. Time out).
[puu.sh]

I read that it could be an autoreset problem, but even though I reset manually just before the upload, I have the same problem...

And I tried with Teacup, Marlin, and Repetier...

Anyone as an idea ?

Thanks (and sorry for my english, I'm french )
Re: Gen7 - Impossible to upload firmware
May 20, 2013 12:23AM
Hi Tibow

I'am having the same problem.
I used a atmega1284 and uploaded the bootloader via AVRISP programmer.
I used the "bootloader-1284P-16MHz.hex"bootloader file from "Gen7 Arduino IDE Support" pack as bootloader.
I am trying to upload the repetier firmware.

Are you using the MCP2200 chip on your Gen7 board?
What chip did you use 644 or 1284?
Did you upload the firmware or was it preloaded?
If you loaded the bootloader what file and from where did you use?
What firmware are you trying to upload?

Sorry for asking stupid questions. I am also trying to find the answer to this problem.
Re: Gen7 - Impossible to upload firmware
May 20, 2013 05:15AM
Hi twistedrerap !

My chip is a 644 - 20MHz...
The first time I power up the electronic, I upload the test firmware : [raw.github.com]
And it worked well ! Then I tried to upload Teacup firmware, impossible... Marlin, impossible...Even the test firmware, I can no longer upload it...

And didn't try to upload any bootloader.
Re: Gen7 - Impossible to upload firmware
May 20, 2013 06:28AM
Are you perhaps using Windows 64-bit? There were a few similar feedback reports and as far as I can see it, Windows simply refused to talk to the MCP2200 after the first attempt. Changing the host OS usually fixed that. Unsure what the real cause is, people usually stop to investigate once it works for them.

Other than that ... "timeout" means, there's no communications happening at all. Also, turning off the power supply entirely (yellow LED off) causes the MCP2200 to reset, which might help picking up communications again. Sometimes USB simply messes up and disconnection its cable for a few seconds helps. On older Windows', setting the COM port number manually helped.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
May 20, 2013 12:11PM
Thanks Traumflug !

Yes, I used a PC with Windows 7 - 64 bits...
So I've tried with another PC with Windows Vista - 32 bits : and it works ! I can upload the test firmware, without reset manually the gen7 !
And I can also upload marlin firmware !

But with vista, I've another problem : I can't run repetier-host software... when I run it, it crashs : "Repetier-Host stop working"


A problem always hides another one...
Re: Gen7 - Impossible to upload firmware
May 21, 2013 05:11AM
Glad to see it working, @Tibow.

In case you're brave, you might want to try with updating the driver. It can be found here in the "Documentation and Software" section: [www.microchip.com]

Another reference: [code.google.com]


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
May 21, 2013 07:26AM
good day

I'am trying to run it from Windows7 home premium 64 bit.
currently trying to upload from win XP but getting all kinds of funny errors from Arduino IDE think its an windows problem the laptop was stored for +/- 5 years.

any pointers or pit falls I need to watch out for in WinXP?
Re: Gen7 - Impossible to upload firmware
May 22, 2013 07:30AM
Quote

any pointers or pit falls I need to watch out for in WinXP?

Tell us if you find some!


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
June 07, 2013 02:42AM
Hi all,

I want to share my experience in uploading the Teacup firmware into Gen7 1.4.1. Somehow I could not burn the boot loader. Then try directly to burn the firmware using Arduino-as-ISP.
Many tries just gave me mismatch error or programmer timeout. I tried both using Arduino GUI and command line.

After several hours trying, I finally managed to upload the firmware. This time that make different is that: instead of using standby 5v power from PSU, I attach ICSP Vcc pin to Arduino 5v and respectively the ground and it was done via the GUI: Upload Using Programmer. I am using Arduino 1.0.5 and Gen7 IDE Support v2.1
Re: Gen7 - Impossible to upload firmware
June 09, 2013 09:46PM
thanks for the info this might be what is causing my problems, Maybe there is something about the 1.4.1 board that is firmware unfriendly when using the psu I'll give it a go
terramir
Re: Gen7 - Impossible to upload firmware
June 10, 2013 02:30AM
I can also burn the bootloader via the Arduino GUI: Tools -> Burn Bootloader. Now its easier to upload the firmware, no need the programmer.
Re: Gen7 - Impossible to upload firmware
June 16, 2013 05:23AM
Hi all

I eventually found the reason why I was unable to upload the firmware.

I was using an 1284PU chip NOT the 1284P-PU as all the tutorials assume you are using. I out of frustration with not being able to upload the firmware I bought a AVRISP Mk II programmer.

using the programmer it is much easier to upload the firmware and somewhere in the process I figured out that the "fuse" for the 1284pu differ form the fuse for the 1284p-pu.

Once I corrected the problem all is well.

hope this will help
Re: Gen7 - Impossible to upload firmware
June 17, 2013 07:22AM
Quote

using the programmer it is much easier to upload the firmware and somewhere in the process I figured out that the "fuse" for the 1284pu differ form the fuse for the 1284p-pu.

Could you elaborate a bit on this, please? So far I considered 1284 and 1284P to be identical, except for signature and power consumption. Accordingly, I'd expect them to require the same fuse settings.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
July 04, 2013 03:13PM
I'm using windows 7 32bit with the latest arduino and the gen7 arduino ide support package 2.1 and am trying to upload the test firmware on my 1.5 board. I have the MCP2200 driver installed and the correct com port selected in the arduino software with the board set to gen7 1284p 20Mhz. Every time I try, the firmware compiles and then it sits forever on the upload screen and never finishes. I have tried changing the baud rate settings on the port from 9600 to 115200 with no change in outcome. Any suggestions?
Re: Gen7 - Impossible to upload firmware
July 04, 2013 04:31PM
Did you select the right board in Arduino IDE ?
The tx/rx led try to light on?
Re: Gen7 - Impossible to upload firmware
July 04, 2013 07:38PM
I have the board selected in the arduino software. I tried reinstalling the bootloader as per the wiki using my usbtiny. Everything went according to the wiki, but I still can't flash any firmware. I keep getting timeouts after about 10 min.
Re: Gen7 - Impossible to upload firmware
July 05, 2013 05:47AM
Quote

I tried reinstalling the bootloader as per the wiki using my usbtiny.

This was your mistake. An USBtiny can't program chips with more than 64k Flash.

You can use the USBtiny to upload firmwares with up to 64k, though, even on bigger chips. The same way you upload bootloaders.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
July 05, 2013 06:47AM
The boot loader reload came as my last attempt. All of the problems mentioned earlier were already happening so I can't blame it on the usb tiny.
Re: Gen7 - Impossible to upload firmware
July 05, 2013 07:51AM
Also, I successfully installed the test firmware via the usbtiny. Interestingly, when I use the power supply as option 1 in the wiki, the test firmware does not start the power supply and the LED does not blink. If I instead hook up the power supply as option 2, the LED blinks as per the test firmware description.

I can't figure out why this is happening. I read 5 V at the powersupply green wire pin on the gen7 board, and if I connect it to ground it starts. All of the pins on the atmega socket read the appropriate voltages. What am I missing?
Re: Gen7 - Impossible to upload firmware
July 06, 2013 07:11AM
Check pin 21 of the ATmega (that's the one in the upper right corner) and it's trace to the ATX20/24 connector. Turning on the PSU happens through this pin. 5V while the PSU is turned off, 0V for turning it on.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Hi,
I am in the process of building a gen 7 ver 1.5 board. I bought the ATmega1284 by mistake instead of the "P" version. I was getting fails due to the wrong signatire being read. I checked the avrdude.conf file and found that the Atmega644 entries are exactly the same as the 644P except for the device signature. So I changed the signature of the 1284P to the signature of the 1284 and was able to get the bootloader burned on the 1284 device. I burned the bootloader through Arduino software using the arduino uno as an ISP and selecting bootloader-1284P-20MHz.hex from the arduino drop down menu.

After installing the 1284 ic in the gen 7 board I tried to load the sprinter firmware through the usb and MCP2200. I am getting time out errors. I have some questions re. the MCP2200. I did enter the configuration utility and as suggested on the gen 7 repraps webpage -> [reprap.org] and only checked the Enable Tx/Rx LEDs box. After clicking on the configure button the output message ended with the line "Device verified".

While the sprinter files are being sent to the board I can with a scope data on the the D+/D- lines. The Tx and Rx Leds on Pin 5 and 6 of the MCP2200 are blinking but there seems to be no data on either tx - pin10 or rx - pin12 of the 2200.
Questions:
1) Do the flashing leds on pin 10 and 12 indicate that the 2200 is seeing data on the D+/- lines from usb or that data is being sent/received to/from pins 10/12 of the 2200?.

2) Does the boot loader process set up a baud rate for the ATmega 1284? The baud rate in the 2200 configuration utility is set to 19200. How do I know what the baudrate for the 1284 is during the serial transmission of loading sprinter???

Any help gratefully appreciated.
Thanks,
Pat
Re: Gen7 - Impossible to upload firmware
August 06, 2013 06:06AM
Quote

Does the boot loader process set up a baud rate for the ATmega 1284?

That's hardcoded in the bootloader. Default is 115200 baud.

Quote

The baud rate in the 2200 configuration utility is set to 19200.

That's just a default value and changed by the host OS as soon as you connect with a different baud rate.

In case everything fails, start with uploading the firmware without bootloader, using your Arduino Uno. Simply exercising software like SetupTest.ino might give more insight, as this acts on its own instead of waiting for commands.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
I'm having a similar problem to Parto but I have a atmega1284P running at 20 MHz. I configured the MCP2200 with the utility to enable the Tx/Rx LEDs and then I burned the bootloader successfully. When trying to upload SetupTest.ino sketch it just times out. So I decided to try and upload using my programmer (Arduino Uno) and the same ICSP I used to burn the bootloader. The Arduino IDE said it uploaded successfully this way but the only thing that seems to be working is the PSU kicks on and the bottom right green led lights up and then a few seconds later it turns off again.

any ideas of whats going on?
Re: Gen7 - Impossible to upload firmware
August 10, 2013 07:14AM
Quote

the only thing that seems to be working is the PSU kicks on and the bottom right green led lights up and then a few seconds later it turns off again.

That's what SetupTest does. It also sends some text over the serial line which you should be able to read with Arduinos' serial monitor.

If you want to make a printer controller from your Gen7 you have to upload a controlling firmware, like Teacup, Repetier, Marlin, ...


Generation 7 Electronics Teacup Firmware RepRap DIY
     
I guess I should have been more specific with my problem. I can upload without any problem using the ICSP. In fact thats how I uploaded my firmware (Teacup) but then when I connect the usb to the mcp2200 and open up Printrun to connect It just makes the Tx led blink every few seconds. I can't upload any firmware or even the test sketch using the mcp2200 either. i've already changed the 10uF inductor to just a jumper wire because Mouser sent me a 20uF instead but that wasn't the problem. So i'm not really sure where to go from here, any help would be great.

Thanks!
Re: Gen7 - Impossible to upload firmware
August 13, 2013 06:47AM
Once you upload a firmware via a programming device, the bootloader is gone and has to be re-uploaded if needed.

Is it possible you forgot these two wire bridges above the MCP2200? Happened to two people already.




Generation 7 Electronics Teacup Firmware RepRap DIY
     

Attachments:
open | download - Gen7 v1.5 Reset Line.jpeg (41.7 KB)
well you just taught me something new haha. I thought once you uploaded the boot loader and locked it, it would stay on there until you erased the entire memory.

I soldered both wires, with the board on stand-by, I measured and got 5V going across both wires.

The MCP2200 was running at 20 MHz for a little while until I noticed I had accidentally mixed up the two crystals. I switched them, swapped out the micro-processor, but perhaps I messed up the MCP2200 and I need to replace it now?

I'm running out of ideas on how to fix this haha.
So I went ahead and replaced the MCP2200 and nothings changed.

I did check all the voltages and found that the Tx pin is supplying 5V to pin 14 of the Atmega. The picture shows that it shouldn't have any voltage yet but after looking at many forums I found that others were having the same problem and that it turned out to be okay - is this true?
Re: Gen7 - Impossible to upload firmware
August 14, 2013 08:55AM
Quote

I thought once you uploaded the boot loader and locked it, it would stay on there until you erased the entire memory.

Actually, this is true. But avrdude does erase the entire memory on each upload. Unless you use the -d flag or something.

Quote

I did check all the voltages and found that the Tx pin is supplying 5V to pin 14 of the Atmega.

You measure the serial signal here and this is fine. The picture shows Gen7 v1.4 which had the USB-TTL converter externally, so there was no signal right after soldering.

The MCP2200 shows up in your PC OS, this shows it's working. You can upload to the ATmega, so this one is working, too. There are only these two tracks between these two chips left ... and you should be able to measure the signals either with a simple logic probe (http://commons.wikimedia.org/wiki/File:Logicprobe_chtaube070101.jpg) or with a voltage meter, if you go with very low baud rates, like 2400 baud or send large amounts of data.

All you can to is to triple-check wether baud rates fit, solder points are fine and upload custom firmware which send/receive data which you can measure. I'm sure it's a very simple mistake.

If everything fails, you can send me the board. I'll fix it for just the shipping costs. Usually this takes me no longer than a few minutes, because ... well, you know, finding others' trouble is much easier than finding that little silliness in the own work.


Generation 7 Electronics Teacup Firmware RepRap DIY
     
Re: Gen7 - Impossible to upload firmware
August 19, 2013 08:42AM
Hi,
I am having a problem compiling the marlin firmware for my 20Mhz gen7 1.5 board. I have built the board and have got to the point where I can compile and upload the ATmega1284 test sketch (using Arduino IDE 1.0.5) throught the gen 7 onboard usb via the MCP2200 and have pins 4 and 5 toggling. I can see the correct text being displayed on the serial monitor. So at this point I'm confident that the hardware works correctly. My problem is that I get errors when I try to compile Marlin under Arduino ver 22. see below


In file included from cardreader.cpp:1:
/Marlin.h:32:23: error: WProgram.h: No such file or directory
In file included from /Marlin.h:37,
from cardreader.cpp:1:
MarlinSerial.h:149: error: expected ',' or '...' before '&' token
MarlinSerial.h:149: error: ISO C++ forbids declaration of 'String' with no type
MarlinSerial.h:168: error: expected ',' or '...' before '&' token
MarlinSerial.h:168: error: ISO C++ forbids declaration of 'String' with no type
/MarlinSerial.h: In member function 'void MarlinSerial::print(int)':
MarlinSerial.h:151: error: 's' was not declared in this scope

If I try to compile the firmware under arduino ver 1.0.5 the compile is successful but in the compile (verbose o/p) there are some lines that appear in Orange text. but I do get the compile done message. See the attached file of the complete log. My system is running windows xp service pack 3. I get the same results on a windows 7 system 32 bit. Any ideas what I'm doing wrong.
Attachments:
open | download - log file for Marlin on arduino105.txt (51.3 KB)
Sorry, only registered users may post in this forum.

Click here to login