Tuesday, August 29, 2017

BMW AHL2 / Variable Light Distribution

Adaptive Headlight II (AHL2)

AHL2 was introduced with the E60. It requires Xenon HID or LED headlights. AHL2 varies the light distribution of the low beam.

Engine start
In switch position "A" (light switch in the switch position for automatic driving lights control) and terminal 15 ON, both headlights execute a reference run. That means: Both swivel modules are moved down slightly and then to the desired position (visible when the vehicle is parked in front of a wall: The light cone moves down and then back up). The desired position depends on the load status of the vehicle. When the engine is started, the headlight driver module initially controls the city light distribution.

City light distribution (Town light)
The city light distribution enables a broader illumination of the left roadway at low speeds. The left headlight is moved approximately 12° to the left and approximately 0.7° downwards. The city light distribution is activated from engine start to a driving speed of approximately 50 km/h.

Pertinent Parameter:
C_AFS_C_V_LO defaultwert = 28 (40 km/h, 25 mph)

Country road light distribution (Basic light)
The country road light distribution is the same as the standard low beam headlights. At a driving speed above approximately 50 km/h, the city light distribution is changed to the country road light distribution. Below a driving speed of approximately 50 km/h, the footwell module (FRM) changes the light distribution back to city. The country road light distribution represents the basic setting for the headlights.

Motorway light distribution
The motorway light distribution increases the range of the driving light. The left headlight is moved approximately 3.5° to the left and approximately 0.25° downwards. The right headlight is moved approximately 0.2° upward. If the vehicle speed exceeds 110 km/h for longer than 30 seconds, or if 140 km/h is exceeded, the footwell module switches on the motorway light distribution. If the vehicle speed drops below 110 km/h, the headlights are gradually reset, depending on the driving speed. This takes places in stages (110 km/h 100 km/h 90 km/h 80 km/h). The country road light distribution is activated again at 80 km/h and below.

Pertinent Parameters:
C_AFS_C_V_HI  defaultwert = 8C (140 km/h, 87 mph)
C_AFS_E_V_LO  defaultwert = 6E (110 km/h, 68 mph) (see timer below)
C_AFS_E1_V_LO defaultwert = 64 (100 km/h, 62 mph)
C_AFS_E2_V_LO defaultwert = 5A  (90 km/h, 56 mph)
C_AFS_E3_V_LO defaultwert = 50  (80 km/h, 50 mph)

C_AFS_E_T_MIN defaultwert = 1E (30s)
Comment = Counter Minimum for LightDistribution E

Fog light distribution
The fog light distribution is activated when the fog lights are switched on. The fog light distribution can be combined with the city light distribution and the country road light distribution. The left headlight is moved approximately 8° to the left and approximately 0.7° downwards. If the high beam headlights are switched on while the fog light distribution is active, the headlight moves to the basic setting, i.e. to the country road light distribution.

Pertinent Parameter:
C_AFS_EX_FOG_ENA defaultwert = 01
Comment = Switch to enable or disable motorway light distribution while fog lights are turned on (1 means motorway light distribution enabled).

