Melexis Datasheet MLX81115
Melexis Datasheet MLX81115
Datasheet
1. Features
Configurations
        MLX81115:        12 pin device in DFN12 4x4 package, 32kB Flash memory + 16kB ROM
Application Controller
        Internal RC-Oscillator (24 MHz default clock)
        16-bit MULAN MCU with
             o max. 32kByte Flash
             o 16kB ROM with MLX4 LIN firmware, MLX16 LIN boot-loader and MLX16 Application User
                 Library
             o 2048 Byte RAM
             o 512 Byte NVRAM with ECC (256 Byte for customer purpose)
        Math Co-processor for 32 bit MUL/DIV Operations
        LIN Protocol Controller according to LIN 2.x and SAE J2602
        Baudrate up to 19.2 kBaud
        Frame processing
        Low interrupt load to the application
IO configuration
        MLX81115
             o 2 x 3 high voltage I/Os with free configurable current sources (up to 48mA) for RGB
        Diagnostic capability for connected LED
        6x 16-bit PWM outputs
        Interrupt capability for all inputs
        Configurable wake up sources (LIN and IOs)
        10 bit ADC with DMA, conversion time <6us, multiple channels and 3 different reference voltages
Voltage Regulator
        Low standby current consumption of max. 38µA in sleep mode
        Integrated battery monitor including over- and under-voltage detection
Other Features
        Automotive Temperature Range of -40°C to 125°C
        28V jump start
        Integrated temperature sensor
Applications
        Any kind of LIN switch applications in automotive
        LIN slaves for LED lighting applications including RGB control
        LIN IO-Extension
Ordering Information
Part No. Temp. Code Package Code Option Code Packing Form Code
MLX81115 K LW AAD-123 RE
Legend:
Temperature Code:               K = -40 to 125°C
Package Code:                   LW = QFN/DFN with wettable flanks
Option Code:                    ABC = A – Major Hardware Design Revision, BC – ROM Code Revision
                                123 = Melexis Reserved
Packing Form:                   RE = Reel
Ordering example:               MLX81115KLW-AAD-100-RE
For the correct order code please contact our sales team. The contact details can be found in chapter Contact
Information.
2. Contents
1. Features .......................................................................................................................................................................................................... 1
2. Contents .......................................................................................................................................................................................................... 3
    2.1. List of Figures .......................................................................................................................................................................................... 6
    2.2. List of Tables............................................................................................................................................................................................ 7
    2.3. Abbreviations .......................................................................................................................................................................................... 9
3. References .................................................................................................................................................................................................... 10
4. Technical description .................................................................................................................................................................................... 11
    4.1. Package data DFN12 4x4 ....................................................................................................................................................................... 11
    4.2. IC Marking ............................................................................................................................................................................................. 12
    4.3. Pin out description ................................................................................................................................................................................ 13
    4.4. Electrical characteristics ........................................................................................................................................................................ 14
       4.4.1. Absolute maximum ratings............................................................................................................................................................ 14
       4.4.2. Operating conditions ..................................................................................................................................................................... 15
       4.4.3. Electrical parameter specification ................................................................................................................................................. 16
5. Typical application examples ........................................................................................................................................................................ 24
    5.1. Application Example MLX81115 ............................................................................................................................................................ 25
6. Block diagram................................................................................................................................................................................................ 26
7. System behavior description ......................................................................................................................................................................... 27
    7.1. The supply system ................................................................................................................................................................................. 27
    7.2. Power On .............................................................................................................................................................................................. 28
    7.3. Power Off .............................................................................................................................................................................................. 29
    7.4. System initialization and Trimming ....................................................................................................................................................... 30
    7.5. Entering SLEEP MODE (GO TO SLEEP MODE = GTSM) ........................................................................................................................... 30
    7.6. WAKE UP from SLEEP MODE ................................................................................................................................................................. 31
    7.7. System behavior in case of different under voltage conditions ............................................................................................................ 32
    7.8. Supply voltage VS over and under voltage detection ............................................................................................................................ 33
    7.9. Enter the Low Power Mode................................................................................................................................................................... 34
8. CPU core MULAN3 – MULtiple CPU with Analogue and Network support .................................................................................................... 35
    8.1. MULAN3 compared to MULAN2 ........................................................................................................................................................... 35
    8.2. MULAN3 CPU Performance ................................................................................................................................................................... 35
    8.3. Math Co-Processor ................................................................................................................................................................................ 35
    8.4. CPU Architecture ................................................................................................................................................................................... 36
    8.5. CPU Address space ................................................................................................................................................................................ 36
    8.6. Memory mapping .................................................................................................................................................................................. 37
9. IO Registers ................................................................................................................................................................................................... 39
    9.1. General.................................................................................................................................................................................................. 39
    9.2. System Protected ports ......................................................................................................................................................................... 39
    9.3. Standard ports....................................................................................................................................................................................... 41
10. Memories .................................................................................................................................................................................................... 45
    10.1. RAM sharing ........................................................................................................................................................................................ 45
    10.2. Flash sharing........................................................................................................................................................................................ 45
    10.3. Flash memory ...................................................................................................................................................................................... 45
       10.3.1. Flash Trimming ............................................................................................................................................................................ 46
       10.3.2. Flash ports ................................................................................................................................................................................... 47
    10.4. NVRAM................................................................................................................................................................................................ 47
       10.4.1. NVRAM organization ................................................................................................................................................................... 49
       10.4.2. NVRAM ports............................................................................................................................................................................... 50
11. Interrupts .................................................................................................................................................................................................... 51
    11.1. Introduction ........................................................................................................................................................................................ 51
    11.2. Interrupt sources ................................................................................................................................................................................. 51
       11.2.1. High level system interrupts ........................................................................................................................................................ 51
           11.2.1.1. Reset interrupt and watchdog ............................................................................................................................................. 51
           11.2.1.2. Stack error ........................................................................................................................................................................... 51
           11.2.1.3. Exception error .................................................................................................................................................................... 52
           11.2.1.4. Protection error ................................................................................................................................................................... 52
           11.2.1.5. Invalid address..................................................................................................................................................................... 52
           11.2.1.6. Program error ...................................................................................................................................................................... 52
       11.2.2. User block interrupts ................................................................................................................................................................... 52
    11.3. Interrupt management........................................................................................................................................................................ 52
       11.3.1. Interrupt enabling and masking .................................................................................................................................................. 52
       11.3.2. Pending interrupts....................................................................................................................................................................... 53
       11.3.3. Call and jump interrupts .............................................................................................................................................................. 53
    11.4. Interrupt priorities .............................................................................................................................................................................. 53
       11.4.1. User priority ................................................................................................................................................................................ 54
    11.5. Mlx16 interrupt table .......................................................................................................................................................................... 55
       11.5.1. Interrupt vectors ......................................................................................................................................................................... 56
    11.6. External Interrupts .............................................................................................................................................................................. 57
12. PWM ........................................................................................................................................................................................................... 60
    12.1. General introduction and features ...................................................................................................................................................... 60
2.3. Abbreviations
ADC            Analog Digital converter
API            Application Program Interface
ASSP           Application Specific Standard Product
CPU            Central Processing Unit
CRC            Cyclic Redundancy Code
DMA            direct memory access
EEPROM         Electrically Erasable/Programmable Read-Only Memories
ECC            Error Correction Code
ECU            Electronic Control Unit (with µ-Controller/µ-Processor)
HV             High Voltage Pin
IC             Integrated Circuit
ID             Identifier
IO             Input Output
IP             Intellectual Property
LIN            Local Interconnect Network
LSB            Least Significant Bit
NB             Narrow Body
NVRAM          Non-Volatile Random-Access Memory (EEPROM with separate RAM)
MCU            Microcontroller Unit
MSB            Most Significant Bit
OSI            Open Systems Interconnection Model
PHY            Physical Layer
PWM            Pulse Width Modulator
RAM            Random Access Memory
ROM            Read Only Memory
SBIF           Single Bit Interface
SMD            Surface Mount Device
SW             Switch
TBD            To Be Defined
3. References
Following documents are referred to in this document:
This documentation as well as application notes, SW tools, libraries and descriptions is not scope of this
specification and can be found under http://softdist.melexis.com/.
Please contact your Melexis Sales channel for getting access.
The descriptions in this document overrule the descriptions in the referred documents.
4. Technical description
4.1. Package data DFN12 4x4
The chip will be assembled in a 12Pin DFN 4x4 package with wettable flanks.
Please keep in mind that the package has tie bars. Landing pattern recommendations can be requested from
Melexis.
4.2. IC Marking
           DFN12 4x4
                MLX81115
                 Pin No.                            Voltage
                              Pin name                                                       Remarks and description
                                                     range
Package view
                                                              VS     1                  12    HV3
                                                                           MLX 81115
                                                                           DFN12 4x4
HV0 2 11 HV4
GND 3 10 HV5
HV1 4 9 GND
HV2 5 8 LIN_IN
GND 6 7 LIN_OUT
                                                                                        Limit         Limit
          Parameter                   Symbol                 Condition                                             Unit
                                                                                        Min           Max
                                                   t < 5 min                             -0.3          +28
                               VS                  t < 2h                                  -           +27
                                                   t < 500 ms                              -           +45
                                                   ISO 7637-2 pulse 1 [1]
                               VS.tr1                                                   -100
                                                   VS=13.5V, TA=(23 5)°C
Supply voltage                                     ISO 7637-2 pulse 2 [1]
                               VS.tr2                                                                 +75
                                                   VS=13.5V, TA=(23 5)°C
                                                   ISO 7637-2 pulses 3A, 3B [1]
                               VS.tr3                                                   -150          +100
                                                   VS=13.5V, TA=(23 5)°C
                                                   ISO 7637-2 pulses 5b [1]                                    V
                               VS.tr5                                                                 +45
                                                   VS=13.5V, TA=(23 5)°C
LIN Bus                        VLIN                T < 500ms                            -40           +40
                                                   ISO 7637-3 pulse 1 [2]
                               VLIN.tr1                                                 -100
                                                   VS=13.5V, TA=(23 5)°C
                                                   ISO 7637-2 pulse 2 [2]
                               VLIN.tr2                                                               +75
                                                   VS=13.5V, TA=(23 5)°C
                                                   ISO 7637-2 pulses 3A, 3B [2]
                               VLIN.tr3                                                 -150          +100
                                                   VS=13.5V, TA=(23 5)°C
Voltage on HV IOs              VIN_HV              Pins HV[6:0],                        -0.3          +45
Maximum latch–up free                              according to JEDEC JESD78,
                               ILATCH                                                   -250          250      mA
current at any pin                                 AEC-Q100-004
ESD capability of pin VS       ESD_VS_IEC          According to IEC 61000-4-2            -6            +6
according IEC 61000-4-2                            [6]
ESD capability of pin LIN      ESD_LIN_IEC         According to IEC 61000-4-2            -8            +8
according IEC 61000-4-2                            [6]                                                         kV
 [1]      ISO 7637-2 test pulses are applied to VS via a reverse polarity diode and blocking capacitor. Further
          information about the test conditions can be found in chapter 22.1.
 [2]      ISO 7637-3 test pulses are applied to LIN via a coupling capacitance of 1nF. Further information about
          the test conditions can be found in chapter 22.1.
          Reset:
               o    Triggered by hardware. When VS or VDDA or VDDD drop below a critical level, the complete
                    chip is powered down.
                o The analogue and digital supply regulators are disabled. No functionality is available in this
                    mode.
          Normal mode. Main application running
                o Microcontroller fully functional
                o Analogue fully functional
          Low power mode (managed via firmware). Digital part running at lower frequency (250kHz)
                o Microcontroller fully functional
                o LIN not possible
                o Analogue fully functional
          Under voltage: triggered by the hardware under voltage detection interrupt (EXT4_IT: UV_VS, see
           chapter 7.8 Supply voltage VS over and under voltage detection).
                o Microcontroller fully functional.
                o Power down behaviour can be managed via software.
                o Reduced current capability on HVx below VS=5.5V.
          Over voltage: triggered by the hardware over voltage detection interrupt (EXT4_IT: OV_VS, see chapter
           7.8 Supply voltage VS over and under voltage detection).
                o Microcontroller fully functional
                o Behaviour can be managed via software.
          Sleep Mode: Triggered by the software.
                o Microcontroller powered down
                o Digital and analogue supply powered down.
                o Sleep Mode and wake-up functionality running on help supply Vaux
                                                                                      Limit
          Parameter                  Symbol              Conditions                                          Unit
                                                                             Min       Typ        Max
 Supply Voltage Range                  VS                                    5.5                    18        V
 Ambient Temperature                   TA                                    -40                   125        °C
                                            Table 2 – Operating conditions
                                                                                             Limits
    Parameter                 Symbol                      Conditions                                              Unit
                                                                                    Min       Typ       Max
                                                   Global parameters
Normal working                                all pins are inputs, IC is trimmed,
                       Inom                                                                    6         10        mA
current                                       no DC loads
                                              all pins are inputs, chip in SLEEP
                                              MODE;
SLEEP MODE                                    VS=14V, TA=27°C                                            28           µA
                       Isleep
current                                       VS=18V, TA=85°C                                            38           µA
                                                     Frequencies
Tolerance of RC
                       frc_24M                fRC=24MHz                              -5                  +5            %
oscillator
Frequency separate
10kHz RC oscillator
                       frc_10k                                                       5         10        20        kHz
for the analogue
Watchdog
Temperature
                                                                                                                   frc_
dependency of the      ∆frc_10k/∆T                                                  -10%                10%
                                                                                                                   10k
10kHz RC oscillator
Startup time of the                           Not tested in production; for
system after Power     tstartup_POR           information only; time until                               500          s
On                                            internal dig reset is inactive
Startup time of the
                                              Not tested in production; for
system after
                       tstartup_SLEEP         information only; time until                               250          s
Release of SLEEP
                                              internal dig reset is inactive
MODE
                                   POR parameters (VS based; for information only)
POR off                Vpor_lh              only for information                              3.6                      V
POR on                 Vpor_hl              only for information                              3.15                     V
                       Vhyst_por
Hysteresis for POR                            only for information                  250                            mV
ON – resistance                                    VS>5.3V
                      VoutlHV                                                                      20       40           Ω
HVOUT                                              ANA_OUTF[15:0] = 0
                                                Open Drain constant current source
Output current                                     VS>5.3V
                      IoutlHV                                                               3               30       mA
HVOUT                                              ANA_OUTG[2] = 0
Output current
                                                                                                    3                mA
HVOUT stepsize
Output current                                      VS>6V
                      IoutlHV                                                               36              48       mA
HVOUT                                               ANA_OUTG[2] = 1
Output current
                                                                                                    6                mA
HVOUT stepsize
                                                    6V≤ VS ≤18V
Output current
                                    [1]             TA = 35°C                                               ±7           %
HVOUT relative        IoutlHV_err
                                                    3mA≤ Iout ≤30mA
error
Temperature
                      TC_Iout                                                                     -0.025             %/K
coefficient
                                                     Current for RGB monitor
                                                    HVENFCMx = 1
Monitor current       I_mon                                                                 0                2       mA
                                                    (Register page Table 65)
Output voltage
                      I_mon_voutswing                                                    VS-4               VS           V
swing
Relative current                                    TA = 25°C
                      I_mon_relcurerr                                                                        1           %
error (<100us)                                      TC saved in NVRAM
                                          [1]
S&H settling time     I_mon_SHsettl                                                                 5       10           us
                                [1]
Output current INL    I_mon_inl                                                                              1           %
Absolute Output                           [1]
                      I_mon_ageerr                                                                           1           %
current aging error
                                            Differential Amplifier for RGB monitor
Monitor Input                                     VS≥ 8.5V                                                               V
                      VIN_mon                                                          VS- 3.7             VS-1.5
Voltage Range
Diagnosis Input
                      VIN_diag                      VS≥ 8.5V                           VS- 4                VS           V
Voltage Range
                                                                                                  VRH3-
Output Voltage                                      Internal output range of sense                         VRH3
                      VOUT                                                              0         VIN*0.                 V
