Configure GW TX power on a per-GW basis

Hello everyone:

Is it possible to configure the TX power for GWs on a per-GW basis? Say, if I have 2 GW, one of which supports up to 28 dBm TX power, while the other supports only up to 20 dBm. I would like both to transmit at the maximum, is there a way to configure this separately per GW?

I know you can change the TX power in the loraserver.toml config file, but that would change it for all GW within the Chirpstack server.

If you can help with this, much appreciated…

Best,

Dan

this is for endnodes

it’s not possible.
different gateways are controlled differently, some are not controlled at all

1 Like

Hello @eugenev, thanks for your reply.

I have been able to change the TX power of the GW downlinks via the downlink_tx_power parameter in the loraserver.toml file:

However, since this is a global parameter, I wanted to know if it can be set individually per GW somehow?

Best,

Dan

inside gw packet forwarder config only.
not in ChirpStack GUI, i mean
anyway, if you define globaly max allowed tx power your gateways will transmit at their maximum as they can

1 Like

I would recommend in this case to configure your gateways so that they still accept 28 dBm, but then only transmit at 20 dBm :slight_smile: That way, you don’t have to change anything at the NS side.

1 Like

Thank you, @eugenev and @brocaar. Unfortunately, it is proving difficult to configure my GWs locally to accept 28 dBm but still transmit at their respective maximums. I have 2 GW: a Laird RG1XX capable of transmitting at 28 dBm, and a Pycom PyGate that has 20 dBm as the max. Unfortunately, when the Pygate receives the command to transmit at 28 dBm, it fails to do so because 28 is an invalid setting for this GW.

I don’t suppose any of you have experience with a Pygate and this specific dilemma?

Best,

Dan

Hi There is a problem with the UDP packet forwarder that causes this very same problem. I don’t know how the Pygate works, and I don’t know if the problem you are experiencing is coming from the packet forwarder but if it uses the standard Semtech SX1301 (SX1308) UDP packet forwarder then you can try this packet forwarder where I fixed that problem.
GitHub - JoToSystems/LoraPacketForwarder: Modified LoraPacket Forwarder to correct rejection on Transmit Power mismatch

1 Like

This is interesting, @Tony. Thank you for the information, it would seem the problem is the same. In fact, the Pygate also responds with:

[567803149] lorapf: ERROR [down] Packet REJECTED, unsupported RF power for TX - 28

However, at the moment I do not know how to modify the packet forwarder on the Pygate, would possibly need to modify the firmware, but Pycom has not yet made this public.

Thank you again for your insight!

@danalvarez, Here is an idea to try. The command which is sent to the SX1301 (SX1308) chip to set actual transmit power is the arithmetic subtraction of the power command from the server less the antenna gain. So, as an example, if you want to transmit at 20dBm and the server is commanding at +27dBm then set the antenna gain to be 7dB.

The arithmetic calculation is performed first and then the resulting value is checked against the tx_tul? values in the global_conf.json file. As an example of the transmit power table, here is the tx_lut value for a transmit power of 20dBm

"tx_lut_11": {
            "pa_gain": 3,
            "mix_gain": 9,
            "rf_power": 20,
            "dig_gain": 0
        }

So my suggestion would be to find the power the server is sending (which I think is +28dBm from you error message) and since you want to transmit at +20dBm then set Antenna Gain to 8dB.
One last check before you do. Check there is a tx_lut entry for 20dBm and if not then find the next lowest and adjust Antenna Gain so the resultant matches the value in the tx_lut table. As an example, if there is not entry for 20dBm but the next lowest is 18dBm then the Antenna Gain should be set to 28-18=10dB.

The problem with the packet forwarder code is it want to find an exact match in the tx_lut table whereas it should find the next lowest value and use that.

1 Like

Hello again, @Tony

Thank you so much for your input! I prefer your solution significantly over what I had done to solve this, which was to change the rf_power param in the lookup table directly to "rf_power": 28. Your idea however seems a lot cleaner, tested it just now and it worked just fine.

One last question would be, have you any idea whether the EU868 lookup table works for US902 devices? That is, are the amplifier gains the same regardless of the region? Unfortunately, the config.json file for US902 in the Packet Forwarder repo does not have a LUT, only the EU868 file has one.

I’ve also linked to your response in the post I’d made on the Pycom forum: https://forum.pycom.io/topic/6284/setting-pygate-downlink-tx-power-to-default/3?_=1598404404031

Thx again!

Best,

Dan

Yes the same parameter apply to the bands from 868 and 915 MHz. They are the gain settings for each section of the transmitter and are related to transmit power levels.

They are set by the gateway manufacturer but you will probably find they are the same as the Semtech reference values.

You can also see a more detailed explanation of these parameter at the 57minute point in this tutorial.

1 Like