RN-171 : problem with reconnect to net.

Hi!
I use WiFi Shield V2.0.
The Shield work in wifi net from 2 acsess point.
Between two points there is a great distance and Shield loses a signal.
When a signal is - the Shield is not connected to the network.
How to get a network reconnection?
I use code:

#include <Arduino.h>
#include <SoftwareSerial.h>
#include “WiFly.h”
#define SSID “NWRN”
#define KEY “nordway-era”
#define AUTH WIFLY_AUTH_WPA2_PSK
SoftwareSerial uart(10,11);
WiFly wifly(uart);
void setup() {
Serial.begin(9600);
uart.begin(9600); // WiFly UART Baud Rate: 9600
uart.setTimeout(100);
wifly.sendCommand(“set wlan tx 12\r”, “AOK”);
wifly.sendCommand(“set wlan auth 4\r”, “AOK”);
wifly.sendCommand(“set wlan channel 0\r”, “AOK”);
wifly.sendCommand(“set wlan join 1\r”, “AOK”);
wifly.sendCommand(“set wlan linkmon 5\r”, “AOK”);
wifly.sendCommand(“set wlan ssid NWRN\r”, “AOK”);
wifly.sendCommand(“set wlan phrase nordway-era\r”, “AOK”);
wifly.sendCommand(“set ip dhcp 3\r”, “AOK”);
wifly.sendCommand(“save\r”);
wifly.sendCommand(“reboot\r”);

delay (2000);

if (wifly.join(SSID, KEY, AUTH)) { Serial.println(“OK”);on_displ_loc_symb (“LAD”);}
else { Serial.println(“Failed”);on_displ_loc_symb (“EEE”); }

?