Show Posts
Pages: [1] 2
1  Using Arduino / Microcontrollers / Bootloading error on: October 19, 2013, 12:07:58 pm
Hello,

I have been struggling with bootloading problem for weeks now and have no other choice then to ask for help from community.

I am using Arduino compatible boards(compatible to Arduino Duemillanove, Atmega328 + FT232R) and trying to bootload using two of them, one as a programmer, other as target board: http://arduino.cc/en/Tutorial/ArduinoISP
I had a batch of 200pcs, which 150 were bootloaderd fine, but with 50 I have same problem.
If I am bootloading with:
a)  Arduino software(which with I bootloaded those 150 pieces), I got "invalid device signature" error(note: I do get the other part; " Expected signature for ATMEGA328P is xx xx xx"). Tried changing Atmega signature from 14 to 0F with no results.
Then I thought, I could use -F in avrdude, so I downloaded Crossover(I'm on Mac), installed it and tried to bootload with Optiboot bootloader using this command line: (corresponding to my serial port and .hex file location)
Code:
avrdude -P /dev/tty.usbserial-A9WNJD1D -b 19200 -c avrisp -p m328p -v -e -U flash:w:/optiboot_atmega328.hex -U lock:w:0x0F:m -F
Everything seems fine until finish, where I got verification error:
Code:
avrdude: Version 5.11.1, compiled on Feb 12 2013 at 01:24:54
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "/usr/local/CrossPack-AVR-20130212/etc/avrdude.conf"
         User configuration file is "/Users/David/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/tty.usbserial-A9WNJD1D
         Using Programmer              : avrisp
         Overriding Baud Rate          : 19200
         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    20     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 AVR ISP
         Hardware Version: 2
         Firmware Version: 1.18
         Topcard         : Unknown
         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.06s

avrdude: Device signature = 0x000000
avrdude: Yikes!  Invalid device signature.
avrdude: Expected signature for ATMEGA328P is 1E 95 0F
avrdude: safemode: lfuse reads as 0
avrdude: safemode: hfuse reads as 0
avrdude: safemode: efuse reads as 0
avrdude: erasing chip
avrdude: reading input file "/optiboot_atmega328.hex"
avrdude: input file /optiboot_atmega328.hex auto detected as Intel Hex
avrdude: writing flash (32768 bytes):

Writing | ################################################## | 100% 0.64s

avrdude: 32768 bytes of flash written
avrdude: verifying flash memory against /optiboot_atmega328.hex:
avrdude: load data flash data from input file /optiboot_atmega328.hex:
avrdude: input file /optiboot_atmega328.hex auto detected as Intel Hex
avrdude: input file /optiboot_atmega328.hex contains 32768 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 24.72s

avrdude: verifying ...
avrdude: verification error, first mismatch at byte 0x0000
         0xff != 0x00
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.

I am unable to think of any other solutions to this problem. Maybe some of you can notice my mistake somewhere?

Thanks on your time,
David
2  Using Arduino / LEDs and Multiplexing / Re: WS2801 w/ 3LEDs on single chip on: June 04, 2013, 05:18:47 am
Ws2811 seems perfect(and simpler of ws2801). Thanks.
3  Using Arduino / LEDs and Multiplexing / Re: WS2801 w/ 3LEDs on single chip on: June 01, 2013, 11:11:41 am
Got that! But if I want to build strip myself... all of above I have to consider. And we are looking into how exactly, right?
4  Using Arduino / LEDs and Multiplexing / Re: WS2801 w/ 3LEDs on single chip on: June 01, 2013, 10:09:15 am
After reading your posts, here's what I know now:

- I have to stick with constant current. I first need to calculate resistors on feedback pins to do that. If I assume, I do not need more then 50mA on LED output pins, I can connect 12ohm resistors to feedback pins. Correct?
- I have to use transistor if I want more LEDs in series. Anyway, I have found piece of 12V LPD6803 strip in my components box. With multimeter, I have found out that connection of LEDs is like on schematic below. I also tested strip and it works fine. Could I connect LEDs in the same way to WS2801?

5  Using Arduino / LEDs and Multiplexing / Re: WS2801 w/ 3LEDs on single chip on: June 01, 2013, 04:49:17 am
Thanks on your answers! It isn't that I'm lazy(actually I printed and went through whole datasheet), I just not fully understand it. For example, what's difference in usage of constant voltage and current?

If feedback pins are on gnd, I will get constant voltage mode. Does that means output voltage will be same all the time and brightness of LEDs will be controlled by current?

About higher voltage, I understand usage of transistor, but I want to avoid it as Chinese manufacturers did. I don't understand how to do that, since max. output is 6V. How did they did it?
6  Using Arduino / LEDs and Multiplexing / WS2801 w/ 3LEDs on single chip on: May 31, 2013, 05:23:12 pm
Hello,

I want to control 3 RGB 5050 LEDs with single WS2801 chip on a 12V. I know I need to use 5v zener diode, resistor and a filter cap to make chip work with 12V supply. Although, few things concern me:
1) Should connect resistors to GFB/RFB/BFB (feedback) pins? As datasheet says, resistors on these pins are used to control current output. If I do not need control of output corrent, I can leave them float or I should connect them to gnd?
2) How to connect LEDs? What about limiting resistors on LEDs? I can't use resistors. As far I know, there are two options:
  a) Connect LEDs in series. I have seen this type of connection on LED pixels. There are 2caps, diode, resistor and extra 3 resistors as current limiting ones for LEDs. (e.g.)As I see from WS2801 datasheet, max. output voltage is 7V. If min. voltage for 5050 led is 2.8V, 3 leds in series give 8.4V and that exceeds 7V(red should work fine, right? 1.7V*3 = 5.1V). What are these limiting resistors for in that case?
  b) Connect single LEDs to chip's output. In that case, every LED would require each own 3 limiting resistors, resulting in 9 extra resistors which does not seem as great solution.