(Source: http://f80.bimmerpost.com/forums/showpost.php?p=19916060&postcount=31)

In the US, vehicle option 8S4 Variable Light Distribution Decoding actually disables (de-code) VLD. Do not remove 8S4 as it may interfere with software update performed by a BMW Center.

Instead, VLD can be simply enabled via coding with NCS Expert or E-Sys (depending on your vehicle chassis.

For my E60, I use NCS Expert and NCS Dummy to enable VLD:
AHL2_ENABLE = aktiv

For the F30, I use E-Sys to enable VLD:
 3073 LaMaster 1, FC
    C_AFS_ENA - F020_enable

Saturday, August 26, 2017

Upgrade the Navigation Map Data for NBT Head Units

BMW NBT head units use the map data type of "Next". This can be confirmed by viewing current map type in the CIC screen. Select Navigation, Options, and scroll to the end of the list and select "Navigation system version".

Acquire the E-Sys software and ENET cable for connection to the OBD2 port on the vehicle.

Use the E-Sys software to download the DE file from the vehicle. Save the file, eg DE.fsc.

Acquire the latest map data, eg Road Map NORTH AMERICA Next 2017-2. Determine the AppID and UpgradeID of the map data. Locate the file named Info_Map.imp in the upgrade media. Identify the AppID and UpgradeID.

Generate the FSC code.

Insert the USB media in the vehicle USB port and follow the onscreen upgrade prompt.

Additional information for those interested in coding F-Series vehicles:

Thursday, May 18, 2017

Download the 1B File From a BMW E-Series Vehicle Equipped with the CIC

CIC is the Car Information Computer used in certain BMW automobiles. To help identify the CIC, please see information about BMW iDrive.

If your BMW E-series vehicle is equipped with a CIC, you may be able to retrieve the 1B file using an OBD2 ENET adapter. I was able to connect to the CIC on my 2010 BMW E60 using the adapter.

I used an Ethernet switch because I wanted to observe the link and activity status  A crossover Ethernet cable can probably be used in place of the switch, but I have not tried it. For the computer network port, I set it to use an autoconfiguration IPv4 address ( /16 or netmask The ODB2 port autoconfiguration IPv4 address is (ignition must be on).

ftp user/pass pairs to try:
  • files/remote
  • root/Hm83stN
  • root/cic0803
The file to download from the CIC is /HBpersistence/normal/generalPersistencyData_DiagnosticSWTController

I used the HxD file editor to extract and save the 1B file as follows:
  • Open the downloaded file with HxD
  • Search for the Hex-values 01 01 00 1B
  • The value should be located at offset 33A
  • Move the cursor to offset 33A
  • Highlight to the beginning of the file and delete. Acknowledge file-size warning and proceed.
  • Move cursor to row 00000130 and to offset 13F. Highlight to end of file and delete. Acknowledge file-size warning and proceed.
  • Save file using the name a.hex. It should be 319 bytes. This is the 1B file for the vehicle.

Additional information about identifying map code and year code. Use HxD to open the file Info_Map.imp in the map update media. It is located under the folder pkgdb\INFO_MAP_xxxxxxxxxxxxxxx

Tuesday, June 7, 2016

Update the CIC navigation data

BMW navigation data update can be performed gradually over an extended period of time during normal vehicle operation, with a set of USB flash drives containing the complete data, and will resume updating after normal vehicle power off. The method described in this blog post is for those who prefer to update the navigation data at one go, which completes in about 40 minutes.

  • Intelligent car battery charger capable of 10A or more.
  • New navigation data on USB flash drive(s).
  • FSC activation code for navigation data update. It is a one-time code specific to the vehicle VIN, navigation system type, and map region / version. Lifetime codes are not authorized by BMW and may have undesirable effect in the future. Use lifetime FSC activation codes at your own risk.
Here is the file structure of a USB flash drive with navigation data, if one is using a single USB flash drive instead of multiple USB flash drives.

Using a computer, one would move pkgdb and config,nfo from the first folder to the root folder and insert the USB flash drive into the vehicle USB port. When prompted, one would remove the USB flash drive from the vehicle and use a computer to move the pkgdb and config.nfo back to the first folder, and move the two files from the second folder to the root folder. Repeat until all data has been copied to the vehicle.

Before starting the navigation data update, connect the car battery charger to the vehicle at 10A or more (eg 12A, 15A). Let it charge for about 10 minutes in case the vehicle battery is too weak or old to maintain 12V without the engine running. Be forewarned that an old or weak battery is detrimental to your vehicle alternator and electronics. You should perform electronic service work only with a vehicle battery that is capable of providing at least 12V.
Car battery charger connected
To begin the update, engage the parking brake for safety, turn the ignition on, but do not start the engine (keep foot off brake or clutch pedal), To conserve vehicle battery energy during navigation data update, turn off DRL, interior light, audio, climate control, and any other accessories.

Insert the USB flash drive into the USB port for data update. It is the USB port in the glove compartment, or in the center console if there isn't one in the glove compartment. Once the USB flash drive is in the correct port, the vehicle will detect that it contains newer navigation data.
USB flash drive with newer navigation data detected

Have the FSC activation code handy. The FSC activation code is alphanumeric, but will not have the numbers 1 (one) or 0 (zero) in order to avoid confusion. Start the update and enter the FSC activation code.
Enter the FSC activation code

Navigation data update in progress
Replace USB flash drive as prompted or follow your navigation data seller's instructions for moving files from the USB flash drive folders to the root directory. Continue to update the navigation data.

It takes about 40 minutes for all navigation data to be copied from the USB flash drive(s) to the CIC. Allow the system to restart. Wait about 5 minutes before verifying the new navigation system version information. To verify, go to Navigation, Map, Option, Navigation system version.
Navigation system version
Remember to re-enable DRL if it was on previously. Turn off ignition. If you wish, you may leave the car battery charger running for an additional 10 minutes to make sure that the battery has enough power to start the engine. Navigation data update is complete.

Thursday, April 14, 2016

MHD Flasher N54

MHD Flasher N54 is the first Android handheld application to bring ECU tuning and monitoring to the BMW N54 engine. The MHD Flasher reveals the immense margin of power BMW left on the table with the N54 while still retaining the sophistication of the original engine management program.

Cable required is a K+DCAN USB cable. The USB port of the cable requires an OTG adapter to connect to the micro USB port on the Android device. Bimmer Software sells tested cables.

It will read your stock ECU and "save" it. If the stock ECU is recognized by MHD, saving it will take only a couple of seconds. Otherwise, it may take an hour or more to read the stock ECU and save it on the Android device. Restoring the ECU would take a while, as an ECU write has to be performed, either from the file on the Android device or from the MHD built-in ECU library. After the first write of an MHD built-in map, switching maps (eg from 93 oct to 91 oct) only takes a couple of minutes.

The MHD Flasher built-in maps are provided by Wedge Performance, already known for their BMW N54 engine tuning. The first write of a MHD built-in map took 39 minutes. An intelligent car battery was used at 10-amp, to prevent the car battery from running low. Turn off power to any vehicle features to conserve vehicle battery, eg audio system, daytime running light, climate control, interior light, etc. When the Android device is writing the ECU for the first, time it will take a while. Turn on the device Airplane Mode after it starts writing the ECU in order to conserve device power. While the vehicle ECU is being written, do not operate any features or doors on the vehicle!

Logging options:

  • Not needed: Boost PSI, STFT 1 and 2.
  • Needed: Boost setpoint, timing correct cyl 1-6, LTFT 1 and 2.

Estimated engine output:
  • Stage 1 pack. 2 maps included (Stage 1, Stage 1 + FMIC). Each with 4 octane variants (acn 91, 91, 93, 95), 340-385 hp.
  • Stage 2 pack. 2 maps included (Stage 2, Stage 2 + FMIC). Each with 4 octane variants (acn 91, 91, 93, 95), 370-430 hp.
  • E40 map. 40% of ethanol, 440hp.
Those are conservative, crank numbers. For instance the e40 map made 400whp on a stock car and would make more on a full bolt-on car.

Internet sources:

Saturday, September 26, 2015

BMW Tools on Windows 10

After upgrading from Windows 7 32-bit to Windows 10 32-bit. I reinstalled BMW Tools and documented the process for my own reference. The OBD2 cable interface is from One-Stop-Electronics. Their cable works for E6x and E9x vehicles that I have worked with. There are cheaper or incompatible cables in the marketplace.
  • Install USB cable driver (eg FTDI virtual COM port driver)
  • Step_1_Install_BMW_Tools.exe
  • Step_2_Install_INPA.exe
  • Step_3_UPDATE.exe
  • English_NCSExpert_4.0.1_with_v54.3_Coding_Files.rar
    • robocopy.exe /s /xo *.* [sourcedir] [targetdir]
  • Download NCS Dummy and the related NCS Dummy profile from a post on BimmerForums.
  • Review:
    • C:\EDIABAS\Bin\obd.ini
    • C:\EDIABAS\Hardware\OBD\OBDSetup.exe
    • C:\NCSEXPER\CFGDAT\NCSEXPER.TXT (is in English at and least 8,145 bytes)
  • Verify / create Window shortcuts for:
    • INPA - C:\EC-APPS\INPA\BIN\INPALOAD.exe (Compatibility: Windows 7)
    • EDIABAS Tool32 - C:\EDIABAS\Bin\TOOL32.EXE (Compatibility: Windows XP SP3)
    • NCS-Expert - C:\NCSEXPER\BIN\NCSEXPER.EXE (Compatibility: Windows 7)
    • NCS-Dummy - C:\NCSDUMMY\NcsDummy.exe
    • They do not require "Run as administrator"; compatibility mode is as indicated
  • Connection process:
    • Start EDIABAS
    • Connect USB cable to OBD-II port
    • Turn engine on, but do not start
    • Test EDIABAS (Job / Ecu Info)
    • Exit EDIABAS
    • Start INPA
    • INPA should indicate battery and ignition status as ON
    • Exit INPA
    • Start NCS-Expert
Happy coding!

BMW Lead The Way

Free Route Planning Software For the CIC and NBT Onboard Navigation System

BMW Lead The Way software runs on Windows (tested in Windows 10). It has the ability to display traffic condition, weather (may be deprecated by Google), gas stations, parking, airports, BMW service, route preview, and to include/avoid highways and toll road. Software works with BMW NBT and CIC navigation systems, but CIC systems require coding to enable route import (NAVI_TRIP_IMPORT).

The Software uses public Google Maps API and is limited to 10 waypoints, including the start and destination. Occasionally, the software "Add itinerary" function stops working. Use "Reload Map" to refresh the map display.

The software author TokenMaster has posted more information about the BMW Lead The Way software at a BimmerFest forum post.