2 new DC BoArduinos + FTDI not loading sketche

For other supported Arduino products from Adafruit: Shields, accessories, etc.

Moderators: adafruit_support_bill, adafruit

2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 6:40 pm

Hi,

I am unable to load my sketches to either of my 2 new DC BoArduinos.

My Duemilanove is working great so I got 2 new DC BoArduinos and got the recommended FTDI cable from
adafruit.

Build up was fine (LED fine, PWR fine), hitting reset gives me 3 blinks on the red LED, as does plugging in the FTDI
cable.

Running a linux host, Fedora Core 12 on a lenovo thinkpad:

usb 6-2: new full speed USB device using uhci_hcd and address 11
usb 6-2: New USB device found, idVendor=0403, idProduct=6001
usb 6-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 6-2: Product: TTL232R-3V3
usb 6-2: Manufacturer: FTDI
usb 6-2: SerialNumber: FTELPQE2
usb 6-2: configuration #1 chosen from 1 choice
ftdi_sio 6-2:1.0: FTDI USB Serial Device converter detected
usb 6-2: Detected FT232RL
usb 6-2: Number of endpoints 2
usb 6-2: Endpoint 1 MaxPacketSize 64
usb 6-2: Endpoint 2 MaxPacketSize 64
usb 6-2: Setting MaxPacketSize 64
usb 6-2: FTDI USB Serial Device converter now attached to ttyUSB0

When attempting to download my sketch WITHOUT reset (I soldiered in C6):

Using Port : /dev/ttyUSB0
Using Programmer : stk500v1
Overriding Baud Rate : 57600
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
avrdude: Send: Q [51] [20]
.
.
.


WHEN I hit "reset" and load, I get a little farther, but it gets interrupted with a sync, flash or just the stk500_ error below:
.
.
.
1] i [69] l [6c] s [73] * [2a] . [00] * [2a] h [68] a [61] [20]
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding
.
.
.

Both boards are behaving in the same way, both were built up over a 2 hour window this am...

Any thoughts/suggestions of what I might be missing?

Thanks
-Todd
Last edited by darthracing on Fri Mar 05, 2010 6:47 pm, edited 1 time in total.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 6:47 pm

example of flash error, upload AFTER hitting reset button

