Show Posts
Pages: [1] 2
1  Forum 2005-2010 (read only) / Interfacing / Re: Serial.read input from processing on: January 23, 2007, 06:28:36 am
i need all 256 values
to make a string and send that could be a solution.
however i have no clue how to do this, but i try it.

thx
2  Forum 2005-2010 (read only) / Interfacing / Re: Serial.read input from processing on: January 22, 2007, 06:45:49 pm
well thx for that
so the idea i hade to solve my problem was wrong. or is there a was to transform the incoming bytes to integers?

i have to transfair 8 integers between 0 and 255 from processing to an array in arduino.
because arduino can not read arrays form the serial port, i thought that by adding 1000 to the first 2000 to the second and so on in processing and then check if the serial.read is between 1000 and 2000 for the first 2000 and 3000 for the second... i could fill my array in the correct order.

can you suggest me an other way to do that?
3  Forum 2005-2010 (read only) / Interfacing / Serial.read input from processing on: January 22, 2007, 02:29:49 pm
hello everyone

i have a problem with receiving data from processing.
this is how i send it:
Code:
 port = new Serial(this, Serial.list()[0], 9600);
  port.write(1086);
and this is how i receive it in the arduino code:
Code:
serbyte = Serial.read();
if (serbyte != -1) {
      dataArrayH[0] = serbyte-1000;
}

this works fine but i get a problem when i try to make this:
Code:
serbyte = Serial.read();
if (serbyte != -1) {
    if (serbyte >= 1000 && serbyte < 2000) {
       dataArrayH[0] = serbyte-1000;
    }
}

after searching the forum i think the problem is that the Serial.read has ASCII output
but i still didn't get my code to work.

could anyone axplain me why this: " if (serbyte >= 1000 && serbyte < 2000) {" is not working?

thx a lot
4  Forum 2005-2010 (read only) / Deutsch / Re: 24VDC Impuls on: November 24, 2010, 11:01:09 am
Ach ein Optokoppler! Wieso bin ich da nicht drauf gekommen...
Hatte sogar noch einen herumliege und alles funktioniert bestens.

Wieso das mit dem Transistor nicht funktioniert interessiert mich aber schon.
Wenn ich am Kollektor messe habe ich aber immer 24V. Da sind die ja schliesslich auch angeschlossen.
5  Forum 2005-2010 (read only) / Deutsch / Re: 24VDC Impuls on: November 24, 2010, 10:44:05 am


So hab ich mir das auch gedacht.
Bei RV habe ich 1k und bei RC 10k genommen.
Die 24V bzw. 0V sollte ich doch dann am Emitter messen können?

Und ja, die Grounds sind verbunden  smiley-wink
6  Forum 2005-2010 (read only) / Deutsch / 24VDC Impuls on: November 24, 2010, 09:23:02 am
Hallo

Ich habe eine Frage zu der Steuerung einer 7-Segment LED Anzeige.
Die Anzeige hat eine interne Logik und zählt von 0 bis 999999.

Um den Wehrt um 1 zu erhöhen muss man an einem Pin +24V anlegen.
Im Moment mache ich das mit einem Relais was auch funktioniert.

Leider ist das Relais etwas langsam und ich suche eine bessere Lösung.
Eigentlich müsste das doch mit einem einfachen NPN Transistor auch funktionieren.
Allerdings habe ich wohl etwas nicht ganz richtig verstanden.
An den Kollektor +24V, die Basis an den Arduino Pin und dann sollte doch am Emitter mehr als nur die 5V vom Ardunio ankommen wenn ich einen Impuls sende?

Messe ich nur irgendwie falsch?
Kann mir jemand zeigen wie die Schaltung richtig aussehen muss?

Danke im voraus.

7  Forum 2005-2010 (read only) / Troubleshooting / Re: Missing part on the Mini on: November 20, 2008, 06:43:01 am
thank you.
i'll check my local electronics store and thry to find one of those.

so long, broenni
8  Forum 2005-2010 (read only) / Troubleshooting / Missing part on the Mini on: November 12, 2008, 05:19:26 am
Hello

My Arduino Mini is missing somthing on its bottom side.
I suspect it to be some kind of capacitor.
Can anyone tell me what exactly is missing?
I would like to buy the part and and fix that.

Here is a photo
http://img233.imageshack.us/my.php?image=arduinominibh4.jpg

cheers broenni
9  Forum 2005-2010 (read only) / Development / Re:  Burning the Bootloader without  AVR-Writer on: November 06, 2008, 11:36:14 am
Hello everyone

I really liked this bootloader burnig approach and I instantly had to try it. I used to burn my ATmegas with a STK500 which was always some kind of a hassle.

