2016-06-08 11:21:58 -07:00
# Received Signal Strength
2016-10-24 16:30:21 -07:00
> Note: This API has been deprecated! Use [on data packet received](/reference/radio/on-data-packet-received) instead.
2017-01-28 11:53:36 -08:00
Find how strong the ``radio`` signal is, from ` -128` to ` -42`.
(`-128` means a weak signal and `-42` means a strong one.)
2016-06-08 11:21:58 -07:00
2016-11-01 17:44:37 -07:00
The @boardname @ finds the signal strength by checking how strong it was
2016-06-08 11:21:58 -07:00
the last time it ran the
2016-10-24 16:30:21 -07:00
[on data packet received ](/reference/radio/on-data-packet-received ) function. That means
2016-06-08 11:21:58 -07:00
it needs to run **receive number** first.
2016-07-18 14:04:15 -07:00
```sig
radio.receivedSignalStrength();
```
2017-09-07 13:42:08 -07:00
## Returns
2016-06-08 11:21:58 -07:00
2017-03-16 07:57:41 -07:00
* a [number ](/types/number ) between `-128` and `-42` that means
2016-06-08 11:21:58 -07:00
how strong the signal is.
2017-09-07 13:42:08 -07:00
## Simulator
2016-06-08 11:21:58 -07:00
2016-11-01 17:44:37 -07:00
This function only works on the @boardname @, not in browsers.
2016-06-08 11:21:58 -07:00
2017-09-07 13:42:08 -07:00
## Example
2016-06-08 11:21:58 -07:00
This example shows how strong the radio signal of the
2016-06-15 07:55:19 -04:00
[light level sender example ](/reference/radio/send-number ) is.
2016-06-08 11:21:58 -07:00
```blocks
let x = 0;
radio.setGroup(99);
basic.forever(() => {
x = radio.receiveNumber();
basic.showNumber(radio.receivedSignalStrength());
});
```
2017-09-07 13:42:08 -07:00
## See also
2016-06-08 11:21:58 -07:00
2016-10-24 16:30:21 -07:00
[on data packet received ](/reference/radio/on-data-packet-received ), [send number ](/reference/radio/send-number ), [on data received ](/reference/radio/on-data-received )
2016-08-09 16:28:08 +01:00
```package
2016-10-22 21:29:31 -07:00
radio
2016-08-09 16:28:08 +01:00
```