Let's Make Robots!

Dagu Adventure Robot Kit Arduino connection problem

I have just bought the Dagu Adventure Robot Kit from robotshop.com.
The robot works out of the box with the demonstration program, but, as you imagine, I want to do something else.... 

My environment is :
•       SO: xubunt 11.10
•       Arduino IDE: Arduino 0022
With this environment I’ve been able to program ATMega 368 in Arduino UNO and Arduino duemilanove, even writing an Arduino bootloader to an ATMega 368.

 
But, when I try to upload an sketch to the Dagu Adventure Robot Kit (double checking taht I have selected the board as indicated in the instruction manual -Arduino Diecemila, Duemilanove or Nano w/ ATMega 168- and with the port selected) it start to upload it, the little leds on the robot board (tx/rx I suppose) blink, but after some seconds it throw this message:

avrdude: stk500_recv(): programmer is not responding

I’ve also tried in another environment (win7 with Arduino 1.0) with the same result.

Have you got any idea of what I'm doing wrong?

Thank you very much!!!

P.D.: in verbose mode the messages are these:

 

Binary sketch size: 4132 bytes (of a 14336 byte maximum)
/usr/share/arduino/hardware/tools/avrdude -C/usr/share/arduino/hardware/tools/avrdude.conf -v -v -v -v -patmega168 -carduino -P/dev/ttyUSB0 -b19200 -D -Uflash:w:/tmp/build3108416037048241157.tmp/Adventure_Robot_JMMPv1.cpp.hex:i 

avrdude: Version 5.10, compiled on Jun 29 2010 at 21:09:48
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "/usr/share/arduino/hardware/tools/avrdude.conf"
         User configuration file is "/home/jmartinz/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyUSB0
         Using Programmer              : arduino
         Overriding Baud Rate          : 19200
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Send: 0 [30]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
         AVR Part                      : ATMEGA168
         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        512    4      0  3600  3600 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           flash         65     6   128    0 yes     16384  128    128  4500  4500 0xff 0xff
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : Arduino
         Description     : Arduino
avrdude: Send: A [41] . [80]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [02] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [98]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [03] 
avrdude: Recv: . [10] 
         Hardware Version: 2
         Firmware Version: 1.16
avrdude: Send: A [41] . [84]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [85]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [86]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [87]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [89]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
         Vtarget         : 0.0 V
         Varef           : 0.0 V
         Oscillator      : Off
         SCK period      : 0.1 us

avrdude: Send: A [41] . [81]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [01] 
avrdude: Recv: . [10] 
avrdude: Send: A [41] . [82]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Recv: . [10] 
avrdude: Send: B [42] . [86] . [00] . [00] . [01] . [01] . [01] . [01] . [03] . [ff] . [ff] . [ff] . [ff] . [00] . [80] . [02] . [00] . [00] . [00] @ [40] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: E [45] . [05] . [04] . [d7] . [c2] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: P [50]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: AVR device initialized and ready to accept instructions

Reading | avrdude: Send: u [75]   [20] 
avrdude: Recv: . [14] . [1e] . [94] . [06] . [10] 
################################################## | 100% 0.00s

avrdude: Device signature = 0x1e9406
avrdude: Send: V [56] . [a0] . [01] . [fc] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [fd] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [fe] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: Send: V [56] . [a0] . [01] . [ff] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [00] 
avrdude: Recv: . [10] 
avrdude: reading input file "/tmp/build3108416037048241157.tmp/Adventure_Robot_JMMPv1.cpp.hex"
avrdude: writing flash (4132 bytes):

Writing | avrdude: Send: U [55] . [00] . [00]   [20] 
avrdude: Recv: . [14] 
avrdude: Recv: . [10] 
avrdude: Send: d [64] . [00] . [80] F [46] . [0c] . [94] b [62] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [ab] . [04] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [e9] . [06] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [0c] . [94] . [8a] . [00] . [00] . [00] . [00] . [00] $ [24] . [00] ' [27] . [00] * [2a] . [00] . [00] . [00] . [00] . [00] % [25] . [00] ( [28] . [00] + [2b] . [00] . [00] . [00] . [00] . [00]   [20] 
avrdude: ser_recv(): programmer is not responding
avrdude: stk500_recv(): programmer is not responding

 



    
    

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

