Xbee RSSI

I want to read the RSSI from an Xbee.I read that RSSI is a PWM signal so I am using the pulsein function but I got a value of 0.Is that RSSI is active in AT command mode.Does the Xbee give RSSI without the command mode.Please let me know.

Any ideas people?

I much prefer to query the XBee in API mode. This code is using Andrew Rapp’s library with an XBee-ZB (XB24-Z7WIT-004).

//returns received signal strength value for the last RF data packet.
void baseXBee::getRSS(void)
{
    uint8_t atCmd[] = {'D', 'B'};
    AtCommandRequest atCmdReq = AtCommandRequest(atCmd);
    send(atCmdReq);
    if (readPacket(10)) {
        if (getResponse().getApiId() == AT_COMMAND_RESPONSE) {
            AtCommandResponse atResp;
            getResponse().getAtCommandResponse(atResp);
            if (atResp.isOk()) {
                uint8_t respLen = atResp.getValueLength();
                if (respLen == 1) {
                    uint8_t* resp = atResp.getValue();
                    rss = -resp[0];
                }
                else {
                    Serial << F("RSS LEN ERR\n");    //unexpected length
                }
            }
            else {
                Serial << F("RSS ERR\n");            //status not ok
            }
        }
        else {
            Serial << F("RSS UNEXP RESP\n");         //expecting AT_COMMAND_RESPONSE, got something else
        }
    }
    else {
        Serial << F("RSS NO RESP\n");                //timed out
    }
}

I tested it in the wire replacement mount (without the API mode).I measured the RSSI using the pin 6 on Xbee. But now I want to use multiple Xbees fixed to 3 corners of a room and then measure the RSSI at each corner with a mobile Xbee in the middle of the room.How shall I do this using the API mode? Can I get the RSSI for each pair like mobile Xbee ,corner1 Xbee and Mobile Xbee , corner2 Xbee. etc

But now I want to use multiple Xbees fixed to 3 corners of a room and then measure the RSSI at each corner with a mobile Xbee in the middle of the room.

For what purpose? RSSI is a very poor measure of distance. With three XBees in the same room, you will likely not get ANY difference in readings.