Show Posts
Pages: 1 2 [3] 4 5 ... 18
31  Using Arduino / General Electronics / Re: MAX232 and FTDI and Arduino on: March 22, 2012, 03:13:12 pm
hmm ok so is their a terminal program where I can choose baud rates that are not exact as the known one?
But why is the Serial to USB cable working?

Thx
Andy
32  Using Arduino / General Electronics / Re: MAX232 and FTDI and Arduino on: March 22, 2012, 02:27:43 pm
The buffer those fill up quite fast in 3 seconds 128byte are full however
since it does not work with the Sparkfun Break out board it must be something different....

Thx
Andy
33  Using Arduino / General Electronics / MAX232 and FTDI and Arduino on: March 22, 2012, 01:55:15 pm
Hy

I got a problem with a MAX232.
So I got a circuit that is decoding a FSK signal and converting it with a MAX232 so that I can read
it with a Serial Monitor Programm on a PC.
For my Laptop I use a Serial to USB cable to hook it up to an USB port:
http://www.frontierpc.com/cables-adapters/connector-cables/misc/products/iogear-usb-pda-serial-adapter-guc232a-10033386.html
This works without a problem.

So now I would like to use the Signal coming from the MAX232 directly with an Arduino. This should be possible by just connection it
to the UART (Pin 0) to receive the Signal. However I do receive something with my Arduino UNO but with the Arduino Mega the port is silent.
With the UNO a lot (all) of the bytes get lost or are corrupted so you can't read the signal it is strange.

The same is true when I use a FTDI Basic Breakout board from Sparkfun. I can read the Signal with my computer but it is not usable for further decoding.

So why is this do I need some filters? Why is it working with the Serial to USB cable?

Thx for your Help,
Andy
34  International / Deutsch / Re: Sensor an der I2C Schnittstelle on: March 22, 2012, 02:55:24 am
uuppps Ich *!*?# ok so ich habs smiley

Code:
byte decToBcd(byte val){
  return ( (val/10*16) + (val%10) );
}

byte bcdToDec(byte val){
  return ( (val/16*10) + (val%16) );
}


void adresseAendern(){
  //Sensor starten
  digitalWrite(13, HIGH);
  delay(2);

  //in Command Mode
  Wire.beginTransmission(adress);
  Wire.send(0xA0);
  Wire.send(0x00);
  Wire.send(0x00);
  Wire.endTransmission();
  delay(100);

  //Adress anfragen
  Wire.beginTransmission(adress);
  Wire.send(0x1C);
  Wire.send(0x00);
  Wire.send(0x00);
  Wire.endTransmission();
  delay(100);

  //Adresse auslesen
  Wire.requestFrom(adress, 3);
  if(Wire.available() > 2){
    byte b1 = bcdToDec(Wire.receive());
    byte b2 = bcdToDec(Wire.receive());
    byte b3 = bcdToDec(Wire.receive());
    /*
    Serial.println((b1), DEC);
     Serial.println((b2), DEC);
     Serial.println((b3), DEC);
     */
    int i2cAdress = b2 << 8 | b3;
    Serial.println((i2cAdress));
  }
  

  //Adress neu setzten
  Wire.beginTransmission(adress);
  Wire.send(0x5C);
  Wire.send(0x00);
  Wire.send(adressNew);
  Wire.endTransmission();
  delay(100);


  //normal Mode
  digitalWrite(13, LOW);
  delay(100);

}
35  International / Deutsch / Re: Sensor an der I2C Schnittstelle on: March 22, 2012, 02:43:34 am
Das ist eine gute Idee, hat irgendwie auch funktioniert denn im Command Mode kann man ja keine Feuchte und Temp auslesen was mir zeigt dass ich im Command Mode drinn bin aber das Auslesen klappt nicht sprich ich verstehe nicht wie ich nun an die Adresse komme.
Hier wäre der Code den ich verwende...

Code:
//Sensor starten
  digitalWrite(13, HIGH);
  delay(2);

  //in Command Mode
  Wire.beginTransmission(adress);
  Wire.send(0xA0);
  Wire.send(0x00);
  Wire.send(0x00);
  Wire.endTransmission();
  delay(100);

  //Adress anfragen
  Wire.beginTransmission(adress);
  Wire.send(0x1C);
  Wire.send(0x00);
  Wire.send(0x00);
  Wire.endTransmission();
  delay(100);

  //Adresse auslesen
  Wire.requestFrom(adress, 3);
  if(Wire.available() > 2){
    int b1 = Wire.receive();
    int b2 = Wire.receive();
    int b3 = Wire.receive();
    Serial.println((b1));
    Serial.println((b2));
    Serial.println((b3));

    int i2cAdress = b2 << 8 | b3;
    Serial.println((i2cAdress));
  }
 
36  International / Deutsch / Re: Sensor an der I2C Schnittstelle on: March 21, 2012, 03:52:41 pm
oops habe das Falsche Dokument hochgeladen dort steht es nicht drinn... sorry

Es ist ein HYT 271 (DIGITALER FEUCHTESENSOR)

37  International / Deutsch / Re: Sensor an der I2C Schnittstelle on: March 21, 2012, 03:23:07 pm
Hmm naja ich weiss im Moment nicht wie ich den Snesor reseten kann um dann direkt in den Command mode zu gelangen....
Kann ein Reset auch per Command genügen denn anders kann ich es mir nich vorstellen....
38  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 01:41:17 pm
I got a document where it is described how to change the address however I can't managed it to get
work....
Maybee you can help me since you are somehow familiar with the I2C interface and the HYR Sensors.

here is the link:
www.ibrutech.ch/Change_Address.pdf

Andy
39  International / Deutsch / Re: Sensor an der I2C Schnittstelle on: March 21, 2012, 12:56:58 pm
Hallo GekoCH,

zu wenig Input, wie bitte soll Dir jemand helfen können? Wie wäre es wenigstens einmal mit der Bezeichnung des Sensors und/oder dem Datenblatt?


Habe das Dokument doch angefügt, es sit wohl nur sichtbar wenn ihr eingeloggt seit.

Gruss
40  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 11:00:21 am
pls google since I don't know where you're from in europe you get it from every electronic store...
41  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 10:47:35 am
just take any HYT they 221 is an old one so use the 271.
 I'm currently using this one too.

42  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 10:39:24 am
ok found the problem. It does work with Arduino v1.
In 0022 you have to cahnge wire.read to wire.receive and wire.write to wire.send and then it does work smiley

However I got another question.
Does someone know how to change the Adress of one sensor?

Thx
Andy
43  International / Deutsch / Sensor an der I2C Schnittstelle on: March 21, 2012, 10:14:10 am
Hallo zusammen

Wollte die ID aus einem Sensor auslesen habe dafür ein Datasheet gekriegt wo drin steht wie es gehen soll
doch irgendwie begreiffe ich das nicht...
Kann mir jemand helfen wie ich die Command richtig an den Sensor sende damit der auch mir antwortet.

Danke das wäre super,
Andi
44  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 08:06:21 am
thx but hmm for which version of the Arduino is this since for my Arduino IDE 0022 it doesn't work...

HYT221.cpp: In member function 'uint8_t HYT221::read()':
HYT221.cpp:33: error: 'class TwoWire' has no member named 'write'

andy
45  Using Arduino / Sensors / Re: HYT 221 from Hygrosens Instruments on: March 21, 2012, 01:02:35 am
I saw this code but it is not working, it is printing always the same values messured at the first time.
So the Code from above does work better.

Andy
Pages: 1 2 [3] 4 5 ... 18