Range                                               amplifier                                              (ADC)
                                                                                                  2
Output Voltage                                      VIN_mon                                                  2           %
                      VOUT_err
relative error                                      VIN_diag                                                 5           %
Gain                  GAIN                                                                         0.2
                                                   Wake up related parameters
Wake up filter time                                 SLEEP MODE, HVx rising &
                      tWU                                                                   25              50           s
pins HVx                                            falling edge
                                                    Time for dominant level after
Wake up filter time
                      tWU_LIN                       SLEEP MODE                              30              150          s
pin LIN
                                           Temperature Sensor related parameters
                                               Temperature Shutdown circuit
                      Tot_on                                                                160    170      180          C
Over temperature                                    tested by special test mode only
                      Tot_off                                                               130    140      150          C
shutdown
                      Tot_hyst               [1]                                             10                          C
                                      Temperature Sensor (for ADC measurement)
Temperature range     Trange                 For information only              -40                          150          C
Accuracy              Tacc                   For information only              -10                          10           C
                                                                                                 Limits
          Parameter               Symbol                    Conditions                                                  Unit
                                                                                       Min        Typ       Max
                                                  VDDA related parameters
  3.3V supply                                    information parameter,
                            VDDA                                                        3.2       3.3        3.4         V
  voltage range (DC)                             with trimmed VBG
  Internal current
                            Iddint_VDDA          Only for information                                        10         mA
  capability
                                                  V1V8 related parameters
  1.8V supply
                            V1V8                 with trimmed VBG                      1.77      1.85       1.93         V
  voltage range
  Internal current
                            Iddint_VDDD          Only for information                                        10         mA
  capability
                                                  V5V6 related parameters
  5.6 supply voltage
                            V5V6                 with trimmed VBG                      5.69      5.75       5.81         V
  range
  current capability        Iddint_V5V6        Only for information                                          2          mA
                                             VDDA based UV RESET parameters
  Undervoltage
                            Vuvr_hl_VDDA         information parameter                  2.7      2.85        3           V
  reset on
  Undervoltage
                            Vuvr_lh_VDDA         information parameter                 2.85        3        3.15         V
  reset off
                            Vhyst_uvr_VDD
  Hysteresis for
                            A                    [1]                                    0.1                              V
  undervoltage reset
  Debouncing for
                            tuvr_VDDA            information parameter                  1          3         10         s
  UVR
                                             VDDD based UV RESET parameters
  Undervoltage
                            Vuvr_hl_VDDD         information parameter                 1.525      1.6       1.675        V
  reset on
  Undervoltage
                            Vuvr_lh_VDDD         information parameter                  1.6      1.675      1.75         V
  reset off
                         Vhyst_uvr_VDD
Hysteresis for
                         D                    information parameter, [1]           0.05                      V
undervoltage reset
Debouncing for
                         tuvr_VDDD            information parameter                 1       3      10       s
UVR
                                Table 4 – Electrical information parameters specification
 [1]
       Guaranteed by design & characterization, not tested in production
                                                                                      Limit
      Parameter                     Symbol              Conditions                                      Unit
                                                                             Min       Typ     Max
                                                  Pin LIN_IN
                                                 Transmitter
Short circuit bus                                 VBUS = VBAT, driver
                          IBUS_LIM                                            40               200       mA
current                                           on
Pull up resistance bus,
normal & standby          RSLAVE (LIN_IN)         VS=8V to 18V                28       30       40      kOhm
mode LIN_IN
                                                  VS = VGND=12V,
Bus current during                                0 < VBUS < 18V
                          IBUS_NO_GND
loss of ground                                    J2602                      -100              100
                                                                                                         µA
 [1]     This parameter is tested by applying a square wave signal to the LIN. The access to internal signals
         RxD,TxD will be performed by test mode. The minimum slew rate for the LIN rising and falling edges is
         50V/us.
 [2]     See Figure 2: LIN timing diagram
 [3]     Standard loads for duty cycle measurements are 1KΩ/1nF, 660Ω/6.8nF, 500Ω/10nF, internal termination
         disabled
 [4]     In accordance to SAE J2602
 [5]     Parameter in relation to internal signal TxD
 [6]     Guaranteed by design & characterization, not measured in production
 [7]     Trim value saved in NVRAM
VS
             VBat                                                                   HV0
                                                                                               0 ... 48mA
                                                      VS                                  VS
                      Optional
                      component
                                                                                    HV1
                                                                                               0 ... 48mA
                                                                                          VS
                                                                MLX81115
                                                                                    HV2
                                                                                               0 ... 48mA
VS
                                                                                    HV3
                                                                                                0 ... 48mA
Optional components VS
LIN_IN
                                                       LIN_OUT                      HV4
                                                                                                0 ... 48mA
VS
                                                      EXP
                                                      GND                           HV5
                                                                                               0 ... 48mA
MLX81115 offers more flexibility due to the higher pin count making 3 additional HV pins available. They can be
used to drive a second RGB-LED.
6. Block diagram
                                                                                                                     VDDA
                                                    ADCx
                                                                                                                  UVLO
                                                                                      Aux Supply +
                                                    INTx                              WakeUp Logic           POR / AWD
            HV0                                     HVDIN
                                                    HVINEN                     WakeUp LIN
            HV1
                                       HVDOUTB
                                       PWMx Out
                                                                                     WakeUp HVx
            HV2
                                       LIN Dig TX
            HV3     0 ... 48mA
            HV4
            HV5
                      ADCx ... ADCVS
                                 ...
                                                                  PWM5 ... 0
...
                    ADC                                           16-bit
                    Divider                                                           Test/Debug
                                                                                                                               GND
                    and Mux
                                                                  PWM                  Interface
                                                           INT                                                LIN Autoconfig
                                                                                                                               LIN _OUT
                                                                  RC-Osc.
                      10-bit ADC                                                                     to ADC MUX
                  Window                                                                                                       LIN_IN
                   WD                                                                         LIN                 LIN
                                           MCU-Core                                         Controller            PHY
                  Timer
                  16kByte                                  2048byte    512byte
                                   32kByte Flash
                   ROM                                       RAM       NVRAM
To guarantee a certain remaining charge for finalize the writing process of the non-volatile memory, in case of
an VBAT drop, the capacitor value on VS has to be calculated depending on the current consumption of the
complete module.
A second smaller value ceramic capacitor is needed to stabilize VS for emission reasons, to ensure a stable
application in case of negative transients.
7.2. Power On
The following block diagram shows an overview over the different Power supplies and the reset circuits:
VS
TRIMVDDA TRIMVDDD
                                                                    VDD                VDD
                                           VDD                   UV_ VDDA          UV_ VDDD
                        POR
                                          Bandgap     VBG
                   IN VLH:3.6V OUT                                        OUT                OUT
                                          (1.2xV) OUT       IN    VLH:3V        IN VLH:1. 675V
                      VHL:3.15V                                                    VHL:1.6V
                                                                 VHL:2.85V
                                         TRIMBGP
                                                                                                   UV_ VDDD
                                                                                                   UV_ VDDA     MRB
                                                                                                        POR
After connecting power to VS pin (assuming any needed external components are applied correctly) the system
will start to work. The on-chip supplies start to build the system voltages after reaching the defined minimum
voltage level on VS pin.
The MRB (for Master Reset, low active) is a digital signal which keeps the complete IC in reset state, as long as
one of the supplies is below the specified value.
MRB is active after Power On VS under the following condition
      as long as VS stays below its POR level (Vpor_lh) or
      as long as VDDA stays below its Under voltage reset level (Vuvr_lh_VDDA) or
      as long as VDDD stays below its Under voltage reset level (Vuvr_lh_VDDD).
VS
                                                                                              VDDA
     Vuvr_lh_VDDA
                                                                                              VAUX
            Vpor_lh
                                                                                               VDDD
     Vuvr_lh_VDDD
                                                                                                    t
                                 tdelay
EN_REG
PORB
UVB_VDDD
UVB_VDDA
MRB
With rising edge PORB after VS ramping up, the bandgap and the under voltage detection circuits for VDDA and
VDDD are switched on. After a built in delay time (tdelay) of typ.150us the bandgap has reached the valid
voltage level and the regulators for VDDA and VDDD are switched on. If VDDA and VDDD are above the under
voltage levels the Master Reset is switched off (MRB=1) and the system starts to work.
In case of application relevant data has been changed in the RAM area of the NVRAM and the power supply is
going down, API has to start as soon as possible saving values into NVRAM.
The available time for this save operation is limited by the energy of the external Capacitor at VS.
Note that incomplete save operations can leave invalid data in the NVRAM.
Saving data in NVRAM can be triggered by the under voltage interrupt or by measuring VS with the ADC.
These values have been stored during Melexis chip test. The defined addresses are reserved for Melexis and it is
not allowed to be changed by API.
Startup steps:
     1. Trimming FLASH (VREF, VMG)
     2. Trimming Bandgap
     3. Trimming VDDA supply voltage
     4. Trimming VDDD supply voltage
     5. Trimming Biasing current
     6. Trimming RC Oscillator
     7. Trimming ADC Reference voltages VRH1..3
     8. Trimming NVRAM charge pump
The API starts the system shutdown process by stopping the communication and application CPU
(M4_RB=0 and HALT=1 set GTSM high).
Note that the system shutdown cannot be interrupted by any wake-up mechanism as long as the process has
not been completed.
The wakeup source, causes the wakeup, will be signalized via the ANA_INB port (see Table 7).
IO port: ANA_INB
Address: 0x281E                                         Access mode: Word – Read and Write
    Bit[7]           Bit[6]        Bit[5]        Bit[4]          Bit[3]         Bit[2]         Bit[1]       Bit[0]
       -                -             -             -               -              -              -            -
    Bit[15]          Bit[14]       Bit[13]       Bit[12]         Bit[11]       Bit[10]         Bit[9]       Bit[8]
                                                                             INTERNAL_
       -                -             -             -               -                        LOCAL_WU      LIN_WU
                                                                                 WU
LIN_WU             Wakeup was caused by a wakeup via LIN request (=1)
LOCAL_WU           Wakeup was caused by a falling or rising edge on HVx pins (=1)
INTERNAL_WU        Wakeup was caused by the internal WAKE UP timer (=1)
                                          Table 7 – Wakeup Source
                WAKEUP
                    MRB
            VBG _ ON ,
            UV det . on
VDDA _ ON
VDDD _ ON
GTSM
 VS
                                            VDDA                  VDDA                    VDDD
                                                                                                       Interrupt
                                                                                                        OV_VS
                                            comp                FILTER                 Level Shifter
                                    VBG
SBY
 VS
                                            VDDA                  VDDA                    VDDD
 ANA_OUTG[9:8]
                                                                                                       Interrupt
                                                                                                        UV_VS
                                            comp                FILTER                 Level Shifter
                                    VBG
SBY
The VS under voltage detection threshold can be programmed with ANA_OUTG[9:8] = PRUV[1:0] from 6V to 9V,
further information can be found in Table 63 and in the chapter Electrical parameter specification.
In the Software Platform C-macros are available to enable the over- and under-voltage detection.
IO port: RC_CTRL
Address: 203Eh                                      Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]        Bit[5]         Bit[4]         Bit[3]      Bit[2]        Bit[1]           Bit[0]
                                        Melexis reserved                                             RC_EN
Bit[15]       Bit[14]       Bit[13]        Bit[12]        Bit[11]     Bit[10]       Bit[9]           Bit[8]
                                                Melexis reserved
Melexis reserved            Write access is not allowed
                            1 – Enable 24MHz clock
RC_EN                       0 – Enable 250kHz clock
                            (read- and writeable)
                                            Table 9 – RC-Control port
The differences are in memory organization and interrupt vectors for the system level interrupts, i.e.
      MULAN3 adds 16kByte ROM.
               o The power up code and the SW for the LIN-CPU (MLX4) is executed from ROM.
               o The ROM contains a boot loader supporting flash reprogramming over LIN
      the ROM will be located at addresses 0xC000h to 0xFFFF
               o 8kByte is used by MLX4 (0xC000 to 0xDFFF)
               o 8kByte by MLX16 (0xE000 to 0xFFFF)
      MULAN3 will include a BIST block for testing the ROM
      the far page 6 (FP6) will be pointing into ROM at address 0xFF00h
      MULAN3 redirects all level 0 interrupts (Reset, Stack, Protection Error, Invalid Address, Program Error)
          into ROM (to FP6)
      MULAN3 changes the interrupt type of Protection error, Invalid Address Error and Program Error (=
          flash error) type to JUMP (instead of CALL)
      port bits are added to control the relocation of MLX4 code from ROM to FLASH (in CONTROL_EXT2
          port)
      port bits are added to determine the access priority for reading the ROM from MLX4 or MLX16 (in
          CONTROL_EXT2 port)
Exempted the debouncing times for some WAKE UP sources from standby mode and the analogue watchdog,
all timings are derived from this system clock.
If not mentioned explicitly, this MULAN3 main system clock is referred to as CK in the following documentation.
This gives the following instruction length, in case the oscillator is running on its typical frequency.
                                                           System
                                                           Clock
                                                                           RB
                                                                Test
                                                              controller
                                    Mlx16                                         Mlx4
                                   periphery                                    periphery
Mulan3
                      Interrupt                                  CPUs
                                          Mlx16-(X)8                              Mlx4
                      controller                               interface
                                               ROM
                                                                                  RAM
                                               Flash
                                                                                 arbiter
                                               Arbiter
                      EEPROM                   ROM
                                                                                  RAM
                       NVRAM                   Flash
Notes:
     The Mlx4 ports are on a separate bus, so there is no need for a port arbiter.
     The NVRAM is only accessed by the Mlx16, so it does not need an arbiter.
                                         Mlx16-(x)8
                                                                                           Allowed
                                                                                                                System Write
                                                                                                   User Write
                               Memory space
                                                                                           Fetch
     F000    -   FFFF           16kByte               Mlx16 User Library
     E000    -   EFFF             ROM                 Mlx16 LIN loader
     D000    -   DFFF             ROM                 Mlx4 code
     C000    -   CFFF             ROM                 Mlx4 code
     7000    -   BFFF           32kByte               Mlx16 code
     6000    -   6FFF            FLASH                Mlx16 code
     5000    -   5FFF            FLASH                Mlx16 code
     4000    -   4FFF            FLASH                Mlx16 code
     3000    -   3FFF          Not Used
     2800    -   2FFF       Mlx16 User ports          2kByte
     2000    -   27FF      Mlx16 System Ports         2kByte
     1200    -   1FFF          Not used
     1180    -   11FF    NVRAM Melexis Area           128 Byte (2)
     1100    -   117F    NVRAM / NVRAM                128 Byte (2)
     1080    -   10FF    NVRAM Melexis Data           128 Byte (2)
     1000    -   107F    NVRAM / NVRAM                128 Byte (2)
     0800    -   0FFF          Not used                                                            (1)
     0000    -   07FF           RAM (1)               RAM: 2048 Byte                               (1)
There are some restrictions for accessing certain areas depending on the type of access:
       Mlx4 can fetch anywhere from physical addresses 0xC000 to 0xDFFF (12 bits word address)
       Mlx16 can on fetch in:
            o FLASH:            Normal case
            o ROM
            o NVRAM:            Patch-code
            o RAM
       Mlx4 and Mlx16 can read any RAM location (limited to 256 bytes for Mlx4)
                           32K
                  Name     Flash        Note
                           size
                                2)
                  Fp0:     BF00         Last FLASH / ROM page (used by interrupt controller)
                                2)
                  Fp1:     BE00         Could be used for C runtime
                                 2)
                  Fp2:     BD00         Could be used for C runtime
                                2)
                  Fp3:     BC00         Could be used for C runtime
                                 2)
                  Fp4:     BB00         Could be used for C runtime
                                 2)
                  Fp5:     BA00         Could be used for C runtime
                                2)
                  Fp6:     FF00         Could be used for C runtime
                  Fp7:     1000         In NVRAM to allow single instruction patch start
                                  1)    Mlx16 private RAM;
                  Dp:      0000
                                        16 byte shared between MLX4 and MLX16
                                  1)
                  Io:      2800         User Ports
                                                    Legend:
                           1)           Fixed address for any FLASH / ROM size
                           2)           Address depending on the FLASH / ROM size
                                       Table 11 – Mlx16 pre-defined pages
