<?xml version="1.0" encoding="ISO-8859-1"?>
<?xml-stylesheet type="text/xsl" href="../XSLT/decoder.xsl"?>
<!-- Copyright (C) JMRI 2004 All rights reserved -->
<!-- $Id: Lenz_LE1000.xml 17977 2011-07-18 17:23:46Z zoo $ -->
<!--                                                                        -->
<!-- JMRI is free software; you can redistribute it and/or modify it under  -->
<!-- the terms of version 2 of the GNU General Public License as published  -->
<!-- by the Free Software Foundation. See the "COPYING" file for a copy     -->
<!-- of this license.                                                       -->
<!--                                                                        -->
<!-- JMRI is distributed in the hope that it will be useful, but WITHOUT    -->
<!-- ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or  -->
<!-- FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License  -->
<!-- for more details.                                                      -->
<decoder-config xmlns:xi="http://www.w3.org/2001/XInclude" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://jmri.org/xml/schema/decoder.xsd">
  <version author="Paul Bednder (paul.bender@acm.org)" version="1" lastUpdated="20040326"/>
<!-- Version 2 - added factory reset menu items (Paul Bender) -->
  <decoder>
    <family name="Lenz Value Line decoders" mfg="Lenz" lowVersionID="10" highVersionID="10">
      <model model="LE1000A" numOuts="2" numFns="0" lowVersionID="10" highVersionID="10" nmraWarrant="yes" nmraWarrantStart="2004" nmraWarrantEnd="200901">
        <size length="0.9" width=".63" height=".13" units="inches"/>
      </model>
    </family>
    <programming direct="yes" paged="yes" register="yes" ops="yes"/>
    <variables>
      <variable label="Primary Address" CV="1" comment="Short address" item="Short Address" default="03">
        <shortAddressVal/>
        <label>Primary Address</label>
        <comment>Short address</comment>
      </variable>
      <variable label="Start Volts" CV="2" item="Vstart" default="16" comment="Range 0-31">
        <decVal/>
        <label>Start Volts</label>
        <comment>Range 0-31</comment>
      </variable>
      <variable label="Accel" CV="3" default="1" comment="Range 0-31">
        <decVal max="31"/>
        <label>Accel</label>
        <comment>Range 0-31</comment>
      </variable>
      <variable label="Decel" CV="4" default="1" comment="Range 0-31">
        <decVal max="31"/>
        <label>Decel</label>
        <comment>Range 0-31</comment>
      </variable>
<!-- deleted max and mid voltage-->
      <variable label="Version ID" CV="7" readOnly="yes" item="Decoder Version">
        <decVal/>
        <label>Version ID</label>
      </variable>
      <variable label="Manufacturer ID" CV="8" readOnly="yes" item="Manufacturer" default="99">
        <decVal/>
        <label>Manufacturer ID</label>
      </variable>
      <variable label="Manufacturer ID - Reset" CV="8" default="99" item="Reset" comment="Writing a value of 33 will reset decoder to factory defaults">
        <decVal/>
        <label>Manufacturer ID - Reset</label>
        <comment>Writing a value of 33 will reset decoder to factory defaults</comment>
      </variable>
