Show Posts
Pages: 1 ... 12 13 [14] 15 16 ... 26
196  Using Arduino / Project Guidance / Re: Reading 10+ LDR with Arduino on: April 03, 2013, 01:23:58 pm
ADD : Or the 4051 would be fine because after a bit of reading, I see the 16 inputs one needs 4 pins from my arduino.

of the 4 pins required, 3 of them are digital pins, OUTPUT, used to select which input in the 4051 (or 4050) is to be read. The other pin is one of the Analog inputs of the arduino that will receive the output of the 4051 for its selected input.
197  Development / Other Software Development / Re: Minimum Build on: April 03, 2013, 11:12:15 am
My intent on starting this thread was / is two fold. One, too (is that the correct to??) discover how to have just the needed code included in the final executable and two, to be sure that there are no hidden delays / waits anywhere.

I understand your concern, Ray, and I partially agree with it.

The size of the final executable is actually small, bacause the linker already does a very good job removing unused functions and the like. This avr-gcc is actually a great compiler.

If the size of the final binary is a problem, one solution to gain 2kb is to flash it to the Atmega using ICSP, thus overwriting the bootloader.

You have a point, however, when it comes to the slow manipulation of ports I/O. The digitaRead/Write calls are really slow, but we can choose not to use them in our sketches. We can do direct port manipulation without giving up everything else. The point, however, is deciding when to do it.




198  Using Arduino / LEDs and Multiplexing / Re: 8x8 LED matrix usage? on: April 03, 2013, 09:32:28 am
The reason I don't want to solder is that I screw it up (idk, maybe I was doing it wrong) and I can't reuse the parts. Thanks crossroads, but the problem that the space between matrix pin lines is as wide as the whole breadboard. I guess I'll just wait for my breadboard... What about power? I know, it's a stupid basic question, but anyway; does a led/matrix/buzzer/any device connected to arduino take whatever current it needs or what?

A LED matrix usually needs a lot more current than the Arduino can provide.

For example: depending on the color, a LED can take from 20mA to 40mA. Lets average that to 30mA.

If you decide to light up all the leds in your matrix, you'll need 64 x 30mA = 1,92A That is right: almost 2 amperes. that is more than enough to fry the voltage regulator in the Arduino board. That would be 10W of power the little voltage regulator of the arduino would have to dissipate.

What LED drivers (like the MAX7219) do is to PWM the rows or columns of LEDs to keep the current low. That is pretty clever of them. For us, it seems that all LEDs are lit, but the driver is PWMing them really quick.

One Arduino can power a LED matrix and the MAX7219 and still light up all the LEDs. That can't be done without the driver.

199  International / Portugues / Re: Sensor Indutivo de Proximidade on: April 03, 2013, 09:22:44 am
Qual a faixa de distância que você pretende trabalhar? A partir de que ponto você quer considerar um objeto próximo?

Qualquer sensor vai funcionar, mesmo que ele não seja incialmente feito para ser CMOS (5V), pode-se usar um amp-op para aumentar sua faixa operacional (se for baixa, por exemplo), ou um divisor de tensão caso a tensão gerada seja superior a 5V.

Nos 2 casos acima, o sensor não será alimentado pelo Arduino, tendo apenas o GND em comum com ele.
200  Using Arduino / Project Guidance / Re: Reading 10+ LDR with Arduino on: April 03, 2013, 09:18:54 am
Use a Mega

Too expensive, and the guy already has an Arduino (not Mega, I suppose)

My suggestion is to use a multiplexer IC, like the CD4051.

Personally, I like and use the MAX4617 (datasheet)
201  Using Arduino / Networking, Protocols, and Devices / Re: Recommend a shield for me on: April 03, 2013, 09:15:04 am
You need to give more details:

what is the distance requirements, or the area to be covered?

I understand the wi-fi shield will be kept, and you need another wireless shield so the arduino can talk to something else, right?
202  Using Arduino / Programming Questions / Re: Controlling PMW to limit voltage output on: April 03, 2013, 09:11:55 am
But you really ought to give more information- some of the boffins here will probably have some suggestions.

Another option is to use 2 resistors in a voltage divider configuration.

