Show Posts
Pages: [1]
1  Using Arduino / Programming Questions / Re: TB6612FNG STBY problem on: January 29, 2011, 04:34:35 pm
I suspect an electrical problem.  Try unplugging the motors; does the RF link work then?  ...with motor standby set to HIGH?

What motors are you using?
2  Forum 2005-2010 (read only) / Troubleshooting / Re: long delay() values = programmer is not responding on: January 19, 2011, 02:38:34 pm
Thanks for the tips.  I'm beginning to believe I've fried part of the hardware.  See http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1295240179/0#0 for my sob-story there.
3  Forum 2005-2010 (read only) / Troubleshooting / long delay() values = programmer is not responding on: January 16, 2011, 11:26:42 pm
My Arduino Uno was working fine.  Now every time I try to upload a sketch, I receive the error "programmer is not responding".

Judging from the similar problems others have had when their sketches had too much serial I/O in the loop(), I think my problem is that my loop() contains too much delay (about 2 seconds).  I think the loader tries to talk to the board, but gives up in less than 2 seconds.

So to be happy in the future, I think I need to make sure the loop() time is always short - for example, under 1 second.

Can anyone with more experience with the Arduino Uno say whether this is true (that a loop() that takes more than a few seconds will cause "programmer is not responding" errors)?

Thanks.
4  Forum 2005-2010 (read only) / Troubleshooting / Re: Strangeness with analogWrite and LEDs on: January 18, 2011, 12:45:55 am
Ah, my newbie-ness is revealed.  Sorry for the confusion, and thanks for the info.
5  Forum 2005-2010 (read only) / Troubleshooting / Re: Strangeness with analogWrite and LEDs on: January 17, 2011, 06:11:42 pm
In other (PIC chip) projects, I've had much better luck doing pulse-width modulation (PWM) on the LED to achieve different brightnesses.  Since LEDs are diodes (switches), they pretty much turn full-on or full-off, depending on the voltage applied.

For example, instead of writing analog values to the LED output pins, write only HIGH or LOW.  If you wanted an LED to have full brightness, write HIGH every time loop() is called.  If you want 50% brightness instead, write HIGH every other time loop() is called, and LOW on the other times loop() is called (HIGH, LOW, HIGH, LOW, etc.).

I'm an Arduino newbie, but I believe some of the output pins are PWM-capable: that is, you can program the Arduino to pulse the pin half the time, or 1/4 of the time, for example.
6  Forum 2005-2010 (read only) / Troubleshooting / Re: Can't get Arduino Uno into DFU mode on: January 20, 2011, 12:28:47 pm
Looking at the 8u2 under a magnifying glass, it looks like the solder on 2 sides of the chip is lacking.

So I'm going to order another, good Uno that I can compare it to.
7  Forum 2005-2010 (read only) / Troubleshooting / Re: Can't get Arduino Uno into DFU mode on: January 18, 2011, 06:40:25 pm
Thanks, I now have some new ideas to try.

On a related note, I see from the Atmega8u2-mu datasheet that the HWB pin is sampled on reset, so that tells me the reset sequence above (release reset before HWB) is correct.

I also found from the datasheet that there's a power-on reset (duh), so that gives me an idea: I think I'll try connecting HWB to ground before plugging in the USB cable, then releasing HWB once the board is clearly powered up.  I'll let you know how that goes.

Another idea I have: on holding Reset low, the HWB/DTR pin should, I think float.  If, on the other hand, I'm not holding Reset low when I think I am holding it low, the HWB/DTR pin should be an output pin and being driven high.  I'm not exactly sure how to tell the difference between a floating pin and a driven-high one, but I think that should be easy to find (e.g., connecting a 10K resistor to gnd should pull down a floating pin, but not a driven-high pin, no?)
8  Forum 2005-2010 (read only) / Troubleshooting / Can't get Arduino Uno into DFU mode on: January 16, 2011, 11:56:19 pm
I'm trying to load new firmware into my Arduino Uno via dfu-programmer, but I haven't been able to get the board into DFU mode.  The Uno was working fine, then I uploaded a bad sketch that keeps me from uploading any more ("programmer is not responding" errors) - so I'm hoping that reburning the Uno's firmware will solve the problem. See http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1295238402 for the thread about my bad sketch.

Versions:
Fedora 14
Arduino software version 21
dfu-programmer 0.5.1
computer: an old Toshiba laptop with 512MB ram, 40GB disk, and a 2GHz Pentium 4. (could old USB ports be my problem?)


I tried based on instructions in http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1285962838/10
- Plug in the Usb cable as you always do for programming the board.
- Ground the Atmega8U2 Reset pin (ICSP1 pin 5 on the schematic).
- Ground the Atmega8U2 HWB pin (C5, DTR side on the schematic).
- Release the grounded Reset pin.
- Release the grounded HWB pin.

My impression from the thread I mentioned above is that if the Uno has successfully been put in DFU mode, it should appear as device "Arduino Uno DFU" rather than just "Arduino Uno".

The last few lines of dmesg output before and after doing the Uno reset sequence above looks like this:

===== Before doing the reset sequence =====
[14986.783056] hub 2-0:1.0: over-current change on port 2
[14987.206090] usb 2-2: new full speed USB device using uhci_hcd and address 10
[14987.392058] usb 2-2: New USB device found, idVendor=2341, idProduct=0001
[14987.392067] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=220
[14987.392073] usb 2-2: Product: Arduino Uno
[14987.392078] usb 2-2: Manufacturer: Arduino (www.arduino.cc)
[14987.392083] usb 2-2: SerialNumber: 6493234363835141F0C0
[14987.397275] cdc_acm 2-2:1.0: ttyACM0: USB ACM device