<!-- Deleted all CV 13 references-->
      <variable label="Long Address" CV="17" item="Extended Address" comment="4 digit address (Range 0001-9999)">
        <longAddressVal/>
        <label>Long Address</label>
        <comment>4 digit address (Range 0001-9999)</comment>
      </variable>
      <variable label="Consist Address" CV="19" mask="XVVVVVVV" item="Consist Address">
        <decVal/>
        <label>Consist Address</label>
      </variable>
      <variable label="Consist Direction" CV="19" mask="VXXXXXXX">
        <enumVal>
          <enumChoice choice="Normal">
            <choice>Normal</choice>
          </enumChoice>
          <enumChoice choice="Reversed">
            <choice>Reversed</choice>
          </enumChoice>
        </enumVal>
        <label>Consist Direction</label>
      </variable>
      <variable label="Normal direction of motion" CV="29" mask="XXXXXXXV" item="Locomotive Direction">
        <enumVal>
          <enumChoice choice="Forward">
            <choice>Forward</choice>
          </enumChoice>
          <enumChoice choice="Reverse">
            <choice>Reverse</choice>
          </enumChoice>
        </enumVal>
        <label>Normal direction of motion</label>
      </variable>
      <variable label="Speed Steps" CV="29" mask="XXXXXXVX" item="Speed Step Mode" default="1">
        <enumVal>
          <enumChoice choice="14">
            <choice>14</choice>
          </enumChoice>
          <enumChoice choice="28/128 (recommended)">
            <choice>28/128 (recommended)</choice>
          </enumChoice>
        </enumVal>
        <label>Speed Steps</label>
      </variable>
      <variable label="Analog conversion mode" CV="29" mask="XXXXXVXX" default="1" item="Analog (DC) Operation">
        <enumVal>
          <enumChoice choice="Off">
            <choice>Off</choice>
          </enumChoice>
          <enumChoice choice="On">
            <choice>On</choice>
          </enumChoice>
        </enumVal>
        <label>Analog conversion mode</label>
      </variable>
      <variable label="Addressing Mode" CV="29" mask="XXVXXXXX" item="Address Format">
        <enumVal>
          <enumChoice choice="2 digit addressing">
            <choice>2 digit addressing</choice>
          </enumChoice>
          <enumChoice choice="4 digit addressing">
            <choice>4 digit addressing</choice>
          </enumChoice>
        </enumVal>
        <label>Addressing Mode</label>
      </variable>
      <variable label="Brake Momentum on DC" CV="50" item="DC Brake Momentum" mask="XXXXXVXX" comment="Governs how loco acts in DC track block">
        <enumVal>
          <enumChoice choice="Loco runs under DC analog voltage control">
            <choice>Loco runs under DC analog voltage control</choice>
          </enumChoice>
          <enumChoice choice="Loco brakes to a stop using momentum set in CV4">
            <choice>Loco brakes to a stop using momentum set in CV4</choice>
          </enumChoice>
        </enumVal>
        <label>Brake Momentum on DC</label>
        <comment>Governs how loco acts in DC track block</comment>
      </variable>
      <variable label="Headlight Dimmed By" CV="51" mask="VVVVVVVV" item="Function F0F options" comment="Controls which function dims headlight (CV 52 controls amount)">
        <enumVal>
          <enumChoice choice="Always Dim" value="00000000">
            <choice>Always Dim</choice>
          </enumChoice>
          <enumChoice choice="F1" value="1">
            <choice>F1</choice>
          </enumChoice>
          <enumChoice choice="F2" value="2">
            <choice>F2</choice>
          </enumChoice>
          <enumChoice choice="F3" value="4">
            <choice>F3</choice>
          </enumChoice>
          <enumChoice choice="F4" value="8">
            <choice>F4</choice>
          </enumChoice>
          <enumChoice choice="F5" value="16">
            <choice>F5</choice>
          </enumChoice>
          <enumChoice choice="F6" value="32">
            <choice>F6</choice>
          </enumChoice>
          <enumChoice choice="F7" value="64">
            <choice>F7</choice>
          </enumChoice>
          <enumChoice choice="F8" value="128">
            <choice>F8</choice>
          </enumChoice>
        </enumVal>
        <label>Headlight Dimmed By</label>
        <comment>Controls which function dims headlight (CV 52 controls amount)</comment>
      </variable>
      <variable label="Headlight Dimming intensity" CV="52" default="255" comment="Controls how much headlights dim (0-dark to 255-max bright)" item="Function F0F behavior">
        <decVal min="0" max="255"/>
        <label>Headlight Dimming intensity</label>
        <comment>Controls how much headlights dim (0-dark to 255-max bright)</comment>
      </variable>
      <variable label="User Private ID #1" CV="105" item="User Id #1">
        <decVal/>
        <label>User Private ID #1</label>
      </variable>
      <variable label="User Private ID #2" CV="106" item="User Id #2">
        <decVal/>
        <label>User Private ID #2</label>
      </variable>
<!-- Define the fixed Function-Output mapping -->
      <constant label="FL(f) controls output 1" minOut="1" default="1"/>
      <constant label="FL(r) controls output 2" minOut="2" default="1"/>
    </variables>
    <resets>
      <factReset label="Reset All CVs" CV="8" default="33"/>
    </resets>
  </decoder>
  <pane name="Lenz">
    <column>
      <display item="Function F0F behavior"/>
      <display item="Function F0F options"/>
    </column>
    <name>Lenz</name>
  </pane>
</decoder-config>