Another option is to use zener diodes. They come in 3.3, 3.6, 3.9, 4.3 and 4.7V, for 0.4W up to 5W (there are several other values, I am just liting those near your requirements).

If you want MORE than 4.5V, your only choices are zeners or voltage dividers.

for less than that, use schottky diodes (low voltage drop, usually below 0.5V ) or regular diodes (>=0.7V).


203  Using Arduino / Project Guidance / Re: Android tablet with Arduino UNO communication over USB - basic program on: April 03, 2013, 08:59:19 am
I understand that. Now i can see when i connect Arduino to Android tablet that arduino is powered and working (Flashing LED from program Blink). I guess that means that Tablet is working as Host. Now i shloud access normal Android USB API to send message over Serial port to Arduino. Where i can received it and turn LED on - off. Can this work?

All that says is that the tablet is powering the Arduino, nothing else. Since it is powered, it is running the sketch in it.

Please try and understand that 1 of the 2 conditions must be true:

- BOTH devices need to be HOST
- The tablet must have the Virtual COM Port driver installed.
204  Using Arduino / LEDs and Multiplexing / Re: 8x8 LED matrix usage? on: April 03, 2013, 08:41:21 am
Your best bet is to get a driver to interface with the LED Matrix. One excellent option - and the one I use -  is the MAX7219 (get the MAX7219CNG+, which comes in a PDIP package).  You can daisy-chain up to 10 MAX7219. The MAX7221 also works.

Both chips use only 3 pins in the Arduino and there are several libraries written for them (they are a basic SPI device).

Another option is to use 2  x 74HC595: one to drive the anodes and another to drive the cathodes.

Keep in mind that the pinouts for these LED matrices are crazy: nothing is what it seems. Don't assume they are in a certain order or that the anodes is one row and cathodes are another row. They are totally random and you have to map them beforehand, in order to plug them correctly to the driver.
205  Using Arduino / Networking, Protocols, and Devices / Re: Bluetooth module usage (JY-MCU) on: April 03, 2013, 08:36:09 am
I have one of those as well. It is simply a serial port "hidden" behind a bluetooth connection. You treat it as a serial device like any other in the arduino side.

To get it to work with Arduino, read this:

http://arduino.cc/forum/index.php?topic=101452.0

Use the SoftwareSerial library.

Now, in the Android side, you must pair (the JY-MCU device name is "linvor" and the default password is "0000"). there is an app called "Connection Terminal" that allows you to talk "serially" over the bluetooth connection.
206  Using Arduino / Project Guidance / Re: Android tablet with Arduino UNO communication over USB - basic program on: April 03, 2013, 08:32:15 am
Unless you have the USB shield (which turns the Uno into a host as well) or use the Arduino Leonardo or the Arduino MEGA ADK, you can't simply connect the 2 devices via USB and expect them to work.

Your PC doesn't seem the UNO's USB port. What it sees is a serial port that the UNO emulates through USB. That is called a "Virtual COM Port", and part of the magic is done through drivers. Unless you have those drivers written and compiled for Android (they have to be very specific to your android and kernel versions), what you want can't be done.
207  Using Arduino / Microcontrollers / Re: Flashing Fusebit Doctor .hex & .bin files on: April 02, 2013, 07:09:41 pm
Thank you! IT woked like a charm.

Just one last question:

Do I need to set any lockbits in the ATMEGA8 after setting the fuses and flashing the HEX and BIN file?
208  Using Arduino / Microcontrollers / Re: Flashing Fusebit Doctor .hex & .bin files on: April 02, 2013, 05:58:37 pm
Sorry for insisting so much in this, but how do I save the BIN (EEPROM) file to the ATMEGA8  ?
209  Using Arduino / Microcontrollers / Re: Tried to burn bootloader to arduino mega 2560. Now it don't respond anymore! on: April 02, 2013, 02:25:48 pm
what happens if you run this:


avrdude -c usbasp -P usb -p Atmega2560 -v -v

?
210  Development / Other Software Development / Re: Minimum Build on: April 02, 2013, 02:06:45 pm
Code:
void setup() { }

void loop () { }
Pages: 1 ... 12 13 [14] 15 16 ... 26