What no one tells you in the tutorials is that you need to use a different version of AVRdude. I ended up making a copy of my Arduino IDE folder and renaming it as Bootloader Burner. I then replaced it's AVRdude with one from AVRstudio. 

It works but I get an error the first time I try and burn and then it works fine the second time. While this allows me to burn bootloaders the new AVRdude no longer lets me upload sketches which is why I have two copies of the Arduino IDE on my computer.

It seems there are many versions of AVRdude on the net and you just need to find one that works. In my case I am using Windows XP but I don't think this matters much.

At last, I was able to burn the bootloader!!! And then to upload programs!!! I'm so happy!! :D

I bougth a USBtiny v1.0 and then I tried to burn the bootloader. In Ubuntu I have had to do it with a root account. AND I have changed the avrdude.conf because for an ATMEGA 168 it expect  signature  = 0x1e 0x94 0x06 and it seems that ATMEGA168P gives back signature = 0x1e 0x94 0x0B

But, after loading the Arduino bootloader I've been able to upload sketches with my user account, changing back the avrdude.conf to its initial value. I suppose that the bootloader changes the signature.

In any case it works and it is great.

 

Thanks!!!

 

I'm trying to upload the bootloader, but I can't.

I have uploaded de ArduinoISP sketch to a duemilanova and I have set the ISP robot connection in this way:

where the coloured numbers are refered to the arduino acting as ISP pins.

Then I select the "Arduino Diecemila, Duemilanove or Nano w/ ATMega 168" and then Tools->Burn bootloader->\w Arduino as ISP.

The connections look like this:

The message is the same that when I tried to upload an sketch to the robot:

avrdude: stk500_recv(): programmer is not responding

I have connected the three leds as said in ArduinoISP sketch:

// 9: Heartbeat - shows the programmer is running

// 8: Error - Lights up if something goes wrong (use red if that makes sense)

// 7: Programming - In communication with the slave 

and 9 is "beating" but 8 and 7 never shine... and that is a bit strange. 

 

 

....

The sample code is working and working ok... so I assume it has to be some stupid thing I'm not doing correctly... but I cant't find what is it :( 

 

What batteries are you using? The adventure robot only works with NiMh or NiCd batteries. Alkaline batteries have too high a voltage when new and may damage the robot.

If the voltage is too high or too low (flat batteries) then the processors may not function correctly or the the memory becomes corrupt.

I'm using Ni-Mh 1.2V 2500mAh (Tronic bought in Lidl).  So, it may be too low voltage.... 

http://lh5.ggpht.com/_v1E5kwvhmwI/TEgYJaXzYGI/AAAAAAAAA2o/5_0YYRXYT4s/s1600-h/22072010019%5B4%5D.jpg

 

I will try with another one as soon I get home.

 

Thank you for your indication!!!

Usually the problem is that users throw in the first batteries they can find (alkaline) which are 1.5V. This gives the CPU 6V or more and can damage the the CPU.

NiMh batteries maintain a steady voltage of 1.2V over the majority of their charge making them perfect for robots.

It is possible the bootloader has been corrupted. Can you re-load the bootloader?

Yes, you are right about the volts, in any case I've tried with another 4 NiMH rechargable batteries (Energizer) with the same result.

I will try to re-load the bootloader. To do so I can use an Arduino duemilanove as ISP, can't I? (following more or less instructions in http://arduino.cc/en/Tutorial/ArduinoISP ) but, as I'm not going to use ISP pins... I can figure out how to access pins 11,12 and 13 (from IO_pins.h). But, how can I access the "reset" pin?

 

Thank you!!