Antenna_gain in dBi or dBd?

Not in the code, that is what al the tx_lut entries in the config are for, so to be compliant we should not be using an identical global config supplied by TTN for all hardware but one tuned to the specific hardware.