-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Get unknown error on every FW Update #30
Comments
What version of the plugin are you using? What does the octoprint.log log file show? |
I have tried both 0.4 and 0.5.
The FW works flawlessly even with the update error.
Ill post from the log When I Get home again.
Aleks
Sendt fra min iPhone
… 30. jan. 2018 kl. 15:22 skrev Ben Lye ***@***.***>:
What version of the plugin are you using? What does the octoprint.log log file show?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
I have the same problem. This doesn't work anymore: This works: Probably, this must be changed in the program code. :-) |
Well that's annoying! Which version do you have, and do you have a link to any updated docs? |
Here is my installed version: This version was automatically installed through the library. |
I have v6.3, which is the current one, and it works fine with the |
Interesting. Why is an old version installed over the library? I'll try. Edit: That's the problem. Thanks. :-) |
The plugin doesn't self-install avrdude - you have to do it yourself. I guess the one you have came with something else on your system. Try this in a shell on your OctoPrint server:
|
I just did a Here is my log from FWUpdate: |
Yes, the same: pi@octopi:~ $ sudo apt-get install --only-upgrade avrdude |
Did you do this first: |
Yes, I did. |
Yes, I did that first. |
@riisefrutti, you're getting checksum errors when avrdude is reading the file back. So the write works, but the read is a mess:
I think you should work out how to get the latest avrdude installed on your system. @grandmastermp, does your log look similar? |
Well, after compiling avrdude 6.3 the error still persist. There is still a communication error. Write works, read does not. |
What happens if you copy the compiled hex file somewhere locally on your Pi and try to run the avrdude command manually? Do you get the same errors? What happens if you add Presumably you've been able to flash this board without errors by other means? |
Hi, |
@grandmastermp did you check your log? Are you seeing the same verification error, or something else? Google suggests that write verification errors can sometimes be fixed by re-flashing the board's bootloader. You would need a USBasp or another external programmer to do that. In the meantime I'm going to add detection for a verification error so that you don't get 'Unknown error' if it is the verification that fails. I can also add an option to disable write verification, but that feels like a bad idea. If it was my board I'd want to fix the problem. |
@benlye |
OK. It would be good to see the plugin log to see if you have the same problem or something else. |
If I have problems with write verification errors, then the manual way should not work. |
You might be getting the 'unknown error' for a different reason'. I'd like to know if it is for write verification or not. If you are getting write verification errors from the plugin, it would be very interesting to know if the manual command works or not. If the manual avrdude command doesn't give errors I'll need to know what it's doing differently to the command the plugin uses. The plugin doesn't do anything special - it just runs the avrdude command, so the results should be the same... |
6.3 log: avrdude: Version 6.3, compiled on Jan 30 2018 at 21:40:53
avrdude: AVR device initialized and ready to accept instructions Reading | ################################################## | 100% 0.01s avrdude: Device signature = 0x1e9801 (probably m2560) avrdude: safemode: hfuse reads as D8 avrdude done. Thank you. pi@tarantula:~ $ /home/pi/avrdude-6.3/avrdude -v -p m2560 -c wiring -P /dev/ttyUSB0 -b115200 -U flash:w:/home/pi/FW/marlin.hex:i -D avrdude: Version 6.3, compiled on Jan 30 2018 at 21:40:53
avrdude: AVR device initialized and ready to accept instructions Reading | ################################################## | 100% 0.01s avrdude: Device signature = 0x1e9801 (probably m2560) Writing | ################################################## | 100% 24.66s avrdude: 170268 bytes of flash written Reading | #### | 7% 1.34savrdude: stk500v2_recv(): checksum error avrdude: verifying ... avrdude: safemode: hfuse reads as D8 avrdude done. Thank you. |
@riisefrutti so you get checksum errors when you try to flash from the Pi command line as well. A quick Google search suggests that re-flashing the board's bootloader may help. |
The just reinstalled PI bootloader. Will try to Flash bootloader to the tarantula board.
Sendt fra min iPhone
… 31. jan. 2018 kl. 15:29 skrev Ben Lye ***@***.***>:
@riisefrutti so you get checksum errors when you try to flash from the Pi command line as well.
A quick Google search suggests that re-flashing the board's bootloader may help.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Still the same error after the upgrade. :-( Here the error message with switch "I" on the end: avrdude -p m1284p -c arduino -P /dev/ttyUSB0 -b 57600 -D -U flash:w:Marlin.ino.sanguino.hex:I And here the flash process without "I": avrdude -p m1284p -c arduino -P /dev/ttyUSB0 -b 57600 -D -U flash:w:Marlin.ino.sanguino.hex avrdude: AVR device initialized and ready to accept instructions Reading | ################################################## | 100% 0.00s avrdude: Device signature = 0x1e9705 (probably m1284p) Writing | ################################################## | 100% 27.00s avrdude: 112158 bytes of flash written Reading | ################################################## | 100% 22.51s avrdude: verifying ... avrdude: safemode: Fuses OK (E:00, H:00, L:00) avrdude done. Thank you. |
It should be a lower case i - |
Ok. |
Yes, it works: avrdude -p m1284p -c arduino -P /dev/ttyUSB0 -b 57600 -D -U flash:w:Marlin.ino.sanguino.hex:i avrdude: AVR device initialized and ready to accept instructions Reading | ################################################## | 100% 0.00s avrdude: Device signature = 0x1e9705 (probably m1284p) Writing | ################################################## | 100% 27.00s avrdude: 112158 bytes of flash written Reading | ################################################## | 100% 22.51s avrdude: verifying ... avrdude: safemode: Fuses OK (E:00, H:00, L:00) avrdude done. Thank you. |
But why doesn't work with your tool? |
I don't know, that's why I've asked you to attach the log... |
@grandmastermp I think I see your problem (but I still want to see your log). In your working example above you are setting the baud rate with I'll add a configurable setting to allow overriding the default avrdude baud rate with a custom one. In the meantime, if you want to, you could edit this file: find this line: and change it to this: |
@benlye Under the directory "OctoPrint" I can not find "venv". |
Oh well. Can you find the log? I have a new version for you to test, but until I see the log I won't know if it will fix your problem... |
Here's my log: 2018-01-31 17:58:36,764 /usr/bin/avrdude -v -p m1284p -c arduino -P /dev/ttyUSB0 -U flash:w:/tmp/tmpkrhPq6:i -D |
"not in sync" = serial speed. Yesssssss. :-) |
Use the Plugin Manager to install this version: I've added 'Advanced Settings' where you can change the avrdude baud rate and also disable write verification. I've done a fair bit of testing already. If it works for you I'll release it. |
Yes, it works. Thank you very much. :-) 2018-02-01 18:55:56,754 /usr/bin/avrdude -v -q -p m1284p -c arduino -P /dev/ttyUSB0 -D -b 57600 -U flash:w:/tmp/tmpHDtyjF:i |
On my side, no help with the new bootloader. Im going to try with another RPI, and a fresh install. Having a feeling there might be something with the PITFT jessie(adafruit) that prevents the reading. Normal upload of FW with arduino IDE works like a charm. |
@riisefrutti Have you tried the command line via ssh? As I did? |
As before SSH unsuccessful, only read error. |
I think the problem is not the plugin. |
@grandmastermp I totally agree. @benlye Thank you for the help. The last update you posted will get me through as of now, and Ill sort the rest out later. |
Cool. I'll merge the PR this morning. |
Perfect. :-) |
Merged #31. |
This issue has been automatically locked because there was no further activity after it was closed. Please open a new issue for any related problems. |
When I try to update fw with the FirmwareUpdater I get through the flashing, but when it is supposed to reset I get FWUpdate fail - unknown error.
It looks like the FW is flashed to the tarantula, and it works great. Cant wrap my head around why the error occures.
The text was updated successfully, but these errors were encountered: