Show Posts
Pages: [1]
1  Using Arduino / Programming Questions / How 2 codes in arduino - As with these two codes in the same Arduino? on: November 30, 2013, 02:25:39 pm
As with these two codes in the same Arduino?

#include <SPI.h>
#include <Ethernet.h>
 
//Configurações do Ethernet Shield
byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = { 192,168,2, 12 }; // ip que o arduino assumirá
byte gateway[] = { 192,168,2, 1 };  // ip do roteador
byte subnet[] = { 255, 255, 255, 0 };
 
// String que representa o estado dos dispositivos
char Luz[7] = "0000L#";
 
EthernetServer server(1212); // Cria o servidor na porta 8081
 
// String onde é guardada as msgs recebidas
char msg[7] = "0000L#";
 
void setup() {
  Ethernet.begin(mac, ip, gateway, subnet);
  server.begin();
  pinMode(A0,OUTPUT);
  pinMode(A1,OUTPUT);
  pinMode(A2,OUTPUT);
  pinMode(A3,OUTPUT);
  pinMode(A4,OUTPUT);
  pinMode(A5,OUTPUT);
}
 
void loop() {
  EthernetClient client = server.available();
  // SE receber um caracter...
  if (client) {
    // guarda o caracter na string 'msg'
    msg[1]=msg[2]; msg[2]=msg[3]; msg[3]=msg[4]; msg[4]=msg[5]; msg[5]=msg[6];
    msg[6] = client.read();
   
    if (msg[6]=='#') {
      switch(msg[5]) {
        case 'R':
          // Se receber o comando 'R#' envia de volta o status dos
          //   dispositivos. (Que é a string 'Luz')
          client.write(Luz);
        break;
        case 'P':
          // Caso P#, aciona o pino do portão pequeno por 1s.
          digitalWrite(A4,HIGH);
          delay(1000);
          digitalWrite(A4,LOW);
        break;
        case 'G':
          // Caso G#, aciona o pino do portão pequeno por 1s.
          digitalWrite(A5,HIGH);
          delay(1000);
          digitalWrite(A5,LOW);       
        break;
        case 'L':
          // Caso L#, ele copia os 4 bytes anteriores p/ a
          //   string 'Luz' e cada byte representa um
          // dispositivo, onde '1'=ON e '0'=OFF
          Luz[0]=msg[1];
          Luz[1]=msg[2];
          Luz[2]=msg[3];
          Luz[3]=msg[4];
          if (Luz[0]=='1') digitalWrite(A0,HIGH); else digitalWrite(A0,LOW);
          if (Luz[1]=='1') digitalWrite(A1,HIGH); else digitalWrite(A1,LOW);
          if (Luz[2]=='1') digitalWrite(A2,HIGH); else digitalWrite(A2,LOW);
          if (Luz[3]=='1') digitalWrite(A3,HIGH); else digitalWrite(A3,LOW);
        break;
       
      }
    }
  }
}

Other:
#include <SPI.h>
#include <Ethernet.h>
#include <EEPROM.h>
 
const char host[] = "servidor.dyndns.org";
const char usuarioClave[] = "dXN1YXJpb0BtYWlsLmNvbTptaXBhc3N3b3Jk";
 
byte mac[] = { 0xAA, 0xAB, 0xAC, 0xAD, 0xAA, 0xAB };
IPAddress ipLocal(192, 168, 1, 5);
 
char servidorIP[] = "checkip.dyndns.org";
char servidorActualizacion[] = "members.dyndns.org";
 
IPAddress ipActual;
IPAddress ipUltimaEnviada;
 
void setup() {
 
  Serial.begin(9600);
  while (!Serial); // Solo para Leonardo
 
  if (Ethernet.begin(mac) == 0) {
    Serial.println("Error consiguiendo la IP por DHCP, intentando manualmente...");
    Ethernet.begin(mac, ipLocal);
  }
 
  delay(1000);
 
  for (byte n = 0; n <= 3; n++) ipUltimaEnviada[n] = EEPROM.read(n); // Cargamos de EEPROM la ultima IP que se envio.
  Serial.print("La IP almacenada en la EEPROM es: ");
  Serial.println(ipUltimaEnviada);
}
 
void loop() {
 
  ipActual = compruebaIP();
 
  if (ipActual != ipUltimaEnviada) {
    Serial.print("Actualizando la IP en ");
    Serial.print(servidorActualizacion);
    Serial.println("..."); 
    if (actualizaIPDynDNS(ipActual) == true){
      for (byte n = 0; n <= 3; n++) EEPROM.write(n, ipActual[n]);
      ipUltimaEnviada = ipActual;
    }
  } else {
    Serial.println("No hacemos nada, la IP no cambiado desde la ultima vez. Esperando 10 minutos...");
  }
 
  delay (600000); // Y esperamos 10 minutos sentados para volver a comprobar la IP.
}
 
IPAddress compruebaIP() {
 
  EthernetClient cliente;
  String webIP;
  int desde, hasta;
 
  if (cliente.connect(servidorIP, 80)) {
 
    cliente.println("GET / HTTP/1.0");
    cliente.println();
 
    webIP = "";
  } else {
    Serial.print("smiley-sad Conexion fallida con ");
    Serial.println(servidorIP);
  }
 
  while (cliente.connected()) {
    while (cliente.available()) {
      webIP.concat((char)cliente.read());
    }
  }
 
  cliente.stop();
 
  desde = webIP.indexOf("Address: ") + 9;
  hasta = webIP.indexOf("</body>");
 
  return ipAIPAddress(webIP.substring(desde, hasta));
}
 
boolean actualizaIPDynDNS(IPAddress ip) {
 
  EthernetClient cliente;
  String webIP;
 
  if (cliente.connect(servidorActualizacion, 80)) {
 
    cliente.print("GET /nic/update?hostname=");
    cliente.print(host);
    cliente.print("&myip=");
 
    cliente.print(ip);
 
    cliente.println("&wildcard=NOCHG&mx=NOCHG&backmx=NOCHG HTTP/1.0");
 
    cliente.println("Host: members.dyndns.org");
 
    cliente.print("Authorization: Basic ");
    cliente.println(usuarioClave);
 
    cliente.println("User-Agent: josematm.com - Wirduino - 0.1");
    cliente.println();
 
  } else {
    Serial.print("smiley-sad Conexion fallida con ");
    Serial.println(servidorActualizacion);
    return false;
  }
 
  while (cliente.connected()) {
    while (cliente.available()) {
      webIP.concat((char)cliente.read());
    }
  }
 
  Serial.println(webIP);
 
  cliente.stop();
 
  if (webIP.lastIndexOf("badauth") != -1) {
    Serial.println("Error de de autentificacion. Comprueba usuario y clave");
    return false;
  } else {
    return true; 
  }
}
 
IPAddress ipAIPAddress(String ipEnCadena){
 
  IPAddress ipEnBytes;
  char digitoIP[4];
  byte cursorDigito = 0;
  byte cursorIP = 0;
 
  for (byte n = 0; n < ipEnCadena.length(); n++){
    if (ipEnCadena.charAt(n) != '.') {
      digitoIP[cursorDigito] = ipEnCadena.charAt(n);
      cursorDigito++;
    } else {
      digitoIP[cursorDigito +1] = '\n';
      ipEnBytes[cursorIP] = atoi(digitoIP);
      cursorDigito = 0;
      memset(digitoIP, 0, sizeof(digitoIP));
      cursorIP++;
    }
  }
  digitoIP[cursorDigito +1] = '\n';
  ipEnBytes[cursorIP] = atoi(digitoIP);
 
  return ipEnBytes;
}
2  Using Arduino / Networking, Protocols, and Devices / Re: Changes to external ip on: January 30, 2013, 11:04:53 am
But how do I access the Internet Arduino if I do not know the external IP?
3  Using Arduino / Networking, Protocols, and Devices / Re: Changes to external ip on: January 17, 2013, 10:38:23 am
Ok But I like to get my external ip (wan) to be able to access the Internet via arduino. In that case then I can not know the external IP.
4  Using Arduino / Networking, Protocols, and Devices / Re: Changes to external ip on: January 16, 2013, 07:12:06 pm
Excellent code Changes to external ip
How do I send the ip found for a PHP page or email?
Or how do I access a page as http://username:password@members.dyndns.org/nic/update?hostname=yourhostname&myip=ipaddress
5  Using Arduino / Programming Questions / Arduino access page on: January 16, 2013, 08:26:01 am
How do I access a page Arduino (webpage) of 30 in 30 seconds?
I would like him from accessing the page http://username:password@members.dyndns.org/nic/update?hostname=yourhostname&myip=ipaddress
6  Using Arduino / Programming Questions / Re: DynDNS Arduino - Not updating the IP on: January 12, 2013, 04:38:34 pm
The code is not in error when uploading to the Arduino. But it is not updating the DynDNS site.

The Serial.print (monitor) appears "*****************************************Start***************************************************"
7  Using Arduino / Programming Questions / DynDNS Arduino - Not updating the IP on: January 12, 2013, 03:21:49 pm
Why this code does not work? Not updating the IP.
Arduino Uno Rev3 + Ethernet W5100

Code:
/* DynDNS
 
 created 2011
 by Boris Landoni
 
 This example code is in the public domain.

 
 http://www.open-electronics.org
 http://www.futurashop.it
 */
 
 

//http://username:password@members.dyndns.org/nic/update?hostname=yourhostname&myip=ipaddress

#include <Ethernet.h>
//#include <EthernetDNS.h>
#include <WString.h>
#include <EEPROM.h>
#include <SPI.h>

#define UPDATE_INTERVAL            30000    // if the connection is good wait 30 seconds before updating again - should not be less than 5

int ledR =  8;
int ledG =  9;

unsigned long pubblica=0;


byte mac[] = { 0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = { 192, 168, 3, 12 };

byte domainaddrip[]= { 208, 78, 70, 70 }; //http://checkip.dyndns.com/
byte ipAddr[4];

byte domaindydns[]= { 204, 13, 248, 112 }; // members.dyndns.org
char hostname[ ]   = "xxxxxxxxxxx";
char userpwdb64[ ] = "xxxxxxxxxxxx";  //http://www.functions-online.com/base64_encode.html    use->   username:password


String ipadsl     = String(20);
String ipadslold  = String(20);
String inString   = String(51);


//Client client(server, 80);
const char* ip_to_str(const uint8_t*);
//void nameFound(const char* name, const byte ipAddr[4]);



EthernetClient client;
EthernetClient clientdyn;

void setup()
{
  pinMode(ledR, OUTPUT);
  pinMode(ledG, OUTPUT);
  Ethernet.begin(mac, ip);
 
  //EthernetDNS.setDNSServer(dnsServerIp);
  Serial.begin(9600);
 
  Serial.println("*****************************************Start***************************************************");
  delay(1000);
 
  //risolviip();
  //delay(1000);
}

void loop()
{
 
  if (millis() < pubblica) pubblica = millis();
     
      if ((millis() - pubblica) > UPDATE_INTERVAL){
          //Serial.print("Passati ");
          //Serial.print(UPDATE_INTERVAL);
          //Serial.println(" ms");
          Serial.print("tempo trascorso dall'accensione ");         
          Serial.println(millis());
          Serial.println(pubblica);         
          pubblica = millis(); 
               
          acquisisciip();         
      }
     
     
}


void acquisisciip()
{
 
  int timeout=0;
  int skip=0;
  ipadsl="";
  inString="";
  digitalWrite(ledG, HIGH);
 
  Serial.print("connecting to ");
  //Serial.print(domain);
  //Serial.print(" = ip ");
  //Serial.println(ip_to_str(domainaddrip));
 
  if (client.connect(domainaddrip, 80)) {
   
    Serial.println("connected");
    client.println("GET / HTTP/1.0");
    //client.println("GET / HTTP/1.0");
    client.print("HOST: ");
    client.println("www.dyndns.com");
    //client.println(ip_to_str(domainaddrip));
    client.println();
  } else {
    Serial.println("connection failed");
  }
 
 
  while (!client.available() && timeout<50)
  {
    timeout++;
    Serial.print("Time out ");
    Serial.println(timeout);
    delay(100);
  }
 
 
 
  while (client.available())
  {
      //Serial.println("client.available");
      //if (client.available())
      //{
        char c = client.read();
        //Serial.print(c);
        skip++;
        if (skip>220)
        {
          if ((inString.length())<50) inString.concat(c);     
        }
      //}
   
       
  }         
 
  client.flush();
 
      if ((inString.length())>5)   
      {
          //Serial.print("inString: ");
          //Serial.println(inString);
          if (inString.equalsIgnoreCase("Address"))
            {   
              int from=(inString.indexOf("Address")+9);
              int lunghe=inString.length();
              int to=(lunghe-16);
              /*Serial.print("Lunghezza instring    = ");
              Serial.println(lunghe); 
              Serial.print("Posizione address + 9 = ");
              Serial.println(from); 
              Serial.print("Posizione fine   - 16 = ");
              Serial.println(to); 
              */
              //strcpy(ipadsl,(inString.substring((inString.indexOf("Address")+9),(inString.length()-16))));
              ipadsl=inString.substring(from,to);
              //Serial.print("Lunghezza ipadsl      = ");
              //Serial.println(ipadsl.length());
              Serial.print("IP rilevato dal sito: >");
              Serial.print(ipadsl);         
              Serial.println("<");
                           
            }   
      }             
   
   
   if (!client.connected())
   {
 
        Serial.println("disconnecting.");
        client.stop();
        delay (1000);
       
        Serial.print("lunghezza IP ");
        //Serial.println(strlen(ipadsl));
        Serial.println(ipadsl.length());
       
        if (((ipadsl))!=0)
        {
              Serial.print("IP nuovo  : >");
              Serial.print(ipadsl);         
              Serial.println("<");

             
              for (int i=0; i<(ipadsl.length()); i++) {    //salva in memoria l'indirizzo acquisito
                ipadslold[i] = EEPROM.read(i);
                //Serial.print("carattere  : >");
                //Serial.print(ipadslold[i]);         
                //Serial.println("<");
              }
             
              Serial.print("IP vecchio: >");
              Serial.print(ipadslold);         
              Serial.println("<");
             
              if ((ipadsl,ipadslold))
              {
                Serial.println("IP diverso PUBBLICO");
                  digitalWrite(ledR, HIGH);
                pubblicaip();
                  digitalWrite(ledR, LOW);
              }
              else
              {           
                Serial.println("IP uguale");   
               
              }
                digitalWrite(ledG, LOW);
             
              //ipadslold="";
              //ipadslold.append(ipadsl);
              //ipadslold="";
              //Serial.print("IP vecchio azzerato: >");
              //Serial.print(ipadslold);         
              //Serial.println("<");
              //strcpy(ipadslold,ipadsl);
              for (int i=0; i<(ipadsl.length()); i++) {    //salva in memoria l'indirizzo acquisito
                EEPROM.write(i, ipadsl[i]);
              }
                 
        }
       
       
   }
   
 
}

void pubblicaip()
{
  int timeout=0;
  Serial.print("connecting to ");
  Serial.println(ip_to_str(domaindydns));

  Serial.print("IP da pubblicare ");
  Serial.println(ipadsl); 
 

 
 
if (clientdyn.connect(domaindydns, 80)) {
    Serial.println("connected");
    clientdyn.print("GET /nic/update?hostname=");
    clientdyn.print(hostname);
    clientdyn.print("&myip=");
    clientdyn.print(ipadsl);
    clientdyn.println(" HTTP/1.0 ");
    //clientdyn.println("Host: members.dyndns.org ");
   
    clientdyn.print("Host: ");
    clientdyn.println(ip_to_str(domaindydns));
   
    clientdyn.print("Authorization: Basic ");
    clientdyn.println(userpwdb64);
   
    clientdyn.println("User-Agent: futura - arduinodydns - 1.1");
    clientdyn.println();
  } else {
    Serial.println("connection failed");
  }

 //   delay(3000);
   
  while (!clientdyn.available() && timeout<50)
  {
    timeout++;
    Serial.print("Time out ");
    Serial.println(timeout);
    delay(100);
  }
 
 
  while (clientdyn.available())
  {
      if (clientdyn.available())
      {
        char c = clientdyn.read();
        Serial.print(c);
      }
  }
   
  if (!clientdyn.connected())
  {
        Serial.println();
        Serial.println("disconnecting.");
        clientdyn.stop();
  }
 
 
 
}




// This is just a little utility function to format an IP address as a string.
const char* ip_to_str(const uint8_t* ipAddr)
{
  static char buf[16];
  sprintf(buf, "%d.%d.%d.%d\0", ipAddr[0], ipAddr[1], ipAddr[2], ipAddr[3]);
  return buf;
}
8  Using Arduino / Programming Questions / Re: cannot convert 'String' to 'const char*' for argument '1' to 'size_t strlen(cons on: January 12, 2013, 03:20:46 pm
Ok. Thanks
9  Using Arduino / Programming Questions / cannot convert 'String' to 'const char*' for argument '1' to 'size_t strlen(cons on: January 12, 2013, 12:50:45 pm
I'm trying to load the code below but is showing error on the line "if ((strlen (ipadsl))! = 0)". I'm using an Arduino Uno REV3

Code:
/* DynDNS
 
 created 2011
 by Boris Landoni
 
 This example code is in the public domain.

 
 http://www.open-electronics.org
 http://www.futurashop.it
 */
 
 

//http://username:password@members.dyndns.org/nic/update?hostname=yourhostname&myip=ipaddress

#include <Ethernet.h>
//#include <EthernetDNS.h>
#include <WString.h>
#include <EEPROM.h>

#define UPDATE_INTERVAL            30000    // if the connection is good wait 30 seconds before updating again - should not be less than 5

int ledR =  8;
int ledG =  9;

unsigned long pubblica=0;


byte mac[] = { 0x54,0x55,0x58,0x10,0x00,0x24 };
byte ip[] = { 192, 168, 0, 98 };

byte domainaddrip[]= { 208, 78, 70, 70 }; //http://checkip.dyndns.com/
byte ipAddr[4];

byte domaindydns[]= { 204, 13, 248, 112 }; // members.dyndns.org
char hostname[ ]   = "xxxxxxx.getmyip.com";
char userpwdb64[ ] = "xxxxxxxxxxxxxxxxxx";  //http://www.functions-online.com/base64_encode.html    use->   username:password


String ipadsl     = String(20);
String ipadslold  = String(20);
String inString   = String(51);


//Client client(server, 80);
const char* ip_to_str(const uint8_t*);
//void nameFound(const char* name, const byte ipAddr[4]);



EthernetClient client;
EthernetClient clientdyn;

void setup()
{
  pinMode(ledR, OUTPUT);
  pinMode(ledG, OUTPUT);
  Ethernet.begin(mac, ip);
 
  //EthernetDNS.setDNSServer(dnsServerIp);
  Serial.begin(9600);
 
  Serial.println("*****************************************Start***************************************************");
  delay(1000);
 
  //risolviip();
  //delay(1000);
}

void loop()
{
 
  if (millis() < pubblica) pubblica = millis();
     
      if ((millis() - pubblica) > UPDATE_INTERVAL){
          //Serial.print("Passati ");
          //Serial.print(UPDATE_INTERVAL);
          //Serial.println(" ms");
          Serial.print("tempo trascorso dall'accensione ");         
          Serial.println(millis());
          Serial.println(pubblica);         
          pubblica = millis(); 
               
          acquisisciip();         
      }
     
     
}


void acquisisciip()
{
 
  int timeout=0;
  int skip=0;
  ipadsl="";
  inString="";
  digitalWrite(ledG, HIGH);
 
  Serial.print("connecting to ");
  //Serial.print(domain);
  //Serial.print(" = ip ");
  //Serial.println(ip_to_str(domainaddrip));
 
  if (client.connect(domainaddrip, 80)) {
   
    Serial.println("connected");
    client.println("GET / HTTP/1.0");
    //client.println("GET / HTTP/1.0");
    client.print("HOST: ");
    client.println("www.dyndns.com");
    //client.println(ip_to_str(domainaddrip));
    client.println();
  } else {
    Serial.println("connection failed");
  }
 
 
  while (!client.available() && timeout<50)
  {
    timeout++;
    Serial.print("Time out ");
    Serial.println(timeout);
    delay(100);
  }
 
 
 
  while (client.available())
  {
      //Serial.println("client.available");
      //if (client.available())
      //{
        char c = client.read();
        //Serial.print(c);
        skip++;
        if (skip>220)
        {
          if ((inString.length())<50) inString.concat(c);     
        }
      //}
   
       
  }         
 
  client.flush();
 
      if ((inString.length())>5)   
      {
          //Serial.print("inString: ");
          //Serial.println(inString);
          if (inString.equalsIgnoreCase("Address"))
            {   
              int from=(inString.indexOf("Address")+9);
              int lunghe=inString.length();
              int to=(lunghe-16);
              /*Serial.print("Lunghezza instring    = ");
              Serial.println(lunghe); 
              Serial.print("Posizione address + 9 = ");
              Serial.println(from); 
              Serial.print("Posizione fine   - 16 = ");
              Serial.println(to); 
              */
              //strcpy(ipadsl,(inString.substring((inString.indexOf("Address")+9),(inString.length()-16))));
              ipadsl=inString.substring(from,to);
              //Serial.print("Lunghezza ipadsl      = ");
              //Serial.println(ipadsl.length());
              Serial.print("IP rilevato dal sito: >");
              Serial.print(ipadsl);         
              Serial.println("<");
                           
            }   
      }             
   
   
   if (!client.connected())
   {
 
        Serial.println("disconnecting.");
        client.stop();
        delay (1000);
       
        Serial.print("lunghezza IP ");
        //Serial.println(strlen(ipadsl));
        Serial.println(ipadsl.length());
       
        if ((strlen(ipadsl))!=0)
        {
              Serial.print("IP nuovo  : >");
              Serial.print(ipadsl);         
              Serial.println("<");

             
              for (int i=0; i<(ipadsl.length()); i++) {    //salva in memoria l'indirizzo acquisito
                ipadslold[i] = EEPROM.read(i);
                //Serial.print("carattere  : >");
                //Serial.print(ipadslold[i]);         
                //Serial.println("<");
              }
             
              Serial.print("IP vecchio: >");
              Serial.print(ipadslold);         
              Serial.println("<");
             
              if (strcmp(ipadsl,ipadslold))
              {
                Serial.println("IP diverso PUBBLICO");
                  digitalWrite(ledR, HIGH);
                pubblicaip();
                  digitalWrite(ledR, LOW);
              }
              else
              {           
                Serial.println("IP uguale");   
               
              }
                digitalWrite(ledG, LOW);
             
              //ipadslold="";
              //ipadslold.append(ipadsl);
              //ipadslold="";
              //Serial.print("IP vecchio azzerato: >");
              //Serial.print(ipadslold);         
              //Serial.println("<");
              //strcpy(ipadslold,ipadsl);
              for (int i=0; i<(ipadsl.length()); i++) {    //salva in memoria l'indirizzo acquisito
                EEPROM.write(i, ipadsl[i]);
              }
                 
        }
       
       
   }
   
 
}

void pubblicaip()
{
  int timeout=0;
  Serial.print("connecting to ");
  Serial.println(ip_to_str(domaindydns));

  Serial.print("IP da pubblicare ");
  Serial.println(ipadsl); 
 

 
 
if (clientdyn.connect()) {
    Serial.println("connected");
    clientdyn.print("GET /nic/update?hostname=");
    clientdyn.print(hostname);
    clientdyn.print("&myip=");
    clientdyn.print(ipadsl);
    clientdyn.println(" HTTP/1.0 ");
    //clientdyn.println("Host: members.dyndns.org ");
   
    clientdyn.print("Host: ");
    clientdyn.println(ip_to_str(domaindydns));
   
    clientdyn.print("Authorization: Basic ");
    clientdyn.println(userpwdb64);
   
    clientdyn.println("User-Agent: futura - arduinodydns - 1.1");
    clientdyn.println();
  } else {
    Serial.println("connection failed");
  }

 //   delay(3000);
   
  while (!clientdyn.available() && timeout<50)
  {
    timeout++;
    Serial.print("Time out ");
    Serial.println(timeout);
    delay(100);
  }
 
 
  while (clientdyn.available())
  {
      if (clientdyn.available())
      {
        char c = clientdyn.read();
        Serial.print(c);
      }
  }
   
  if (!clientdyn.connected())
  {
        Serial.println();
        Serial.println("disconnecting.");
        clientdyn.stop();
  }
 
 
 
}




// This is just a little utility function to format an IP address as a string.
const char* ip_to_str(const uint8_t* ipAddr)
{
  static char buf[16];
  sprintf(buf, "%d.%d.%d.%d\0", ipAddr[0], ipAddr[1], ipAddr[2], ipAddr[3]);
  return buf;
}
Pages: [1]