See below my RN XV config and my sketche WiFly Ver 2.30, 10-26-2011 on RN-171 Beacon=100 Probe=5 Reboot=0 OPEN=*OPEN* CLOSE=*CLOS* REMOTE=*HELLO* FlushSize=64 MatchChar=0 FlushTimer=10 IdleTimer=0 CmdChar=$ IF=UP DHCP=ON IP=MY IP:2000 NM=255.255.255.0 GW=my GW HOST=216.52.233.122:80 PROTO=TCP,HTTP, MTU=1524 FLAGS=0x7 TCPMODE=0x0 BACKUP=0.0.0.0 DNS=192.168.1.1 Name=api.pachube.com Backup=backup2 FTP=208.109.78.34:21 File=wifly-EZX.img User=roving Pass=MY PWD Dir=public Timeout=40 FTP_mode=0x0 SSID=MY SSID Chan=10 ExtAnt=0 Join=1 Auth=WPA1 Mask=0x1fff Rate=12, 24 Mb Linkmon=0 Passphrase=MY PASSPHRASE TxPower=0 SleepTmr=0 WakeTmr=0 Trigger=0x1 Autoconn=0 IoFunc=0x0 IoMask=0x21f0 IoValu=0x0 DebugReg=0x0 PrintLvl=0x1 TimeEna=0 TIMEADR=129.6.15.28:123 Zone=7 Baudrate=9600 Flow=0x0 Mode=0x2 JoinTmr=1000 Replace=0x24 DeviceId=WiFly-EZX Password= Format=0x0 Signal=0 Average=5 BCAST=255.255.255.255:55555 Interval=0x7 Sensor=0x0 SensePwr=0x0 <2.30> ************* Dedicated sketche for Pachube and Wifly board // WiFly Pachube Client // Send data to a Pachube Feed // (Based on Ethernet's WebClient Example) // (based upon Sparkfun WiFly Web Client example) // Sparkfun WiFly library updated and can be found here // https://github.com/jcrouchley/WiFly-Shield // Built using Arduino IDE V0.22 #include "WiFly.h" // using NewSoftSerial V11 beta // downloaded from here http://arduiniana.org/2011/01/newsoftserial-11-beta/ // this will be included as Software Serial in Arduino IDE 1.0 #include // Wifly RN-XV (XBee shaped) module connected // WiFly Tx to pin 2 (SoftSerial Rx) // WiFly Rx to pin 3 (SoftSerial Tx) SoftwareSerial mySerial(2, 3); // Edit credentials.h to provide your own credentials #include "Credentials.h" // Using Pachube API V2 WiFlyClient client("api.pachube.com", 80); void setup() { pinMode(A2,INPUT); //digitalWrite(A3,HIGH) ecrire sur une ligne io digital // lots of time for the WiFly to start up and also in case I need to stop the transmit delay(10000); Serial.begin(115200); // nice and fast mySerial.begin(9600); // default WiFly baud rate - good enough for this WiFly.setUart(&mySerial); // Tell the WiFly library that we are not using the SPIUart Serial.println("Wifly begin"); WiFly.begin(); // startup the WiFly Serial.println("Wifly join"); // Join the WiFi network if (!WiFly.join(ssid, passphrase, WEP_MODE)) { Serial.println("Association failed."); while (1) { // Hang on failure. } } } uint32_t timeLastUpdated; int i; char buff[64]; void loop() { if (millis() - timeLastUpdated > TIMETOUPDATE) { // time for the next update timeLastUpdated = millis(); // prepare the data to send // format (API V2) // multiple lines each with , // feedID can be the datastream name of the numberic ID sprintf(buff,"0,%d\n1,%d",i++,analogRead(0)); Serial.println("connecting..."); if (client.connect()) { Serial.println("connected"); client.print("PUT /v2/feeds/"); // APIV2 client.print(PACHUBEFEED); client.println(".csv HTTP/1.1"); client.println("Host: api.pachube.com"); client.print("X-PachubeApiKey: "); client.println(APIKEY); client.println("User-Agent: Arduino (WiFly RN-XV)"); client.print("Content-Type: text/csv\nContent-Length: "); client.println(strlen(buff)); client.println("Connection: close"); client.println(); client.print(buff); client.println(); } else { Serial.println("connection failed"); } delay(2000); while (client.available()) { // TODO verify success (HTTP/1.1 200 OK) Serial.write(client.read()); // display the result } Serial.println(); if (client.connected()) { Serial.println("disconnecting."); client.stop(); Serial.println("disconnected."); } } } ******************** Credentials.h #ifndef __CREDENTIALS_H__ #define __CREDENTIALS_H__ // supply your own Pachube feed ID #define PACHUBEFEED "MY PACHUBE FEED" // this API key will only work from my IP address - you need to supply your own #define APIKEY "MY PACHUBE API KEY" #define TIMETOUPDATE 15000 // frequency of update - every 15 seconds // Wifi parameters char passphrase[] = "MY PASSPHRASE"; char ssid[] = "MY SSID"; boolean mode = WPA_MODE; //or WEP_MODE #endif