Basically, I'd love to hear corrections/suggestions on things I have wrote up there. I believe they are not all correct.

I have attached a schematic at my current stage of develop.

Thanks!
David

p.s.: here's link to datsheet
7  Using Arduino / General Electronics / Using Arduino with high voltages on: September 30, 2012, 05:56:13 am
Hello,

I need to use Arduino as a sensor for high voltage - 220V. Basically, when a high-voltage device turns on it turns 220V power. I need that 220V transform somehow to the 5V and send to the Arduino which will take care of rest.
So, I am looking for hardware solution. I have successfully did 5V->220V with Solid State Relay and some minor components, but now is opposite what I am looking for.
8  Using Arduino / LEDs and Multiplexing / Re: Strobe with Power LED - transistor suggestion on: August 06, 2012, 09:30:57 am
Hello focalist,

I just wanted to say thanks for all suggestions. RFD3055 + LM317 are great combination. I have got them running smoothly at first try. I will make some more strobes using those two, for sure. Thanks again
9  Using Arduino / LEDs and Multiplexing / Re: Strobe with Power LED - transistor suggestion on: July 25, 2012, 12:08:38 pm
Okay, this time is correct, right? I have used datasheet as reference this time smiley



So I shouldn't be worried about positive from digital and negative as output at mosfet's drain?

btw. what power circuit you are using for your power LEDs?
10  Using Arduino / LEDs and Multiplexing / Re: Strobe with Power LED - transistor suggestion on: July 25, 2012, 11:47:04 am
So, picture below'd be good setup? LED represent 10W power LED @ 12V, 900mA, resistor is 100-200ohm and MOSFET is RFD3055.
I'm worried because output on Arduino digital pin is positive, but DRAIN on mosfet is connected to negative.



11  Using Arduino / LEDs and Multiplexing / Re: Strobe with Power LED - transistor suggestion on: July 25, 2012, 05:44:36 am
Thanks everyone for their suggestions. I think I'll stick with focalist's advice with power MOSFET since they are easier for me to get.
Foaclist, could you share your wiring of MOSFETs with me?
12  Using Arduino / LEDs and Multiplexing / Strobe with Power LED - transistor suggestion on: July 22, 2012, 01:40:32 pm
Hello,

I have made a LED strobe with 10W power LED. My setup was(code can be seen below): on three digital outputs I have made Darlington's pairs with 2n2222 transistors. So, total 6pcs of those. And outputs of every transistor pair I have chained together. That was my positive going to LED. Negative was directly from gnd. Additional pot was connected to control rate of blinking. Power supply was 12V. Since I'm using Boarduino, I have added heat sink to power regulator.
Now, the problem. Since it wasn't for me, my friend putted it on a aluminium surface and short-circled controller. Atmega was burned, transistors also. Next time I'm gonna put it in a box, for sure, but I am looking for some higher power transistor that could raise my voltage+amps so I can use only one output for this. So, from 5V 40mA(that many digital output on Arduino gives) to 12V 700mA, for example. Even more wouldn't be bad.
I have succeeded it with 2n2222, but it's unreliable. What other transistor could I use?


Code:
//e-radionica.com

const int pot = 0;
const int led = 8;
const int led2 = 9;
const int led3 = 12;
int val = 0;
int val2;
 
void setup(){
 pinMode(led, OUTPUT);
 pinMode(led2, OUTPUT);
 pinMode(led3, OUTPUT);
}

void loop(){
val = analogRead(pot);
val2 = map(val, 1, 1023, 30, 280);
digitalWrite(led, HIGH);
digitalWrite(led2, HIGH);
digitalWrite(led3, HIGH);
delay(val2);
digitalWrite(led, LOW);
digitalWrite(led2, LOW);
digitalWrite(led3, LOW);
delay(val2);
}
13  Using Arduino / Programming Questions / Re: Adding switches on: April 05, 2012, 07:31:30 am
Yeah, it's obvious now. Thanks. I had debugged it using Serial Monitor
14  Using Arduino / Programming Questions / Re: Adding switches on: March 29, 2012, 07:25:38 am
Not sure what time zone are you into, but here it has just started smiley-razz

So, actually, I thought about suggestions how to write that part of program. Is my method good?
About the first switch, I've connected it to digital pin. Have I wrote it wrong?


And, once again, sorry for such a topic and answers, I'm beginner, remember yourself at these days smiley-wink
15  Using Arduino / Programming Questions / Re: Adding switches on: March 28, 2012, 05:08:11 pm
Any suggestions?
Pages: [1] 2