Show Posts
Pages: 1 2 [3] 4 5 ... 314
31  Using Arduino / Networking, Protocols, and Devices / Re: Explaining a-, synchronous, SPI, I2C, TWI, 2/3 wire interface, Serial TX/RX on: April 16, 2014, 06:22:05 am
Quote
I2C is asynchronous as there is only one data line. You cannot transmit and receive data at the same time like you can with the SPI & UART interfaces.

Synchronous is not the same as duplex or bidirectional. I2C is synchronous because the clock signal synchronizes the two communication partners but it's not fullduplex, it's a synchronous halfduplex communication.
32  Using Arduino / Project Guidance / Re: Multiple LEDs with analogue output on: April 16, 2014, 04:16:12 am
Quote
Here is the sort of thing but instead of on/off control I'd like to set the voltage.  I'd guess some sort of programmable chips exist but I'd prefer a solution that is wholly controlled from the Arduino's pins.

The Arduino (at least the basic types as the UNO) don't have an analog output where you can set a voltage. The "emulate" such an analog output using PWM (pulse width modulation) which means the turn a digital output on for some time and then off again for some time in quite a fast manner (several hundred times a second). That's a perfect way to dim LEDs because the human eye won't notice the fast on/off switching and get fooled to see a dimmed brightness value.

What kind of Arduino are you using? What LED devices are you talking about (links)? Do you want to dim them all together or each individually? You won't be able to control all devices with just the Arduino itself, you'll need some external hardware to provide enough power to the LED devices.
33  Using Arduino / Networking, Protocols, and Devices / Re: Explaining a-, synchronous, SPI, I2C, TWI, 2/3 wire interface, Serial TX/RX on: April 16, 2014, 04:08:10 am
Quote
The address can be found out with a utility code.

Can be found is correct, but usually you look that up in the datasheet.
I2C has the additional advantage that by design you're able to connect devices with different voltage levels (5V and 3V3) to the same bus without destroying them because the lines are pulled up by resistors and not actively by the master or slave devices.

Quote
COM port style TX/RX line pins that run at 5V while PC com port runs at 12V.

PC (better RS232) has +/- 3-12V, the negative levels are usually the bigger problem than the voltage but you should never connect TTL UART devices directly to RS232, that's correct. This interface is asynchronous which means that the timing is more critical. UART allows two way communication (bidirectional) with just two wires (they're usually counted without the power wires Vcc and GND). Using chips as the MAX485 you can use these UART ports to communicate with RS-485 devices (used in ModBux for example).