========= After doing the reset sequence =====
[14986.783056] hub 2-0:1.0: over-current change on port 2
[14987.206090] usb 2-2: new full speed USB device using uhci_hcd and address 10
[14987.392058] usb 2-2: New USB device found, idVendor=2341, idProduct=0001
[14987.392067] usb 2-2: New USB device strings: Mfr=1, Product=2, SerialNumber=220
[14987.392073] usb 2-2: Product: Arduino Uno
[14987.392078] usb 2-2: Manufacturer: Arduino (www.arduino.cc)
[14987.392083] usb 2-2: SerialNumber: 6493234363835141F0C0
[14987.397275] cdc_acm 2-2:1.0: ttyACM0: USB ACM device
(that is, the dmesg output is unchanged)

So it looks to me like the reset sequence isn't causing my OS to see the Uno unplug itself and the Uno DFU appear.

====== lsusb output after the reset sequence
Bus 002 Device 010: ID 2341:0001  
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 014: ID 045e:00f6 Microsoft Corp.
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
(the Microsoft device is a USB mouse.  I get the same symptom without the mouse, and on each of the laptops two USB ports)

Also, when I run dfu-programmer after the reset sequence, I get the following:
[root@blaptop bneedham]# dfu-programmer at90usb82 erase
dfu-programmer: no device present.

After the reset sequence above, the Uno's pin 13 Led blinks 3 times, then comes on steady (that's my old sketch running).

So, I suspect that the sequence above isn't successfully resetting the Atmeta8U2.  I'm wondering whether grounding the ICSP1 pin 5 is, for some reason, not causing the Atmega8U2 to reset.

Any troubleshooting ideas?

So, can someone confirm how to know whether the Uno is in DFU mode?

Thanks.

9  Forum 2005-2010 (read only) / Troubleshooting / Re: Arduino Uno sketch limit size on: January 17, 2011, 05:56:35 pm
The error "first mismatch at byte 0x7800" translates to decimal 30720.  So it seems to me that, as you say, there is a limit of 30720 rather than 32256.  I'm a newbie, so I can't suggest how to increase the limit or reduce your code size - sorry.
10  Forum 2005-2010 (read only) / Frequently-Asked Questions / Re: Newbie Troubles on: January 17, 2011, 07:18:28 pm
When you say you can't find resources to design and build the arm, do you mean the whole project (for example, how to connect the Arduino to the servos, and how to program the Arduino to control the servos), or do you mean just the mechanical design of the robot arm (how to cut out something that will fasten to the servos to be the arm)?

If your question is the second, I can only sympathize that I have similar problems: doing simple mechanical design.

If your question is the first instead, I recommend you start with a little simpler project and work up to the robot arm.  For example: project 1: get the Arduino board to blink an LED; project 2: build a circuit and write Arduino code to play a tone on a speaker (this will teach you the Pulse-Width Modulation (PWM) technique you'll need for the servos); project 3: build a circuit and write the code to wiggle two servos (this project lets you get everything working without having to think about mechanical design); project 4 - finally - mount the servos on wooden arms and program your new robot arm.
11  Forum 2005-2010 (read only) / Frequently-Asked Questions / Re: pov 8x8 or more... leds.... on: January 20, 2011, 04:27:17 pm
I found a more detailed discussion of this topic in this very forum by Googling 'persistence of vision arduino' (without the quotes).

That thread you might find useful is http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1232186941
12  Forum 2005-2010 (read only) / Frequently-Asked Questions / Re: Java RXTX help! on: January 17, 2011, 08:09:03 pm
I should be clearer:

The "Using port: null" indicates the problem: that Preferences.get("serial.port") is returning null - that is, you haven't set a preference for the serial port to use.  When CommPortIdentifier.getPortIdentifier() is called with null as the port of interest, it gives you the NoSuchPortException.
13  Forum 2005-2010 (read only) / Frequently-Asked Questions / Re: Java RXTX help! on: January 17, 2011, 08:04:48 pm
It sounds like you're having similar problems to what others have had using the Preferences object in the Silveira Neto tutorial.

See http://silveiraneto.net/2009/03/01/arduino-and-java/#comment-4322 for one solution: removing the Preferences references completely.
14  Forum 2005-2010 (read only) / Uno Punto Zero / Re: Tutorial - How to change firmware on 8u2 on: January 21, 2011, 04:20:41 pm
Ah, that's a nice feature: being able to yank both wires at once and the cap takes care of enforcing the HWB state requirement.  Thanks for that detail.
15  Forum 2005-2010 (read only) / Uno Punto Zero / Re: Tutorial - How to change firmware on 8u2 on: January 19, 2011, 03:15:27 pm
Clarification for reply #10.  According to the datasheet, the chip looks at the HWB pin state as reset is released (on the rising edge of /Reset).  So you should take the wire off the reset pin before taking the wire off the HWB pin.  If you take both wires off at once, it's a matter of luck whether the HWB pin is still grounded when you release the reset pin.

So to save frustration, I recommend following the datasheet, and remove the Reset wire before you remove the HWB wire.
Pages: [1]