9. IO Registers
9.1. General
There are 2 port spaces for the Mlx16:
     System protected ports (starting at address 0x2000), Mlx16 bit USER must be cleared.
     User ports (starting at address 0x2800), not protected.
Writing to non-existing custom ports will have no effect and reading from non-existent custom ports will always
return 0.
                                     Access
        Name            Address                                         Description                           Page
                                      Mode
                       0x2057
                       0x2056
                       0x2055
                       0x2054
                       0x2053
                       0x2052
                       0x2051
                       0x2050
                       0x204F
 ANA_OUTF              0x204E                   HV current output control register                           107
                       0x204D
 ANA_OUTE              0x204C                   Analog chip ports - ADCREF trimming                          88
                       0x204B
 ANA_OUTD              0x204A                   Analog chip ports - ADCREF trimming                          88
                       0x2049
                       0x2048
                       0x2047
                       0x2046
                       0x2045
                       0x2044
                       0x2043
 LIN_XKEY              0x2042      Word/Byte    Enables LINXCFG port
                       0x2041
                       0x2040
                       0x203F
 RC_CTRL               0x203E      Word/Byte    RC control                                                   34
                       0x203D
                                                Second level interrupt controller – over-temperature,
 XI4_PEND              0x203C                                                                                57
                                                overvoltage …
                       0x203B
 XI3_PEND              0x203A      Word/Byte    Second level interrupt controller                            57
                       0x2039
 XI2_PEND              0x2038      Word/Byte    Second level interrupt controller – PWM unit                 57
                       0x2037
 XI1_PEND              0x2036      Word/Byte    Second level interrupt controller – Timer2 unit              57
                       0x2035
 XI0_PEND              0x2034      Word/Byte    Second level interrupt controller – Timer1, 3 unit           57
                       0x2033
                                                Second level interrupt controller – over-temperature,
 XI4_MASK              0x2032      Word/Byte                                                                 57
                                                overvoltage …
                               Access
        Name      Address                                          Description                         Page
                                Mode
                 0x2031
 XI3_MASK        0x2030      Word/Byte   Second level interrupt controller                            57
                 0x202F
 XI2_MASK        0x202E      Word/Byte   Second level interrupt controller - PWM unit                 57
                 0x202D
 XI1_MASK        0x202C      Word/Byte   Second level interrupt controller – Timer2 unit              57
                 0x202B
 XI0_MASK        0x202A      Word/Byte   Second level interrupt controller – Timer1, 3 unit           57
 CK_TRIM         0x2029      Byte        Melexis reserved
 FL_CTRL1        0x2028      Word/Byte   Flash control register
                 0x2027
 FL_CTRL0        0x2026      Word/Byte   Flash control register                                       47
                 0x2025
 NV_CTRL         0x2024      Word/Byte   NVRAM Control register                                       50
                 0x2023
 ANA_TEST        0x2022      Word/Byte   Melexis reserved
                 0x2021
 ANA_OUTC        0x2020      Word/Byte   Melexis trim register
                 0x201F
 ANA_OUTB        0x201E      Word/Byte   Melexis trim register
                 0x201D
 ANA_OUTA        0x201C      Word/Byte   Melexis trim register
                 0x201B
 PATCH3_A        0x201A      Word/Byte   4th Patch start address
                 0x2019
 PATCH2_A        0x2018      Word/Byte   3rd Patch start address
                 0x2017
 PATCH1_A        0x2016      Word/Byte   2nd Patch start address
                 0x2015
 PATCH0_A        0x2014      Word/Byte   1st Patch start address
                 0x2013
 PATCH3_I        0x2012      Word/Byte   4th Patch jump instruction
                 0x2011
 PATCH2_I        0x2010      Word/Byte   3rd Patch jump instruction
                 0x200F
 PATCH1_I        0x200E      Word/Byte   2nd Patch jump instruction
                 0x200D
 PATCH0_I        0x200C      Word/Byte   1st Patch jump instruction
 SLVIT           0x200B                  Melexis reserved
 SLVCMD          0x200A      Word/Byte   Melexis reserved
                 0x2009
 PEND            0x2008      Word/Byte   Pending interrupt flags
                 0x2007
 MASK            0x2006      Word/Byte   Interrupt mask                                               55
                 0x2005
 PRIO            0x2004      Word/Byte   Interrupt priority
 SHRAM_H         0x2003      Byte        Mlx4 private RAM start address
 SHRAM_L         0x2002      Word/Byte   Max number of bytes writable by Mlx4
                 0x2001
 CONTROL         0x2000      Word/Byte    System control register                                     51
                            Table 12 – System Protected Ports Overview
                                    Access
         Name          Address                                        Description                          Page
                                     Mode
                       0x28ED
 SC_CTRL               0x28EC     Word/Byte    Control register for LIN AA
                       0x28EB
 ANA_OUTP              0x28EA     Word/Byte    Control register for HVDIFF
                       0x28E9
 ANA_OUTO              0x28E8     Word/Byte    Control register for shunt measurement unit                106
                       0x28E7
 ANA_OUTN              0x28E6     Word/Byte    HV[4] and HV[5] current selection register
                       0x28E5
 ANA_OUTM              0x28E4     Word/Byte    Current trim register for HVDIFF
                       0x28E3
 ANA_OUTL              0x28E2     Word/Byte    Current control and trim register
                       0x28E1
 ANA_OUTK              0x28E0     Word/Byte    10Bit DAC for HVDIFF
                       0x28DF
 ANA_OUTI              0x28DE     Word/Byte    HV differential measurement control
                       0x28DD
 ANA_OUTH              0x28DC     Word/Byte    LIN Auto Addressing and current control
                       0x28DB
 ANA_OUTG              0x28DA     Word/Byte    HV Bias Current select register                            109
                       0x28D9
 HV_TMR                0x28D8     Word/Byte    Timer channel A or B to HV                                 110
                       0x28D7
 HV_ENWU               0x28D6     Word/Byte    HV - Enables wakeup detection                              110
                       0x28D5
 HV_INEN               0x28D4     Word/Byte    HV - Threshold config / Input comparator type              109
                       0x28D3
 HV_OUTOD              0x28D2     Word/Byte    HV - Open drain outputs                                    109
                       0x28D1
 HV_DEB                0x28D0     Word/Byte    HV - Debounce configuration                                107
                       0x28CF
 HV_CFG                0x28CE     Word/Byte    HV configuration                                           107
                       0x28CD
 HV_IN                 0x28CC     Word/Byte    HV - Debounced and un-debounced input from pin             110
                       0x28B1
                       0x28B0
                       0x28AF
                       0x28AE
                       0x28AD
                       0x28AC
                       0x28AB
                       0x28AA
                       0x28A9
                       0x28A8
                       0x28A7
                       0x28A6
                       0x289F
                       0x289E
                       0x289D
                       0x289C
                       0x289B
                       0x289A
                       0x2885
                             Access
       Name       Address                                     Description                          Page
                              Mode
 PWM6_CMP        0x2884     Word/Byte   PWM 6 - Compare interrupt threshold register              66
                 0x2883
 PWM6_HT         0x2882     Word/Byte   PWM 6 - High threshold register                           66
                 0x2881
 PWM6_LT         0x2880     Word/Byte   PWM 6 - Low threshold register                            65
                 0x287F
 PWM6_PER        0x287E     Word/Byte   PWM 6 - Period duration                                   66
 PWM6_PSCL       0x287D     Byte        PWM 6 - Prescaler register                                67
 PWM6_CTRL       0x287C     Word/Byte   PWM 6 - Control register                                  67
                 0x287B
 PWM5_CMP        0x287A     Word/Byte   PWM 5 - Compare interrupt threshold register              66
                 0x2879
 PWM5_HT         0x2878     Word/Byte   PWM 5 - High threshold register                           66
                 0x2877
 PWM5_LT         0x2876     Word/Byte   PWM 5 - Low threshold register                            65
                 0x2875
 PWM5_PER        0x2874     Word/Byte   PWM 5 - Period duration                                   66
 PWM5_PSCL       0x2873     Byte        PWM 5 - Prescaler register                                67
 PWM5_CTRL       0x2872     Word/Byte   PWM 5 - Control register                                  67
                 0x2871
 PWM4_CMP        0x2870     Word/Byte   PWM 4 - Compare interrupt threshold register              66
                 0x286F
 PWM4_HT         0x286E     Word/Byte   PWM 4 - High threshold register                           66
                 0x286D
 PWM4_LT         0x286C     Word/Byte   PWM 4 - Low threshold register                            65
                 0x286B
 PWM4_PER        0x286A     Word/Byte   PWM 4 - Period duration                                   66
 PWM4_PSCL       0x2869     Byte        PWM 4 - Prescaler register                                67
 PWM4_CTRL       0x2868     Word/Byte   PWM 4 - Control register                                  67
                 0x2867
 PWM3_CMP        0x2866     Word/Byte   PWM 3 - Compare interrupt threshold register              66
                 0x2865
 PWM3_HT         0x2864     Word/Byte   PWM 3 - High threshold register                           66
                 0x2863
 PWM3_LT         0x2862     Word/Byte   PWM 3 - Low threshold register                            65
                 0x2861
 PWM3_PER        0x2860     Word/Byte   PWM 3 - Period duration                                   66
 PWM3_PSCL       0x285F     Byte        PWM 3 - Prescaler register                                67
 PWM3_CTRL       0x285E     Word/Byte   PWM 3 - Control register                                  67
                 0x285D
 PWM2_CMP        0x285C     Word/Byte   PWM 2 - Compare interrupt threshold register              66
                 0x285B
 PWM2_HT         0x285A     Word/Byte   PWM 2 - High threshold register                           66
                 0x2859
 PWM2_LT         0x2858     Word/Byte   PWM 2 - Low threshold register                            65
                 0x2857
 PWM2_PER        0x2856     Word/Byte   PWM 2 - Period duration                                   66
 PWM2_PSCL       0x2855     Byte        PWM 2 - Prescaler register                                67
 PWM2_CTRL       0x2854     Word/Byte   PWM 2 - Control register                                  67
                 0x2853
 PWM1_CMP        0x2852     Word/Byte   PWM 1 - Compare interrupt threshold register              66
                 0x2851
 PWM1_HT         0x2850     Word/Byte   PWM 1 - High threshold register                           66
                 0x284F
 PWM1_LT         0x284E     Word/Byte   PWM 1 - Low threshold register                            65
                 0x284D
 PWM1_PER        0x284C     Word/Byte   PWM 1 - Period duration                                   66
 PWM1_PSCL       0x284B     Byte        PWM 1 - Prescaler register                                67
 PWM1_CTRL       0x284A     Word/Byte   PWM 1 - Control register                                  67
                             Access
       Name       Address                                      Description                           Page
                              Mode
                 0x2841
 TMR3_CNT        0x2840     Word/Byte   Timer 3 - Counter                                           82
                 0x283F
 TMR3_REGA       0x283E     Word/Byte   Timer 3 - Channel A                                         80
                 0x283D
 TMR3_REGB       0x283C     Word/Byte   Timer 3 - Channel B                                         80
                 0x283B
 TMR3_CTRL       0x283A     Word/Byte   Timer 3 - Control register                                  81
                 0x2839
 TMR2_CNT        0x2838     Word/Byte   Timer 2 - Counter                                           82
                 0x2837
 TMR2_REGA       0x2836     Word/Byte   Timer 2 - Channel A                                         80
                 0x2835
 TMR2_REGB       0x2834     Word/Byte   Timer 2 - Channel B                                         80
                 0x2833
 TMR2_CTRL       0x2832     Word/Byte   Timer 2 - Control register                                  81
                 0x2831
 TMR1_CNT        0x2830     Word/Byte   Timer 1 - Counter                                           82
                 0x282F
 TMR1_REGA       0x282E     Word/Byte   Timer 1 - Channel A                                         80
                 0x282D
 TMR1_REGB       0x282C     Word/Byte   Timer 1 - Channel B                                         80
                 0x282B
 TMR1_CTRL       0x282A     Word/Byte   Timer 1 - Control register                                  81
                 0x2829
                 0x2828
                 0x2827
                 0x2826
                 0x2825
                 0x2824
                 0x2823
                 0x2822
                 0x2821
 LIN_XCFG        0x2820     Word/Byte   Configuration port for external LIN phy or protocol layer
                 0x281F
 ANA_INB         0x281E     Word/Byte   Wake up sources                                             31
                 0x281D
 ANA_INA         0x281C     Word/Byte   Interrupt source of generated interrupts                    57
                 0x281B
 AWD_CTRL        0x281A     Word/Byte   Analog Watchdog (AWD) interface                             98
                 0x2819
                 0x2818
                 0x2817
                 0x2816
                 0x2815
 ADC_DBASE       0x2814                 ADC Data base pointer                                       87
                 0x2813
 ADC_SBASE       0x2812                 ADC Mux, Reference and Trigger source selection             87
                 0x2811
 ADC_CTRL        0x2810                 ADC control register                                        88
                 0x280F
                 0x280E
                 0x280D
                 0x280C
                 0x280B
                 0x280A
                 0x2809
                 0x2808
                 0x2807
                             Access
         Name     Address                                          Description               Page
                              Mode
 TIMER           0x2806     Word/Byte     Timer control register                            68
                 0x2805
 WD_TG           0x2804     Byte         Intelligent watchdog tag register                  96
 WD_CTRL         0x2803     Byte         Core watchdog - Control register                   96
 WD_T            0x2802     Byte         Core watchdog - Timeout register                   96
 HW_VER          0x2801                  MULAN3 Hardware Version
 VARIOUS         0x2800     Byte         NVRAM Status Register                              50
                               Table 13 – Standard Ports Overview
10. Memories
10.1. RAM sharing
MLX4 and MLX16 share the RAM by a mechanism controlled by 2 ports, SHRAML and SHRAMH. The principle is
shown in Figure 11
                                      Private
                                        M4
                                                    MLX4 private
                            RAMSize
                                                   MLX16 private
                                      Shared
                                       M4
Notes:
     Ports SHRAMH and SHRAML can only be changed when Mlx4 is in reset (e.g. M4_RB = 0). When Mlx4 is
       running, writing to those ports has no action (e.g. ports are unchanged) and no error is flagged to
       Mlx16.
The 32 user bits are secured by a hardware ECC mechanism (ECC= Error Checking and Correcting) and additional
7 bits. By this the memory can correct single bit fail per double word, and detect double bit fail per double
word. The MLX16 doesn't check if there was a double bit failure. In case there is a double bit failure an invalid
opcode can be fetched from the MLX16. This will cause a reset of the complete device.
The write of a flash memory page takes typically 5ms the erase procedure typically 40ms. The memory is read
by the CPU at full system clock speed.
Furthermore, the memory has a special range. It is a latch based buffer, which is used to read or write the non-
volatile memory array by page. This buffer has the size of 1 page
39 bits
BF80
5FFF
                      40FF
                                     32 DW              Main Page 1
                      4080
                      407F
32 DW Main Page 0
4000
The macro uses the 1.8 and 3.3 volt power supply to perform both read and in-system programming (ISP), built-
in charge pumps generate the high voltages for write and erase operations.
 trimming system ports FLASHTRIMx. The last instruction of the state machine is a jump back to the reset
 address and a stop of flash data replacement.
 After this last instruction the firmware will execute normally.
IO port: FLCTRL0
Address: 2026h                                      Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]         Bit[5]         Bit[4]       Bit[3]       Bit[2]        Bit[1]                Bit[0]
                                            FL_WRERA_ FL_WRERA_
Melexis reserved testmode bits                                        FL_DBE                              FL_DETECT
                                            SEL          EN
Bit[15]       Bit[14]       Bit[13]         Bit[12]      Bit[11]      Bit[10]       Bit[9]               Bit[8]
Melexis reserved testmode bits
Melexis reserved
                            write is ignored, read back to all=0
