setting rf_power and pwr_idx, and the max allowed Tx power in India

I am trying to setup a lora gateway in India. I’m using a WM1302 concentrator for the gateway. Since the git repository ‘sx1302_hal’ used to get the concentrator running does not contain the config file for Indian frequency range (IN865), I’m making one up myself. I’m confused about what the integer values of ‘rf_power’ and ‘pwr_idx’ of the look up table in the config sheet mean. What value of transmission power does the values of rf_power correspond to?

From the LoRa regional documentation, I was able to gather that the max allowed value of Equivalent Isotropically Radiated Power(EIRP) in India is 30dBm. Does this mean that if i keep the antenna gain 0 dBi and assume that the cable loss is 1 dB(is this a reasonable assumption?) , then the maximum allowed transmitter power is equal to 29 dBm?

“tx_gain_lut” stands for TX Gain Look-Up-Table (LUT).
rf_power refers to the transmission power, in dBm. The packet forwarder will choose the entry to know what to configure during transmission, based on this value. If there is no exact match, it’ll pick the nearest one (rounded down, I believe).

pa_gain refers to whether this setting (PA Gain) is enabled, while pwr_idx refers to the power index to set into the hardware. I believe these parameters, and rssi_offset and rssi_tcomp, are supposed to come from the hardware manufacturer. The hardware manufacturer is supposed to have completed calibration and adjustments. Since WM1302 is a product, can you create a new configuration file for IN865, based on the one they provided for EU868?

I would only adjust the tx_freq_min, tx_freq_max and freq of radio_0 and radio_1, and chan_multiSF_0…7, chan_Lora_std and chan_FSK.

The maximum transmission power is indeed linked to your Indian regulations and your understanding appears to be correct. Your requested (to the packet forwarder) transmission power does not need to factor in losses, as the packet forwarder will do some computation for you. Cable loss is normally negligible and would cause the signal to become weaker anyway. We need to handle the antenna gain properly, as a stronger antenna could cause the limit to be exceeded if the packet forwarder does not factor in the antenna’s capabilities correctly. The code for the packet forwarder takes your requested transmission power (or the one it can use) and subtract antenna_gain from it. Therefore, antenna_gain must specify the gain of your attached antenna.