Show Posts
Pages: [1] 2 3
1  Using Arduino / Microcontrollers / Re: Little project based on Arduino on: August 23, 2012, 02:54:27 pm
Thanks you all for your great - and quick - help!
That was really appreciated!
It appears simplier than expected, I think I'm going to follow the Attiny way.
Just one more question. Is it possible to add Ethernet/Wifi capability in a similar simple way?
2  Using Arduino / Microcontrollers / Little project based on Arduino on: August 23, 2012, 01:03:09 pm
Hello,
I'm thinking about making a project with only one I/O connection (or maybe a couple).
The point is, using an Arduino board would be a waste of pins/energy...wouldn't it?
Is there an easy way to use the power of Arduino (IDE, bootloader(?) etc...) to make this project?
Is there an article/tutorial where to start?
Keep in mind that I'm not familiar with such things butI have some basic knowledge of electronics.

Thanks in advance.

Gianmarco
3  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 29, 2011, 05:39:47 am
Thanks you all  smiley-razz
The REAL problem is that all worked WELL...I thought:
I need an Ethernet Shield to connect to the Arduino (as the Ethernet Board has no USB interface).
The Et. board would have the same possibility as the shield, plus some more functions...

At this point I don't remember how i connected this two boards, but they worked just great  smiley-confuse
4  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 28, 2011, 06:48:04 pm
Hello,
I've just taken a photo of my environment. I have an UNO and an Ethernet Board (Note: NOT Shield, but the Board, with PoE module on it).

I'm waiting for the FTDI cable to come, so I connected the two boards together, in order to upload sketches via USB.

I've basically connected pin 10/13 of UNO to Ethernet's one. Than

5v--->5v
GND--->GND
Reset--->Reset

Note: I've made a project a few days ago to open my gate (connecting my remote control to a line). All worked well until 3 days ago. Unfortunately I can't remember if I made some changes and if Yes, where....  smiley-confuse smiley-confuse smiley-confuse

