8051 core.
256 bytes internal RAM.
8K bytes program Mask ROM.
14 channels 10V open drain PWM DAC, 10 dedicated channels and 4 channels shared with I/O pin.
20 bi-direction I/O pin, 12 dedicated pin, 4 shared with DAC, 4 shared with DDC/IIC interface.
3 output pins shared with H/V sync output and self test output pins.
SYNC processor for composite sync separation, polarity and frequency check, and polarity adjustment.
Built-in monitor self test pattern generator.
Built-in Low Power Reset circuit.
IIC interface for DDC1/DDC2B and EEPROM, only one EEPROM needed to store DDC1/DDC2B and
display mode information.
Watch dog timer with programmable interval.
40 pin PDIP package.
GENERAL DESCRIPTION
The MTV012A micro controller is an 8051 CPU core-embedded device specially tailored to CRT monitor
applications. It includes an 8051 CPU core, 256-byte SRAM, 14 built-in PWM DACs, DDC1/DDC2B
interface, 24Cxx series EEPROM interface and an 8K-byte internal program ROM.
BL OCK DIAGRAM
STOUT
P1.0-7
X1
X2
P2.0-3
P3.0-P3.2
8051
CORE
P3.4
P0.0-7
RD
WR
INT1
RST
P2.4-7
P0.0-7
XFR
RD
WR
WATCH-DOG
TIMER
RST
H/VSYNC
CONTROL
14 CHANNEL
PWM DAC
HSYNC
VSYNC
HBLANK
VBLANK
DA0-9
DA10-13
HSCL
HSDA
This datasheet contains new product information. Myson Technology reserv es the rights to modify the product specification
without notice. No liability is assumed as a result of the use of this product. No rights under any patent accompany the sale of the
product.
I9Active high reset.
I/O10IIC clock / General purpose I/O / Rxd.
I/O11IIC data / General purpose I/O / Txd.
I/O12IIC data / General purpose I/O / INT0.
I13Horizontal SYNC or composite SYNC.
I/O14IIC clock / General purpose I/O / T0.
I15Vertical SYNC.
O16Horizontal blank / General purpose output.
O17Vertical blank / General purpose output.
O18Oscillator output.
MTV012A includes all the 8051 functions with the following exceptions:
1.1 PSEN, ALE, RD and WR pins are disabled. The external RAM access is restricted to XFRs within
MTV012A.
1.2 Port0, port3.3 and ports3.5 ~ 3.7 are not general purpose I/O ports. They are dedicated to monitoring
control/DAC pins.
1.3 INT1 and T1 input pins are not provided.
1.4 Ports2.4 ~ 2.7 are shared with DAC pins; ports3.0 ~ 3.2 and port3.4 are shared with monitor control
pins.
In addition, there are 2 timers, 5 interrupt sources and a serial interface compatible with the standard
8051. The Txd/Rxd (P3.0/P3.1) pins are shared with the DDC interface. INT0/T0 pins are shared with
the IIC interface. An extra option can be used to switch the INT0 source from P3.2 to P2.0. This feature
maintains an external interrupt source when the IIC interface is enabled.
Note: All regis t ers lis t ed in thi s doc u m ent resid e in the external RAM area (XFR). For the intern al
RAM memory map , please refer to th e 8051 spec.
The XFR is a group of registers allocated in the 8051 external RAM area. Most of the registers are used
for monitor control or PWM DAC. The program can initialize Ri value and use "MOVX" instruction to
access these registers.
3. PWM DAC
Each D/A converter's output pulse width is controlled by an 8-bit register in the XFR. The frequenc y of
these outputs is (Xtal frequency)/253 or (Xtal frequency)/256, selected by DIV253. If DIV253=1, writing
FDH/FEH/FFH to the DAC register generates a stable high output. If DIV253=0, the output will pulse low
at least once even if the DAC register's content is FFH. Writing 00H to the DAC register generates stable
low output.
DA0 (r/w) :The output pulse width control for DA0.
DA1 (r/w) :The output pulse width control for DA1.
DA2 (r/w) :The output pulse width control for DA2.
DA3 (r/w) :The output pulse width control for DA3.
DA4 (r/w) :The output pulse width control for DA4.
DA5 (r/w) :The output pulse width control for DA5.
DA6 (r/w) :The output pulse width control for DA6.
DA7 (r/w) :The output pulse width control for DA7.
DA8 (r/w) :The output pulse width control for DA8.
DA9 (r/w) :The output pulse width control for DA9.
DA10 (r/w) :The output pulse width contro l f or DA10.
DA11 (r/w) :The output pulse width contro l f or DA11.
DA12 (r/w) :The output pulse width control for DA12.
DA13 (r/w) :The output pulse width contro l f or DA13.
WDT (w) :Watchdog timer & special control bit.
DIV253 = 1→ The PWM DAC output frequency is (Xtal frequency)/253.
= 0→ The PWM DAC output frequency is (Xtal frequency)/256.
*1. All D/A converters are centered with value 80h after power-on.
DA0
DA1
DA2
DA3
DA4
DA5
DA6
DA7
DA8
DA9
DA10
DA11
DA12
DA13
b0
b0
b0
b0
b0
b0
b0
b0
b0
b0
b0
b0
b0
b0
4/14
MTV012A Revision 1.1 12/23/1998
Page 5
MYSON
MTV012A
TECHNOLOGY
4. H/V SYNC Proces sing
The H/V SYNC processing block performs the functions of composite signal separation , SYNC input
presence check, frequency counting, and polarity detection and control, as well as protection of
VBLANK output while VSYNC speeds up to a high DDC comm unication clock rate. The present and
frequency function block treat any pulse shorter than 1 OSC period as noise.
4.1 Composite SYNC Separate
MTV012A continuously monitors the input HSYNC. If the vertical SYNC pulse can be extracted from the
input, a CVpre flag is set and the user can select the extracted "CVSYNC" for the source of polari ty
check, frequency count and VBLANK. The CVSYNC will have a 10-16 us delay compared to the original
signal. The delay depends on the OSC frequency and composite m ix method.
4.2 H/V Frequency Counter
MTV012A can discriminate between HSYNC/VSYNC frequency and saves the information in XFRs. The
15-bit H counter counts the time of the 64xHSYNC period, but only 11 upper bits are loade d into the
HCNTH/HCNTL latch.
The 11-bit output value will be (2/Hfreq) / (1/OSCfreq), updated once per VSYNC/CVSYNC period when
VSYNC/CVSYNC is present, or continuously updated when VSYNC/CVSYNC is not present. The 14-bit
V counter counts the time between 2 VSYNC pulses, but only 9 upper bits are loaded i nto the
VCNTH/VCNTL latch. The 9-bit output value will be (1/Vfreq) / (512/OSCfreq), updated every
VSYNC/CVSYNC period. An extra overflow bit indicates the condition of H/V counter overflow. The
VFchg/HFchg interrupt is active when VCNT/HCNT value changes or overflows. Tables 4.2.1 and 4.2.2
show the HCNT/VCNT value under the 8MHz OSC operations.
4.2.1 H-Freq Table
H-Freq(KHZ)
1
2
3
4
5
6
7
8
9
10
11
12
13
*1. The H-Freq output (HF10 - HF0) is valid.
*2. The tolerance deviation is + 1 LSB.
*1. The V-Freq output (VF8 - VF0) is valid.
*2. The tolerance deviation is + 1 LSB.
4.3 H/V Present Check
The H present function checks the input HSYNC pulse; the Hpre flag is set when HSYNC is over 10KHz
or cleared when HSYNC is under 10Hz. The V present function checks the input VSYNC pulse; the Vpre
flag is set when VSYNC is over 40Hz or cleared when VSYNC is under 10H z. The control bit "PREFS"
selects the time base for these functions. The HPRchg interrupt is set when the Hpre value changes.
The VPRchg interrupt is set when the Vpre/CVpre values change. However, the CVpre flag interrupt
may be disabled when S/W disables the composite function.
4.4 H/V Polarity Detection
The polarity functions detect the input HSYNC/VSYNC high and low pulse duty cycle. If the high pulse
duration is longer than that of the low pulse, the negative polarity is asserted; otherwise, positive polarity
is asserted. The HPLchg interrupt is set when the Hpol value changes. The VPLchg interrupt is set when
the Vpol value changes.
60.53102h / 258183h / 387
66.670EAh / 23415Fh / 351
70.0690DEh / 22214Eh / 334
70.080DEh / 22214Eh / 334
720D9h /217145h / 325
72.3780D7h / 215143h / 323
72.70D6h / 214142h / 322
870B3h / 17910Dh / 269
4.5 Output HBLANK/VBLANK Control and Polarity Adjustment
HBLANK is the MUX output of HSYNC and the self-test horizontal pattern. The VBL ANK is the MUX
output of VSYNC, CVSYNC and the self-test vertical pattern. The MUX selection and output polarity are
S/W controllable. The VBLANK output is cut off when VSYNC frequency is over 200Hz or 133Hz
depends on 8MHz/12MHz OSC selection. HBLANK/VBLANK shares the output pin with P4.1/ P4.0.
4.6 Self-Test Pattern Generator
This generator can generate 4 display patterns for testing purposes: positive cross-hatch, negative
cross-hatch, full white and full black (shown in the following figure). It was originally designed to support
monitor manufacturers to do a burn-in test, or offer the end-user a reference to check the monitor. The
generator's output STOUT shares the output pin with P4.2.
C1, C0 = 1,1→ Selects CVSYNC as the polarity, freq and VBLANK source.
= 1,0→ Selects VSYNC as the polarity, freq and VBLANK source.
= 0,0→ Disables composite function (MTV012 compatible mode).
= 0,1→ H/W auto switch to CVSYNC when CVpre =1 and VSpre=0.
HVsel = 1→ Pin #16 is P41, pin #17 is P40.
= 0→ Pin #16 is HBLANK, pin #17 is VBLANK.
STOsel = 1→ Pin #29 is P42.
= 0→ Pin #29 is STOUT.
PREFS = 0→ Selects 8MHz OSC as H/V present check and self-test pattern time base.
= 1→ Selects 12MHz OSC as H/V present check and self-test pattern time base.
HALFV = 1→ VBLANK is half frequency output of VSYNC.
HB
P4OUT (w) :Port 4 data output value.
INTFLG (w) : Interrupt flag. An interrupt event will set its individual flag, and, if the corresponding
interrupt enable bit is set, the 8051 core's INT1 source will be driven by a zero level.
Software MUST clear this register while serving the interrupt routine.
= 0→ Clears HSYNC frequency change f lag.
VFchg = 1→ No action.
= 0→ Clears VSYNC frequency change flag.
INTFLG (r) : Interrupt flag.
HPRchg= 1→ Indicates an HSYNC presence change.
VPRchg= 1→ Indicates a VSYNC presence change.
HPLchg= 1→ Indicates an HSYNC polarity change.
VPLchg= 1→ Indicates a VSYNC polarity change.
HFchg = 1→ Indicates an HSYNC frequency change or counter overflow.
VFchg = 1→ Indicates a VSYNC frequency change or counter overflow.
5.1 DDC1 Mode
MTV012A enters DDC1 mode after reset. In this mode, VSYNC is used as a data clock when the HSCL
pin remains at high. The data stream taken from an 8-bit FIFO in MTV012A is sent in a 9-bit packet that
includes a null bit (=1) as packet separator. The software program should tak e care of the FIFO depth.
The FIFO generates a FIFOI interrupt when there are fewer than N (N = 1, 2, 3 or 4 controlled by LS1,
LS0) bytes to be output to the HSDA line. On the other hand, the FIFO sets the FIFOH flag when there
are more than 7 bytes queuing for output. The FIFOI interrupt can be enabled or disab led by S/W. A
simple way to control FIFO is to set {LS1,LS0}={1,0} and enable FIFOI, then load FIFO 4 bytes every
time a FIFOI interrupt occurs. A special control bit "LDFIFO" can reduce S/W effort when EDID data is
saved in EEPROM. If LDFIFO=1, FIFO will be automatically loaded when S/W reads MBUF XFR.
5.2 DDC2B Mode
MTV012A switches to DDC2B mode when it detects a high to low transition on the HSCL pin. Once
MTV012A enters DDC2B mode, the host can access the EEPROM using IIC bus protocol as if the
HSDA and HSCL are directly bypassed to ISDA and ISCL pins. MTV012A will return to DDC1 mode if
HSCL is kept high for a 128-VSYNC clock period. However, it will permanently remain in DDC2B mode
if a valid IIC access has been detected on the HSCL/HSDA bus. The DDC2 flag reflects the current DDC
MTV012A Revision 1.1 12/23/1998
9/14
Page 10
MYSON
MTV012A
TECHNOLOGY
status; S/W may clear it by setting CLRDDC. The control bits M128/M256 are used to b lock the
EEPROM write operation from the host if the address is over 128/256.
5.3 Master Mode IIC Function Block
The master mode IIC block is connected to the ISDA and ISCL pins. The software program can access
the external EEPROM through this interface. Since the EDID/VDIF data and the display information
share the common EEPROM, precaution must be taken to avoid bus conf lict. In DDC1 mode, the IIC
interface is controlled by MTV012A only. In DDC2B mode, the host may access the EEPROM directly.
Software can test the HSCL condition by reading the BUSY flag, which is set in case of HSCL=0. A
summary of master IIC access is illustrated as follows:
5.3.1. To Write EEPROM
1. Write to MBUF the EEPROM slave address (bit 0 = 0).
2. Set S bit to Start.
3. After MTV012A transmits this byte, a MI interrupt will be triggered.
4. The program can write MBUF to transfer the next byte, or set the P bit to stop.
* Please see the attachments about "Master IIC Transmission Timing".
5.3.2. To Read EEPROM
1. Write to MBUF the slave address (bit 0 = 1).
2. Set the S bit to Start.
3. After MTV012A transmits this byte, a MI interrupt will be triggered.
4. Set or reset the ACK flag according to the IIC protocol.
5. Read out to MBUF the useless byte in order to continue the data transfer.
6. After MTV012A receives a new byte, the MI interrupt is triggered again.
7. Reading MBUF also triggers the next receiving operation, but the P bit needs to be set before reading
can terminate the operation.
* Please see the attachments about the "Master IIC Timing Receiving".
5.4 Slave Mode IIC Function Block
The slave mode IIC block can be connected to HSDA/HSCL pins or ISDA/ISCL pins, and selected by the
SLVsel control bit. This block is receiving mode only. S/W may set the SLVADR register to determine the
address range to which this block should respond. The block first detects an IIC slave address match
condition, then issues a SLVMI interrupt. The data received from SDA is shifted onto the shift register
and moved to the SLVBUF latch. The first byte loaded is the word address (the slave address is
dropped). This block also generates a SLVBI each time the SLVBUF is loaded. If S/W can't read out the
SLVBUF in time, the next byte will not be written to SLVBUF and the slave block returns NACK to the
master. This feature guarantees the data integrity of communication. A WADR flag can tell S/W if the
data in SLVBUF is a word address.
* Please see the attachments about "Slave IIC Block Timing".
6. Low Power Reset (LVR) & Watch d o g Tim er
When the voltage level of the power supply is below 4.0V for a specific time, the LVR will generate a chip
reset signal. After the power supply is above 4.0V, LVR maintains the reset state for a 144 Xtal cycle to
guarantee that the chip exit reset condition has a stable Xtal oscillation. The specific time of power
supply in the low level is 3us and is adjustable by an external capacitor connected to the RST pin.
The watchdog timer automatically generates a device reset when it overflows. The interval of overflow is
0.25 sec x N, in which N is a number from 1 to 8, and can be programmed via register WDT(2:0). The
timer function is disabled after power-on reset; the user can activate this function by setting WEN, and
clear the timer by setting WCLR.
LS1, LS0= 11→ FIFOL is the status which has a FIFO depth of < 5.
= 10→ FIFOL is the status which has a FIFO depth of < 4.
= 01→ FIFOL is the status which has a FIFO depth of < 3.
= 00→ FIFOL is the status which has a FIFO depth of < 2.
LDFIFO = 1→ FIFO will be written while S/W reads MBUF.
M256= 1→ Disables host writing EEPROM when address is over 256.
M128= 1→ Disables host writing EEPROM when address is over 128.
ACK= 1→ In receiving mode, there is no acknowledgment by MTV012A.
= 0→ In receiving mode, ACK is returned by MTV012A.
S, P= ↑,0→ Start condition when Master IIC is not transferring.
= X,↑→ Stop condition when Master IIC is not transferring.
= 1,X→ Will resume transfer after a read/write MBUF operation.
= X,0→ Forces HSCL low and occupies the IIC bus.
* MTV012A uses a 100KHz clock to sample the S/P bit; any pulse should sustain at least 20us.
* A write/read MBUF operation can be recognized only after 10us of the MI flag's rising edg e.
MSTUS (r) : Master IIC interface status register.
SCLERR= 1→ The ISCL pin is pulled-low by other devices during the
transfer, and cleared when S=0.
DDC2= 1→ DDC2B is active.
= 0→ MTV012A remains in DDC1 mode.
BERR= 1→ IIC bus error, no ACK received from the slave, updated every time
when slave sends ACK on the ISDA pin.
HFREQ= 1→ MTV012A detects a higher than 200Hz clock on the VSYNC pin.
FIFOH= 1→ FIFO high indicated.
FIFOL= 1→ FIFO low indicated.
BUSY= 1→ Host drives the HSCL pin to low.
* While writing FIFO, the FIFOH/FIFOL flag will reflect the FIFO condition after 30us.
INTFLG (w) :Interrupt flag. An interrupt event will set its individual flag and, if the corresponding
interrupt enable bit is set, the 8051 INT1 source will be driven b y a zero level. Software
MUST clear this register while serving the interrupt routine.
FIFOI= 1→ No action.
= 0→ Clears FIFOI flag.
MI= 1→ No action.
= 0→ Clears Master IIC bus interrupt flag (MI).
INTFLG (r) : Interrupt flag.
FIFOI = 1→ Indicates the FIFO low condition; when EFIFO is set, MTV012A will be
interrupted by INT1.
MI= 1→ Indicates when a byte is sent/received to/from the IIC bus; when EEPI is
active, MTV012A will be interrupted by INT1.
INTEN (w) : Interrupt enabler.
EFIFO = 1→ Enables FIFO interrupt.
MTV012A Revision 1.1 12/23/1998
11/14
Page 12
MYSON
MTV012A
TECHNOLOGY
EMI= 1→ Enables master IIC bus interrupt.
MBUF (w) : Master IIC data shift register write; after START and before STOP condition, this
register will resume MTV012A's transmission to the IIC bus.
MBUF (r) : Master IIC data shift register read; after START and before STOP condition, this
register will resume MTV012A's receiving from the IIC bus.
WDT (w) : Watchdog timer control register.
WEN= 1→ Enables the watchdog timer.
WCLR= 1→ Clears the watchdog timer.
CLRDDC= 1→ Clears the DDC2 flag.
LVSEL= 1→ Low voltage reset will occur when VDD < 4.1V.
= 0→ Low voltage reset will occur when VDD < 3.6V.
WDT2: W DT0 = 0→ Overflow interval = 8 x 0.25 sec.
= 1→ Overflow interval = 1 x 0.25 sec.
= 2→ Overflow interval = 2 x 0.25 sec.
= 3→ Overflow interval = 3 x 0.25 sec.
= 4→ Overflow interval = 4 x 0.25 sec.
= 5→ Overflow interval = 5 x 0.25 sec.
= 6→ Overflow interval = 6 x 0.25 sec.
= 7→ Overflow interval = 7 x 0.25 sec.
= 0→ Slave IIC connects to HSDA/HSCL.
ESLVBI= 1→ Enables slave buffer interrupt.
ESLVMI= 1→ Enables slave address match interrupt.
SLVSTUS (r) : Slave IIC block status.
WADR= 1→ The data in SLVBUF is a word address.
SLVS= 1→ The slave block has detected a START; will be cleared when STOP
is detected.
SLVBI= 1→ SLVBUF has been loaded with a new data byte; reset by S/W
reading SLVBUF.
SLVMI= 1→ Slave block has detected the slave address match condition; cleared
by S/W writing 0 to SLVMI.
SLVINT (w) :Slave block interrupt. The SLVBI/SLVMI interrupt will set its flag, and, if the
corresponding interrupt enable bit is set, the 8051 INT1 source will be driven by a zero
level. Software MUST clear this register while serving the interrupt routine.
SLVMI= 1→ No action.
= 0→ Clears SLVMI.
SLVBUF (r) :Slave IIC data latch.
SLVADR (w) : Slave IIC address to which the slave block should respond.
12/14
MTV012A Revision 1.1 12/23/1998
Page 13
MYSON
MTV012A
TECHNOLOGY
4.0 Test Mode Condit io n
In normal application, users should not allow MTV012 to enter its test/program mode, outlined as
follows:
Maximum Supply VoltageVDD-0.3 to +6.0V
Maximum Input VoltageVin-0.3 to VDD+0.3V
Maximum Output VoltageVout-0.3 to VDD+0.3V
Maximum Operating TemperatureTopg0 to +70
Maximum Storage TemperatureTstg-25 to +125
o
C
o
C
5.2 Allow able Operating Conditi on s
at: Ta= 0 to 70 oC, VSS=0V
NameSymbolMin.Max.Unit
Supply VoltageVDD4.06.0V
Input "H" VoltageVih10.7 x VDDVDD +0.3V
Input "L" VoltageVil1-0.30.15 x VDDV
Operating Freq.Fopg-15MHz
Crystal FrequencyfXtal8MHz
PWM DAC FrequencyfDAfXtal=8MHz31.2531.62KHz
PWM DAC FrequencyfDAfXtal=12MHz46.87547.43KHz
HS Input Pulse WidthtHIPW fXtal=8MHz0.312uS
VS Input Pulse Width
HS Input Pulse WidthtHIPW fXtal=12MHz0.28US
VS Input Pulse Width
HSYNC to HBLANK Output JittertHHBJ5NS
H+V to VBLANK Output DelaytVVBD fXtal=8MHz16uS
H+V to VBLANK Output DelaytVVBD fXtal=12MHz10uS
VS Pulse Width in H+V Signal
VS Pulse Width in H+V Signal
fXtal=8MHz3US
fXtal=12MHz2US
fXtal=8MHz32uS
fXtal=12MHz20uS
6.0 PACK AGE DIMENSION
40 PIN PDIP 600 mil
1.981mm
+/-0.254
3.81mm
+/-0.127
3.302mm
+/-0.254
52.197mm +/-0.127
MTV 012
2.540mm0.457mm +/-0.1271.270mm +/-0.254
1.778mm
+/-0.127
0.254mm
(min.)
15.494mm +/-0.254
13.868mm +/-0.102
5o~7
16.256mm +/-0.508
6o +/-3
0.254mm
+/-0.102
0
o
MTV012A Revision 1.1 12/23/1998
14/14
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.