testmode bits
                            Define the action when CPU writes into Flash:
FL_WRERA_SEL                1: Latches Area content stored into NV-Area target page
                            0: NV-Area target page erased
FL_WRERA_EN                 Enable NV-Area Write or Erase when CPU writes into it
                            Double Error Detected in Flash read. Will be set and kept until the bit will be cleared
FL_DBE                      by software. It must be cleared by software. The Bit will trigger a program error
                            interrupt.
                             0 if no flash present (only ROM/XROM) / 1 if there is a flash (read only bit, write is
FL_DETECT
                             ignored)
                                             Table 15 – Flash control port
 10.4. NVRAM
 The controller incorporates 2 NVRAM blocks of 128 words (2K Bit) each. Each NVRAM is organized in 2 pages.
With this NVRAM it is possible to store non-volatile information of the customer’s application data.
The NVRAM has a built-in error detection and a single bit error correction.
 In SRAM mode, the memory operates as a static RAM with fast read and write cycles.
 The SRAM can be read and written with word access in unlimited number of times, while independent
 nonvolatile data resides in NVRAM. The data of the NVRAM are unchanged during the SRAM mode.
 The SRAM can be read and written at full CPU operating frequency.
 In the nonvolatile modes the SRAM functions are disabled, because there is a data transfer between SRAM and
 NVRAM. Once the recall or store cycle is initiated, further input or output are disabled until the cycle is
 completed.
 In nonvolatile storage operation, all data from the SRAM are transferred in one parallel step to NVRAM. The
 store cycle has to be initiated under user control via a pin signal.
 The store operation takes maximum <15ms. No SRAM access is allowed during storage operation.
The nonvolatile recall mode is used for writing back the data from NVRAM to SRAM. Internally, recall is a two-
step procedure. First, the SRAM data is cleared and second, the nonvolatile data is written to the SRAM. The
content of the SRAM will be overwritten.
The recall operation does not affect the data in the NVRAM cells, they can be recalled an unlimited number of
times.
The recall operation takes maximum <10s. No SRAM access is allowed during recall operation.
Application Hints:
Melexis supports Read, Write and Store with library routines
The store operation is completely under Software control. It can be done at any time by software.
Syntax:
User:            Access to SRAM (volatile area) always possible;
                 Store and Recall (to/from non-volatile area) only in System mode possible
Testmode:        Access possible only in test mode
IO port: VARIOUS
Address: 2800h                                        Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]         Bit[5]         Bit[4]          Bit[3]           Bit[2]        Bit[1]        Bit[0]
NV_DED                       WKUP           PHISTAT1        PHISTAT0         Melexis reserved            SWI
Bit[15]       Bit[14]        Bit[13]        Bit[12]         Bit[11]          Bit[10]       Bit[9]        Bit[8]
Melexis reserved
Melexis reserved             write is ignored, read back to all=0
SWI                          Software interrupt request (automatically cleared, write only bit)
PHISTAT0
                             LIN physical status (read only bit, write is ignored)
PHISTAT1
WKUP                         LIN wake-up (read only bit, write is ignored)
                             Double Error Detected in NVRAM read. Will be set and kept until the next NVRAM
NV_DED
                             read access. Cannot be cleared by software (read only bit, write is ignored).
                                          Table 19 – NVRAM status port
 11. Interrupts
 11.1. Introduction
 This chapter explains how the interrupts are handled inside the chip. It clarifies and gives add-on information on
 the description of the interrupts in the MLX16X8 data book. It also gives the customer an overview of the
 interrupt allocation table.
IO port: CONTROL
Address: 2000h                                        Access mode: Word, Byte – Read and Write
Bit[7]       Bit[6]          Bit[5]         Bit[4]         Bit[3]       Bit[2]        Bit[1]             Bit[0]
                                                                                                         Melexis
WD_BOOT       Melexis reserved                                                            HALT
                                                                                                         reserved
Bit[15]       Bit[14]        Bit[13]        Bit[12]         Bit[11]        Bit[10]        Bit[9]         Bit[8]
Melexis reserved
Melexis reserved             Write access is not allowed.
                             1 – Last reset was triggered from watchdog
WD_BOOT                      0 – Last reset was a POR
                             (read only bit, write is ignored)
                             1 – Halt the MLX16
HALT
                             (Write only bit, read access gives always “0”)
                                              Table 20 – CONTROL port
