Montage Technology M88RS2000 User manual

DVB-S Satellite Receiver
M88RS2000
Driver User’s Manual
Revision Number: 0.0
Revision Date: November 23, 2009

Disclaimer
INFORMATION IN THIS DOCUMENT IS PROVIDED IN CONNECTION WITH MONTAGE PRODUCTS. NO
LICENSE, EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, TO ANY INTELLECTUAL PROPERTY
RIGHTS IS GRANTED BY THIS DOCUMENT. EXCEPT AS PROVIDED IN MONTAGE'S TERMS AND CONDITIONS
OF SALE FOR SUCH PRODUCTS, MONTAGE ASSUMES NO LIABILITY WHATSOEVER, AND MONTAGE
DISCLAIMS ANY EXPRESS OR IMPLIED WARRANTY, RELATING TO SALE AND/OR USE OF MONTAGE
PRODUCTS INCLUDING LIABILITY OR WARRANTIES RELATING TO FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABILITY, OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL
PROPERTY RIGHT.
Montage may make changes to specifications and product descriptions at any time, without notice.
Designers must not rely on the absence or characteristics of any features or instructions marked "reserved" or
"undefined." Montage reserves these for future definition and shall have no responsibility whatsoever for conflicts or
incompatibilities arising from future changes to them.
Other names and brands may be claimed as the property of others.
Do not disclose or distribute to any third party without written permission of Montage.
Copyright © Montage Technology 2009.
M88RS2000M88DS3001M88DS3002
Driver User’s Manual
Montage Technology Confidential and Proprietary ii

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary iii
Revision History
Revision
Number Revision
Date
Changes
Page Number Description
0.0 11/23/2009 - Initial release

Revision Number: 0.0
Revision Date: November 23, 2009
Document Number: SW-0060-D 1
1Introduction
Montage provides a primary reference for the driver of M88RS2000 DVB-S satellite receiver. The driver includes
demodulator and tuner APIs. It can be integrated into user’s own applications easily. The user can use it as a reference,
and then write their own code according to their specific hardware, operating system and compiler.
This user’s manual introduces variables and functions of the driver, and demonstrates how to use the driver in an STB
(Set-Top Box) application.
We assume that the user have a basic familiarity with the M88RS2000 and C program. If you have difficulties
understanding this user’s manual, please refer to the M88RS2000 data sheet.
2 Software Overview
This manual describes how to control M88RS2000 by software on the manufacturer’s platform, such as ST or LSI etc.
Montage provides a set of fully developed software functions with their definitions. The driver is OS-independent so that
the user can use the M88RS2000 with a variety of embedded processors and embedded operating systems appropriate
for their platform.
2.1 Files Of The Driver
The M88RS2000 driver is written in standard ANSI C. It consists of source files and header files. For more details,
please refer to Table 1.
Table 1. Driver’s Files List
Name Type Description
mt_fe_rs2k.c C source file Provides APIs to operate the receiver.
mt_fe_i2c.c C source file Includes 2-wire bus API to read/write the receiver’s register
and download firmware through 2-wire bus.
mt_fe_example.c C source file Provides an example for using the APIs to search satellite TP
and DiSEqC applications.
mt_fe_def.h C header file Declares variables and functions. Defines variable types used
in the driver.
mt_fe_i2c.h C header file Declares the APIs of 2-wire bus and 2-wire bus repeater.
M88RS2000
Driver User’s Manual

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 2
2.2 How To Use The Driver
Please use the driver as follow steps.
Figure 1. Following Steps To Use The Driver
3 Driver Main APIs
3.1 Realize 2-wire Bus APIs
Corresponding files:
−mt_fe_i2c.c -- Source codes of the 2-wire bus operation.
−mt_fe_i2c.h -- Declaration of corresponding 2-wire bus APIs.
−mt_fe_def.h -- Define the 2-wire bus’s slave address.
Applications can access and control the M88RS2000 through a 2-wire bus. The bus speed is up to 400KHz. Users
should realize the belowing functions of 2-wire bus interface based on the users' OS 2-wire bus drivers.
3.1.1 About The 2-wire Bus Chip Address
3.1.1.1 Demodulator Part’s Address
The M88RS2000 chip address is selected by the ADDR_SEL pin and 2-wire bus operations. Currently, the chip’s default
address is D0H. Table 2. 2-wire Bus’s Slave Address Selection
ADDR_SEL
Pin
Demodulator Part’s Address
Write Operation Read Operation
0D0H D1H
1D2H D3H
Realize 2-wire Bus
APIs
Initialize M88RS2000
LNB & DiSEqC
Blind Scan
Manual Search
Get TP & Signal
Information

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 3
3.1.1.2 Tuner Part’s Address
The M88RS2000 operates tuner part’s registers through C0H for write operation and C1H for read operation.
3.1.2 Functions Need To Be Finished By Users
3.1.2.1 2-wire Bus
3.1.2.1.1 Write Operation With a Stop Signal
S32 _mt_i2c_tx_with_stop (U8 chip_addr, U8 *p_data, U16 byte_nb, U32 time_out)
Description:
This function contains 2-wire bus write operation with a stop signal.
Arguments:
U8 chip_addr -- 2-wire bus chip address;
U8 *p_data -- Data to be written;
U16 byte_nb -- Length of data to be written;
U32 time_out -- 2-wire bus time out.
Return:
S32
3.1.2.1.2 Read Operation With a Stop Signal
S32 _mt_i2c_rx_with_stop (U8 chip_addr, U8 *p_buf, U16 byte_nb, U32 time_out)
Description:
This function contains 2-wire bus read operation with a stop signal.
Arguments:
U8 chip_addr -- 2-wire bus chip address;
U8 *p_data -- Store the read data;
U16 byte_nb -- Length of read data;
U32 time_out -- 2-wire bus time out.
Return:
S32
3.1.2.1.3 Write Operation Without Stop Signal
S32 _mt_i2c_tx_without_stop (U8 chip_addr, U8 *p_data, U16 byte_nb, U32 time_out)
Description:
This function contains 2-wire bus write operation without stop signal.
Arguments:
U8 chip_addr -- 2-wire bus chip address;
U8 *p_data -- Data to be written;
U16 byte_nb -- Length of data to be written;
U32 time_out -- 2-wire bus time out.

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 4
Return:
S32
3.1.2.1.4 Read Operation Without Stop Signal
S32 _mt_i2c_rx_without_stop (U8 chip_addr, U8 *p_buf, U16 byte_nb, U32 time_out)
Description:
This function contains 2-wire bus read operation without stop signal.
Arguments:
U8 chip_addr -- 2-wire bus chip address;
U8 *p_data -- Store the read data;
U16 byte_nb -- Length of the read data;
U32 time_out -- 2-wire bus time out.
Return:
S32
3.1.2.1.5 Time Delay
void _mt_i2c_delay (U32 time)
Description:
This function sets the time delay of 2-wire bus.
Arguments:
U32 time -- The delay time. Unit is micro-second (ms).
Note: In multi-task embedded OS, we strongly recommended that users should use mutex or semaphore to
protect and synchronize 2-wire bus operations in multi-threads. Otherwise some unexpected 2-wire bus errors
may be occurred.
3.1.3 Read/Write Demodulator Part’s Registers
3.1.3.1 Write Operation
MT_FE_RET mt_fe_dmd_set_reg (U8 addr, U8 data)
Description:
This function writes demodulator register.
Arguments:
U8 addr -- Sub-address of demodulator register;
U8 data -- Data to be written.
Return:
MT_FE_RET
3.1.3.2 Read Operation
MT_FE_RET mt_fe_dmd_get_reg (U8 addr, U8 *p_buf)
Description:

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 5
This function reads demodulator register.
Arguments:
U8 addr -- Sub-address of demodulator register;
U8 *p_buf -- Store the read data.
Return:
MT_FE_RET
3.1.4 Read/Write Tuner Part’s Registers
3.1.4.1 Write Operation
MT_FE_RET mt_fe_tn_set_reg (U8 addr, U8 data)
Description:
This function writes tuner register.
Arguments:
U8 addr -- Sub-address of tuner register;
U8 data -- Data to be written.
Return:
MT_FE_RET
3.1.4.2 Read Operation
MT_FE_RET mt_fe_tn_get_reg (U8 addr, U8 *p_buf)
Description:
This function reads tuner register.
Arguments:
U8 addr -- Sub-address of tuner register;
U8 *p_buf -- Store the read data.
Return:
MT_FE_RET
Note:
In the function source codes, you'll find a sentence:
val |= 0x05;
The operation opens the 2-wire bus repeater twice. This means that below operations need two stop signals. If
there's only one stop signal, the sentence should change to:
val |= 0x04;
3.2 Macro Definitions
Corresponding file:
−mt_fe_def.h -- Include macro definitions, variable type defines and APIs.

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 6
Belowing lists all the macro definitions which are important or can be modified, and with their corresponding information.
3.2.1 MT_FE_DEBUG
This variable switches on/off some debug information print.
1 -- Enable the debug information printing;
0 -- Disable the debug information printing.
3.2.2 MT_FE_TS_OUTPUT_MODE
This variable defines the MPEG TS output mode.
MtFeTsOutputMode_Serial -- Serial mode output;
MtFeTsOutputMode_Parallel -- Parallel mode output (Default mode);
MtFeTsOutputMode_Common -- DVB common interface mode output.
3.2.3 LIMIT_TP_CARRIER_OFFSET_6MHZ
This variable determines whether to limit the carrier offset range or not. The range is from -6MHz to +6MHz.
0 -- Disable to limit the carrier offset range;
1 -- Enable to limit the carrier offset range.
3.2.4 Level Defines Of LNB Corresponding Pins
Please define these levels according to the circuit design.
3.2.4.1 Pin Level
•MT_FE_PIN_LEVEL_LOW -- Define as 0. Pin level is LOW;
•MT_FE_PIN_LEVEL_HIGH -- Define as 1. Pin level is HIGH.
3.2.4.2 LNB Enable
MT_FE_PIN_LNB_EN_LEVEL_WHEN_LNB_ENABLE
This macro definition defines which level of pin LNB_EN means LNB enable.
•MT_FE_PIN_LEVEL_LOW -- Enable LNB when pin LNB_EN is LOW;
•MT_FE_PIN_LEVEL_HIGH -- Enable LNB when pin LNB_EN is HIGH.
3.2.4.3 LNB Voltage Selection
MT_FE_PIN_VSEL_LEVEL_WHEN_LNB_13V
This macro definition defines which level of pin VSEL means LNB voltage is 13V.
•MT_FE_PIN_LEVEL_LOW -- LNB voltage is 13V when the level is LOW, and LNB voltage is 18V when
the level is HIGH;
•MT_FE_PIN_LEVEL_HIGH -- LNB voltage is 13V when the level is HIGH, and LNB voltage is 18V when
the level is LOW.
3.2.4.4 The Level Of Pin VSEL When LNB Standby
MT_FE_PIN_VSEL_LEVEL_WHEN_LNB_STANDBY

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 7
This macro definition defines level of pin VSEL when LNB stands by.
•MT_FE_PIN_LEVEL_LOW -- The level is LOW when LNB stands by;
•MT_FE_PIN_LEVEL_HIGH -- The level is HIGH when LNB stands by.
3.2.4.5 The Level Of Pin DISEQC_OUT When LNB Standby
MT_FE_PIN_DISEQC_OUT_LEVEL_WHEN_LNB_STANDBY
This macro definition defines level of pin DISEQC_OUT when LNB standby.
•MT_FE_PIN_LEVEL_LOW -- The level is LOW when LNB stands by;
•MT_FE_PIN_LEVEL_HIGH -- The level is HIGH when LNB stands by.
3.2.5 Macro Definitions Of Reference Signal Strength
3.2.5.1 AVG_NUM
This variable defines the length of an array to store the last few signal strength data. The final data will be the average
value. Default value is 1.
3.2.5.2 SIGNAL_STENGTH_RATIO
This variable the ratio of the signal strength. Default value is 100.
3.3 M88RS2000 Initialization
MT_FE_RET mt_fe_rs2k_init (void)
Descriptions:
This function initializes the receiver (includes tuner part and demodulator part) and configure the MPEG TS output
format.
Note: After the system boots up, users should call this function to initialize the M88RS2000.
3.4 LNB & DiSEqC
After M88RS2000 is initialized, users should connect cables and set the correct LNB status. If there's more than one
cable, users should set up LNB and DiSEqC controlling devices to select the specific cable.
3.4.1 Set LNB
MT_FE_RET mt_fe_rs2k_set_LNB (BOOL is_LNB_enable, BOOL is_22k_enable, MT_FE_LNB_VOLTAGE
voltage_type)
Descriptions:
This function sets the LNB.
Arguments:
BOOL is_LNB_enable -- Enable or disable LNB;
BOOL is_22k_enable -- Enable or disable a 22KHz tone signal;
MT_FE_LNB_VOLTAGE voltage_type -- Select 13V or 18V.
Return:
MT_FE_RET

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 8
3.4.1.1 MT_FE_LNB_VOLTAGE
This enumeration selects the LNB voltage.
typedef enum _MT_FE_LNB_VOLTAGE
{
MtFeLNB_13V = 0, // LNB voltage 13V
MtFeLNB_18V // LNB voltage 18V
} MT_FE_LNB_VOLTAGE;
3.4.2 Send a Tone Burst Signal
MT_FE_RET mt_fe_rs2k_DiSEqC_send_tone_burst (MT_FE_DiSEqC_TONE_BURST mode)
Descriptions:
This function sets to send tone burst signal though DiSEqC interface.
Arguments:
MT_FE_DiSEqC_TONE_BURST mode -- Send modulated or unmodulated tone burst signal.
Return:
MT_FE_RET
3.4.2.1 MT_FE_DiSEqC_TONE_BURST
typedef enum _MT_FE_DiSEqC_TONE_BURST
{
MtFeDiSEqCToneBurst_Moulated = 0, // modulated tone burst
MtFeDiSEqCToneBurst_Unmoulated // unmodulated tone burst
} MT_FE_DiSEqC_TONE_BURST;
3.4.3 Message Transmission Through DiSEqC Interface
MT_FE_RET mt_fe_rs2k_DiSEqC_send_receive_msg (MT_FE_DiSEqC_MSG msg)
Descriptions:
This function sends or receive message through DiSEqC interface.
Arguments:
MT_FE_DiSEqC_MSG msg -- Send or receive DiSEqC messages.
Return:
MT_FE_RET
3.4.3.1 MT_FE_DiSEqC_MSG
This structure sets the DiSEqC message format.
typedef struct _MT_FE_DiSEqC_MSG
{
U8 data_send[8]; // max 8 bytes to be sent
U8 size_send; // actual bytes to be sent

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 9
BOOL is_enable_receive; // receive reply message or not
U8 data_receive[8]; // max 8 bytes to store received message data
U8 size_receive; // actual received bytes
} MT_FE_DiSEqC_MSG;
3.4.4 Examples Of Control DiSEqC Devices
There are two kinds of frequently used DiSEqC devices: DiSEqC switches and DiSEqC motors. We give examples for
these two types of devices. For any other DiSEqC devices' usage or more details, please refer to the device operation
manual or DiSEqC standards.
3.4.4.1 DiSEqC Switches
Figure 2. Application Of DiSEqC Switch
DiSEqC Commands Example:
MT_FE_DiSEqC_MSG msg;
msg.data_send[0] = 0xE0; /*Framing Byte*/
msg.data_send[1] = 0x10; /*Address Byte*/
msg.data_send[2] = 0x38; /*Command Byte*/
msg.data_send[3] = 0xF0 + (port - 1)*4; /*Data Byte*/
msg.size_send = 4; /*Data size to be sent*/
msg.is_enable_receive = FALSE; /*Do not receive the reply messages*/
if(18V) msg.data_send[3] |= 0x02; /*Bit 1 set 1*/
if(22K on) msg.data_send[3] |= 0x01; /*Bit 0 set 1*/
mt_fe_rs2k_DiSEqC_send_receive_msg(msg);
DiSEqC Switch
Receiver
Port 1 Port 2 Port 3 Port 4
Sat A Sat B
Sat A: Single Local Osc
Sat B: Dual Local Osc

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 10
3.4.4.2 DiSEqC Motors
3.4.4.2.1 Drive The Motor To Rotate
There are two rotated directions (East and West). And there is two frequently used rotate modes (Step mode and
Continuous mode). If the step mode is selected to rotate the motor, it will stop automatically. If the continuous mode is
selected, the motor will keep rotating until it receives stop commands.
DiSEqC Commands Example:
MT_FE_DiSEqC_MSG msg;
direction = MT_FE_ROTATE_EAST ? 0x68 : 0x69; /*Rotate to the East?*/
rotate_mode = MT_FE_ROTATE_STEP ? 0xFF : 0x00; /*Step mode?*/
msg.data_send [0] = 0xE0; /*Framing Byte*/
msg.data_send [1] = 0x31; /*Address Byte*/
msg.data_send [2] = direction; /*Command Byte1*/
msg.data_send [3] = rotate_mode; /*Command Byte2*/
msg.size_send = 4; /*Data size to be sent*/
msg.is_enable_receive = FALSE; /*Do not receive the reply messages*/
mt_fe_rs2k_DiSEqC_send_receive_msg(msg);
3.4.4.2.2 Stop The Motor Rotation
If the continuous rotate mode is selected, users should send the stop commands to stop the motor.
DiSEqC Commands Example:
MT_FE_DiSEqC_MSG msg;
msg.data_send[0] = 0xE0; /*Framing Byte*/
msg.data_send[1] = 0x31; /*Address Byte*/
msg.data_send[2] = 0x60; /*Command Byte*/
msg.size_send = 3; /*Data size to be sent*/
msg.is_enable_receive = FALSE; /*Do not receive the reply messages*/
mt_fe_rs2k_DiSEqC_send_receive_msg(msg);
3.5 Blind Scan (Optional)
This step is optional. If the satellite TP parameters are unknown, users can use the blind scan operation to search the
TPs.
3.5.1 Register Callback Function
MT_FE_RET mt_fe_rs2k_register_notify (void (*notify)(MT_FE_MSG msg, void* p_param))
Descriptions:

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 11
This function is to register a callback function and it is optional. The function defines users' action when blind scan
process send out some messages.
Arguments:
void (*notify)(MT_FE_MSG msg, void* p_param) -- Callback function.
Return:
MT_FE_RET
3.5.1.1 MT_FE_MSG
This enumeration defines the callback messages.
typedef enum _MT_FE_MSG
{
MtFeMsg_BSTpFind, // Find a TP
MtFeMsg_BSTpLocked, // The TP is valid
MtFeMsg_BSTpUnlock, // The TP is invalid
MtFeMsg_BSStart, // Start blind scan
MtFeMsg_BSFinish, // Blind scan finished
MtFeMsg_BSOneWinFinish, // Blind scan finished one window
MtFeMsg_BSAbort, // Abort current blind scan process
} MT_FE_MSG;
3.5.2 Search TPs In a Specific Band
MT_FE_RET mt_fe_rs2k_blindscan (U16 begin_freq_MHz, U16 end_freq_MHz, MT_FE_BS_TP_INFO *p_bs_info)
Descriptions:
This function blind scans TPs in a specific band.
Arguments:
U16 begin_freq_MHz -- Start frequency;
U16 end_freq_MHz -- End frequency;
MT_FE_BS_TP_INFO *p_bs_info -- Structure to store blind scan initialize data & results.
Return:
MT_FE_RET
3.5.2.1 begin_freq_MHz & end_freq_MHz
These two varibles define the frequency band of blind scan. Usually, the start frequency is 950MHz, and the end
frequency is 2150MHz. Users can modify the frequency band according to the requirement.
3.5.2.2 MT_FE_BS_TP_INFO
This structure defines the structure to store blind scan initialized data and results.
typedef struct _MT_FE_BS_TP_INFO
{
U8 bs_times; // blind scan times

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 12
U8 bs_algorithm; // blind scan algorithm
U16 tp_num; // scanned TP number
U16 tp_max_num; // max TP number
MT_FE_TP_INFO *p_tp_info; // all scanned TPs' array
} MT_FE_BS_TP_INFO;
Relative Variables:
1. bs_times -- Define blind scan times (bs_times > 0, and bs_times = 1 or 3 is strongly recommended).
Sometimes select 1 time blind scan may lose some weak signal or special TPs, and then choose 3 times blind
scan may improve the blind scan performance. But 3 times blind scan will spend much longer time. If times > 1,
the first time will ignore all TPs which symbol rate < 10000. And the second time scans all TPs. The third time
ignore all symbol rate >= 10000 TPs.
2. bs_algorithm -- Select blind scan method.
a. MT_FE_BS_ALGORITHM_A -- Try to lock scanned new TPs after every window is scanned over. One
window bandwidth is about 40MHz.
b. MT_FE_BS_ALGORITHM_B -- Try to lock scanned new TPs after 1 time blind scan finished.
3.5.3 Stop a Blind Scan Process
MT_FE_RET mt_fe_rs2k_blindscan_abort (void)
Descriptions:
This function can use to stop the blind scan process and it is optional. When the scan is in process, users can stop the
scan by call this function.
3.5.4 Blind Scan Example
3.5.4.1 Blind Scan Parameters Configuration
MT_FE_BS_TP_INFO bs_tp_info;
bs_tp_info.bs_times = 1; // blind scan times
bs_tp_info.bs_algorithm = MT_FE_BS_ALGORITHM_B; // blind scan method
bs_tp_info.tp_num = 0; // current TP number
bs_tp_info.tp_max_num = 200; // max TP number
bs_tp_info.tp_info=
(MT_FE_TP_INFO *)malloc(sizeof(MT_FE_TP_INFO) * bs_tp_info.tp_max_num);
// array to save the scanned TP data
Relative Variables:
1. bs_tp_info.bs_times = 1;
Note: Select blind scan times. If user does care about the blind scan speed, 1 time blind scan is a better choice.
Otherwise user can select 3(or 2, more than 3 is not recommended) times blind scan, and some weak signals or special
signals can be found.
2. bs_tp_info.bs_algorithm = MT_FE_BS_ALGORITHM_B;

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 13
Note: Select blind scan algorithm. User can choose method A or B. Method A means try to lock new found TPs after
every screen is scanned over. If user wants to know the detail blind scan progress, user can choose this method. One
screen's bandwidth is about 40MHz. Method B means try to lock new found TPs after one time blind scan is completed.
If user only wants to know the overall blind scan result of each time, method B is a better choice.
3. bs_tp_info.tp_num = 0;
Note: Count the number of found TP, the initialize value must be 0.
4. bs_tp_info.tp_max_num = 200;
Note: Configure the maximum TP number. Since the fake TPs may be occured, it is strongly recommended to set a big
number of the maximum TP number.
5. bs_tp_info.tp_info = (MT_FE_TP_INFO *)malloc(sizeof(MT_FE_TP_INFO) * bs_tp_info.tp_max_num);
Note: The structure stores the found TPs' data.
3.5.4.2 Start Blind Scan
MT_FE_RET mt_fe_rs2k_blindscan(U16 begin_freq_MHz, U16 end_freq_MHz, MT_FE_BS_TP_INFO *p_bs_info);
After configuration, user can call this function to start the blind scan procedure.
3.5.4.3 Stop Blind Scan
MT_FE_RET mt_fe_rs2k_blindscan_abort(void);
This function can be called to interrupt the blind scan procedure.
3.6 Manual Search
3.6.1 Lock a Specific TP
MT_FE_RET mt_fe_rs2k_connect (U32 freq_KHz, U16 sym_rate_KSs, MT_FE_RS2K_CODE_RATE_SEL code_rate,
MT_FE_LOCK_STATE *p_lock_state);
Descriptions:
This function is used to lock a specific channel (TP). If locked, M88RS2000 will set to the channel (TP) and output the TS
with a defined MPEG TS output mode.
Arguments:
U32 freq_KHz -- TP frequency;
U16 sym_rate_KSs -- TP symbol rate;
MT_FE_RS2K_CODE_RATE_SEL code_rate -- TP code rate;
MT_FE_LOCK_STATE *p_lock_state -- TP lock state, store the connect operation result.
Return:
MT_FE_RET
3.6.1.1 MT_FE_LOCK_STATE
This enumeration sets TP lock state flag.
typedef enum _MT_FE_LOCK_STATE
{
MtFeLockState_Undef = 0, // Initialize TP state
MtFeLockState_Locked, // TP state locked

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 14
MtFeLockState_Unlocked, // TP state unlocked
MtFeLockState_Waiting // TP state waiting, wait for the lock process finished (Not used in M88RS2000,
reserved for other project use.)
} MT_FE_LOCK_STATE;
3.6.1.2 MT_FE_RS2K_CODE_RATE_SEL
This enumeration sets code rate parameter. If the correct code rate parameter is unknown, user can set
MtFeRs2kCodeRateSel_Undef or MtFeRs2kCodeRateSel_All and the receiver will set the correct parameter
automatically.
typedef enum _MT_FE_RS2K_CODE_RATE_SEL
{
MtFeRs2kCodeRateSel_Undef = 0, // Undefined
MtFeRs2kCodeRateSel_1_2 = 0x08, // 1/2
MtFeRs2kCodeRateSel_2_3 = 0x10, // 2/3
MtFeRs2kCodeRateSel_3_4 = 0x20, // 3/4
MtFeRs2kCodeRateSel_5_6 = 0x40, // 5/6
MtFeRs2kCodeRateSel_7_8 = 0x80, // 7/8
MtFeRs2kCodeRateSel_All = 0xf8 // All, Auto
} MT_FE_RS2K_CODE_RATE_SEL;
3.6.2 Stop Connecting
MT_FE_RET mt_fe_rs2k_connect_abort (void);
Sometimes a connect operation may delay a long time to try frequency offset. User can interrupt the connecting
manually by call this function.
3.7 Get TP & Signal Information
After the connect operation, users can get the lock status and monitor the signal information.
3.7.1 Get TP Lock Status
MT_FE_RET mt_fe_rs2k_get_lock_state (MT_FE_LOCK_STATE *p_lock_state);
Descriptions:
This function gets TP lock status.
Arguments:
MT_FE_LOCK_STATE* p_lock_state-- TP lock state.
Return:
MT_FE_RET
3.7.1.1 Get SNR
MT_FE_RET mt_fe_rs2k_get_snr (S32 *p_snr);
Descriptions:
This function gets signal SNR (Signal Noise Ratio).

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 15
Arguments:
S32 *p_snr -- Signal SNR.
Return:
MT_FE_RET
3.7.1.2 Get BER
MT_FE_RET mt_fe_rs2k_get_ber (U32 *p_total_bit, U32 *p_err_bit);
Descriptions:
This function gets BER (Bit Error Ratio). Note: BER = (p_err_bit / p_total_bit) * 100%.
Arguments:
U32 *p_total_bit -- Total bit;
U32 *p_err_bit -- Error bit.
Return:
MT_FE_RET
3.7.1.3 Get Signal Gain
MT_FE_RET mt_fe_rs2k_get_signal_gain (U32* gain);
Descriptions:
This function gets signal gain (include tuner part and demodulator part).
Arguments:
U32 *gain -- Gain value.
Return:
MT_FE_RET
3.7.1.4 Get Signal Strength
MT_FE_RET mt_fe_rs2k_get_strength (S8 *p_strength);
Descriptions:
This function gets signal strength by signal gain. This is a reference function. User can modify it if need.
Arguments:
S8 *p_strength -- Reference strength.
Return:
MT_FE_RET
3.7.1.5 Get Code Rate
MT_FE_RET mt_fe_rs2k_get_FEC (MT_FE_CODE_RATE *code_rate);
Descriptions:
This function gets signal code rate information.
Arguments:
MT_FE_CODE_RATE *code_rate -- Signal FEC indicator.

M88RS2000
Driver User’s Manual
Montage Technology Confidential and Proprietary 16
Return:
MT_FE_RET
4 Other APIs
4.1 Get Driver’s Version Number
MT_FE_RET mt_fe_rs2k_get_driver_version (U32* p_version);
Descriptions:
This function gets the driver’s version number.
Arguments:
U32 *p_version -- Driver’s version number.
Return:
MT_FE_RET
4.2 Software Reset
MT_FE_RET mt_fe_rs2k_soft_reset (void);
Descriptions:
This function can soft reset the receiver.

Contact Information
Montage Technology, Inc.
Address: 2025 Gateway Place, Suite 262, San Jose, CA 95110, USA
Tel: +1 408-982-2788
Fax: +1 408-982-2789
Email: [email protected]
Montage Technology (Shanghai) Co., Ltd.
Address: Suite 406, Innovation Center, 680 Guiping Road, Shanghai 200233, China
Tel: +86 21 51696833
Fax: +86 21 54263132
E-mail: infosh@montage-tech.com
Website: www.montage-tech.com
M88RS2000
Driver User’s Manual
Table of contents