Show Posts
Pages: [1] 2
1  Using Arduino / Project Guidance / Re: Which recomended data output? on: March 27, 2013, 03:43:55 am
There are several ways of doing this. I would run a database. Send the data from the arduino to the PC/Webserver and get the PC/Webserver to log the data into the database. The data could be send, as you say, every 15 minuttes but altso on request. So lets say you are looking at the data. You could send a command to get the Arduino to send it every 5seconds while watching data (or something like that).

When you have the data in a database, there are so many ways of showing data and you can store a huge amount of data without being afraid of them getting corrupt on the SDCARD or something.
2  Using Arduino / Project Guidance / Re: Arduino Uno i/o Expansion Shield on: March 22, 2013, 08:27:51 am
Maybe something like: https://www.adafruit.com/products/593
3  Using Arduino / LEDs and Multiplexing / Re: controlling several LED's with one button on: March 18, 2013, 02:08:00 am
Its not me who wrote the topic. I just answered that it could be done with one button. I agree with the other aspects you said.

My bad.

The point stands though, I think the design needs work before starting to write any code.


I agree on that  smiley
4  Using Arduino / LEDs and Multiplexing / Re: controlling several LED's with one button on: March 15, 2013, 07:08:30 am
Press and hold x seconds = reset
Press manualy the game score again.
And so on..

Lots of opportunties with just one button. 

Sure...but you come in here and say "what should my code be?" then suddenly start changing the specifications? The people here aren't machines who'll write and rewrite code for you, they have lives of their own.

PS: That's a horrible user interface. Is there any reason why you can only have one button?


Its not me who wrote the topic. I just answered that it could be done with one button. I agree with the other aspects you said.
5  Using Arduino / LEDs and Multiplexing / Re: controlling several LED's with one button on: March 15, 2013, 06:38:02 am
Only one button?

In that case:

How will you reset the score for each game?

How will you correct a mistake if you press the button accidentally?



Press and hold x seconds = reset
Press manualy the game score again.
And so on..

Lots of opportunties with just one button. 
6  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 13, 2013, 04:37:16 am
I think i solved the problem.
Code:
       if (Serial.available() > 0) [b]{[/b]
                // read the incoming byte:
                incomingByte = Serial.read();
    >>>>>>>>>>>>    } <<<<<<<<<<<<<<<<<<<<<<
                // turn on/off LED
         if (incomingByte > 0) {
                 digitalWrite(13, HIGH);
                }
                else
                {
                  digitalWrite(13, LOW);
                }                  
        }

moved the bracket down and it all worked. 1.0.1.0.1.0.1.0


- thanks for the help guys. It is very apriciated!
7  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 12, 2013, 04:46:02 am
48 is hex 0x30 which is '0'
49 is hex 0x31 which is '1'

In ASCII that is. So if you have altered your sketch in some way those numbers are perfectly reasonable.

I didnt see this message, sorry. The reciving part had the case 1 case 2 code. That was the diffrence.
8  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 12, 2013, 03:49:00 am
No. I tried that "case '1' " code as suggested. That was when i got these in weird numbers in the serial monitor. Must be the cause, because i got "10101100101" with the code from first post.

The code in your first post (Arduino 1 - Sending unit) does not generate those numbers.

Can you post your current sending code please?

The code is exactly the same as in the first post. Thats why i am confused. I will upload the code again and the problem should be gone, cant see why this suddently happens when i am sending 1 and 0s.

At the moment i have the pin2 (my enable) on HIGH always. Maybe this is the problem, i will read your post and see if it explains the problems.

Cant say thanks to many times. So thanks again.
9  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 12, 2013, 03:14:04 am
I just hooked it up again and now i get these numbers "4948494849484949" in the serial monitor. Now i am lost.

Not when I just tested it. Is your first post still the current code?

No. I tried that "case '1' " code as suggested. That was when i got these in weird numbers in the serial monitor. Must be the cause, because i got "10101100101" with the code from first post.
10  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 12, 2013, 02:19:39 am
I just hooked it up again and now i get these numbers "4948494849484949" in the serial monitor. Now i am lost.

Crossroads: Thanks for the suggestions. Neither of the solutions did solve the problem.

PeterH: very bad drawings but hope you understand. https://www.dropbox.com/s/6h4j220xxasc1tr/Arduino-S-R.JPG

DI to TX(1) and RO to RX(0) on both sender and reciver.

*Update*

Forgot about the resistors. I got a resistor of 150ohm between A and B on both max485. Got a 560 resistor from the one end of A to GND and B to 5V. Altso 560 ohm.
11  Using Arduino / Programming Questions / Re: Send/Recive between 2 arduinos on: March 11, 2013, 08:46:00 am
Thanks for the quick answer.

I am getting some thing like "110101001" so somehow it doenst recive every time i send a 1 or 0.

The LED changes when it is 1 and 0. So no problem there. But the information recived is not correct with the information send.

**Update**

this is the exact serial monitor "010101001010110101001010010101" - The time between i get each number is difrent. Sometimes i get 0101 as i should. Other times there are a bigger delay.
12  Using Arduino / Programming Questions / Send/Recive between 2 arduinos on: March 11, 2013, 08:33:44 am
Hi

I am trying to send and recive serial communication with the help from 2 max485 and 2 arduinos.

There seems to be something wrong with the code (suprice?  smiley-wink), it doenst get every bit that i am sending. I am sending a "1" .. wait... then sending "0" and so on.

The LED on the reciving board turns on, and off. But doenst do anything for 2-3-4 pulses and then keeps on going like before - totaly random.

they are both powered on by USB from the same PC.

Arduino 1 - Sending unit

Code:
void setup(){
  Serial.begin(9600); //opens serial port, sets data rate to 9600 bps
  pinMode(2, OUTPUT);
}

void loop()
{
  digitalWrite(2, HIGH); // Set pin2 HIGH
  Serial.write(1); // send a byte with the value 1
 
  delay(2000);  // Wait 2sec
  Serial.write(0); // send a byte with the value 0
  delay(2000); // Wait 2sec
}

Arduino 2 - Reciving unit

Code:
int incomingByte = 0;   // for incoming serial data

void setup() {
        Serial.begin(9600);     // opens serial port, sets data rate to 9600 bps
        pinMode(13, OUTPUT);
}

void loop() {

        // send data only when you receive data:
        if (Serial.available() > 0) {
                // read the incoming byte:
                incomingByte = Serial.read();
        }
                // turn on/off LED
         if (incomingByte > 0) {
                 digitalWrite(13, HIGH);
                }
                else
                {
                  digitalWrite(13, LOW);
                }                 
        }

Any suggestions i have done wrong? Seems pretty basic, but cant find the mistake.
13  Using Arduino / Interfacing w/ Software on the Computer / Re: Communication with arduino and OPC/SCADA? on: February 15, 2013, 02:38:13 am
Thanks for the posts guys. I will look into it.

Looking forward to the driver VisBee and trying out your software. Could you post it here maybe when it is released?
14  Using Arduino / Sensors / Re: Differential Connections analog input on: February 06, 2013, 03:21:29 am
The voltage i am trying to measure is only 60mV. Forgot that part.
15  Using Arduino / Sensors / Re: Differential Connections analog input on: February 06, 2013, 03:20:27 am
The current is 50A. But in a later project could go all the way to 200A. Power supply is 24DC.

I dont have to measure it right now but the current can pass either way.
Pages: [1] 2