I2C has two defined speeds (100kHz and 400kHz), SPI usually is much faster with speeds in the MHz range while the UART interface usually is the slowest variant with common speeds in the 1-100kHz range (although i can go higher up to some MHz).
34  Using Arduino / Networking, Protocols, and Devices / Re: Is it possible to communicate the smartphone (Android) and the Zigbee module on: April 16, 2014, 03:50:06 am
Is your smartphone able to be a USB host (most are not), what ZigBee module are you using (the usually don't have USB interfaces)? How is that question related to the Arduino platform?
35  Using Arduino / Networking, Protocols, and Devices / Re: Wire not working on Due? on: April 16, 2014, 03:47:29 am
Provide a wiring diagram. I'd guess that the problem is on the hardware side but that's currently just a wild guess.
36  Using Arduino / Networking, Protocols, and Devices / Re: Testing Ethernet shield example on: April 16, 2014, 03:42:09 am
You setup your shield with IP 192.168.7.100:

Code:
IPAddress ip(192,168,7,100);

but try to access it with IP 192.168.7.12

Why are you trying to access another IP than the one you applied to the shield?
37  International / Deutsch / Re: Ausgänge über .txt File von SD Card steuern on: April 16, 2014, 03:36:55 am
Wenn Du diesen Teil:

Code:
    while (Text.available()) {
      Serial.write(Text.read());
      digitalWrite(LED_R, HIGH);
      delay(100);
      digitalWrite(LED_R, LOW);
      delay(100);
     
    }

durch:

Code:
    uint8_t pin = 2;
    while (Text.available()) {
      uint8_t read_byte = Text.read();
      Serial.write(read_byte);
      if (read_byte < '0' || read_byte > '1') continue;
      if (pin < 20) {
        digitalWrite(pin++, read_byte == '1' ? HIGH : LOW);
      }
      digitalWrite(LED_R, HIGH);
      delay(100);
      digitalWrite(LED_R, LOW);
      delay(100);
    }

ersetzt, werden die ersten 18 Bytes im Textfile, die entweder '0' oder '1' sind, den entsprechenden Pin (ab 2 aufwärts, ab 14 sind es beim UNO die analogen Pins) setzen. Was natürlich noch fehlt, ist der pinMode()-Aufruf für alle Pins, damit sie Ausgänge werden.
38  Using Arduino / Project Guidance / Re: Token detection. on: April 16, 2014, 03:26:31 am
Quote
RFID seems like a too expensive solution.

http://imall.iteadstudio.com/wireless/rfid/im120618002.html

Less than 6 bucks is too expensive? Or is it the 50 cents for the tag? In this case you definitely have to define your budget and/or the number of tokens you have.

You're hiding most of the information from us but want some help finding a technology for your project. Do you want to waste our time?
39  International / Deutsch / Re: Ausgänge über .txt File von SD Card steuern on: April 16, 2014, 02:41:24 am
Der entsprechende Code-Block ist sehr einfach:

Code:
if (read_byte == '1') {
  digitalWrite(port, HIGH);
} else {
  digitalWrite(port, LOW);
}

Darauf wärst Du bestimmt auch gekommen. Wahrscheinlich liegt das Problem woanders, aber um das festzustellen, sollten wir Deinen aktuellen Code sehen.
40  International / Deutsch / Re: WIFI+UDP+NTP keine Verbindung on: April 16, 2014, 02:37:08 am
Quote
1. Frage : nein sehe ich garnicht von udp Protokoll

Siehst Du denn dort wenigstens mindestens ein Paket, das den Zielport 123 hat? Wurde das mit TCP geschickt?

Quote
3. Frage:  Udp.endPacket()  liefert an seriellen Schnittstelle den Wert "0"

Das heisst zumindest, dass das WiFi-Shield auch der Meinung ist, dass das Paket nicht verschickt wurde. Deshalb mal eine grundlegende Frage: hast Du mal versucht, mit dem WiFi-Shield einen Server per TCP zu erreichen, also z.B. eine Webseite abzurufen? Damit wäre zumindest grundsätzlich geklärt, ob die Netzwerkparameter richtig eingestellt wurden.
41  Using Arduino / Project Guidance / Re: Token detection. on: April 15, 2014, 12:06:11 pm
RFID?

For more help provide more details about your project. Do you just have to know that a specific token is on that surface or do you have to know where it is? How do we have to imagine these tokens?
42  Using Arduino / Sensors / Re: Wiring an analog input to an existing circuit on: April 15, 2014, 11:58:35 am
Quote
Goal:  I would like to, if possible, attach an analog input into the existing circuit to be able to graph/write/whatever. record the changes over time.

Questions:
1. Is this feasible? 

No, because there's probably no point in the device where you can get that analog value.

Quote
2. Is there anything in general that I would try to identify to connect to the right location?

Without having the schematics of that device I would rather try to catch the display signals and interpret them than to search for an analog output of the wanted values.
43  Using Arduino / Project Guidance / Re: How can i connect Laser Diode to Arduino? on: April 15, 2014, 11:46:32 am
What type of laser diode? In what package? That's about the same as asking "how do I open a computer case?".
44  Using Arduino / Project Guidance / Re: Possible problem using DS1307 RTC while using emonTx Arduino Shield on: April 15, 2014, 11:45:07 am
Either remap the shields A4 pin to the A0 pin or use another Arduino type (Leonardo or Mega2560 are candidates) where the I2C pins are not mapped to the analog inputs.
45  Using Arduino / Programming Questions / Re: Reversing value. on: April 15, 2014, 11:39:02 am
Change this line:

Code:
    delayMicroseconds((analogRead(0) * 6) + 1000);

into:

Code:
    delayMicroseconds(7138 - (analogRead(0) * 6));

This makes the phase cutting shorter as the voltage increases.
Pages: 1 2 [3] 4 5 ... 314