The user is supposed to write the appropriate interrupt handlers for these interrupts.
Those interrupts typically share a single interrupt line of the MULAN/Mlx16 interrupt controller. They are
organized in a second level interrupt controller as described below.
All the masking bits are grouped into dedicated ports; please refer to the ports map for detail. When the MASK
bit is set, the belonging interrupt is enabled.
After reset the MASK ports are reset, so all interrupts are disabled.
The pending bit is set only once, even when more than one IRQ occurred before being serviced.
Software can clear a pending interrupt source by setting the corresponding bit in the IO port PEND / XIxPEND.
At the interrupt vector the priority is set and a jump to the appropriate interrupt service routine (ISR) follows.
At the end of the ISR a return can be placed, and the program counter returns to where it came from before the
IRQ occurred.
As after a stack error or a reset a return point cannot be defined, those interrupts execute a JUMP to the vector
address.
It is the responsibility of the customer to make sure that in the main loop these PR bits have the correct value
so that all wanted interrupts can be acknowledged. In the Melexis firmware platform, this interrupt level is set
to seven (lowest priority) when entering the main function. This means that every IRQ can interrupt the main
function.
When entering an ISR, the first instruction has to be a PSUP, #constant instruction that pushes this M register
on the stack and sets a new value in the PR bits (#constant parameter in this instruction, value from 0 to 7). By
writing a new value in the PR bits in the ISR, another level of interrupts can be masked.
It is possible that an ISR of an IRQ with software priority 5 sets these bits to 2. By doing so, all IRQs with
software priority less than 2 (higher number) are blocked. This means that an ISR routine of an IRQ with
software priority 5 can block an IRQ with software priority 4 by changing the PR bits in its ISR. This is called
“interrupt priority inversion”. The customer has the responsibility to check if this can cause problems in his
application.
The M register has to be manually restored when exiting the ISR by popping it from the stack. This has to be the
very last instruction of the ISR.
The PSUP and pop instructions to keep track of the M register and PR bits are handled automatically in the
Melexis firmware platform.
 Reminder:
 For Mlx16X8, the highest priority is 0 and the lowest is 7.
 The absolute priority is compared to Mlx16 priority to trigger an interrupt
 The relative priority is used by interrupt controller to decide between identical absolute priority interrupts fired
 at the same time: Lowest is issued first.
 Note:
 The level 0 of priority is not reachable in user mode. When Mlx16X8 sets priority to 0 in user mode, it is
 interpreted as priority 1 by the interrupt controller.
The sources are distributed to the five second level interrupt controllers as follows:
12. PWM
12.1. General introduction and features
The controller has 6 independent PWM modules which can be mapped to the different HVs. The mapping can
be found in the chapter ‘Routing of PWM outputs to external pins’.
To make the use of the PWM module more comfortable a macro library and an application note are available at
the Softdist server.
The following chapters are intent to give a more detailed technical description of the PWM unit.
                                                                                        SET_OUT
                                                                                                   PLT shadow buffer
                                                        EXT
                                                                                                                                  FPWMO
                                                                                                       Mirror Pulse
                                                                                                       Generation
                                                                                                                                                  1       PWMO
                                                                                                                                                  0 sel
                                                                                                                                                          CMPI
                                                                                                   Equality Comparator
Each PWM module supports two main schemes to impact the shape of the generated output signal:
     Independent mode
     Mirror mode
In mirror mode the output is a pulse centered on the middle of the output period.
In independent mode the duty cycle and the phase shift of the output are controlled by software with two
threshold levels.
These three parameters PPER, PLT and PHT are double buffered and updated at the end of the current output
period (CNT==0). This double buffer system prevents unexpected output waveform while modifying
parameters.
A programmable synchronous counter defines the period of the corresponding PWM output. A programmable
prescaler fixes the ratio between the clock of this counter and the input clock frequency.
The PWM module can create 2 interrupts, the fix counter interrupt CNTI at counter = 0, and the programmable
PWM compare interrupt CMPI. The compare interrupt triggers, when the internal counter reaches the value
programmed into port PCMP. PCMP is not buffered and can be updated any time.
The PWM counters clock selector is controlled by the port PPSCL. The value of this port is not buffered and can
be updated at any time.
The period length value PPER is double buffered, it will be update in case the counter value CNT is equal to 00h.
The PPER value is hardware limited to 0xFFFEh, even if the PPER port is written to0xFFFFh, the shadow register
will be updated to 0xFFFEh.
The frequency Fcnt of the PWM counter is given by the following equation:
                                              f CK 1
        Equation 1                  f CNT        
                                              M 2N
Where: Fck       : PWM input frequency ; equal to the main system clock CK.
       Fcnt      : clock frequency of PWM internal counter
       M         : Programmed predivider between 0 and 15. Value fixed in IO port PPSCL[7:4].
       N         : Programmed predivider between 0 and 11. Value fixed in IO port PPSCL[3:0].
And the frequency Fpwmo of the PWM output PWMO is given by the equation:
                                                                  f CNT
        Equation 2                                   f PWM 
                                                                 PPER
Where: Fpwm      : PWM frequency
       PPER      : programmed period width, internal counter CNT is restarted,
                   when this value is reached.
Fck / 2N-1
Fck / 2N
Fck / 2N+1
                                               PPERmax
                       PWM output resolution
PPERmax / 2
Example:
Assumptions:
        PWM with 24kHz at max resolution is needed,
        Fck=24MHz
Definition steps:
     start with N=0, M=0
     PPER = Fck/Fpwm = 24MHz / 24kHz = 1000
     PPER = 1000 => Fpwm = 24MHz/1000 = 24.00 kHz
     max resolution possible is > 10 bit (10bit=1024, 11bit=2048) for M = 0
To allow this, the PWM modules are connected internally in a daisy-chain-like hierarchical scheme.
The PWM module generating the time regime is called “master”, the block running on an external counter (or
frequency resp.) is called “slave”.
Every PWM module can be either master or slave to the previous one. A single master following multiple slaves
is also possible; all share then the time base of the master.
This bit EXT controls if a PWM module operates as master or slave. EXT=1 means a PWM module is slave to the
previous PWM module.
After Reset all PWM modules act as independent masters, not taking into account the external connections.
In this mode, the PWM high time is defined by the following equation:
                1
        PWMO    0
               CNT=0                                       CNT=0
                           CNT=PLT        CNT=PHT     CNT=PPER     CNT=PLT       CNT=PHT   CNT=PPER
The COMPARE always uses the PLT and PHT values in the shadow registers only, therefore the ports can be
updated at any time. The port values are transferred only after the PLT register was written, when the PWM
counter CNT getting equal to 0.
If the PWM module operates as slave (bit EXT=1 in PCTRL port), the external counter input CNT_EXT with the
master counter is used instead of the internal counter. The write of the masters PLT register will enable the
transfer of the threshold values and the period into the shadow registers for the slaves as well.
Special cases:
     PPER=0 : PWMO is frozen to the state being active at shadow register update
     PHT < PLT, PHT and PLT < PPER : identical phase shift and duty cycle, inverted PWMO signal
     PLT < PPER < PHT : PWMO stays at always high
     PHT < PPER < PLT : PWMO stays at always low
     PLT and PHT > PPER: PWMO is frozen to the state being active at shadow register update
     PHT = PLT, PHT and PLT < PPER : PWMO stays at always low
Assuming
     The control bit MODE is high,
     TCK is the oscillator clock period,
     TCNT is the counter clock period,
     The pulse length value PLT is lower than the period value PPER,
                                                      Thigh   1   PLT    1
        Equation 5                   t PWM _ HIGH                  
                                                      PPER f PWM PPER f PWM
Once the value Thigh has been written in the IO port PLT_x, the low and high thresholds are updated as
described below:
     The low threshold PLT is computed and the resulting value is used to set PLT; i.e. the previous value is
         discarded. If this result is lower than 0, i.e. LT > PPER, PWM, data are forced to 0000h and the output
         PWMO will be forced to 0.
     The high threshold PHT is computed and the resulting value is use to set PHT. If this result is greater
         than PPER, i.e. PLT > PPER, the output PWMO will be forced to 1.
The new desired pulse length value is memorized in buffer. Due to this double buffer mechanism, threshold
values can be updated at any time.
Important: The new desired period value PPER must be updated before PLT.
                                                        Thigh (↔ PLT)
                                  TCNT                Thigh/2
                         1
             PWMO        0
 In mirror mode the PLT and PHT values are recalculated only after the PLT port was written, when the PWM
 counter CNT getting equal to 0.
 If the PWM module operates as slave (bit EXT=1 in PCTRL port), the external counter input CNT_EXT with the
 master counter is used instead of the internal counter. The write of the masters PLT register will enable the
 write of the shadow registers for the slaves as well.
 Special cases:
      PLT = 0 : PWMO stays at always low
      PLT > PPER: PWMO stays at always high (also valid for PPER=0 )
 Due to a double buffer mechanism the port values PHT and PLT can be updated at any time.
 Writing the PWM low threshold (PLT) enables the transfer of the port values into the double-buffer shadow
 registers by default. The shadow registers will be written next time the counter CNT gets equal 0.
 The PWM comparator value PCMP is used to generate interrupt independently of the threshold values.
 This interrupt signal CMPI will be high active during one period of CK. An interrupt is generated when control bit
 PWM_ECI is high and CNT reaches the value of PCMP.
 The prescaler port PPSCL controls the bits PWM_PRDV1[3:0] and PWM_PRDV0[3:0]. The IO port update can be
 done at any time.
 The routing can be activated by dedicated control bits, for further detail please refer to the ports descriptions in
 the according HV IO chapters (see 20.4).
  13. Timers
  There are 4 timer hardware blocks integrated. One simple 15bit timer and 3 universal 16bit timer with 6
  different operation modes. More information can be found in the chapters below.
                                1 MHz
                  Trimming
    MULAN                                            Programmable              TIMER_IT (*)
    System                                               dividier              (1µs to
     Clock                                            by 1 to 32768            32768µs)
                                         1
                                                        15      (*) : Can be disabled by interrupt
                   Port TIMER                                   controller
                                                Figure 20 – Simple Timer
  A 15 bits free running counter clocked by 1MHz is available to generate TIMER_IT interrupt at a rate varying
  from 1µs (TIMER [14:0] = 0) to 32768µs (TIMER [14:0] = 32767). The timer is made of a down counting loadable
  binary counter. It is enabled by TMR_EN (bit 15) of port TIMER. Once enabled, each time it reaches 0x0000; it is
  reloaded by the value of port TIMER [14:0] and generates a TIMER_IT interrupt. Reading port TIMER reads the
  current value of the counter when TMR_EN = 1 or an unknown value when TMR_EN = 0.
IO port: TIMER
Address: 0x2806                                        Access mode: Byte – Read and Write
Bit        15        14    13     12      11    10     9     8     7      6     5     4       3      2    1     0
           TMR_EN                      TIMER[14:8]                                        TIMER[7:0]
At reset     0    x        x      x       x    x      x     x     x       x     x     x       x      x    x     x
                                                 Table 28 – Timer port
  The Timer block is used in association with the MLX16X8. According to the selected mode the block generates
  one digital output signal and up to 5 edges sensitive interrupt signals.
A programmable and reset-able 16-bits synchronous counter is the principal part of the Timer block; and,
except for the Pulse accumulator mode, a programmable pre-divider fixes the ratio between the clock of this
counter and the input clock frequency.
                                                                                                 INTERRUPT
             EN_DIV
                                                PCK                                                DATA
             CK                  Pre-divider                       16-bit up counter
                                                                                                  RESET
                                                                                  TCNT_x
                                               Control register
                                                                                                   RESET
                                               TIMx_EDGA          TIMx_START      TIMx_EBLK
TCTRL_x
Note:
The symbol ‘x’ reflects the number of the timer module.
The IO port associated to the Control and flag bits, e.g. TIMx_EXT, is the port TCTRL_x.
The IO port associated to the counter value TIMx_CNT is the port TCNT_x.
The IO port associated to the TIMER are the ports TREGA_x and TREGB_x.
The mode in which Timer unit work is defined by the control bits TIMx_MODE[2:0]. All modes use a common
set of hardware -see Figure 21- according to the selected mode:
         The hardware is connected or not to the input and output pins.
         Up to 5 interrupts signals Tx_INT[5:1] are generated. All interrupt are rising-edge sensitive and high
         during one period of the main clock CK
            EN_DIV                                                                                TCNT_x
                                                              CNT_CK
                                      Pre-divider
CK 16-bit up counter
RST
                                                                            TIMx_CNT         16
                                                                                                                                     TX_INT1
                                  2                                                                                                  Tx_INT2
                                                                                                                                                unused
                                                        TIMx_OUT_GE        Greater or Equal comparator     INT_TIMER    Interrupts   Tx_INT3
                                                                                      (TxGE)                              block      Tx_INT4
                                                                                                                                               INT_TIMER
                                                                                                                                     Tx_INT5
                                                                                                                                                unused
   control register
                                                                                             16
                      TIMx_DIV0
                                      TIMx_START
                      TIMx_DIV1
                                                                                     TIMx_CMPB
                                                    TCTRL_x
                                                                                               TREGB_x
                                                                       Channel B
The IO port associated to the Compare value TIMx_CMPB is the port TREGB_x.
The counter clock, CNT_CK, is the CPU clock, CK, divided by a pre-defined number, TIMx_DIV, being 1, 16 or
256. The counter is incremented on CNT_CK rising edge and a pre-defined comparator value, TIMx_CMPB, is
loaded in the 16-bits IO port TREGB_x.
The comparator output, TIMx_OUT_GE, is set to 1 if the counter value, TIMx_CNT, is bigger than or equal to
TIMx_CMPB. And the counter will be reset to ‘0000h’ on the next CK rising edge.
An interrupt, Tx_INT4=INT_TIMER, is generated if the counter reaches the pre-defined comparator value,
TIMx_CMPB.
Assuming TIMx_CMPB<>0x0000, and clock enabled input EN_DIV=1, the period, TINT_TIMER, of the interrupt
signal INT_TIMER is given by the following equations:
                                                                       Fck
           Equation 6                               FCNT_CK 
                                                                    TIM x_DIV
                                                                   TIMx_DIV
           Equation 7                               TINT_TIMER               TIMx_CMPB 1
                                                                     Fck
           Equation 8                                                  1           Fck          1
                                                    FINT_TIMER                        
                                                                   TINT_TIMER   TIMx_DIV TIMx_CMPB 1 
16
  control register
                                                                               16
                     TIMx_START   TIMx_ENCMP
                                                                         TIMx_CMPB
                                          TCTRL_x
                                                                                    TREGB_x
                                                         Channel B
The IO ports associated to the Compare values TIMx_CMPA and TIMx_CMPB are the ports TREGA_x and
TREGB_x.
This mode uses the 16-bits counter as a free running counter. The counter clock, CNT_CK, is the CPU clock, CK,
divided by a pre-defined number, TIMx_DIV, being 1, 16 or 256 – see paragraph 13.2.9. The counter is
incremented on the CNT_CK rising edge.
Two pre-defined comparator values, TIMx_CMPA and TIMx_CMPB, are loaded in the 16-bits IO ports TREGA_x
and TREGB_x.
An interrupt, Tx_INT2=INT_CMPA, is generated when the counter value is equal to the pre-defined comparator
value TIMx_CMPA.
The programmed time for this interrupt signal, TINT_CMPA, is given by the following equation:
                                                               TIMx_DIV
            Equation 10                        TINT_CMPA                TIMx_CMPA 1
                                                                  Fck
Where: Fck is the frequency of the CPU clock, and
       TIMx_DIV = 1, 16, or 256.
The same equation matches for the interrupt Tx_INT4=INT_CMPB with its compare value TIMx_CMPB.
The reset of the 16-bits counter is controlled with the control bits TIMx_ENCMP and TIMx_START.
     If TIMx_ENCMP is set to 1, the 16-bits counter is reset when its value reaches the comparator value
        TIMx_CMPB.
     If TIMx_ENCMP is set to 0, the 16-bits counter will be reset when the maximum counting value 0xFFFF
        is reached.
Channel A INT_CAPA
                      EN_DIV                                                              TCNT_x
                                                                 CNT_CK
                      CK                     Pre-divider                                            INT_OVF
                                                                          16-bit up counter
                                                                   RST                                                      Tx_INT1
                                                                                                                                      INT_CAPA
   control register                                                                                                         Tx_INT2
                                                                                                                                      OVRA
                      TIMx_EDGB1 TIMx_EDGA1                                                                    Interrupts   Tx_INT3
                                                    TIMx_START                                                                        INT_OVF
                      TIMx_EDGB0 TIMx_EDGA0                                                                      block      Tx_INT4
                                                                          TIMx_CNT                                                    OVRB
                                                             TCTRL_x                 16                                     Tx_INT5
                                                                                                                                      INT_CAPB
              Tx_INB = IN_CAPB
                                             Edge selector                                           OVRB
                                                                               TIMx_CAPB
                      CK                      (TxEDGB)
                                                                                          TREGB_x
                                                                                                    INT_CAPB
Channel B
The IO ports associated to the Capture values TIMx_CAPA and TIMx_CAPB are the ports TREGA_x and TREGB_x.
This mode uses the 16-bits counter as a free running counter. The counter clock, CNT_CK, is the CPU clock, CK,
divided by a pre-defined number, TIMx_DIV, being 1, 16 or 256 – see paragraph 13.2.9. The counter is
incremented on the CNT_CK rising edge.
The input signal, IN_CAPA, is sampled by CPU clock, CK, and when an event is detected on channel A:
The content of the free-running counter TIMx_CNT is saved in the 16-bits IO port TREGA_x,
An interrupt, Tx_INT1=INT_CAPA, is generated.
The edge selector can be programmed with the control bits TIMx_EDGA[1:0] to detect the following events:
rising, falling, or rising and falling edges.
The input signal, IN_CAPB, is also sampled by CPU clock CK, and when an event is detected on channel B:
The content of the free-running counter is saved in the 16-bits IO port TREGB_x,
An interrupt, Tx_INT5=INT_CAPB, is generated.
The edge selector can be programmed with the control bits TIMx_EDGB[1:0] to detect the following events:
rising, falling, or rising and falling edges.
An interrupt, Tx_INT3=INT_OVF, is generated when the counter overflows, i.e. reaches the values 65535. Using
this interrupt the counter length can be extended by software.
The interrupt signals, Tx_INT2=OVRA and Tx_INT4=OVRB, respectively controlled by channel A and B, are
generated if two consecutive capture actions occur without CPU reading operation in between. The first value
memorized in the corresponding port is not overwritten. Beware on interrupt management (priority, clear
pending operation) because up to 5 interrupt can be generated in the same time.
TIMx_STA
                               INT_CAPA / OVRA                                        INT_CAPB / OVRB                                    NOTES
   RT
                                   event           event     CPU
                                detected (1)    detected (1) read
                                                                                                                                    (1) According to
                                                                                                                                    the
                     INT_CAPA
1                                                                      -                                                            programming of
                                                                                                                                    the edge
                        OVRA
                                                                                                                                    selector EDGA.
                                TIMx_CAPA      TIMx_CAPA
                                  updated      not updated
                                                                                                                                    - Timer Capture
                    INT_CAPA                                               INT_CAPB
                                0              stay endlessly to '0'                   0               stay endlessly to '0'
                                                                                                                                    mode disabled
0
                     OVRA
                                0              stay endlessly to '0'
                                                                            OVRB
                                                                                       0               stay endlessly to '0'
                                                                                                                                    - 16-bits counter
                                     0                                                      0                                       reset to 0000h.
                                               Table 29 – Timer capture output signals.
16
                                                                       TIMx_CNT      16
                      EN_DIV
                                                        CNT_CK
                      CK              Pre-divider
                                                                        16-bit up counter             INT_OVF
                                                             RST                                                             Tx_INT1   unused
   control register                                                                                                          Tx_INT2
                                                                                           TCNT_x                                      INT_CMPA
                      TIMx_EDGB1                                                                                Interrupts   Tx_INT3
                                               TIMx_START                                                                              INT_OVF
                      TIMx_EDGB0                                       TIMx_CNT     16                            block      Tx_INT4
                                                                                                                                       OVRB
                               2                        TCTRL_x                                                              Tx_INT5
                                                                                                                                       INT_CAPB
   IN_CAP2
                           Edge selector                                                                OVRB
   CK                                                                          TIMx_CAPB
                            (TxEDGB)
                                                                                         TREGB_x     INT_CAPB
Channel B
Note:
The symbol ‘x’ should be replaced by ‘1’, ‘2’ or ‘3’ depending on the Timer speaking about.
The IO port associated to the Compare value TIMx_CMPA is the port TREGA_x.
The IO port associated to the Capture value TIMx_CAPB is the port TREGB_x.
Compare Channel A
This mode uses the 16-bits counter as a free running counter. The counter clock, CNT_CK, is the CPU clock, CK,
divided by a pre-defined number, TIMx_DIV, being 1, 16 or 256 – see paragraph 13.2.9. The counter is
incremented on the CNT_CK rising edge.
Assuming bit TIMx_START is high, the 16-bits counter is reset when its value reaches the maximum counting
value 0xFFFF.
An interrupt, Tx_INT1=INT_CMPA, is generated when the counter value TIMx_CNT is equal to the pre-defined
comparator value TIMx_CMPA.
The programmed time for this interrupt signal, TINT_CMPA, is given by the following equation:
                                                             TIMx_ DIV
            Equation 11                        TINT_CMPA               TIMx_ CMPA  1
                                                                Fck
Where: Fck is the frequency of the CPU clock, and
       TIMx_DIV = 1, 16, or 256.
    As long as the bit TIMx_START is not set to 0, the counting sequence is repeated indefinitely; and the frequency
    at which the interrupt signals is generated is given by Equation 12:
                                                                          Fck      1
                                                            FOUT               
            Equation 12                                                TIMx_ DIV 65536
    Capture Channel B
    The input signal, IN_CAPB, is sampled by CK, and when an event is detected on channel input B:
            The content of the free-running counter is saved into the 16-bits IO port TREGB_x,
            An interrupt, Tx_INT5=INT_CAPB, is generated.
    The edge selector can be programmed with the control bit TIMx_EDGB[1:0] to detect the following events:
    rising, falling, or rising and falling edges.
    An interrupt, Tx_INT3=INT_OVF, is activated when the counter overflows. The counter length can be extended
    by software using this interrupt.
    The interrupt signal, Tx_INT4=OVRB, is generated if two consecutive capture actions occur without CPU reading
    operation in between. The first value TIMx_CAPB, memorized in port TREGB_x, is not overwritten.
TIMx_S
                               INT_CMPA                                             INT_CAPB / OVRB                                             NOTES
 TART
                                                                                                                                              DIV
                               TINT_CMPA          FOUT
                                                                                                                                TINT_CMPA         TIMx_ CMPA  1
                                                                                                                                              Fck
1                   INT_CMPA
                                                                        -                                                                   Fck      1
                                                                                                                                FOUT             
                               0   TIMx_CMPA       65535                                                                                 TIMx_ DIV 65536
                                                                                       TIMx_CAPB      TIMx_CAPB
                                                                                         updated      not updated
                                                                            INT_CAPB
                                                                                         0              stay endlessly to '0'
                                                                                                                                - Timer Compare/Capture mode
0                   INT_CMPA                   stay endlessly to '0'
                                                                                                                                disabled
                                                                             OVRB
                                                                                         0              stay endlessly to '0'
                               0     CMPA         65535                                       0
                                                                                                                                - 16-bits counter reset to 0000h.
                                                   Table 30 – Timer Compare/Capture output signals.
Note:
The symbol ‘x’ should be replaced by ‘1’, ‘2’ or ‘3’ depending on the Timer.
This mode uses the 16-bits counter as an event counter. The clock of the counter CNT_CK is the CPU clock, CK,
controlled by EN_DIV – see paragraph 13.2.9.
The input signal, IN_ACC, is sampled by CK when input EN_DIV is high, and when an event is detected the
counter is incremented by 1. The edge selector can be programmed to detect the following events on IN_ACC:
rising, falling, or rising and falling edges.
If the control bit TIMx_START is low the Pulse accumulator mode is disabled and output INT_OVF is frozen to 0.
An interrupt, Tx_INT3=INT_OVF, is generated when the counter overflows, i.e. value 65535 is reached. Using
this interrupt the counter length can be extended by software. This interrupt signal must be connected to a
rising-edge sensitive interrupt inputs.
             Edge selector
  IN_DEB
              (TxEDGB)               R/S
                                                  2
                                                                         Output Block                    Tx_OUT_DEB
                                                                                                         internal debounced helper signal
The IO port associated to the Compare value TIMx_CMPB is the port TREGB_x.
This mode uses the 16-bits counter as delay counter. The counter clock, CNT_CK, is the CPU clock, CK, divided
by a pre-defined number, TIMx_DIV, being 1, 16 or 256 – see paragraph 13.2.9. The counter is incremented on
the CNT_CK rising edge.
A pre-defined comparator value, TIMx_CMPB, is loaded in the 16-bits IO port TREGB_x and defines the
debounce delay. The equality comparator output, TIMx_OUT_GE, is set to 1 when the counter reaches this
value; and an R/S block manages the freeze control of the internal debounced helper signal Tx_OUT_DEB.
This edge selector is programmed to detect rising and falling edges. By using the two control bits, TIMx_DIN1
and TIMx_DIN0, the debounce method can be changed. The bits TIMx_DIN select the time at which the falling
and/or rising edge detection are displayed on output INT_EDGF and INT_EDGR (i.e. immediately or delayed by
the debounce delay counter).
So when a rising edge is detected on Tx_OUT_DEB
         An interrupt, Tx_INT4= INT_EDGR, can be generated immediately or after the debounce delay counter
And when a falling edge is detected on Tx_OUT_DEB
         An interrupt,Tx_INT5 INT_EDGF, can be generated immediately or after the debounce delay counter
If the control bit TIMx_START is low, the Debouncer mode is disabled and outputs INT_EDGR, INT_EDGF and
Tx_OUT_DEB are frozen to 0.
Note: The case where the debounce delay TIMx_CMPB=0000h is to be avoided. If TIMx_CMPB=0000h the
following two cases are defined:
         if TIMx_DIN1 = TIMx_DIN0 = 1, then Tx_OUT_DEB is equal to IN_DEB delayed by one period of CK, and
         if TIMx_DIN1 = TIMx_DIN0 = 0 then Tx_OUT_DEB is equal to IN_DEB delayed by two periods of CK.
The input signal, IN_DEB, is sampled by CK, and when a rising or falling edge is detected the output value,
Tx_OUT_DEB, is frozen to 0 or 1, until the programmed delay is reached.
An interrupt signal is generated each time Tx_OUT_DEB toggle.
Particular case, if the debounce delay is shorter than the bouncing period: The signal Tx_OUT_DEB will change
according to the bits TIMx_DIN and to the state of the input IN_DEB after the debounce delay counter. The
rules are the same than for the standard case, see Table 32.
IN_DEB
                      0            0
                                                  Tx_OUT_DEB
INT_EDGR
INT_EDGF
DELAY DELAY
IN_DEB
                                                  Tx_OUT_DEB
                      0            1
                                                  INT_EDGR
INT_EDGF
DELAY DELAY
IN_DEB
                                                  Tx_OUT_DEB
                      1            0
                                                  INT_EDGR
INT_EDGF
DELAY DELAY
IN_DEB
1 1 Tx_OUT_DEB
INT_EDGR
INT_EDGF
All the IO ports involved in a single timer module (TIMER_x) programming are summarized below:
          The Data ports TREGA_x and TREGB_x,
          The Control port TCTRL_x, and
          The Counter port TCNT_x.
According to the selected Timer mode –see previous paragraphs-, the data saved in the port
TREGA_x is referred as the compare value TIMx_CMPA, or as the capture value TIMx_CAPA.
TREGB_x is referred as the compare value TIMx_CMPB, or as the capture value TIMx_CAPB.
For detailed address location please refer to the ports map description chapter.
                  Interrupt
Mode                              / output      / top level name    Interrupt description
                  name
                                                /                   Greater than or equality comparator.
Timer             INT_TIMER       / Tx_INT4
                                                TMRx_CMPB_IT        (TIMx_CNT > TIMx_REGB)
                                                /                   Equality comparator. (TIMx_CNT =
                  INT_CMPA        / Tx_INT2
                                                TMRx_CMPA_IT        TIMx_REGA)
Dual
                                                                    Greater than or equal (TIMx_CNT >
Compare
                  INT_CMPB        / Tx_INT4     /TMRx_CMPB_IT       TIMx_REGB). Reset TIMx_CNT if control bit
                                                                    TIMx_ENCMP is high.
                                                                    Capture signal for channel A. Active edge
                  INT_CAPA        / Tx_INT1     / TMRx_CAPA_IT      programmed with the control bit
                                                                    TIMx_EDGA.
                                                                    Capture signal for channel B. Active edge
                  INT_CAPB        / Tx_INT5     / TMRx_CAPB_IT      programmed with the control bit
Dual                                                                TIMx_EDGB.
Capture
                                                /                   Overrun on Channel A. Previous interrupt
                  INT_OVRA        / Tx_INT2
                                                TMRx_CMPA_IT        INT_CAPA not executed.
                                                /                   Overrun on Channel B. Previous interrupt
                  INT_OVRB        / Tx_INT4
                                                TMRx_CMPB_IT        INT_CAPB not executed.
                  INT_OVF         / Tx_INT3     / TMRx_OVF_IT       Counter overflow. (TIMx_CNT > FFFFh)
                                                /                   Equality comparator. (TIMx_CNT =
                  INT_CMPA        / Tx_INT2
                                                TMRx_CMPA_IT        TIMx_REGA)
                  INT_OVF         / Tx_INT3     / TMRx_OVF_IT       Counter overflow. (TIMx_CNT > FFFFh)
Capture
                                                /                   Overrun on Channel B. Previous interrupt
Compare           INT_OVRB        / Tx_INT4
                                                TMRx_CMPB_IT        INT_CAPB not executed.
                                                                    Capture signal for channel B. Active edge
                  INT_CAPB        / Tx_INT5     / TMRx_CAPB_IT
                                                                    programmed with TIMx_EDGB.
Pulse
                  INT_OVF         / Tx_INT3     / TMRx_OVF_IT       Counter overflow. (TIMx_CNT > FFFFh)
Accumulator
                                                /
                  INT_EDGF        / Tx_INT4                          Falling edge detected on Tx_OUT_DEB
Debouncer                                       TMRx_CMPB_IT
                  INT_EDGR        / Tx_INT5     / TMRx_CAPB_IT Rising edge detected on Tx_OUT_DEB
                                         Table 37 – Interrupts functions
The Timer interrupts are connected into MULAN3 external interrupts block.
14. RC-Oscillator
The digital part of controller is supplied by a RC oscillator, which is trimmed via software according to the ports
map description and NVRAM allocation table.
1.) In case of over temperature detection the Bit OVT in port ANA_INA (for details see chapter 11.6) is set. This
can create an interrupt, if the corresponding external interrupt source ANA_INA[15] has been activated. With
this interrupt software should reduce the clock frequency and the power consumption of external components
at pin VDDA as much as possible.
It is also useful to switch off parts of the IC to reduce internal power and to protect external devices. This
especially covers output drivers (e.g. pwm, high voltage ...).
There is no automatic shutdown of any parts of the IC.
If the internal temperature falls below the lower threshold (Tot_off) all drivers can be switched on again.
The over-temperature detection circuitry is active after Power On, but can be deactivated separately by the
corresponding bits in the ports map (see ANA_OUTx ports).
2.) During the Melexis wafer test the temperature values for -40 °C, 35 °C and 125 °C are saved into NVRAM 2,
page 2. These values are used as reference points for the on chip temperature sensor.
The reference values are stored at following addresses:
The channel list contains up to 255 entries (channels in words) + delimiter (0xFFFF). The delimiter is signaling
the ADC that the end of the channel list is reached.
C-macros are available in the Software Platform for configuration and start of the ADC.
                   VS              Channel[0]
                TEMP               Channel[1]
                VDDD               Channel[2]                                   SYSTEM CLOCK
                                                                                                                 DIV
             VDDA / 2              Channel[3]
              V5V6 / 4             Channel[4]
                                                                                                                                      CLK
                                                                                                                                                                     ADC_EOC_SYNC
                                                            TMR1_CAPA_IT
              HV[0..3]            Channel[16..19]
                                                                                                                                                             Ref
                                                            TMR1_CAPB_IT
         HVIODIFFx                 Channel[20]              TMR1_CMPA_IT
                                                            TMR1_CMPB_IT
                                                             PWM4_CMPI                                             TRIG_SRC
                                                             PWM3_CMPI
                                                             PWM2_CMPI
                                                                                             Trigger
                                                                                                                                            VRH3
                                                                                             select
                                                             PWM1_CMPI
                                                             PWM4_CNTI                                                                      VRH2
                                                             PWM3_CNTI
                                                                                                                                            VRH1                     to ADC Interrupt
                                                             PWM2_CNTI
                                                                                                                                                    select
                                                             PWM1_CNTI                                         SOFT_TRIG
                                                                                                                                                    Ref
                         RAM                                                                                                                                                                                                        RAM
                                                       Transfer0                                                                                                                                              Transfer0
                     Config 0                                                      Read                Write       SIN[3:0]   SREF[7:4]        SREF[1:0]                                Read          Write                      Sample 0
                     Config 1                                                                                                                                                                                                    Sample 1
                                                                                             DMA request                             ADC control unit                                   DMA request
                          ...                                        fe
                                                                        r   N                                                                                                                                                         ...
                                                                   ns                              Address           SBASE counter                                 DBASE counter        Address                    Tr
                                                            Tr
                                                               a                                                                                                                                                      a
                                                                                                                                                                                                                     ns
                          ...                                                                                                                                                                                          fer
                                                                                                                                                                                                                          N           ...
                                                                                   DMA channel                                                                                          DMA channel
                    Config N                                                                                                                                                                                                     Sample N
                                                                                                         ADC_SBASE[15:0]                                ADC_DBASE[15:0]
                         16bits                                                                                                                                                                                                      16bits
                                                                                                                                    LOOP
                                                                                                                                   START
                                                   SREF                          SREF
                                SIN[3:0]                                                                                                                                                                                         ADC[9:0]
                                                    [7:4]                         [1:0]
                                 Input           Hardware                        reference                                                                                                                                       ADC result
                                 channel         trigger                         voltage