Here is a picture that may help (at least that's what i hope). Thanks again Nick  smiley-mr-green

5  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 28, 2011, 04:16:51 pm
Hello,
thanks again for answering. I tried that too with no luck.
Commented the line, started the sketch. Result? All works fine until I open the Serial Monitor... smiley-confuse smiley-confuse smiley-confuse
6  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 28, 2011, 01:39:39 pm
Thanks Nick too!

Here is my code:

Code:
/*
  Web Server
 
 A simple web server that shows the value of the analog input pins.
 using an Arduino Wiznet Ethernet shield.
 
 Circuit:
 * Ethernet shield attached to pins 10, 11, 12, 13
 * Analog inputs attached to pins A0 through A5 (optional)
 
 created 18 Dec 2009
 by David A. Mellis
 modified 4 Sep 2010
 by Tom Igoe
 
 */

#include <SPI.h>
#include <Ethernet.h>

// Enter a MAC address and IP address for your controller below.
// The IP address will be dependent on your local network:
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
IPAddress ip(192,168,1, 11);

// Initialize the Ethernet server library
// with the IP address and port you want to use
// (port 80 is default for HTTP):
EthernetServer server(80);

void setup()
{
   Serial.begin(9600);
  // start the Ethernet connection and the server:
  Ethernet.begin(mac, ip);
  server.begin();
  Serial.println("Entered setup");
}

void loop()
{
    Serial.println("Looping...");
  // listen for incoming clients
  EthernetClient client = server.available();
  if (client) {
    // an http request ends with a blank line
    boolean currentLineIsBlank = true;
    while (client.connected()) {
      if (client.available()) {
        char c = client.read();
        // if you've gotten to the end of the line (received a newline
        // character) and the line is blank, the http request has ended,
        // so you can send a reply
        if (c == '\n' && currentLineIsBlank) {
          // send a standard http response header
          client.println("HTTP/1.1 200 OK");
          client.println("Content-Type: text/html");
          client.println();

          // output the value of each analog input pin
          for (int analogChannel = 0; analogChannel < 6; analogChannel++) {
            client.print("analog input ");
            client.print(analogChannel);
            client.print(" is ");
            client.print(analogRead(analogChannel));
            client.println("<br />");
          }
          break;
        }
        if (c == '\n') {
          // you're starting a new line
          currentLineIsBlank = true;
        }
        else if (c != '\r') {
          // you've gotten a character on the current line
          currentLineIsBlank = false;
        }
      }
    }
    // give the web browser time to receive the data
    delay(1);
    // close the connection:
    client.stop();
  }
}

It works PERFECTLY. However when I open the SM it bloks all. The SM is showing:
Entered setup
Looping...
Looping...
...
as expected. But the page does not load anymore. Any idea?  smiley-mad smiley-mad smiley-mad
7  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 27, 2011, 06:40:29 pm
Here is the code:

Code:
/*
  Web Server
 
 A simple web server that shows the value of the analog input pins.
 using an Arduino Wiznet Ethernet shield.
 
 Circuit:
 * Ethernet shield attached to pins 10, 11, 12, 13
 * Analog inputs attached to pins A0 through A5 (optional)
 
 created 18 Dec 2009
 by David A. Mellis
 modified 4 Sep 2010
 by Tom Igoe
 
 */

#include <SPI.h>
#include <Ethernet.h>

// Enter a MAC address and IP address for your controller below.
// The IP address will be dependent on your local network:
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
IPAddress ip(192,168,1, 11);

// Initialize the Ethernet server library
// with the IP address and port you want to use
// (port 80 is default for HTTP):
EthernetServer server(80);

void setup()
{
  Serial.println("This is setup");
  // start the Ethernet connection and the server:
  Ethernet.begin(mac, ip);
  server.begin();
 // Serial.begin(9600);
}

void loop()
{
    Serial.println("Looping!");
  // listen for incoming clients
  EthernetClient client = server.available();
  if (client) {
    // an http request ends with a blank line
    boolean currentLineIsBlank = true;
    while (client.connected()) {
      if (client.available()) {
        char c = client.read();
        // if you've gotten to the end of the line (received a newline
        // character) and the line is blank, the http request has ended,
        // so you can send a reply
        if (c == '\n' && currentLineIsBlank) {
          // send a standard http response header
          client.println("HTTP/1.1 200 OK");
          client.println("Content-Type: text/html");
          client.println();

          // output the value of each analog input pin
          for (int analogChannel = 0; analogChannel < 6; analogChannel++) {
            client.print("analog input ");
            client.print(analogChannel);
            client.print(" is ");
            client.print(analogRead(analogChannel));
            client.println("<br />");
          }
          break;
        }
        if (c == '\n') {
          // you're starting a new line
          currentLineIsBlank = true;
        }
        else if (c != '\r') {
          // you've gotten a character on the current line
          currentLineIsBlank = false;
        }
      }
    }
    // give the web browser time to receive the data
    delay(1);
    // close the connection:
    client.stop();
  }
}

Works fine for me, until I open the Serial Monitor.
No output from it and no more page loading.
8  Using Arduino / Programming Questions / Re: I'm going crazy with this: serial monitor blocks my sketch! on: December 27, 2011, 06:20:55 pm
Hello,
that's new to me.

I'm using IDE v. 1.0 on MAC OSX.

I've completed my project two days ago and is stopped working. I've tried the most simple Ethernet Webserver and it works, but only if I don't open the serial monitor.

Is the reset a problem for that sketch?

Thanks
9  Using Arduino / Programming Questions / I'm going crazy with this: serial monitor blocks my sketch! on: December 27, 2011, 06:08:55 pm
Hello,
I'm looking for some good guy here around who can help me.

I'm running with no problem the Example sketch called "WebServer"

http://arduino.cc/en/Tutorial/WebServer

This sketch works well for me, until I open the Serial Monitor. This blocks the page loading!
The browser waits for some time and then... It display an error that in english would be something like "Cannot reach the page".

Now, that is REALLY strange, isn't it? smiley-mad

Can, please, someone help? Thanks
10  Using Arduino / Programming Questions / Float decimal precision...Why only two digits? on: December 24, 2011, 01:59:08 pm
Hello,

here is my code:

Code:
void setup()
{
  Serial.begin(9600);
 
  float value = 28.123456;

  Serial.println(value);
 
   
}

void loop()
{
 

 
}
 

I always get "28.12" as answer. Is there a workaround to get some more decimal precision? I would need 6 digital digits... smiley-zipper
11  Using Arduino / Installation & Troubleshooting / Re: Arduino Ethernet on: December 23, 2011, 08:29:34 pm
I temporary solved that issue by connecting pin 10, 11, 12 and 13 from UNO to Ethernet and by powering the last one.

I'm gonna buy the USB2Serial adapter. Thanks  smiley-razz
12  Using Arduino / Installation & Troubleshooting / Re: Arduino Ethernet on: December 23, 2011, 04:05:26 pm
anyway it's quite strange. I bought the shield and i cannot use it without additional stuff. Is that possible or am I missing something? smiley-confuse
13  Using Arduino / Installation & Troubleshooting / Re: Arduino Ethernet on: December 23, 2011, 02:30:28 pm
No problem at all...

is there a chance to use the ethernet board as a shield for UNO?
14  Using Arduino / Installation & Troubleshooting / Re: Arduino Ethernet on: December 23, 2011, 06:37:29 am
Thanks for answering!
Ok, but mine isn't a shield! It is a board smiley arduino Ethernet smiley
15  Using Arduino / Installation & Troubleshooting / Arduino Ethernet on: December 22, 2011, 08:48:43 pm
Hello,
I just bought Arduino Ethernet with PoE and I just discovered that it has no USB port.
What is the best way to upload to the Arduino a sketch? I also have UNO  smiley-razz
Pages: [1] 2 3