1/****************************************************************************** 2 * 3 * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved. 4 * 5 * This program is free software; you can redistribute it and/or modify it 6 * under the terms of version 2 of the GNU General Public License as 7 * published by the Free Software Foundation. 8 * 9 * This program is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12 * more details. 13 * 14 ******************************************************************************/ 15 16#include "odm_precomp.h" 17 18s8 odm_CCKRSSI_8723B(u8 LNA_idx, u8 VGA_idx) 19{ 20 s8 rx_pwr_all = 0x00; 21 22 switch (LNA_idx) { 23 /* 46 53 73 95 201301231630 */ 24 /* 46 53 77 99 201301241630 */ 25 26 case 6: 27 rx_pwr_all = -34 - (2 * VGA_idx); 28 break; 29 case 4: 30 rx_pwr_all = -14 - (2 * VGA_idx); 31 break; 32 case 1: 33 rx_pwr_all = 6 - (2 * VGA_idx); 34 break; 35 case 0: 36 rx_pwr_all = 16 - (2 * VGA_idx); 37 break; 38 default: 39 /* rx_pwr_all = -53+(2*(31-VGA_idx)); */ 40 /* DbgPrint("wrong LNA index\n"); */ 41 break; 42 43 } 44 return rx_pwr_all; 45} 46