Figure 28 – AD converter overview illustrating control including DMA and channel multiplexing
 During the power-up procedure (low_level_init.c: low_level_init) the initialization of ADC trimming register will
 be executed. So there is no need to do a re-initialization of the ADC trimming register.
IO port: ADC_SBASE
Address: 0x2812                                        Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]          Bit[5]         Bit[4]       Bit[3]           Bit[2]         Bit[1]        Bit[0]
                                                   ADC_SBASE[7:0]
IO port: ADC_DBASE
Address: 0x2814                                        Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]          Bit[5]         Bit[4]      Bit[3]            Bit[2]         Bit[1]        Bit[0]
                                                  ADC_DBASE[7:0]
IO port: ADC_CTRL
Address: 0x2810                                        Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]          Bit[5]         Bit[4]          Bit[3]        Bit[2]         Bit[1]        Bit[0]
ADC_SYNC_
              -                                              -             LOOP           TRIG_SRC      START
SOC
IO port: ANA_OUTE
Address: 0x204C                                      Access mode: Word, Byte – Read and Write
Bit[7]        Bit[6]        Bit[5]         Bit[4]          Bit[3]         Bit[2]          Bit[1]          Bit[0]
Melexis
                                                          TR_ADCREF3
reserved
IO port: ANA_OUTD
Address: 0x204A                                      Access mode: Word, Byte – Read and Write
Bit[7]       Bit[6]         Bit[5]         Bit[4]          Bit[3]         Bit[2]          Bit[1]          Bit[0]
Melexis
                                                          TR_ADCREF1
reserved
    ADC_SIN[4:0]                                                                                                   Settling
                                     Source             Input                         Remark
                         CH                                                                                         time
                                                    voltage range
4     3    2   1    0
                                                                       Internal high ohmic divider 1:14
0     0    0   0    0   0       VS                0 .. 14*VRHx                                                    5us
                                                                       [1]
0     0    0   0    1   1       TEMP              internal             Internal temperature sensor                5us
0     0    0   1    0   2       VDDD              internal             Digital supply voltage                     5us
                                                                       Analogue supply voltage, divided
0     0    0   1    1   3       VDDA/2            internal                                                        5us
                                                                       by 2
                                                                       Analogue supply voltage 5.6V,
0     0    1   0    0   4       V5V6/4            internal                                                        5us
                                                                       Divided by 4
                                                                       Auxiliary analogue supply voltage,
0     0    1   0    1   5       VAUX/2            internal                                                        100us
                                                                       divided by 2
0     0    1   1    0   6       LINAAMP           internal             LIN autoconfig amplifier output            10us
                                                                       LIN autoconfig common mode
0     0    1   1    1   7       LINVCMO           internal                                                        10us
                                                                       voltage
                                                                       Offset calibration for ground
0     1    0   0    0   8       HV[4]                                  related differential measurement
                                                                       [2]
                                                                       Ground related differential
0     1    0   0    1   9       HV[5]-HV[4]
                                                                       measurement [2]
0     1    0   1    0   10
0     1    0   1    1   11
0     1    1   0    0   12
0     1    1   0    1   13      HV[3]             0 .. 4*VRHx[3]       with internal divider 1:4 [1]              10us
0     1    1   1    0   14      HV[4]             0 .. 4*VRHx[3]       with internal divider 1:4 [1][2]           10us
0     1    1   1    1   15      HV[5]             0 .. 4*VRHx[3]       with internal divider 1:4 [1][2]           10us
1     0    0   0    0   16      HV[0]             0 .. 4*VRHx[3]       with internal divider 1:4 [1]              10us
1     0    0   0    1   17      HV[1]             0 .. 4*VRHx[3]       with internal divider 1:4 [1]              10us
1     0    0   1    0   18      HV[2]             0 .. 4*VRHx[3]       with internal divider 1:4 [1]              10us
1     0    0   1    1   19      HV[3]             0 .. 2*VRHx[3]       with internal divider 1:2 [1]              10us
                                                                       Difference:
                                                                       VRHx - ((VS - VHV) / 5)
1     0    1   0    0   20      HVIODIFF[x]       VS .. VS-VRHx                                                   10us
                                                                       VHV - input voltage on HVx pin
                                                                       VRHx - reference voltage
                                                                                      HVDIFF=
1     0    1   0    1   21       HVIODIFF[0]        VS .. VS-HVDIFF                                               10us
                                                                           VRHx - ((VS – HV[0]) / 5) [3][4]
                                                                                                       HVDIFF=
1     0    1   1    0   22        HVIODIFF[1]        VS .. VS-HVDIFF                                              10us
                                                                               VRHx - ((VS – HV[1]) / 5) [3][4]
                                                                                      HVDIFF=
1     0    1   1    1   23       HVIODIFF[2]        VS .. VS-HVDIFF                                               10us
                                                                           VRHx - ((VS – HV[2]) / 5) [3][4]
                                                                                                       HVDIFF=
1     1    0   0    0   24        HVIODIFF[3]        VS .. VS-HVDIFF                                              10us
                                                                               VRHx - ((VS – HV[3]) / 5) [3][4]
                                                                                      HVDIFF=
1     1    0   0    1   25       HVIODIFF[4]        VS .. VS-HVDIFF                                               10us
                                                                          VRHx - ((VS – HV[4]) / 5) [2][3][4]
                                                                                                       HVDIFF=
1     1    0   1    0   26        HVIODIFF[5]        VS .. VS-HVDIFF                                              10us
                                                                            VRHx - ((VS – HV[5]) / 5) [2][3][4]
                                              Table 44 – ADC channels selection
The hardware trigger sources are selected by the bits ADC_REF[7:4] (see Table 45).
In case of ADC Channel [26:21] become selected: The chosen ADC Trigger from table below is pre-processed by
SC Filtering Circuit and forwarded as DMA trigger after <counter time> delay – see IO-map SC counter values.
The counter time shall delay the ADC trigger into the on-time of the PWM duty cycle. For each of the different
RGB channels a separate <counter time> can be used.
[ ]
Where
    VRHx is the reference voltage (see Figure 29)
    Divider is the input divider of the ADC channel (see Table 44)
     2. Turn-off the LOOP bit to stop the infinite conversion. Otherwise it will never end.
     3. Wait until the ADC_START bit is cleared.
     4. The ADC_CTRL port can be set to 0 in case the ADC_START bit is cleared.
Code-Example:
Code-Example:
uint16 adcRes[1] = {0};
uint16 adcOff[2] = {0x0000, 0xFFFF};
Please also refer to package Rth data if approximation of ambient temperature is needed.
To calculate the temperature from an ADC value a linear abstraction can be used. With this approach following
software example can be used:
17.2. Applications
The Watchdog block is used in association with the MLX16. According to the selected mode the block waits for a
MLX16 acknowledgement between different time limits, or else a System reset interrupt is generated.
A MLX16 acknowledgement resets the internal WD counter.
       In Window mode:
        the Watchdog is a reset-able free-running up counter. The acknowledge signal should appear only
        within a time window starting at half of the predefined timeout value.
The WD attention interrupt and the System reset interrupt will be used by the software.
                                                   WD_MODE              WD_TO
            WD_DIV
                                      WD_CNT
   CK250K     Clock                                      Timeout Unit
                                  8 bits counter                                WD Reset Interrupt (SYS_WD_RST)
            prescaler                                    - mode control
                                                         - timeout generation   WD Attention Interrupt (WD_ATT)
   Reset                                                 - window checking
   User Mode (from CPU)                                  - protection mode      Protection Error Intrrupt (SYS_PROT_ERR)
                                                           checking
                                               WD_TG                                WD_ERR
                                                                                    WD_WND
                            Figure 30 – Functional diagram of the Watchdog block.
The Watchdog mode, simple timer, window or intelligent is selected via the control bit WD_MODE. All modes
use a timeout value WD_TO, which determines the watchdog timeout WD_TO. An 8 bit free-running counter
WD_CNT is counting using the pre-scaled input clock until it reaches the value WD_TO.
The WD prescaler module supports the following ratios WD_DIV: 1/8, 1/32, 1/128, 1/512 of the 250kHz input
clock frequency. And the watchdog time-out value is defined by the following equation:
                                                      1
         Equation 13                 TimeOut             2 2WD _ DIV  8  WD _ TO
                                                     FCK
Where: Fck=1/Tck is the frequency of the WD input clock
       WD_DIV is the WD predivider value, defined in IO port WCTRL
       WD_TO is the time out value, defined in IO port WDT
For a given time, several combinations of WD_TO and WD_DIV can be found. It is recommended to use WD_TO
values as big as possible and to reduce WD_DIV.
Examples of timeout values for different Tosc values are given in Table 50.
The operating mode can be set only once after resetting, which usually happens in the system initialization. To
change the mode, a new system reset is needed. To acknowledge the watchdog, the IO port WDT must be
written.
The IO port associated to the Time Out value WD_TO is the port WDT.
The IO port associated to the Tag value WD_TG is the port WTG.
The IO port associated to the Control and flag bits, e.g. WD_MODE, is the port WCTRL.
 The Intelligent mode is different from the previous ones, as it supposes the software to allocate for a given task
 a given amount of time and a tag.
       After the timeout programmed, WD_TO:
               o An attention interrupt WD_ATT is generated,
               o the software can verify its state using the tag WD_TG,
               o The software can set a new couple of timeout value and tag.
       The watchdog reset USER_WD_RST occurs only in case WD_TO and WD_TG had not been updated 1/8
          of the timeout after the first interrupt WD_ATT.
       An attempt to change the control bit WD_MODE sets the flag bit WD_ERR to 1. An interrupt PROT_ERR
          is generated.
       To write new values in the IO port, the MULAN3 user bit USER must be set to 0, i.e. ‘System mode’
          must be selected. Or else the flag bit WD_ERR is set to 1 and an interrupt PROT_ERR is generated.