5] x [78] . [94] . [84] . [b5] . [82] ` [60] . [84] . [bd] [20]
avrdude: Recv: . [8a]

avrdude: stk500_paged_write(): (a) protocol error, expect=0x14, resp=0x8a
##################### | 100% 2.22s

avrdude: failed to write flash memory, rc=-4
avrdude: Send: Q [51] [20]
avrdude: Recv: . [88]
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0x88

avrdude done. Thank you.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 6:52 pm

example of a sync error message:

[80] | [7c] . [81] + [2b] . [80] . [83] . [80] . [e2] . [92] . [e0] . [8c] . [19] . [9d] . [09] d [64] . [e0]
avrdude: Recv: . [10]
#avrdude: Send: U [55] . [00] . [03] [20]
avrdude: Recv: . [14]
avrdude: Recv: . [10]
avrdude: Send: t [74] . [00] . [80] F [46] [20]
avrdude: Recv: . [94]

avrdude: stk500_paged_load(): (a) protocol error, expect=0x14, resp=0x94
avrdude: Send: V [56] [20] . [00] . [00] . [00] [20]
avrdude: Recv: p [70]
avrdude: stk500_cmd(): programmer is out of sync
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 6:54 pm

A re "upload" from the arduino tool generates the message below, and a rapid flashing red LED:

Using Port : /dev/ttyUSB0
Using Programmer : stk500v1
Overriding Baud Rate : 57600
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Recv: . [e0]
avrdude: stk500_getsync(): not in sync: resp=0xe0
avrdude: Send: Q [51] [20]
avrdude: Recv: . [e0]
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0xe0

avrdude done. Thank you.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 6:55 pm

wait, rapid flash is due to my code, looking at the serial monitor....
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 05, 2010 7:10 pm

SO it looks like I am getting sketches loaded, but it requires reset, several attempts and I always get error messages... is this normal?
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am


Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Sun Mar 07, 2010 1:08 pm

adafruit wrote:try not using -vvvv ?


I'll try turning verbosity down, but the duelonove is fine with it on. I had adjusted the download bitrate without success...
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 1:29 pm

darthracing wrote:
adafruit wrote:try not using -vvvv ?


I'll try turning verbosity down, but the duelonove is fine with it on. I had adjusted the download bitrate without success...


I set

upload.verbose=false (the default setting) and am getting

Binary sketch size: 12064 bytes (of a 30720 byte maximum)

avrdude: stk500_getsync(): not in sync: resp=0xe0
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0xe0


I then tried to set/reset the board type hoping something was wrong..
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 1:39 pm

verbose on

Binary sketch size: 12064 bytes (of a 30720 byte maximum)
/opt/arduino-0018/hardware/tools/avrdude -C/opt/arduino-0018/hardware/tools/avrdude.conf -v -v -v -v -patmega328p -cstk500v1 -P/dev/ttyUSB0 -b57600 -D -Uflash:w:/tmp/build7371847151441723828.tmp/tbm_speedo.cpp.hex:i


avrdude: Version 5.4-arduino, compiled on Oct 22 2007 at 13:15:12
Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

System wide configuration file is "/opt/arduino-0018/hardware/tools/avrdude.conf"
User configuration file is "/home/tas/.avrduderc"
User configuration file does not exist or is not a regular file, skipping

Using Port : /dev/ttyUSB0
Using Programmer : stk500v1
Overriding Baud Rate : 57600
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Send: 0 [30] [20]
avrdude: Recv: . [e0]
avrdude: stk500_getsync(): not in sync: resp=0xe0
avrdude: Send: Q [51] [20]
avrdude: Recv: . [e0]
avrdude: stk500_disable(): protocol error, expect=0x14, resp=0xe0

avrdude done. Thank you.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am


Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 2:22 pm

A pattern I am noticing is that the auto-reset feature of the FTDI chip works ONLY when I first plug in the USB cable - I can unplug/plug back in and the auto-reset works.

Could this be a linux serial driver issue? I am running Fedora Core 12, looks fine, no errors posted as some were getting according to google seaches...

Code: Select all
Mar 12 11:18:47 localhost kernel: usb 6-2: new full speed USB device using uhci_hcd and address 9
Mar 12 11:18:47 localhost kernel: usb 6-2: New USB device found, idVendor=0403, idProduct=6001
Mar 12 11:18:47 localhost kernel: usb 6-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Mar 12 11:18:47 localhost kernel: usb 6-2: Product: TTL232R-3V3
Mar 12 11:18:47 localhost kernel: usb 6-2: Manufacturer: FTDI
Mar 12 11:18:47 localhost kernel: usb 6-2: SerialNumber: FTELPQE2
Mar 12 11:18:47 localhost kernel: usb 6-2: configuration #1 chosen from 1 choice
Mar 12 11:18:47 localhost kernel: ftdi_sio 6-2:1.0: FTDI USB Serial Device converter detected
Mar 12 11:18:47 localhost kernel: usb 6-2: Detected FT232RL
Mar 12 11:18:47 localhost kernel: usb 6-2: Number of endpoints 2
Mar 12 11:18:47 localhost kernel: usb 6-2: Endpoint 1 MaxPacketSize 64
Mar 12 11:18:47 localhost kernel: usb 6-2: Endpoint 2 MaxPacketSize 64
Mar 12 11:18:47 localhost kernel: usb 6-2: Setting MaxPacketSize 64
Mar 12 11:18:47 localhost kernel: usb 6-2: FTDI USB Serial Device converter now attached to ttyUSB0
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 3:07 pm

Here I run the loader outside the tool.

I am using a single "-v" (upload.verbose=true sets "-v -v -v -v" ) and can finally see I am getting 80% loaded before
an error.

I have my DC Boarduino completely pulled from the breadboard, only connected to power and FTDI cable:


Code: Select all
[root@vader log]# /opt/arduino-0018/hardware/tools/avrdude -C/opt/arduino-0018/hardware/tools/avrdude.conf -v -patmega328p -cstk500v1 -P/dev/ttyUSB3 -b57600 -D -Uflash:w:/tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex

avrdude: Version 5.4-arduino, compiled on Oct 22 2007 at 13:15:12
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/

         System wide configuration file is "/opt/arduino-0018/hardware/tools/avrdude.conf"
         User configuration file is "/root/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port            : /dev/ttyUSB3
         Using Programmer      : stk500v1
         Overriding Baud Rate  : 57600
         AVR Part              : ATMEGA328P
         Chip Erase delay      : 9000 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        65     5     4    0 no       1024    4      0  3600  3600 0xff 0xff
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : STK500
         Description     : Atmel STK500 Version 1.x firmware
         Hardware Version: 2
         Firmware Version: 1.16
         Vtarget         : 0.0 V
         Varef           : 0.0 V
         Oscillator      : Off
         SCK period      : 0.1 us

avrdude: AVR device initialized and ready to accept instructions

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

avrdude: Device signature = 0x1e950f
avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: efuse reads as 0
avrdude: reading input file "/tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex"
avrdude: input file /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex auto detected as Intel Hex
avrdude: writing flash (11984 bytes):

Writing | ########################################           | 80% 2.77s
avrdude: stk500_paged_write(): (a) protocol error, expect=0x14, resp=0x54
Writing | ################################################## | 100% 2.81s

avrdude: failed to write flash memory, rc=-4

avrdude: stk500_cmd(): programmer is out of sync
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 3:10 pm

Running the same command again, it worked!

Code: Select all
.
.
.
         Programmer Type : STK500
         Description     : Atmel STK500 Version 1.x firmware
         Hardware Version: 2
         Firmware Version: 1.16
         Vtarget         : 0.0 V
         Varef           : 0.0 V
         Oscillator      : Off
         SCK period      : 0.1 us

avrdude: AVR device initialized and ready to accept instructions

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

avrdude: Device signature = 0x1e950f
avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: efuse reads as 0
avrdude: reading input file "/tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex"
avrdude: input file /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex auto detected as Intel Hex
avrdude: writing flash (11984 bytes):

Writing | ################################################## | 100% 3.46s

avrdude: 11984 bytes of flash written
avrdude: verifying flash memory against /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex:
avrdude: load data flash data from input file /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex:
avrdude: input file /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex auto detected as Intel Hex
avrdude: input file /tmp/build146064053241145192.tmp/tbm_speedo.cpp.hex contains 11984 bytes
avrdude: reading on-chip flash data:

Reading | ###                                                | 6% 0.17savrdude: loadaddr(): (b) protocol error, expect=0x14, resp=0x14
Reading | ################################################## | 100% 2.62s

avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x069c
         0x80 != 0xc0
avrdude: verification error; content mismatch

avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: efuse reads as 0
avrdude: safemode: Fuses OK

avrdude done.  Thank you.


Besides the inconsistency, the need to remove the Boarduino from its application to reprogram is a big issue for me - might be worth another topic.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Re: 2 new DC BoArduinos + FTDI not loading sketche

Postby darthracing » Fri Mar 12, 2010 3:31 pm

Its a DC Boarduino, and powercycling before and upload seems to help the consistency.

I have never had a clean download to the Boardino - jumping to my Arduino Duemilanove and seeing how
works perfectly means something is missing, or my assembly is terrible (2x!). I guess I'll develop on the Arduino and try
flashing to the Boarduino only as necessary.

Making sure I get Write 100% is as good as I can get/hope to get - again, loading manually with the "-v" command is necessary to see how successful I am or not.
darthracing
 
Posts: 19
Joined: Mon Feb 08, 2010 3:59 am

Next

Return to Other Arduino products from Adafruit

Who is online

Users browsing this forum: No registered users and 3 guests

Stuff to buy from the Adafruit store and links to product documentation!


New Products [114]

Raspberry Pi[82]
 
FLORA[24]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[12]
Arduino[60]
 
NETduino[14]
 
BeagleBone[23]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[39]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[9]


 
Breakout Boards[35]
LCDs & Displays[49]
Components & Parts[70]
Batteries & Power[54]
EL Wire/Tape/Panel[52]
LEDs[112]
 
Wireless[16]
Cables[66]
 
Lasers[6]
Sensors/Parts[147]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[41]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[25]


 
Stickers[41]
 
Skill badges[55]
 
Books[26]
 
Circuit Playground[7]
 
Gift Certificates[4]