It all works great, even with the old ATmega8 chips.
I just fixed 5 broken Arduinos here at my university!

It would be great if this could be included in the Arduino Software.
thanks.

so long, broenni
10  Forum 2005-2010 (read only) / Development / Re: Good source of components in Switzerland? on: November 06, 2008, 09:57:24 am
Hi Robert

Here are some links to Swiss stores:

At Distrelec you can order online and you will get the parts by the next day. https://www.distrelec.ch/ishopWebFront/home.do?language=de&shop=CH


Pusterla in Zürich is a nice small and really messy shop, but they have everything the average hobbyist needs. http://www.pusterla.ch/

Grieder is a shop in Basel. http://www.griederbauteile.ch/

There are many more.
11  Forum 2005-2010 (read only) / Interfacing / Re: ULN2003A alternative on: November 25, 2010, 09:15:58 am
In parallel! Thats a great idea. 1000mA is more then enough.
So I can just solder one on top of the other and use the same socket.

thx
12  Forum 2005-2010 (read only) / Interfacing / ULN2003A alternative on: November 25, 2010, 07:01:12 am
Hallo

I recently did a project where I used some ULN200A darlington drivers to control LED stripes.
This worked well. I now made some changes to the projects and the LED stripes got a little longer. That leads to the Problem that I'm now slightly over 500mA.

So I'm looking for an alternative that if possible would fit where the ULN2003A was.
Any ideas?

I read in the data sheet of the LED stripe which currently run @ 24VDC that they support up to 25VDC. If I change that to 25, would it bring down the mA?
13  Forum 2005-2010 (read only) / Interfacing / Re:  atmega standalone circuit on: August 16, 2010, 03:04:58 pm
Thanks for the advice.

While working on an other project that also involved audio I recalled that it might be a good idea to get the ground of the audio and the Sharp as far from each other as possible.
So I placed the sensor right next to where the power enters my breadboard and the noise was gone.

I also changed the caps for the 7805. I now use a 100n parallel witch a 100u on the input and a 100u on the output. I let it run for some time and it didn't get very hot.
14  Forum 2005-2010 (read only) / Interfacing / atmega standalone circuit on: August 13, 2010, 05:26:36 pm
Hello

I'm working on a small project where I use stand alone ATmega 168 for some audio and LED fading.
It will be a small pcb that runs on 12v and has a audio line input and output.
A Sharp GP2Y0A02YK infrared distance sensor will be used to control audio volume and LED brightness.
It all works quite well except for the things.

As soon as i plug in the Sharp sensor I get a high pitch sound on the speaker.
I'm not sure why this happens but I think  I need to separate the audio from the power supply.

The second issue is that my 5v power regulator is getting really hot.
Even if the circuit is only drawing about 100mA.

Here is the circuit diagram. Any suggestions?

15  Forum 2005-2010 (read only) / Interfacing / RS232 projector on: May 11, 2010, 01:00:56 pm
Hi there

I have a question regarding the RS232 communication with a projector.
The Arduino is supposed to send a command to turn the projector on.
I use a Sparkfun RS232 Shifter Board Kit (PRT-00133) to turn TTL into RS232.
The shifter board TX and RX are connected to pin 0 and 1 of the Arduino.
It actually works fine with a Panasonic PT-D5700E, but not with the Sanyo PLC TWC500L

This is the Arduino code for the Panasonic PT-D5700E that is working:
Code:
Serial.print(0x02, BYTE); // STX
Serial.print(0x41, BYTE); // A
Serial.print(0x44, BYTE); // D
Serial.print(0x5A, BYTE); // Z
Serial.print(0x5A, BYTE); // Z
Serial.print(0x3B, BYTE); // ;
Serial.print(0x50, BYTE); // P
Serial.print(0x4F, BYTE); // O
Serial.print(0x4E, BYTE); // N
Serial.print(0x03, BYTE); // ETX

I can also to this directly from processing with an USB to serial adapter.
Then it looks like this:
Code:
myPort.write(2);
myPort.write("ADZZ;PON");
myPort.write(3);

Now the part where i'm stuck.

For the Sanyo PLC TWTC500L it works fine from Processing
Code:
myPort.write("C00");
myPort.write(13);

But it doesn't work with the Arduino:
Code:
Serial.print(0x43, BYTE); // C
Serial.print(0x30, BYTE); // 0
Serial.print(0x30, BYTE); // 0
Serial.print(0x0D, BYTE); // CR

What am I missing here?
I think the projector is not understand the command at all.
It should give a answer when it receives something and that would make the RX LED on the Arduino blink but it doesn't.

Here are the serial command specifications for both projectors:
Sanyo PLC-WTC500
Panasonic PT-D5700


Any help is welcome.

So long,
Roland
Pages: [1] 2