IO port: WD_TG
Address: 0x2804                                       Access mode: Word, Byte – Read and Write
Bit[7]             Bit[6]             Bit[5]       Bit[4]            Bit[3]       Bit[2]           Bit[1]    Bit[0]
WD_TAG[7:0]
WD_TAG[7:0]:            tag value; using this port the Watchdog software can manage different owners
                                         Table 51 – Watchdog ports – Tag value.
IO port: WD_CTRL
Address: 0x2803                                       Access mode: Byte – Read and Write
Bit[7]         Bit[6]        Bit[5]               Bit[4]      Bit[3]         Bit[2]         Bit[1]       Bit[0]
WD_ERR         WD_WND                WD_MODE[1:0]                   -              -               WD_DIV[1:0]
                            Flag for access error; depends on the Watchdog mode. Read and clear bit.
WD_ERR:                           1 = WD access error detected; the interrupt PROT_ERR is generated
                                  0 = no WD access error
                            Flag to indicates the open windows; for windows mode only
WD_WND:                           1 = window is open, Watchdog acknowledge is allowed
                                  0 = window is closed, no acknowledge allowed
                            Watchdog mode.
WD_MODE[1:0]:                         00 = Watchdog disabled        10 = Window Watchdog mode
                                      01 = Timer Watchdog mode 11 = Intelligent Watchdog mode
                            Predivider for Watchdog counter. The Watchdog counter clock frequency is divided by:
WD_DIV[1:0]:                          00 = division by 1*8            10 = division by 16*8
                                      01 = division by 4*8            11 = division by 64*8
                                  Table 52 – Watchdog ports – Status and Control port.
IO port: WD_T
Address: 0x2802                                       Access mode: Word, Byte – Read and Write
Bit[7]             Bit[6]             Bit[5]       Bit[4]            Bit[3]       Bit[2]           Bit[1]    Bit[0]
WD_TO[7:0]
WD_TO[7:0]:             Time Out value; to be compare with the internal free running counter.
                                    Table 53 – Watchdog ports – Time Out value.
Analogue and digital watchdog use the same interrupts, as described in chapter
“18 Analogue Watchdog (AWD)”.
 The watchdog uses a completely separate 10kHz oscillator. Its nominal period t AWD_PER is ~0.1ms. The watchdog
 starts always with maximum timeout delay immediately after releasing the Master reset, so it has the same
 behavior after POR or WAKE UP from SLEEP MODE.
 The application has no possibility to stop this watchdog.
 After half of the timeout (tAWD_TIMEOUT/2) the analogue watchdog generates an info signal AWD_ATT, which is
 connected to watchdog attention interrupt.
 When the timer reaches the AWD_TIMEOUT, a reset is issued. The reset feeds directly into the system reset
 INT0.
 The watchdog delay is programmable by application through the port AWD containing 8 bits for AWD_TIME and
 2 bit for the clock prescaler AWD_CKDIV (division ratios are 1-4-16-64).
 The delay can be updated via the AWD port at any time.
 A write to the AWD port resets the watchdog counter and the AWD_WRITE_FAIL flag. The watchdog will be
 acknowledged.
MLX16 MLX4
RxD debounce
The RxD debouncing circuit and the integrated low pass filter in the receiver path prevent RxD spikes in case of
RF interferences and automotive pulses to guarantee a correct sampling of the master request.
TxD timeout
A special feature is the TxD timeout. In case of a faulty blocked TxD (MLX or LIN controller crash) the Bus output
is switched off automatically after the specified TxD timeout reaction time to prevent a dominant bus. The
transmission is continued by next TxD L to H transition without delay.
Melexis provides a software library which supports the LIN-Auto Addressing via Bus Shunt Method. Further
technical information can be found in [10] Melexis Application note, LIN-AA according Bus Shunt Method (BSM)
Slave Node Position Detection (SNPD).
                                                                                                                               differential amplifier +
                                                                                                                               shift to ADC range is
                                                                       HVDIFFSEL                                               shared for all HVIOs
                                                                                                         VS             +
                                                                                                                         -
ADC Divider
HVENFCM
                                                                                                                      Adjustable current
                                                                                                              I_fcm
                                                                                                                       0..2mA for RGB
                                                                                                                           monitor
                                                  HV_OUTOD
                  HVDIFFSEL
                                        HV_ENWU
                              HVENFCM
HV_INEN
HV_IN
VAUX
  Function                                                                        HV[...]
                                                            5         4       3        2       1        0
  Low side driver 48mA (open drain) ...                     X         X       X        X       X        X
  ... with PWM output from block                            6         5       4        3       2        1
  ADC measurement via its own ADC channel                   X         X       X        X       X        X
  Digital Schmitt trigger input                             X         X       X        X       X        X
  Digital Schmitt trigger for WAKE UP                       X         X       X        X       X        X
  Programmable Debouncing for Inputs                        X         X       X        X       X        X
The HV open-drain outputs are designed for LED controlling with a constant current to adapt the brightness and
color of RGB LEDs. This will be done via current modulation (see section 12). The maximum continuous current
during the on-time is defined by a high accuracy and high stability active current source.
In order to prevent undesired LED glowing at all HV-pins an internal leakage compensation can be enabled via
the bits HVPUSEL[0] and HVPUSEL[1] in the ANA_OUTG register (see Table 63).
In case higher current (>30mA) requirements, three additional current values (up to 48mA) can be configured.
The settings can be found in section 20.5 HVIO configuration ports. For this configuration the thermal condition
has to be considered (TA, Rth package, module encapsulation).
VS
                                                                               HVPUSEL[0]
                 HVIO[5:0]                                                    ANA_OUTG[1]
                                                                                          HV
                                                            HV0IOUTCTRL
                                                            ANA_OUTF[3:0]                      ESD
             OPA
                                                 HVDOUTB1                                                             G
                                                             HV1IOUTCTRL
                                                             ANA_OUTF[7:4]
                                                                                                     VS
                                                                              HVPUSEL[1]
                                                                             ANA_OUTG[10]
                                                                                   RGB leakage
                                                                                   compensation
                                                 HVDOUTB3
                                                              HV3IOUTCTRL                                             R
                                                             ANA_OUTF[15:12]
                                                 HVDOUTB4
                                                              HV4IOUTCTRL                                             G
                                                              ANA_OUTN[3:0]
                                                 HVDOUTB5
                                                              HV5IOUTCTRL
                                                                                                                      B
                                                              ANA_OUTN[7:4]
                                                                 differential
                                                               amplifier + shift to
                                                                 ADC range
                                               HVDIFFSEL     VS
                                                                        +
                                                                        -             ... ADC
                                                                                                 ADC
                                                                                         Mux
                          HVIO[x]
HVENFCM
I_fcm
                                             Programmable current
                                                source 0 .. 2mA
                                                for LED forward
                                             voltage measurement
The inline current measurement is intended to detect aging and temperature effects at the diodes. It is
supported by
     Precision current source to GND (max. 2mA)
     special differential amplifier transferring the difference VS-V(HVIOx) to the ADC input < 1.25V
Principle:
     diode switched off during modulation period
     current source and differential amplifier switched on  the LED diode starts to conduct with
         ~1.5...3.7V voltage drop
     voltage is measured and compared with value stored at initial calibration (EOL programming at
         customer)
     Diagnostic for OPEN ((VS-V(HVIOx)) > 3.7V) and SHORT ((VS-V(HVIOx)) < 1.5V) is supported
The differential amplifier can also be used in combination with the RGB current source.
Melexis provides a software library which supports the LED forward voltage measurement. The library is part of
the Melexis Software Platform.
Melexis provides a software library which supports the shunt current measurement. The library is part of the
Melexis Software Platform.
The hardware unit will be controlled via the ANA_OUTO and the ADC_SIN[4:0] port. A description of
ADC_SIN[4:0] can be found in chapter 16.3 ADC Channel selection Guide. More details to ANA_OUTO can be
found in Table 56.
IO port: ANA_OUTO
Address: 0x28E8                                                                  Access mode: Byte – Read and Write
Bit[7]                    Bit[6]           Bit[5]              Bit[4]  Bit[3]       Bit[2]                    Bit[1]                   Bit[0]
                                                                         D_8B
Bit[15]                   Bit[14]          Bit[13]       Bit[12]       Bit[11]      Bit[10]                   Bit[9]                   Bit[8]
     -                         -                -              -            -              -                  EN_SENSEOPAMP            SBY_8BDAC
D_8B:                                    8 bit DAC overcurrent comparator
                                         standby 8 bit DAC
SBY_8BDAC:                                         1 = DAC disabled
                                                   0 = DAC enabled
                                         enable overcurrent opamp
EN_SENSEOPAMP:                                     1 = overcurrent detection enabled
                                                   0 = overcurrent detection disabled
                                                              Table 56 – Port ANA_OUTO
                                                                        Vref = 2.5 V
                                   ANA_OUTM[7]                                                                 XTA1SEL[6]
                                                              Vref
                                                              Trim
                                   ANA_OUTM[3]
                                                                                                                                            TA1
                                   ANA_OUTO[7]
                                                                                                               XTA1SEL[7]
                                                                              8 Bit
                                                                              DAC
ANA_OUTO[0]
                                   ANA_OUTO[8]                            SBY
               VS
                                                                                                                         -             OC_SENSE
                                                                                                                             EN
                    HV5     ANA_OUTO[9]                R1                              R2                              +
                                                                                                                                  EN
                                                                                     GAIN1 = -10
  VSHUNT
                                                                                     Offset = 250mV
                                                                          -                                 ADC_MUX[9]                 ADCIN11_8
                                                 ADC_MUX[8]
                                                                                EN
                                                                          +
ANA_OUTO[9] ANA_OUTO[9]
                    HV4                                R1                             R2
  V_gndshift
 The 8-bit DAC for the overcurrent threshold can be programmed via the ANA_OUTO[7:0] register (ANA_OUTO
 [7:0]=0xFF => threshold=max=2.5V; Reset value for the ANA_OUTO[7:0] = 0x00 => 0V).
 The amplifier offset value can be measured with ADC-converter using bit OFFSCAL and can be added to D_8B
 [7:0] for compensation.
Via the signal OC_SENSE (see also portsmap) it’s possible to detect and react in case of an overcurrent event.
IO port: HV_CFG
Address: 0x28CE                                       Access mode: Word – Read and Write
Bit[7]              Bit[6]    Bit[5]         Bit[4]          Bit[3]       Bit[2]           Bit[1]       Bit[0]
                                       [1]            [1]
-                   -         HVIFRB5        HVIFRB4         HVIFRB3      HVIFRB2          HVIFRB1      HVIFRB0
Bit[15]             Bit[14]   Bit[13]        Bit[12]         Bit[11]      Bit[10]          Bit[9]       Bit[8]
                              HVTMREN        HVTMREN         HVTMREN      HVTMREN
-               -               [1]           [1]                                          HVTMREN1     HVTMREN0
                              5              4               3            2
HVIFRBx         HV Interrupt on rising edge (=0) or falling edge (=1)
HVTMRENx        Routing to the timer input enable
                              Table 57 – HV Configuration Port 1 - Interrupt config
  [1]   only valid for MLX81115
IO port: HV_DEB
Address: 0x28D0                                       Access mode: Word – Read and Write
Bit[7]         Bit[6]         Bit[5]         Bit[4]         Bit[3]         Bit[2]       Bit[1]        Bit[0]
HV3DEB1        HV3DEB0        HV2DEB1        HV2DEB0        HV1DEB1        HV1DEB0      HV0DEB1       HV0DEB0
Bit[15]        Bit[14]        Bit[13]        Bit[12]        Bit[11]        Bit[10]      Bit[9]        Bit[8]
                                                                      [1]          [1]            [1]        [1]
-              -              -              -              HV5DEB1        HV5DEB0      HV4DEB1       HV4DEB0
               HV Debouncing: for each HV[x] there are 2 bits to select the debounce time:00=off, 01=1ms,
HVxDEBy
               10=4ms, 11=8ms
bits[15:12]    unused
                                  Table 58 – HV Configuration Port 2 - HV debounce
  [1]      only valid for MLX81115
IO port: ANA_OUTF
Address: 0x204E                                       Access mode: Word – Read and Write
Bit[7]        Bit[6]          Bit[5]         Bit[4]         Bit[3]         Bit[2]          Bit[1]       Bit[0]
HV1IOUTCT     HV1IOUTCT       HV1IOUTCT      HV1IOUTCT      HV0IOUTCT      HV0IOUTCT       HV0IOUTCT    HV0IOUTCT
RL3           RL2             RL1            RL0            RL3            RL2             RL1          RL0
Bit[15]       Bit[14]         Bit[13]        Bit[12]        Bit[11]        Bit[10]         Bit[9]       Bit[8]
HV3IOUTCT     HV3IOUTCT       HV3IOUTCT      HV3IOUTCT      HV2IOUTCT      HV2IOUTCT       HV2IOUTCT    HV2IOUTCT
RL3           RL2             RL1            RL0            RL3            RL2             RL1          RL0
HV0IOUTCT
              HV0 Current output control register
RLx
HV1IOUTCT
              HV1 Current output control register
RLx
HV2IOUTCT
              HV2 Current output control register
RLx
HV3IOUTCT
              HV3 Current output control register
RLx
                                   Table 59 – HV Current output control register
                    [1]
IO port: ANA_OUTN
Address: 0x28E6                                       Access mode: Word – Read and Write
Bit[7]        Bit[6]        Bit[5]         Bit[4]             Bit[3]      Bit[2]           Bit[1]      Bit[0]
HV5IOUTCT     HV5IOUTCT     HV5IOUTCT      HV5IOUTCT          HV4IOUTCT   HV4IOUTCT        HV4IOUTCT   HV4IOUTCT
RL3           RL2           RL1            RL0                RL3         RL2              RL1         RL0
HV4IOUTCT
              HV4 Current output control register
RLx
HV5IOUTCT
              HV5 Current output control register
RLx
                            Table 60 – HV Current output control register MLX81115
 [1]     only valid for MLX81115
                                                    HVIBIASSEL = 0
    HVxIOUTCTRL3          HVxIOUTCTRL2          HVxIOUTCTRL1              HVxIOUTCTRL0         HV Current Output
         1                     0                     0                         0                     3 mA
         1                     0                     0                         1                     6 mA
         1                     0                     1                         0                     9 mA
         1                     0                     1                         1                    12 mA
         1                     1                     0                         0                    15 mA
         1                     1                     0                         1                    18 mA
         1                     1                     1                         0                    21 mA
         1                     1                     1                         1                    24 mA
         0                     1                     1                         0                    27 mA
         0                     1                     1                         1                    30 mA
                                                                                              Open Drain Mode
          0                      0                        0                     0             (max possible
                                                                                              current)
                                Table 61 – HV Current output with HVIBIASSEL=0
                                                    HVIBIASSEL = 1
    HVxIOUTCTRL3          HVxIOUTCTRL2         HVxIOUTCTRL1          HVxIOUTCTRL0              HV Current Output
         1                      1                     0                    1                        36 mA
         1                      1                     1                    0                        42 mA
         1                      1                     1                    1                        48 mA
                               Table 62 – HV Current output with HVIBIASSEL=1
IO port: ANA_OUTG
Address: 0x28DA                                                Access mode: Word – Read and Write
Bit[7]           Bit[6]           Bit[5]            Bit[4]              Bit[3]         Bit[2]             Bit[1]        Bit[0]
                 WUI[1]           WUI[0]                                               HVIBIASSEL         HVPUSEL[0]
