1 //<MStar Software> 2 //****************************************************************************** 3 // MStar Software 4 // Copyright (c) 2010 - 2012 MStar Semiconductor, Inc. All rights reserved. 5 // All software, firmware and related documentation herein ("MStar Software") are 6 // intellectual property of MStar Semiconductor, Inc. ("MStar") and protected by 7 // law, including, but not limited to, copyright law and international treaties. 8 // Any use, modification, reproduction, retransmission, or republication of all 9 // or part of MStar Software is expressly prohibited, unless prior written 10 // permission has been granted by MStar. 11 // 12 // By accessing, browsing and/or using MStar Software, you acknowledge that you 13 // have read, understood, and agree, to be bound by below terms ("Terms") and to 14 // comply with all applicable laws and regulations: 15 // 16 // 1. MStar shall retain any and all right, ownership and interest to MStar 17 // Software and any modification/derivatives thereof. 18 // No right, ownership, or interest to MStar Software and any 19 // modification/derivatives thereof is transferred to you under Terms. 20 // 21 // 2. You understand that MStar Software might include, incorporate or be 22 // supplied together with third party`s software and the use of MStar 23 // Software may require additional licenses from third parties. 24 // Therefore, you hereby agree it is your sole responsibility to separately 25 // obtain any and all third party right and license necessary for your use of 26 // such third party`s software. 27 // 28 // 3. MStar Software and any modification/derivatives thereof shall be deemed as 29 // MStar`s confidential information and you agree to keep MStar`s 30 // confidential information in strictest confidence and not disclose to any 31 // third party. 32 // 33 // 4. MStar Software is provided on an "AS IS" basis without warranties of any 34 // kind. Any warranties are hereby expressly disclaimed by MStar, including 35 // without limitation, any warranties of merchantability, non-infringement of 36 // intellectual property rights, fitness for a particular purpose, error free 37 // and in conformity with any international standard. You agree to waive any 38 // claim against MStar for any loss, damage, cost or expense that you may 39 // incur related to your use of MStar Software. 40 // In no event shall MStar be liable for any direct, indirect, incidental or 41 // consequential damages, including without limitation, lost of profit or 42 // revenues, lost or damage of data, and unauthorized system use. 43 // You agree that this Section 4 shall still apply without being affected 44 // even if MStar Software has been modified by MStar in accordance with your 45 // request or instruction for your use, except otherwise agreed by both 46 // parties in writing. 47 // 48 // 5. If requested, MStar may from time to time provide technical supports or 49 // services in relation with MStar Software to you for your use of 50 // MStar Software in conjunction with your or your customer`s product 51 // ("Services"). 52 // You understand and agree that, except otherwise agreed by both parties in 53 // writing, Services are provided on an "AS IS" basis and the warranty 54 // disclaimer set forth in Section 4 above shall apply. 55 // 56 // 6. Nothing contained herein shall be construed as by implication, estoppels 57 // or otherwise: 58 // (a) conferring any license or right to use MStar name, trademark, service 59 // mark, symbol or any other identification; 60 // (b) obligating MStar or any of its affiliates to furnish any person, 61 // including without limitation, you and your customers, any assistance 62 // of any kind whatsoever, or any information; or 63 // (c) conferring any license or right under any intellectual property right. 64 // 65 // 7. These terms shall be governed by and construed in accordance with the laws 66 // of Taiwan, R.O.C., excluding its conflict of law rules. 67 // Any and all dispute arising out hereof or related hereto shall be finally 68 // settled by arbitration referred to the Chinese Arbitration Association, 69 // Taipei in accordance with the ROC Arbitration Law and the Arbitration 70 // Rules of the Association by three (3) arbitrators appointed in accordance 71 // with the said Rules. 72 // The place of arbitration shall be in Taipei, Taiwan and the language shall 73 // be English. 74 // The arbitration award shall be final and binding to both parties. 75 // 76 //****************************************************************************** 77 //<MStar Software> 78 //////////////////////////////////////////////////////////////////////////////// 79 // 80 // Copyright (c) 2008-2009 MStar Semiconductor, Inc. 81 // All rights reserved. 82 // 83 // Unless otherwise stipulated in writing, any and all information contained 84 // herein regardless in any format shall remain the sole proprietary of 85 // MStar Semiconductor Inc. and be kept in strict confidence 86 // ("MStar Confidential Information") by the recipient. 87 // Any unauthorized act including without limitation unauthorized disclosure, 88 // copying, use, reproduction, sale, distribution, modification, disassembling, 89 // reverse engineering and compiling of the contents of MStar Confidential 90 // Information is unlawful and strictly prohibited. MStar hereby reserves the 91 // rights to any and all damages, losses, costs and expenses resulting therefrom. 92 // 93 //////////////////////////////////////////////////////////////////////////////// 94 95 /////////////////////////////////////////////////////////////////////////////////////////////////// 96 /// 97 /// @file apiPNL.h 98 /// @brief Panel Interface 99 /// @author MStar Semiconductor Inc. 100 // Ver0100: 1. add OutTimingMode() to XC_PNL_OBJ. 2. adds APIPNL_OUT_TIMING_MODE to PanelType 101 // Ver0101: 1. Correct the libversion from '1''0' to '0''1' 102 // 2. Fix the bug that C++ will have compile error for MACRO: MApi_PNL_Init_Ex 103 // 3. Remove the MApi_PNL_Init prototype 104 // CL215113++: 105 // 1. Fix Gamma 10bit display error 106 // 2. Update debug function: MApi_PNL_SetDbgLevel. 107 // CL215791++: 108 // 1. Fix Gamma 10bit display error 109 // 2. Update debug function: MApi_PNL_SetDbgLevel. 110 // CL218113++: 111 // 1. Enable SUPPORT_SYNC_FOR_DUAL_MODE in T8, T9, Janus. 112 // CL215791++: 113 // 114 // CL258947++:sync to utopia_t3_u3 CL 251806 115 // 1. fix LVDS output output issues: XC_MOD_OUTPUT_CONF MASK is wrong 116 // 2. Adds MApi_PNL_PreInit for SEC to give output options before panel init. 117 // 3. Adds SSC related functions: request by SEC, the SPAN value range shall be 400, 500, 600 118 // 4. Adds SetOutputPattern function. 119 // 5. Modifies MDrv_PNL_SetGammaTbl with MLoad function. 120 // 6. Adds MHal_Output_LVDS_Pair_Setting for Vestel project 121 // CL261417++: Fix gamma wrong problem. 122 // Temprary disable the MLoad function in MDrv_PNL_SetGammaTbl. 123 /////////////////////////////////////////////////////////////////////////////////////////////////// 124 125 #ifndef _API_XC_PANEL_EX_H_ 126 #define _API_XC_PANEL_EX_H_ 127 128 // Common Definition 129 #include "MsTypes.h" 130 #include "MsVersion.h" 131 #include "UFO.h" 132 133 #ifdef __cplusplus 134 extern "C" { 135 #endif 136 137 //------------------------------------------------------------------------------------------------- 138 // Macro and Define 139 //------------------------------------------------------------------------------------------------- 140 #ifndef _MS_VERSION_H_ 141 #define MSIF_TAG {'M','S','I','F'} // MSIF 142 #define MSIF_CLASS {'0','0'} // DRV/API (DDI) 143 #define MSIF_CUS 0x0000 // MStar Common library 144 #define MSIF_MOD 0x0000 // MStar Common library 145 #define MSIF_CHIP 0x000B 146 #define MSIF_CPU '0' 147 #define MSIF_OS '2' 148 #endif 149 150 // library information 151 #define MSIF_PNL_EX_LIB_CODE {'P','E','X','_'} 152 #define MSIF_PNL_EX_LIBVER {'0','4'} 153 #define MSIF_PNL_EX_BUILDNUM {'5','3'} 154 #define MSIF_PNL_EX_CHANGELIST {'0','0','6','6','7','4','7','1'} 155 156 #define PNL_EX_API_VERSION /* Character String for DRV/API version */ \ 157 MSIF_TAG, /* 'MSIF' */ \ 158 MSIF_CLASS, /* '00' */ \ 159 MSIF_CUS, /* 0x0000 */ \ 160 MSIF_MOD, /* 0x0000 */ \ 161 MSIF_CHIP, \ 162 MSIF_CPU, \ 163 MSIF_PNL_EX_LIB_CODE , /* IP__ */ \ 164 MSIF_PNL_EX_LIBVER , /* 0.0 ~ Z.Z */ \ 165 MSIF_PNL_EX_BUILDNUM , /* 00 ~ 99 */ \ 166 MSIF_PNL_EX_CHANGELIST, /* CL# */ \ 167 MSIF_OS 168 169 /// ApiStatusEX version of current XC lib 170 #define API_PNLEXSTATUS_EX_VERSION 1 171 172 //------------------------------------------------------------------------------------------------- 173 // Type and Structure 174 //------------------------------------------------------------------------------------------------- 175 /// Define PNL device number 176 typedef enum 177 { 178 E_PNL_EX_DEVICE0 = 0, 179 E_PNL_EX_DEVICE1, 180 E_PNL_EX_MAX_DEVICE_NUM 181 } PNL_EX_DEVICE_NUM; 182 183 /// Define return value of MApi_PNL 184 typedef enum 185 { 186 E_PNL_EX_FAIL = 0, 187 E_PNL_EX_OK = 1, 188 E_PNL_EX_GET_BASEADDR_FAIL, ///< get base address failed when initialize panel driver 189 E_PNL_EX_OBTAIN_MUTEX_FAIL, ///< obtain mutex timeout when calling this function 190 } PNL_EX_Result; 191 192 /// Define aspect ratio 193 typedef enum 194 { 195 E_PNL_EX_ASPECT_RATIO_4_3 = 0, ///< set aspect ratio to 4 : 3 196 E_PNL_EX_ASPECT_RATIO_WIDE, ///< set aspect ratio to 16 : 9 197 E_PNL_EX_ASPECT_RATIO_OTHER, ///< resvered for other aspect ratio other than 4:3/ 16:9 198 } PNL_EX_ASPECT_RATIO; 199 200 /// Define the panel gamma precision type 201 typedef enum 202 { 203 E_PNL_EX_GAMMA_10BIT = 0, ///< Gamma Type of 10bit 204 E_PNL_EX_GAMMA_12BIT, ///< Gamma Type of 12bit 205 E_PNL_EX_GAMMA_ALL ///< The library can support all mapping mode 206 } PNL_EX_GAMMA_TYPE; 207 208 /// Define Gamma type 209 typedef enum 210 { 211 E_PNL_EX_GAMMA_8BIT_MAPPING = 0, ///< mapping 1024 to 256 gamma entries 212 E_PNL_EX_GAMMA_10BIT_MAPPING, ///< mapping 1024 to 1024 gamma entries 213 E_PNL_EX_GAMMA_ALL_MAPPING ///< the library can map to any entries 214 } PNL_EX_GAMMA_MAPPEING_MODE; ///< samping mode for GAMMA correction 215 216 /// Define The dimming control flag. when use with setter/getter, it will set/get MIN/MAX/Current value 217 typedef enum 218 { 219 E_PNL_EX_DIMMING_MIN = 0, ///< Indicate to Get/Set Min Dimming value. 220 E_PNL_EX_DIMMING_CURRENT , ///< Indicate to Get/Set Current Dimming value. 221 E_PNL_EX_DIMMING_MAX , ///< Indicate to Get/Set Max Dimming value. 222 } PNL_EX_DIMMING_CTRL; 223 224 /// Define PANEL Signaling Type 225 typedef enum 226 { 227 E_PNL_EX_LINK_TTL, ///< TTL type 228 E_PNL_EX_LINK_LVDS, ///< LVDS type 229 E_PNL_EX_LINK_RSDS, ///< RSDS type 230 E_PNL_EX_LINK_MINILVDS, ///< TCON 231 E_PNL_EX_LINK_ANALOG_MINILVDS, ///< Analog TCON 232 E_PNL_EX_LINK_DIGITAL_MINILVDS, ///< Digital TCON 233 E_PNL_EX_LINK_MFC, ///< Ursa (TTL output to Ursa) 234 E_PNL_EX_LINK_DAC_I, ///< DAC output 235 E_PNL_EX_LINK_DAC_P, ///< DAC output 236 E_PNL_EX_LINK_PDPLVDS, ///< For PDP(Vsync use Manually MODE) 237 E_PNL_EX_LINK_EXT, /// EXT LPLL TYPE 238 } PNL_EX_LINK_TYPE; 239 240 /// Define PANEL Signaling Type 241 typedef enum 242 { 243 // M10 New Panel Type 244 E_PNL_EX_LINK_EPI34_8P = E_PNL_EX_LINK_EXT, /// 10 245 E_PNL_EX_LINK_EPI28_8P, /// 11 246 E_PNL_EX_LINK_EPI34_6P, /// 12 247 E_PNL_EX_LINK_EPI28_6P, /// 13 248 249 ///LINK_MINILVDS_6P_2L, /// replace this with LINK_MINILVDS 250 E_PNL_EX_LINK_MINILVDS_5P_2L, /// 14 251 E_PNL_EX_LINK_MINILVDS_4P_2L, /// 15 252 E_PNL_EX_LINK_MINILVDS_3P_2L, /// 16 253 E_PNL_EX_LINK_MINILVDS_6P_1L, /// 17 254 E_PNL_EX_LINK_MINILVDS_5P_1L, /// 18 255 E_PNL_EX_LINK_MINILVDS_4P_1L, /// 19 256 E_PNL_EX_LINK_MINILVDS_3P_1L, /// 20 257 258 E_PNL_EX_LINK_HS_LVDS, /// 21 259 E_PNL_EX_LINK_HF_LVDS, /// 22 260 261 E_PNL_EX_LINK_TTL_TCON, /// 23 262 E_PNL_EX_LINK_MINILVDS_2CH_3P_8BIT, // 2 channel, 3 pair, 8 bits /// 263 E_PNL_EX_LINK_MINILVDS_2CH_4P_8BIT, // 2 channel, 4 pair, 8 bits /// 264 E_PNL_EX_LINK_MINILVDS_2CH_5P_8BIT, // 2 channel, 5 pair, 8 bits /// 265 E_PNL_EX_LINK_MINILVDS_2CH_6P_8BIT, // 2 channel, 6 pair, 8 bits /// 266 267 E_PNL_EX_LINK_MINILVDS_1CH_3P_8BIT, // 1 channel, 3 pair, 8 bits /// 268 E_PNL_EX_LINK_MINILVDS_1CH_4P_8BIT, // 1 channel, 4 pair, 8 bits /// 269 E_PNL_EX_LINK_MINILVDS_1CH_5P_8BIT, // 1 channel, 5 pair, 8 bits /// 270 E_PNL_EX_LINK_MINILVDS_1CH_6P_8BIT, // 1 channel, 6 pair, 8 bits /// 271 272 E_PNL_EX_LINK_MINILVDS_2CH_3P_6BIT, // 2 channel, 3 pari, 6 bits /// 273 E_PNL_EX_LINK_MINILVDS_2CH_4P_6BIT, // 2 channel, 4 pari, 6 bits /// 274 E_PNL_EX_LINK_MINILVDS_2CH_5P_6BIT, // 2 channel, 5 pari, 6 bits /// 275 E_PNL_EX_LINK_MINILVDS_2CH_6P_6BIT, // 2 channel, 6 pari, 6 bits /// 276 277 E_PNL_EX_LINK_MINILVDS_1CH_3P_6BIT, // 1 channel, 3 pair, 6 bits /// 278 E_PNL_EX_LINK_MINILVDS_1CH_4P_6BIT, // 1 channel, 4 pair, 6 bits /// 279 E_PNL_EX_LINK_MINILVDS_1CH_5P_6BIT, // 1 channel, 5 pair, 6 bits /// 280 E_PNL_EX_LINK_MINILVDS_1CH_6P_6BIT, // 1 channel, 6 pair, 6 bits /// 281 }PNL_EX_LINK_EXT_TYPE; 282 283 /// Define power on and off timing order. 284 typedef enum 285 { 286 E_PNL_EX_POWER_TIMING_1 , ///< Timing order 1 287 E_PNL_EX_POWER_TIMING_2 , ///< Timing order 2 288 E_PNL_EX_POWER_TIMING_NA = 0xFFFF, ///< Reserved Timing order 289 } PNL_EX_POWER_TIMING_SEQ; 290 291 /// Define TI bit mode 292 typedef enum 293 { 294 E_PNL_EX_TI_10BIT_MODE = 0, 295 E_PNL_EX_TI_8BIT_MODE = 2, 296 E_PNL_EX_TI_6BIT_MODE = 3, 297 } PNL_EX_TIBITMODE; 298 299 /// Define which panel output timing change mode is used to change VFreq for same panel 300 typedef enum 301 { 302 E_PNL_EX_CHG_DCLK = 0, ///<change output DClk to change Vfreq. 303 E_PNL_EX_CHG_HTOTAL = 1, ///<change H total to change Vfreq. 304 E_PNL_EX_CHG_VTOTAL = 2, ///<change V total to change Vfreq. 305 } PNL_EX_OUT_TIMING_MODE; 306 307 /// Define panel output format bit mode 308 typedef enum 309 { 310 E_PNL_EX_OUTPUT_10BIT_MODE = 0,//default is 10bit, becasue 8bit panel can use 10bit config and 8bit config. 311 E_PNL_EX_OUTPUT_6BIT_MODE = 1, //but 10bit panel(like PDP panel) can only use 10bit config. 312 E_PNL_EX_OUTPUT_8BIT_MODE = 2, //and some PDA panel is 6bit. 313 } PNL_EX_OUTPUTFORMAT_BITMODE; 314 315 /// Panel device ID 316 typedef struct 317 { 318 MS_U32 u32Version; 319 MS_U32 u32Id; 320 } PNL_DeviceId; 321 322 /// Panel Api information 323 typedef struct __attribute__((packed)) 324 { 325 PNL_EX_GAMMA_TYPE eSupportGammaType; ///< Gamma type supported by apiPNL 326 } PNL_EX_ApiInfo; 327 328 /// Panel status 329 typedef struct __attribute__((packed)) 330 { 331 MS_BOOL bPanel_Initialized; ///< panel initialized or not 332 MS_BOOL bPanel_Enabled; ///< panel enabled or not, if enabled, you can see OSD/Video 333 } PNL_EX_ApiStatus; 334 335 /// Panel status 336 typedef struct 337 { 338 MS_U32 u32ApiStatusEx_Version;///<Version of current structure. Please always set to "API_PNLEXSTATUS_EX_VERSION" as input 339 MS_U16 u16ApiStatusEX_Length; ///<Length of this structure, u16ApiStatusEX_Length=sizeof(PNL_EX_ApiExtStatus) 340 341 MS_BOOL bPNLInitialize; ///< panel initialized or not 342 MS_BOOL bPNLEnable; ///< panel enabled or not, if enabled, you can see OSD/Video 343 MS_U16 u16VTotal; ///< Output vertical total 344 MS_U16 u16DEVStart; ///< Output DE vertical start 345 MS_U16 u16DEVEnd; ///< Output DE Vertical end 346 MS_U16 u16VSyncStart; ///< Output VSync start 347 MS_U16 u16VSyncEnd; ///< Output VSync end 348 MS_U16 u16HTotal; ///< Output horizontal total 349 MS_U16 u16DEHStart; ///< Output DE horizontal start 350 MS_U16 u16DEHEnd; ///< Output DE horizontal end 351 MS_U16 u16HSyncWidth; ///< Output HSync width 352 MS_BOOL bIsPanelManualVysncMode; ///< enable manuel V sync control 353 MS_BOOL bInterlaceOutput; ///< enable Scaler Interlace output 354 MS_BOOL bYUVOutput; ///< enable Scaler YUV output 355 } PNL_EX_ApiExtStatus; 356 357 /// Panel output control, must be called before g_IPanel.Enable(), otherwise will output after called g_IPanelEx.Enable() 358 typedef enum 359 { 360 E_PNL_EX_OUTPUT_NO_OUTPUT = 0, ///< even called g_IPanelEx.Enable(TRUE), still no physical output 361 E_PNL_EX_OUTPUT_CLK_ONLY, ///< after called g_IPanelEx.Enable(TRUE), will output clock only 362 E_PNL_EX_OUTPUT_DATA_ONLY, ///< after called g_IPanelEx.Enable(TRUE), will output data only 363 E_PNL_EX_OUTPUT_CLK_DATA, ///< after called g_IPanelEx.Enable(TRUE), will output clock and data 364 } PNL_EX_OUTPUT_MODE; 365 366 /// Define Panel MISC control index 367 /// please enum use BIT0 = 0x01, BIT1 = 0x02, BIT2 = 0x04, BIT3 = 0x08, BIT4 = 0x10, 368 typedef enum 369 { 370 E_PNL_EX_MISC_MFC_ENABLE = 0x0001, 371 E_PNL_EX_MISC_SKIP_CALIBRATION = 0x0002, 372 373 E_PNL_EX_MISC_MFC_MCP = 0x0010, // bit 4 374 E_PNL_EX_MISC_MFC_ABChannel = 0x0020, // bit5 375 E_PNL_EX_MISC_MFC_ACChannel = 0x0040, // bit 6 376 E_PNL_EX_MISC_MFC_ENABLE_60HZ = 0x0080, // bit 7, for 60Hz Panel 377 E_PNL_EX_MISC_MFC_ENABLE_240HZ = 0x0100, // bit 8, for 240Hz Panel 378 } PNL_EX_MISC; 379 380 typedef enum 381 { 382 E_PNL_EX_TCON_TAB_TYPE_GENERAL, 383 E_PNL_EX_TCON_TAB_TYPE_GPIO, 384 E_PNL_EX_TCON_TAB_TYPE_SCALER, 385 E_PNL_EX_TCON_TAB_TYPE_MOD, 386 E_PNL_EX_TCON_TAB_TYPE_GAMMA, 387 E_PNL_EX_TCON_TAB_TYPE_POWER_SEQUENCE_ON, 388 E_PNL_EX_TCON_TAB_TYPE_POWER_SEQUENCE_OFF, 389 } PNL_EX_TCON_TAB_TYPE; 390 391 /** 392 * Represent a panel interface. 393 * 394 * Provide panel attributes, and some panel basic functions 395 */ 396 typedef struct 397 { 398 // 399 // Data 400 // 401 const char* ( * const Name ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< Panel name 402 MS_U16 ( * const HStart ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< DE H start 403 MS_U16 ( * const VStart ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< DE V start 404 MS_U16 ( * const Width ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< DE H width 405 MS_U16 ( * const Height ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< DE V height 406 MS_U16 ( * const HTotal ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< Htotal 407 MS_U16 ( * const VTotal ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< Vtotal 408 MS_U8 ( * const HSynWidth ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< H sync width 409 MS_U8 ( * const HSynBackPorch ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< H sync back porch 410 MS_U8 ( * const VSynBackPorch ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< V sync back porch 411 MS_U16 ( * const DefaultVFreq ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< deault V Freq 412 MS_U8 ( * const LPLL_Mode ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< 0: single, 1: dual mode 413 MS_U8 ( * const LPLL_Type ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< 0: LVDS, 1: RSDS 414 PNL_EX_ASPECT_RATIO ( * const AspectRatio ) ( const PNL_DeviceId *pPNL_DeviceId ); // /< please refer to E_PNL_ASPECT_RATIO 415 MS_U32 ( * const MinSET ) ( const PNL_DeviceId *pPNL_DeviceId ); // / < MinSET 416 MS_U32 ( * const MaxSET ) ( const PNL_DeviceId *pPNL_DeviceId ); // / < MaxSET 417 418 // 419 // Manipulation 420 // 421 /// @brief Set Span-Spectrum-Control 422 /// @param u16Fmodulation IN:SSC_SPAN_PERIOD 423 /// @param u16Rdeviation IN:SSC_STEP_PERCENT 424 /// @param bEnable IN:Enable / Disable 425 /// 426 void ( * const SetSSC ) ( const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16Fmodulation, MS_U16 u16Rdeviation, MS_BOOL bEnable ) ; 427 428 /// @brief Enable panel's output, but "not include the function to turn VCC on". 429 /// @param bEnable IN:Enable / Disable 430 MS_BOOL ( * const Enable ) ( const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable ) ; 431 432 /// @brief Set Gamma correction table. 433 /// @param eGammaType Resolution of gamma table 434 /// @param pu8GammaTab gamma table 435 /// @param u16NumOfLevel T2: 256, T3: can be 256 / 1024 levels 436 MS_BOOL ( * const SetGammaTbl ) ( const PNL_DeviceId *pPNL_DeviceId, 437 PNL_EX_GAMMA_TYPE eGammaType, 438 MS_U8* pu8GammaTab[3], 439 PNL_EX_GAMMA_MAPPEING_MODE Gamma_Map_Mode ) ; 440 441 /// @brief Get Gamma correction table. 442 /// @return A Gamma table used currently. 443 MS_U8** ( * const GammaTab ) ( const PNL_DeviceId *pPNL_DeviceId ) ; 444 445 /// @brief printout panel data, width, height, htt, vtt etc. 446 void ( * const Dump ) ( const PNL_DeviceId *pPNL_DeviceId ) ; 447 448 /// @brief Get Min/Max/Current Dimming Value according to the given flag. 449 /// @param max_min_setting Flag of Min / Max / Current Dimming Value.s 450 MS_U8 ( * const DimCtrl ) ( const PNL_DeviceId *pPNL_DeviceId, PNL_EX_DIMMING_CTRL max_min_setting ) ; 451 452 /// @brief Query Power On Timing with given power on timing order.\n 453 /// @param power_on_sequence_timing order 454 MS_U16 ( * const OnTiming ) ( const PNL_DeviceId *pPNL_DeviceId, PNL_EX_POWER_TIMING_SEQ power_on_sequence_timing ) ; 455 456 /// @brief Query Power Off Timing with given power on timing order.\n 457 /// @param power_off_sequence_timing order 458 MS_U16 ( * const OffTiming ) ( const PNL_DeviceId *pPNL_DeviceId, PNL_EX_POWER_TIMING_SEQ power_off_sequence_timing ) ; 459 460 // 461 // Custimized methods, can be provided by clinets. 462 // 463 void ( *TurnBackLightOn ) ( const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable ) ; 464 PNL_EX_OUT_TIMING_MODE 465 ( * const OutTimingMode )( const PNL_DeviceId *pPNL_DeviceId ); ///<output timing mode 466 467 ///@brief Set Gamma value 468 ///@param u8Channel R/G/B channel, 0->R, 1->G, 2->B 469 ///@param u16Offset The address of Gamma value 470 ///@param u16GammaValue Gamma value 471 MS_BOOL (* const SetGammaValue)( const PNL_DeviceId *pPNL_DeviceId, MS_U8 u8Channel, MS_U16 u16Offset, MS_U16 u16GammaValue); 472 473 /// @brief Get Gamma correction table. 474 /// @param eGammaType Resolution of gamma table 475 /// @param pu8GammaTab gamma table 476 /// @param Gamma_Map_Mode 8Bit mapping or 10Bit mapping 477 MS_BOOL ( * const GetGammaTbl ) ( const PNL_DeviceId *pPNL_DeviceId, 478 PNL_EX_GAMMA_TYPE eGammaType, 479 MS_U8* pu8GammaTab[3], 480 PNL_EX_GAMMA_MAPPEING_MODE Gamma_Map_Mode ) ; 481 }XC_PNL_EX_OBJ; 482 483 /// A panel struct type used to specify the panel attributes, and settings from Board layout 484 typedef struct __attribute__((packed)) 485 { 486 const char *m_pPanelName; ///< PanelName 487 #if !(defined(UFO_PUBLIC_HEADER_212) || defined(UFO_PUBLIC_HEADER_300)) 488 #if !defined (__aarch64__) 489 MS_U32 u32AlignmentDummy0; 490 #endif 491 #endif 492 // 493 // Panel output 494 // 495 MS_U8 m_bPanelDither :1; ///< PANEL_DITHER, keep the setting 496 PNL_EX_LINK_TYPE m_ePanelLinkType :4; ///< PANEL_LINK 497 498 /////////////////////////////////////////////// 499 // Board related setting 500 /////////////////////////////////////////////// 501 MS_U8 m_bPanelDualPort :1; ///< VOP_21[8], MOD_4A[1], PANEL_DUAL_PORT, refer to m_bPanelDoubleClk 502 MS_U8 m_bPanelSwapPort :1; ///< MOD_4A[0], PANEL_SWAP_PORT, refer to "LVDS output app note" A/B channel swap 503 MS_U8 m_bPanelSwapOdd_ML :1; ///< PANEL_SWAP_ODD_ML 504 MS_U8 m_bPanelSwapEven_ML :1; ///< PANEL_SWAP_EVEN_ML 505 MS_U8 m_bPanelSwapOdd_RB :1; ///< PANEL_SWAP_ODD_RB 506 MS_U8 m_bPanelSwapEven_RB :1; ///< PANEL_SWAP_EVEN_RB 507 508 MS_U8 m_bPanelSwapLVDS_POL :1; ///< MOD_40[5], PANEL_SWAP_LVDS_POL, for differential P/N swap 509 MS_U8 m_bPanelSwapLVDS_CH :1; ///< MOD_40[6], PANEL_SWAP_LVDS_CH, for pair swap 510 MS_U8 m_bPanelPDP10BIT :1; ///< MOD_40[3], PANEL_PDP_10BIT ,for pair swap 511 MS_U8 m_bPanelLVDS_TI_MODE :1; ///< MOD_40[2], PANEL_LVDS_TI_MODE, refer to "LVDS output app note" 512 513 /////////////////////////////////////////////// 514 // For TTL Only 515 /////////////////////////////////////////////// 516 MS_U8 m_ucPanelDCLKDelay; ///< PANEL_DCLK_DELAY 517 MS_U8 m_bPanelInvDCLK :1; ///< MOD_4A[4], PANEL_INV_DCLK 518 MS_U8 m_bPanelInvDE :1; ///< MOD_4A[2], PANEL_INV_DE 519 MS_U8 m_bPanelInvHSync :1; ///< MOD_4A[12], PANEL_INV_HSYNC 520 MS_U8 m_bPanelInvVSync :1; ///< MOD_4A[3], PANEL_INV_VSYNC 521 522 /////////////////////////////////////////////// 523 // Output driving current setting 524 /////////////////////////////////////////////// 525 // driving current setting (0x00=4mA, 0x01=6mA, 0x02=8mA, 0x03=12mA) 526 MS_U8 m_ucPanelDCKLCurrent; ///< define PANEL_DCLK_CURRENT 527 MS_U8 m_ucPanelDECurrent; ///< define PANEL_DE_CURRENT 528 MS_U8 m_ucPanelODDDataCurrent; ///< define PANEL_ODD_DATA_CURRENT 529 MS_U8 m_ucPanelEvenDataCurrent; ///< define PANEL_EVEN_DATA_CURRENT 530 531 /////////////////////////////////////////////// 532 // panel on/off timing 533 /////////////////////////////////////////////// 534 MS_U16 m_wPanelOnTiming1; ///< time between panel & data while turn on power 535 MS_U16 m_wPanelOnTiming2; ///< time between data & back light while turn on power 536 MS_U16 m_wPanelOffTiming1; ///< time between back light & data while turn off power 537 MS_U16 m_wPanelOffTiming2; ///< time between data & panel while turn off power 538 539 /////////////////////////////////////////////// 540 // panel timing spec. 541 /////////////////////////////////////////////// 542 // sync related 543 MS_U8 m_ucPanelHSyncWidth; ///< VOP_01[7:0], PANEL_HSYNC_WIDTH 544 MS_U8 m_ucPanelHSyncBackPorch; ///< PANEL_HSYNC_BACK_PORCH, no register setting, provide value for query only 545 546 ///< not support Manuel VSync Start/End now 547 ///< VOP_02[10:0] VSync start = Vtt - VBackPorch - VSyncWidth 548 ///< VOP_03[10:0] VSync end = Vtt - VBackPorch 549 MS_U8 m_ucPanelVSyncWidth; ///< define PANEL_VSYNC_WIDTH 550 MS_U8 m_ucPanelVBackPorch; ///< define PANEL_VSYNC_BACK_PORCH 551 552 // DE related 553 MS_U16 m_wPanelHStart; ///< VOP_04[11:0], PANEL_HSTART, DE H Start (PANEL_HSYNC_WIDTH + PANEL_HSYNC_BACK_PORCH) 554 MS_U16 m_wPanelVStart; ///< VOP_06[11:0], PANEL_VSTART, DE V Start 555 MS_U16 m_wPanelWidth; ///< PANEL_WIDTH, DE width (VOP_05[11:0] = HEnd = HStart + Width - 1) 556 MS_U16 m_wPanelHeight; ///< PANEL_HEIGHT, DE height (VOP_07[11:0], = Vend = VStart + Height - 1) 557 558 // DClk related 559 MS_U16 m_wPanelMaxHTotal; ///< PANEL_MAX_HTOTAL. Reserved for future using. 560 MS_U16 m_wPanelHTotal; ///< VOP_0C[11:0], PANEL_HTOTAL 561 MS_U16 m_wPanelMinHTotal; ///< PANEL_MIN_HTOTAL. Reserved for future using. 562 563 MS_U16 m_wPanelMaxVTotal; ///< PANEL_MAX_VTOTAL. Reserved for future using. 564 MS_U16 m_wPanelVTotal; ///< VOP_0D[11:0], PANEL_VTOTAL 565 MS_U16 m_wPanelMinVTotal; ///< PANEL_MIN_VTOTAL. Reserved for future using. 566 567 MS_U8 m_dwPanelMaxDCLK; ///< PANEL_MAX_DCLK. Reserved for future using. 568 MS_U8 m_dwPanelDCLK; ///< LPLL_0F[23:0], PANEL_DCLK ,{0x3100_10[7:0], 0x3100_0F[15:0]} 569 MS_U8 m_dwPanelMinDCLK; ///< PANEL_MIN_DCLK. Reserved for future using. 570 571 ///< spread spectrum 572 MS_U16 m_wSpreadSpectrumStep; ///< move to board define, no use now. 573 MS_U16 m_wSpreadSpectrumSpan; ///< move to board define, no use now. 574 575 MS_U8 m_ucDimmingCtl; ///< Initial Dimming Value 576 MS_U8 m_ucMaxPWMVal; ///< Max Dimming Value 577 MS_U8 m_ucMinPWMVal; ///< Min Dimming Value 578 579 MS_U8 m_bPanelDeinterMode :1; ///< define PANEL_DEINTER_MODE, no use now 580 PNL_EX_ASPECT_RATIO m_ucPanelAspectRatio; ///< Panel Aspect Ratio, provide information to upper layer application for aspect ratio setting. 581 /* 582 * 583 * Board related params 584 * 585 * If a board ( like BD_MST064C_D01A_S ) swap LVDS TX polarity 586 * : This polarity swap value = 587 * (LVDS_PN_SWAP_H<<8) | LVDS_PN_SWAP_L from board define, 588 * Otherwise 589 * : The value shall set to 0. 590 */ 591 MS_U16 m_u16LVDSTxSwapValue; 592 PNL_EX_TIBITMODE m_ucTiBitMode; ///< MOD_4B[1:0], refer to "LVDS output app note" 593 PNL_EX_OUTPUTFORMAT_BITMODE m_ucOutputFormatBitMode; 594 595 MS_U8 m_bPanelSwapOdd_RG :1; ///< define PANEL_SWAP_ODD_RG 596 MS_U8 m_bPanelSwapEven_RG :1; ///< define PANEL_SWAP_EVEN_RG 597 MS_U8 m_bPanelSwapOdd_GB :1; ///< define PANEL_SWAP_ODD_GB 598 MS_U8 m_bPanelSwapEven_GB :1; ///< define PANEL_SWAP_EVEN_GB 599 600 /** 601 * Others 602 */ 603 MS_U8 m_bPanelDoubleClk :1; ///< LPLL_03[7], define Double Clock ,LVDS dual mode 604 MS_U32 m_dwPanelMaxSET; ///< define PANEL_MAX_SET 605 MS_U32 m_dwPanelMinSET; ///< define PANEL_MIN_SET 606 PNL_EX_OUT_TIMING_MODE m_ucOutTimingMode; ///<Define which panel output timing change mode is used to change VFreq for same panel 607 MS_U8 m_bPanelNoiseDith :1; ///< PAFRC mixed with noise dither disable 608 } PNL_EX_PanelType; 609 610 //Display information 611 typedef struct 612 { 613 MS_U32 VDTOT; //Output vertical total 614 MS_U32 DEVST; //Output DE vertical start 615 MS_U32 DEVEND;//Output DE Vertical end 616 MS_U32 HDTOT;// Output horizontal total 617 MS_U32 DEHST; //Output DE horizontal start 618 MS_U32 DEHEND;// Output DE horizontal end 619 MS_BOOL bInterlaceMode; 620 MS_BOOL bYUVOutput; 621 } PNL_EX_DST_DispInfo; 622 623 //HW LVDS Reserved Bit to L/R flag Info 624 typedef struct 625 { 626 MS_U32 u32pair; // pair 0: BIT0, pair 1: BIT1, pair 2: BIT2, pair 3: BIT3, pair 4: BIT4, etc ... 627 MS_U16 u16channel; // channel A: BIT0, channel B: BIT1, 628 MS_BOOL bEnable; 629 } PNL_EX_HW_LVDSResInfo; 630 631 /// Define the initial OverDrive for XC 632 typedef struct 633 { 634 MS_U8 u8ODTbl[1056]; 635 MS_U32 u32PNL_version; ///<Version of current structure. 636 // OD frame buffer related 637 #if defined(UFO_PUBLIC_HEADER_700) 638 MS_PHY u32OD_MSB_Addr; ///<OverDrive MSB frame buffer start address, absolute without any alignment 639 #else 640 MS_PHYADDR u32OD_MSB_Addr; ///<OverDrive MSB frame buffer start address, absolute without any alignment 641 #endif 642 MS_U32 u32OD_MSB_Size; ///<OverDrive MSB frame buffer size, the unit is BYTES 643 #if defined(UFO_PUBLIC_HEADER_700) 644 MS_PHY u32OD_LSB_Addr; ///<OverDrive LSB frame buffer start address, absolute without any alignment 645 #else 646 MS_PHYADDR u32OD_LSB_Addr; ///<OverDrive LSB frame buffer start address, absolute without any alignment 647 #endif 648 MS_U32 u32OD_LSB_Size; ///<OverDrive MSB frame buffer size, the unit is BYTES 649 } PNL_EX_OD_INITDATA; 650 651 typedef struct 652 { 653 MS_U16 m_u16ExpectSwingLevel; 654 MS_U8 m_u8ModCaliPairSel; 655 MS_U8 m_u8ModCaliTarget; 656 MS_S8 m_s8ModCaliOffset; 657 MS_BOOL m_bPVDD_2V5; 658 }PNL_EX_ModCaliInfo; 659 660 //------------------------------------------------------------------------------------------------- 661 // Function and Variable 662 //------------------------------------------------------------------------------------------------- 663 664 /******************************************************************************/ 665 /* Variable */ 666 /* ****************************************************************************/ 667 /** 668 * 669 * The global interface for panel manipulation. 670 * 671 * @attention <b>Call "MApi_PNL_Init()" first before using this obj</b> 672 */ 673 extern XC_PNL_EX_OBJ g_IPanelEx; 674 675 typedef enum 676 { 677 E_PNL_EX_NO_OUTPUT, 678 E_PNL_EX_CLK_ONLY, 679 E_PNL_EX_CLK_DATA, 680 E_PNL_EX_MAX, 681 } PNL_EX_PREINIT_OPTIONS; 682 683 DLL_PUBLIC PNL_EX_Result MApi_PNL_EX_GetLibVer(const MSIF_Version **ppVersion); 684 DLL_PUBLIC const PNL_EX_ApiInfo* MApi_PNL_EX_GetInfo(const PNL_DeviceId *pPNL_DeviceId); 685 DLL_PUBLIC MS_BOOL MApi_PNL_EX_GetStatus(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_ApiStatus *pPnlStatus); 686 DLL_PUBLIC MS_BOOL MApi_PNL_EX_GetStatusEx(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_ApiExtStatus *pPnlExtStatus); 687 688 DLL_PUBLIC MS_BOOL MApi_PNL_EX_SetDbgLevel(MS_U16 u16DbgSwitch); 689 690 DLL_PUBLIC MS_BOOL MApi_PNL_EX_IOMapBaseInit(const PNL_DeviceId *pPNL_DeviceId); 691 692 DLL_PUBLIC MS_BOOL MApi_PNL_EX_PreInit(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_PREINIT_OPTIONS eInitParam); 693 694 #ifndef _API_XC_PANEL_EX_C_ 695 #define MApi_PNL_EX_Init(x...) MApi_PNL_EX_Init_Ex(x, (MSIF_Version){{ PNL_EX_API_VERSION },}); 696 #endif 697 698 DLL_PUBLIC MS_BOOL MApi_PNL_EX_Init_Ex(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_PanelType *pSelPanelType/* <in > */, MSIF_Version LIBVER); 699 DLL_PUBLIC void MApi_PNL_EX_SetOutput(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_OUTPUT_MODE eOutputMode); 700 DLL_PUBLIC MS_BOOL MApi_PNL_EX_ChangePanelType(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_PanelType *pSelPanelType); 701 //------------------------------------------------------------------------------ 702 /// Dump TCON Table 703 /// @param pTCONTable \b IN: Table 704 /// @param u8Tcontype \b IN: use APIPNL_TCON_TAB_TYPE ad input 705 /// @return TRUE --OK FALSE 706 //------------------------------------------------------------------------------ 707 DLL_PUBLIC MS_BOOL MApi_PNL_EX_TCONMAP_DumpTable(const PNL_DeviceId *pPNL_DeviceId, MS_U8 *pTCONTable, MS_U8 u8Tcontype); 708 DLL_PUBLIC MS_BOOL MApi_PNL_EX_TCONMAP_Power_Sequence(const PNL_DeviceId *pPNL_DeviceId, MS_U8 *pTCONTable, MS_BOOL bEnable); 709 DLL_PUBLIC void MApi_PNL_EX_TCON_Count_Reset ( const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable ); 710 DLL_PUBLIC void MApi_PNL_EX_TCON_Init( const PNL_DeviceId *pPNL_DeviceId ); 711 DLL_PUBLIC MS_BOOL MApi_PNL_EX_GetDstInfo(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_DST_DispInfo *pDstInfo, MS_U32 u32SizeofDstInfo); 712 // MOD Output swing should between 40~600 713 DLL_PUBLIC MS_BOOL MApi_PNL_EX_Control_Out_Swing(const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16Swing_Level); 714 DLL_PUBLIC MS_BOOL MApi_PNL_EX_ForceSetPanelDCLK(const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16PanelDCLK ,MS_BOOL bSetDCLKEnable ); 715 DLL_PUBLIC MS_BOOL MApi_PNL_EX_ForceSetPanelHStart(const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16PanelHStart ,MS_BOOL bSetHStartEnable); 716 717 DLL_PUBLIC void MApi_PNL_EX_SetOutputPattern(const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable, MS_U16 u16Red , MS_U16 u16Green, MS_U16 u16Blue); 718 DLL_PUBLIC void MApi_PNL_EX_Mod_Calibration_Setting(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_ModCaliInfo *pstModCaliInfo); 719 DLL_PUBLIC MS_BOOL MApi_PNL_EX_Mod_Do_Calibration(const PNL_DeviceId *pPNL_DeviceId); 720 721 /* 722 Type: This type means package. Different package maybe have different type id. 723 Check board define or system configure for type id. 724 */ 725 DLL_PUBLIC void MApi_PNL_EX_BD_LVDS_Output_Type(const PNL_DeviceId *pPNL_DeviceId, MS_U16 Type); 726 DLL_PUBLIC void MApi_PNL_EX_SetLPLLTypeExt(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_LINK_EXT_TYPE eLPLL_TypeExt); 727 DLL_PUBLIC void MApi_PNL_EX_Init_MISC(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_MISC ePNL_MISC); 728 DLL_PUBLIC void MApi_PNL_EX_MOD_OutputConfig_User(const PNL_DeviceId *pPNL_DeviceId, MS_U32 u32OutputCFG0_7, MS_U32 u32OutputCFG8_15, MS_U32 u32OutputCFG16_21); 729 DLL_PUBLIC void MApi_PNL_EX_HWLVDSReservedtoLRFlag(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_HW_LVDSResInfo lvdsresinfo); 730 731 DLL_PUBLIC void MApi_PNL_EX_MOD_PVDD_Power_Setting(const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bIs2p5); 732 733 // more SSC function, shall be added into XC_PNL_OBJ 734 DLL_PUBLIC int MApi_PNL_EX_SetSSC_En(const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable); 735 //------------------------------------------------------------------------------ 736 /// Set panel SSC Fmodulation 737 /// @param u16Fmodulation \b IN:Fmodulation, Unit:0.1Khz 738 /// @return TRUE --OK FALSE 739 //------------------------------------------------------------------------------ 740 DLL_PUBLIC int MApi_PNL_EX_SetSSC_Fmodulation(const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16Fmodulation); 741 //------------------------------------------------------------------------------ 742 /// Set panel SSC Rdeviation 743 /// @param u16Rdeviation \b IN: u16Rdeviation, Unit:1%%(1/10000) 744 /// @return TRUE --OK FALSE 745 //------------------------------------------------------------------------------ 746 DLL_PUBLIC int MApi_PNL_EX_SetSSC_Rdeviation(const PNL_DeviceId *pPNL_DeviceId, MS_U16 u16Rdeviation); 747 DLL_PUBLIC PNL_EX_Result MApi_PNL_EX_SkipTimingChange(const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bFlag); 748 749 //------------------------------------------------------------------------------------------------- 750 /// Initialize OverDrive 751 /// @param pPNL_ODInitData \b IN: the Initialized Data 752 /// @param u32ODInitDataLen \b IN: the length of the initialized data 753 /// @return E_APIPNL_OK or E_APIPNL_FAIL 754 //------------------------------------------------------------------------------------------------- 755 DLL_PUBLIC PNL_EX_Result MApi_PNL_EX_OverDriver_Init(const PNL_DeviceId *pPNL_DeviceId, PNL_EX_OD_INITDATA *pPNL_ODInitData, MS_U32 u32ODInitDataLen); 756 757 //------------------------------------------------------------------------------------------------- 758 /// OverDrive Enable 759 /// @param bEnable \b IN: TRUE: Enable OverDrive; FALSE: Disable OverDrive 760 /// @return E_APIPNL_OK or E_APIPNL_FAIL 761 //------------------------------------------------------------------------------------------------- 762 DLL_PUBLIC PNL_EX_Result MApi_PNL_EX_OverDriver_Enable(const PNL_DeviceId *pPNL_DeviceId, MS_BOOL bEnable); 763 764 765 //------------------------------------------------------------------------------------------------- 766 /// Get TCON capability 767 /// @return MS_BOOL 768 //------------------------------------------------------------------------------------------------- 769 DLL_PUBLIC MS_BOOL MApi_PNL_EX_Get_TCON_Capability(const PNL_DeviceId *pPNL_DeviceId); 770 771 772 //------------------------------------------------------------------------------------------------- 773 /// Set FRC MOD pair swap 774 /// @param u32Polarity \b IN: u32Polarity, (d:c:b:a)=([15:14],[13:12],[11:10],[9:8]) => (10,00,11,01), => (2,0,3,1) 775 //------------------------------------------------------------------------------------------------- 776 DLL_PUBLIC void MApi_PNL_EX_SetPairSwap(const PNL_DeviceId *pPNL_DeviceId, MS_U32 u32Polarity); 777 778 779 //------------------------------------------------------------------------------------------------- 780 /// Cal Ext LPLL Set by DCLK 781 /// @param ldHz \b IN: ldHz = Htt*Vtt*Vfreq 782 //------------------------------------------------------------------------------------------------- 783 DLL_PUBLIC void MApi_PNL_EX_CalExtLPLLSETbyDClk(const PNL_DeviceId *pPNL_DeviceId, MS_U32 ldHz); 784 785 ////////////////////////////////////////////// 786 // Below functions are obosolted ! Please do not use them if you do not use them yet. 787 ////////////////////////////////////////////// 788 789 //------------------------------------------------------------------------------------------------- 790 ///-obosolte!! use MApi_PNL_Control_Out_Swing instead 791 //------------------------------------------------------------------------------------------------- 792 DLL_PUBLIC MS_BOOL MApi_PNL_EX_SetDiffSwingLevel(const PNL_DeviceId *pPNL_DeviceId, MS_U8 u8Swing_Level); 793 794 795 #ifdef __cplusplus 796 } 797 #endif 798 799 #endif 800