I am using an ATmega1284P, "Mighty1284P 8MHz board" and programmer "USBtinyISP. (AVR pocket programmer)
Question1)
I get a lot of errors trying to upload and have to do it several times before the program is uploaded.
I have used the AVRISP mkii via AVR studio, but this is a bit of a pain to change programs and look for the current file.
Is there a "setting" some were to make the USBtinyISP a bit more robust....
Question2)
I can only use "file", "Upload using programmer", (Ctrl+Shft+U), when I try from the main screen "upload" it errors and displays error:
processing.app.SerialNotFoundException: Serial port 'COM3' not found. Did you select the right one from the Tools > Serial Port menu?
at ssing.app.Serial.(Serial.java:191)
at processing.app.Serial.(Serial.java:77)
at processing.app.debug.Uploader.flushSerialBuffer(Uploader.java:77)
at processing.app.debug.AvrdudeUploader.uploadViaBootloader(AvrdudeUploader.java:174)
at processing.app.debug.AvrdudeUploader.uploadUsingPreferences(AvrdudeUploader.java:67)
at processing.app.Sketch.upload(Sketch.java:1671)
at processing.app.Sketch.exportApplet(Sketch.java:1627)
at processing.app.Sketch.exportApplet(Sketch.java:1599)
at processing.app.Editor$DefaultExportHandler.run(Editor.java:2380)
at java.lang.Thread.run(Thread.java:619)
But it will upload via "file", "Upload using programmer", (Ctrl+Shft+U)
Question 3)
I have also found a neat RTC software from AVR (App AVR134), but I can not get it to work as an Arduino sketch...
Please see attached.
Could some one see if they can transpose the code to C++ or for Ardunio
Or if they have a similar sketch.
I would prefer not to use a RTC chip as I am VERY short on PCB real estate
The reason you can use the USBtinyISP with 'upload using programmer' successfully by not use it successfully to 'burn bootloader' is a 'flaw' in the firmware for the USBtinyISP, which they have never addressed if they will ever fix.
From the product description:
........It cannot program chips with more than 64K of flash, such as the Atmega1280/1281, or Atmega2560/2561..........
This restriction applies to the ATmega1284P also as the bootloader does reside above that 64K boundary. It can burn sketches using the IDE option of 'upload using programmer' as long as the sketch size does not cross that 64K boundary.
There are very inexpensive USBasp programmer that will work with these larger flash AVR chips, or you can use another arduino board running the arduinoISP sketch.
Now why it fails to do normal IDE serial sketch uploading using COM3 can be several reasons including wrong bootloader, wrong wiring of the USB serial converter cable/converter, or wrong custom hardware files/folders, or not using the best fuse settings when burning the bootloader. I would check what value your using for the LOW fuse byte as many have found serial errors unless they used the full swing oscillator option of "bobuino.bootloader.low_fuses=0xf7".
Q1+2
It does not fail all the time, and the errors are relating to verification errors (Byte not written correctly).
Bootloader is ok, Wiring ok, files ok, so will look at "fuse" settings
Hi
Just an update on using to program Atmega1248P (Mighty1284P 8MHz) with the AVRISP mkii
Error:
processing.app.SerialNotFoundException: Serial port 'COM3' not found. Did you select the right one from the Tools > Serial Port menu?
at processing.app.Serial.(Serial.java:191)
at processing.app.Serial.(Serial.java:77)
at processing.app.debug.Uploader.flushSerialBuffer(Uploader.java:77)
at processing.app.debug.AvrdudeUploader.uploadViaBootloader(AvrdudeUploader.java:174)
at processing.app.debug.AvrdudeUploader.uploadUsingPreferences(AvrdudeUploader.java:67)
at processing.app.Sketch.upload(Sketch.java:1671)
at processing.app.Sketch.exportApplet(Sketch.java:1627)
at processing.app.Sketch.exportApplet(Sketch.java:1599)
at processing.app.Editor$DefaultExportHandler.run(Editor.java:2380)
at java.lang.Thread.run(Thread.java:619)
So it seems this programmer is having the same error, but when you program via Ctrl+Shft+U ("File", "Upload using programmer")
Error:
avrdude: usbdev_open(): did not find any USB device "usb"
There must be a setting somewhere that is astray....?
Hi
Thanks for the link, it worked, well at least via Crtl+Shft+U
It is also a lot faster, I think the AVR pocket rocket reads back the full ROM were as the AVRISPmkii only reads back ROM "programmed" for verifercation.
Anyway thanks for the help
Tried that but my AVRISPMkII keeps showing up under Jungo. I can't figure out how it worked for you. I tried many times removing and reinstalling and updating under the Device Manager, but it only shows up under Jungo. Which was my understanding that you actually need to remove the Jungo drivers for it to show up under libusb. Hmm...
Yes I have the same problem, every time I unplug the AVRISP and replug it back into the USB port it installs under "Jungo"
I will see what I can find out here and advice if possible.
Now here's something interesting. I've always thought you couldn't have it both ways under libusb and Jungo, but I downloaded and installed libusb-filter program and applied it to the AVRISPmkII driver. Run the Filter Wizard and install a device filter.
Now the AVRISPmkII will still show up under the Jungo driver, but I can use it now under avrdude as avrisp2 and STILL work with Atmel Studio 6 device programmer. Although you do need to replug the usb after using it in Atmel Studio 6.
C:\Documents and Settings\randalm\My Documents\My Stuff\Arduino\arduino-1.0.4\hardware\tools\avr\etc>..\bin\avrdude -c avrisp2 -Pusb -pm8 -v
avrdudev5.11: Version 5.11, compiled on Sep 2 2011 at 19:38:36
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
Copyright (c) 2007-2009 Joerg Wunsch
System wide configuration file is "...\Arduino\arduino-1.0.4\hardware\tools\avr\etc\avrdude.conf"
Using Port : usb
Using Programmer : avrisp2
avrdudev5.11: usbdev_open(): Found AVRISP mkII, serno: 000200134487
AVR Part : ATMEGA8
Chip Erase delay : 10000 us
PAGEL : PD7
BS2 : PC2
RESET disposition : dedicated
RETRY pulse : SCK
serial program mode : yes
parallel program mode : yes
Timeout : 200
StabDelay : 100
CmdexeDelay : 25
SyncLoops : 32
ByteDelay : 0
PollIndex : 3
PollValue : 0x53
Memory Detail :
Block Poll Page Polled
Memory Type Mode Delay Size Indx Paged Size Size #Pages MinW MaxW ReadBack
----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
eeprom 4 20 128 0 no 512 4 0 9000 9000 0xff 0xff
flash 33 10 64 0 yes 8192 64 128 4500 4500 0xff 0x00
lfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
hfuse 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
lock 0 0 0 0 no 1 0 0 2000 2000 0x00 0x00
calibration 0 0 0 0 no 4 0 0 0 0 0x00 0x00
signature 0 0 0 0 no 3 0 0 0 0 0x00 0x00
Programmer Type : STK500V2
Description : Atmel AVR ISP mkII
Programmer Model: AVRISP mkII
Hardware Version: 1
Firmware Version Master : 1.17
Vtarget : 5.0 V
SCK period : 1.00 us
avrdudev5.11: AVR device initialized and ready to accept instructions
Reading | ################################################## | 100% 0.02s
avrdudev5.11: Device signature = 0x1e9307
avrdudev5.11: safemode: lfuse reads as 9F
avrdudev5.11: safemode: hfuse reads as D9
avrdudev5.11: safemode: lfuse reads as 9F
avrdudev5.11: safemode: hfuse reads as D9
avrdudev5.11: safemode: Fuses OK
avrdudev5.11 done. Thank you.