Bit[15]          Bit[14]          Bit[13]           Bit[12]             Bit[11]        Bit[10]            Bit[9]        Bit[8]
                                                                                       HVPUSEL[1][1]      PRUV[9]       PRUV[8]
HVPUSEL[0]       RGB leakage compensation HVIO[2:0]: 0=on, 1=off
HVPUSEL[1]       RGB leakage compensation HVIO[5:3]: 0=on, 1=off
HVIBIASSEL       HV Bias Current select register: 0=max 30mA current output, 1= max 48mA current output
                 Configure internal wake up time
                 00 – no Wake Up
                 01 – 4096 * 1/10kHz = 409.6 ms
WUI[1:0]
                 10 – 8192 * 1/10kHz = 819.2 ms
                 11 – 16384 * 1/10kHz = 1.6384 s
IO port: HV_OUTOD
Address: 0x28D2                                                Access mode: Word – Read and Write
Bit[7]           Bit[6]            Bit[5]            Bit[4]             Bit[3]         Bit[2]             Bit[1]        Bit[0]
-                -                 HVDOUTB5[1]       HVDOUTB4[1]        HVDOUTB3       HVDOUTB2           HVDOUTB1      HVDOUTB0
Bit[15]          Bit[14]           Bit[13]           Bit[12]            Bit[11]        Bit[10]            Bit[9]        Bit[8]
-                -                 HVENPWM5[1]       HVENPWM4[1]        HVENPWM3       HVENPWM2           HVENPWM1      HVENPWM0
HVDOUTBx         HV open drain selection: 0=OD off, 1=OD on
HVENPWMx         enable the routing from the PWM to the according bit
                          Table 64 – HV Configuration Port 3 - inverted open drain output signal
  [1]        only valid for MLX81115
IO port: HV_INEN
Address: 0x28D4                                                Access mode: Word – Read and Write
Bit[7]           Bit[6]             Bit[5]              Bit[4]            Bit[3]            Bit[2]           Bit[1]        Bit[0]
HVENFCM[5][1]    HVENFCM[4][1] HVINEN5[1]               HVINEN4[1]        HVINEN3           HVINEN2          HVINEN1       HVINEN0
Bit[15]          Bit[14]            Bit[13]             Bit[12]           Bit[11]           Bit[10]          Bit[9]        Bit[8]
HVDIFFSEL3       HVDIFFSEL2         HVDIFFSEL1          HVDIFFSEL0        HVENFCM3          HVENFCM2         HVENFCM1      HVENFCM0
                 Select HV input for the differential amplifier: 0000b== no HV selected, 0001b==HV0, 0010b==HV1, 0100b==HV2,
HVDIFFSELx
                 1000b==HV3.
                 Enable precision current source for corresponding HV pin: 0000b== no HV selected, 0001b==HV0, 0010b==HV1, 0100b==HV2,
HVENFCMx
                 1000b==HV3.
HVINENx          Enable digital Schmitt-trigger input (=1), analog mode (=0) (e.g. for ADC measurement), reset value is 0
                Table 65 – HV Configuration Port 4 - digital or analog mode, RGB monitor measurement
  [1]        only valid for MLX81115
IO port: HV_ENWU
Address: 0x28D6                                               Access mode: Word – Read and Write
Bit[7]          Bit[6]            Bit[5]           Bit[4]             Bit[3]            Bit[2]             Bit[1]          Bit[0]
-               -                 HVENWU5[1]       HVENWU4[1]         HVENWU3           HVENWU2            HVENWU1         HVENWU0
Bit[15]         Bit[14]           Bit[13]          Bit[12]            Bit[11]           Bit[10]            Bit[9]          Bit[8]
-               -                 -                -                  -                 -                  HVDIFFSEL5[1]   HVDIFFSEL4[1]
HVENWUx         Enables the HV[x] as Wake Up Source
HVDIFFSEL
                Select HV input for the differential amplifier: 00b== no HV selected, 01b==HV4, 10b==HV5
[5:4]
                                         Table 66 – HV Configuration Port 5 - wake up
 [1]        only valid for MLX81115
IO port: HV_TMR
Address: 0x28D8                                               Access mode: Word – Read and Write
Bit[7]          Bit[6]          Bit[5]         Bit[4]         Bit[3]       Bit[2]                          Bit[1]          Bit[0]
                                          [1]          [1]
-               -               HVTMR4         HVTMR5         HVTMR3       HVTMR2                          HVTMR1          HVTMR0
Bit[15]         Bit[14]         Bit[13]        Bit[12]        Bit[11]      Bit[10]                         Bit[9]          Bit[8]
-               -               -              -
HVTMRx          =0 : route digital input to TMR0_A, =1 : route to TMR0_B input
IO port: HV_IN
Address: 0x28CC                                               Access mode: Word – Read
Bit[7]          Bit[6]         Bit[5]       Bit[4]         Bit[3]       Bit[2]      Bit[1]                                 Bit[0]
                                       [1]           [1]
-               -              HVDIN5       HVDIN4         HVDIN3       HVDIN2      HVDIN1                                 HVDIN0
Bit[15]         Bit[14]        Bit[13]      Bit[12]        Bit[11]      Bit[10]     Bit[9]                                 Bit[8]
-               -              -            -              -            -           -                                      -
HVDINx          Inputs from HV pins – debounced or undebounced – dependent on port HV_DEB
                                              Table 68 – HV Status Port
 [1]        only valid for MLX81115
By detecting that the system operation is wrong, it is possible to save dump the current state like switch
positions and important system information from the application and force the system by hardware control to
restart with refreshed and valid data, breaking endless loops in API caused by unexpected conditions.
The following description goes into detail, how the controller hardware can be used to reach such a high quality
API behavior. Additional information can be taken from block descriptions.
  A) A System hang-up
Sometimes it might happen that API runs into infinite loop, waiting for event which cannot arrive. Customer can
use a set of different watchdogs to cancel these endless loops by falling into reset state.
The MULAN3 processor offers a digital watchdog, which can be used to set different time frames for a known
subroutine to be finished, otherwise assuming that something goes wrong and such a routine should be
stopped because an expected event has not occurred.
If the controller does not receive a valid acknowledge signal of the independent analogue Watchdog – the
complete system will be reset, powered down – after then a system restart will be done with default inactive
loads.
The best way to come out of any self-locked states is to accept a complete and refreshed restart, discarding any
data and start from a well-known state again.
By taking the above features into the application software, it is possible to make the system safe against
malfunction caused by system disturbances. In such cases the silicon is able to return to normal operation after
problem has been removed.
If this is impossible – the system can protect itself by switching off disturbed functions and keeping non-
disturbed functions still alive if possible.
The protection of the application is the key feature of the controller.
21.1.6. Under-voltage VS
If the ECU battery supply voltage is missing or decreases under the specified value, the LIN pin behaves passive.
For the LIN pin the specification “LIN Physical Layer Spec 2.1 (Nov. 24, 2006)” is valid.
Supply Pin VS is protected via the reverse polarity diode and the supply capacitors. No damage will occur for
defined test pulses. A deviation of characteristics is allowed during pulse 1 and 2; but the module will recover to
the normal function after the pulse without any additional action. During test pulse 3a, 3b, 5 the module will
work within characteristic limits.
    A: All functions of the device are performed as designed during and after the disturbance occurs.
    B: All functions of the device are performed as designed during the disturbance occurs. One or more
       functions can violate the specified tolerances. All functions return automatically within their normal
       limits after the disturbance is removed.
    C: A function of a device does not perform as designed during the disturbance occurs but returns
       automatically to the normal operation after the disturbances is removed
   D: A function of a device does not perform as designed during the disturbance occurs and does not return
      automatically to the normal operation after the disturbances is removed. The device needs to be reset
      by a simple operation/action to return to the specified limits/function.
                                                        vpulse1
                                                                                                                                                            vpulse2
       90%
                                                                                                             10%
                        1 µs                                                                                 12V
                           2 ms                                                                              0V
                                          0.5...5s                                                                                          200 ms                                                        t
                V                                                     5 ns
                                                                                                                       V                                                             90%
              12V                                                     10%
                                                                                                                                                                                           vpulse3b
              0V
                                                                  t
                                             vpulse3a                                                                                                      vpulse3b
                                                                                  vpulse3a
12V 10%
                      100 µs                                                                                         0V
                        10 ms              90 ms                       90%
                                                                                                                               100 µs                                           t   5 ns
                                                                                                                                 10 ms                   90 ms                                 100 ns
90% Pulse 5
                                                                                                                                                                       Pulse 5 at
                                                                                                                           vpulse5                                      device
                                                                                                       40V
                                                                                                                              10%
                                                                                                      12V
                                                                                                                                                                                                      t
                                                                                                                                         tr = 0.1...10ms
td = 40...400ms
                               D12)
             VS
                                                                             VS
 Connector
                                          R12)                                                      R22)
                                                                                   Signal-
             LIN                                                 LIN   Actuators    line
                                                                                                                      Signal
                                                                                                                       -line
GND
                               1) optional implemented
                               2) mandatory implemented
[1]
  Tests were performed with Tantalum SMD: 10%, 7343, 35V
[2]
  During the test higher voltage than 50V can occur. It would be verified that neither the DUT nor the capacitor
will be damaged.
ESD capability of
                        HV5                   Acc. To IEC 61000-4-2 [1][2]               -10        +10    kV
HVx-pin versus GND
[1] Equivalent to discharging a 100pF capacitor through a 1.5kΩ resistor conform AEC-Q100-002.
[2] Tested by external test house (IBEE Zwickau, EMC test report no. 04-10-17).
must be accessible on the application PCB. A schematic with further information can be found in Figure 38.
It is not possible to use the debugging pins simultaneously in the application and for debugging. There must be
an option (e.g. jumper) to separate the debugging pins from the application circuitry
It is important to mention that for debugging/programming the controller must be supplied from the Mini E-
Mlx. The Mini E-Mlx itself has to be connected to a 12V power supply (Figure 38).
For debugging purpose there is a device version with higher pincount available. It gives access to the debug
interface and the HVx application pins at the same time.
Figure 38 – RGB-controller debug interface with the Melexis Mini E-Mlx emulator
It is important to mention that for debugging/programming the controller must be supplied from the Mini E-
Mlx. The Mini E-Mlx themselves has to be connected to a 12V power supply (Figure 38).
Melexis provides for both options a production tool called PTC-04. For further information please contact your
distributor or the Melexis sales team.
   IPC/JEDEC J-STD-020
    Moisture/Reflow Sensitivity Classification for Nonhermetic Solid State Surface Mount Devices
    (classification reflow profiles according to table 5-2)
   EIA/JEDEC JESD22-A113
    Preconditioning of Nonhermetic Surface Mount Devices Prior to Reliability Testing
    (reflow profiles according to table 2)
Wave Soldering SMD’s (Surface Mount Devices) and THD’s (Through Hole Devices)
   EN60749-20
    Resistance of plastic- encapsulated SMD’s to combined effect of moisture and soldering heat
   EIA/JEDEC JESD22-B106 and EN60749-15
    Resistance to soldering temperature for through-hole mounted devices
   EN60749-15
    Resistance to soldering temperature for through-hole mounted devices
Solderability SMD’s (Surface Mount Devices) and THD’s (Through Hole Devices)
For all soldering technologies deviating from above mentioned standard conditions (regarding peak
temperature, temperature gradient, temperature profile etc) additional classification and qualification tests
have to be agreed upon with Melexis.
The application of Wave Soldering for SMD’s is allowed only after consulting Melexis regarding assurance of
adhesive strength between device and board.
Melexis recommends reviewing on our web site the General Guidelines soldering recommendation
(http://www.melexis.com/Quality_soldering.aspx).
Melexis is contributing to global environmental conservation by promoting lead free solutions. For more
information on qualifications of RoHS compliant products (RoHS = European directive on the Restriction Of the
use of certain Hazardous Substances) please visit the quality page on our website:
http://www.melexis.com/quality.aspx
26. Disclaimer
The information furnished by Melexis herein (“Information”) is believed to be correct and accurate. Melexis disclaims (i) any and all liability in connection with or
arising out of the furnishing, performance or use of the technical data or use of the product(s) as described herein (“Product”) (ii) any and all liability, including
without limitation, special, consequential or incidental damages, and (iii) any and all warranties, express, statutory, implied, or by description, inc luding
warranties of fitness for particular purpose, non-infringement and merchantability. No obligation or liability shall arise or flow out of Melexis’ rendering of
technical or other services.
The Information is provided "as is” and Melexis reserves the right to change the Information at any time and without notice. Therefore, before placing orders
and/or prior to designing the Product into a system, users or any third party should obtain the latest version of the relevant information to verify that the
information being relied upon is current.
Users or any third party must further determine the suitability of the Product for its application, including the level of reliability required and determine whether
it is fit for a particular purpose.
The Information is proprietary and/or confidential information of Melexis and the use thereof or anything described by the In formation does not grant, explicitly
or implicitly, to any party any patent rights, licenses, or any other intellectual property rights.
This document as well as the Product(s) may be subject to export control regulations. Please be aware that export might require a prior authorization from
competent authorities.
The Product(s) are intended for use in normal commercial applications. Unless otherwise agreed upon in writing, the Product(s) are not designed, authorized or
warranted to be suitable in applications requiring extended temperature range and/or unusual environmental requirements. High reliability applications, such
as medical life-support or life-sustaining equipment are specifically not recommended by Melexis.
The Product(s) may not be used for the following applications subject to export control regulations: the development, production, processing, operation,
maintenance, storage, recognition or proliferation of 1) chemical, biological or nuclear weapons, or for the development, production, maintenance or storage of
missiles for such weapons: 2) civil firearms, including spare parts or ammunition for such arms; 3) defense related products, or other material for military use or
for law enforcement; 4) any applications that, alone or in combination with other goods, substances or organisms could cause serious harm to persons or goods
and that can be used as a means of violence in an armed conflict or any similar violent situation.
The Products sold by Melexis are subject to the terms and conditions as specified in the Terms of Sale, which can be found
at https://www.melexis.com/en/legal/terms-and-conditions.
This document supersedes and replaces all prior information regarding the Product(s) and/or previous versions of this document.
Melexis NV © - No part of this document may be reproduced without the prior written consent of Melexis. (2016)
For additional information, please contact our Direct Sales team and get help for your specific needs:
                                                                                                            Spec
 IC Revision                          Changes in Specification                          Date Stamp
                                                                                                           Version
MLX81115A         Initial revision                                                     August 2015           001
                  Chapter IO Register updated
                  Chapter IC Marking updated
                                                                                        May 2016             002
                  Ordering Code updated
                  Chapter CPU core MULAN3 updated
                  Order Information updated
                  Chapter Standard ports updated
                  Chapter Digital Watchdog – Window mode updated
                  Chapter Analog Watchdog updated
                  Chapter NVRAM organization updated
                  Chapter Absolute maximum rating
                  Chapter ESD and EMC updated
                  Chapter Pin out description
                  Chapter RGB control updated
                  Chapter Electrical parameter specification                            May 2017             003
                           Sleep Current updated
                           Parameter for RGB leakage compensation resistor
                           added,
                           Section LIN AA updated,
                           Parameter for Shunt differential amplifier updated
                  Chapter LIN Slave Node Position Detection updated
                  Chapter External Interrupts
                  Chapter End of Line Programming added
                  Chapter Shunt Current Measurement added
                  Typos corrected
                  Chapter External Circuitry on Signal Lines; recommended
                                                                                       January 2018          004
                  values updated
                  Order Information updated
                  Chapter Electrical parameter specification
                           Parameter for Shunt differential amplifier updated           April 2018           005
                  Order Information updated
                                                                                        September
                  Chapter ESD and EMC updated                                                                006
                                                                                           2018
                  Chapter External Circuitry on Supply Lines updated
                         Footnote “50V remark” added
                  Order Code information updated                                       March 2020            007
                  Package drawing for DFN12 updated
The ROM code Revision is coded in the last 2 characters of the Order Code. Further information can be found in
chapter 1 Features, Ordering Information.