tautcony / ISTA-Patcher

An IL patcher
GNU General Public License v3.0
37 stars 14 forks source link

ISTA Execute measures plan requests activation. #7

Closed roadray closed 1 year ago

roadray commented 1 year ago

HI. ISTA Execute measures plan is not active. Is it possible to modify the patch program so that it becomes active? I regedit license, but it doesn't work. [HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\BMWgroup\ISPI\Rheingold] "License"="BMW Group MOSSR2your_email_here@bmw.de2099-05-01T00:00:00*wePC9Q9xawMjVPA2fkMVvioHNtA=dGhpcyBpcyBrZXkKoffline" Please check. https://mega.nz/file/GkQxRKia#GhFbdcIxkyA_KN9ao3hQqL61AgY8KK7G6jWYid22Uuc Thank you. ista

tautcony commented 1 year ago
  1. Regedit license is provieded in here, the format you've provided may not a valid one.

  2. Folder Logs under ISTA is required, I need logs from startup through execution to the measures plan in order to troubleshoot.

roadray commented 1 year ago
  1. Regedit license is provieded in here, the format you've provided may not a valid one.
  2. Folder Logs under ISTA is required, I need logs from startup through execution to the measures plan in order to troubleshoot.

I am sending you the link below. https://mega.nz/folder/L9AknbJR#NvtGVx2sNaXkmUBiUKUIuQ

roadray commented 1 year ago
  1. Regedit license is provieded in here, the format you've provided may not a valid one.
  2. Folder Logs under ISTA is required, I need logs from startup through execution to the measures plan in order to troubleshoot.

I am sending you the link below. https://mega.nz/folder/L9AknbJR#NvtGVx2sNaXkmUBiUKUIuQ

Please check.

tautcony commented 1 year ago

Review the logs and find a potentially relevant problem point

2023-04-09 21:06:08.158 INFO [T] ISTA: [1] MultisessionLogic.NavigationServiceTabSelectionChanged - The calculation of Measurement Plan is deactivated, either Programming is disabled or the LightMode is active

The corresponding contexts are as follows:

bool flag = ConfigSettings.OperationalMode == OperationalMode.ISTA && !ConfigSettings.IsProgrammingEnabled();
if (this.IsRelatedToProgramming(current) && ConfigSettings.getConfigStringAsBoolean("BMW.Rheingold.Programming.PsdzDoNativePlanCalcalation", true) && !flag)
{
    this.ContinueProgrammingSession();
    return;
}
Log.Info(Log.CurrentMethod(), "The calculation of Measurement Plan is deactivated, either Programming is disabled or the LightMode is active", Array.Empty<object>());

So, you should check that the configuration BMW.Rheingold.Programming.Enabled should be true and that BMW.Rheingold.Programming.PsdzDoNativePlanCalcalation is not present or be true.

roadray commented 1 year ago

Review the logs and find a potentially relevant problem point

2023-04-09 21:06:08.158 INFO [T] ISTA: [1] MultisessionLogic.NavigationServiceTabSelectionChanged - The calculation of Measurement Plan is deactivated, either Programming is disabled or the LightMode is active

The corresponding contexts are as follows:

bool flag = ConfigSettings.OperationalMode == OperationalMode.ISTA && !ConfigSettings.IsProgrammingEnabled();
if (this.IsRelatedToProgramming(current) && ConfigSettings.getConfigStringAsBoolean("BMW.Rheingold.Programming.PsdzDoNativePlanCalcalation", true) && !flag)
{
  this.ContinueProgrammingSession();
  return;
}
Log.Info(Log.CurrentMethod(), "The calculation of Measurement Plan is deactivated, either Programming is disabled or the LightMode is active", Array.Empty<object>());

So, you should check that the configuration BMW.Rheingold.Programming.Enabled should be true and that BMW.Rheingold.Programming.PsdzDoNativePlanCalcalation is not present or be true.

Is it possible to modify the patch program? If possible, please revise the program.

tautcony commented 1 year ago

I just explained the details of the problem, which does not imply that it has anything to do with the program by now.

These configuration is on YOUR computer, please check registry by yourself.

roadray commented 1 year ago

BMW.Rheingold.Programming.PsdzDoNativePlanCalcalation

Yes, I checked with the registry and found that there was no BMW.Rheingold.Programming.PsdzDoNativePlanCalibration, so I added it. The test will be done in the evening. Thank you.

roadray commented 1 year ago

I tested it, but it didn't run. I don't know what the problem is.

tautcony commented 1 year ago

The following are other logs found that may be related, but not directly to the program itself.

2023-04-09 21:17:47.504 INFO [T] ISTA: [54] CloseOperationMeasurement - Executing.
2023-04-09 21:17:47.504 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Closing operation measurement.
2023-04-09 21:17:47.505 INFO [T] ISTA: [43] IcomTraceCollector.IcomTraceCollector() - The IcomTraceCollector is not active by ipAddress: '192.168.1.107', vin17: 'XXXXXXXXXXXXXXXXX', devType: 'ENET', Enabled: 'True'
2023-04-09 21:17:47.506 INFO [T] ISTA: [54] StartMeasurementService.DisconnectImib - Disconnecting the Imib...
2023-04-09 21:17:47.510 WARNING [T] ISTA: [54] StartMeasurementService.DisconnectImib - device structure was null or no IMIB
2023-04-09 21:17:47.513 INFO [T] ISTA: [54] StartMeasurementService.SetConnectionState - Setting connection state to reserved: False, and blocked: False
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Operation measurement closed.
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] CloseOperationMeasurement - Executed.

This one corresponds to a code requirement to use VCIDeviceType.ICOM for OBD connection instead of VCIDeviceType.ENET. I hav never executed a measure plan in ISTA, so I don't know the actual requirements. Based on the information provided, it is difficult to determine the exact issue without more associated error messages.

If you are familiar with the prerequisites for executing the measure plan in ISTA and can verify which prerequisite is not being met, please let me know so we can further investigate the issue.

roadray commented 1 year ago

The following are other logs found that may be related, but not directly to the program itself.

2023-04-09 21:17:47.504 INFO [T] ISTA: [54] CloseOperationMeasurement - Executing.
2023-04-09 21:17:47.504 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Closing operation measurement.
2023-04-09 21:17:47.505 INFO [T] ISTA: [43] IcomTraceCollector.IcomTraceCollector() - The IcomTraceCollector is not active by ipAddress: '192.168.1.107', vin17: 'XXXXXXXXXXXXXXXXX', devType: 'ENET', Enabled: 'True'
2023-04-09 21:17:47.506 INFO [T] ISTA: [54] StartMeasurementService.DisconnectImib - Disconnecting the Imib...
2023-04-09 21:17:47.510 WARNING [T] ISTA: [54] StartMeasurementService.DisconnectImib - device structure was null or no IMIB
2023-04-09 21:17:47.513 INFO [T] ISTA: [54] StartMeasurementService.SetConnectionState - Setting connection state to reserved: False, and blocked: False
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Operation measurement closed.
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] CloseOperationMeasurement - Executed.

This one corresponds to a code requirement to use VCIDeviceType.ICOM for OBD connection instead of VCIDeviceType.ENET. I hav never executed a measure plan in ISTA, so I don't know the actual requirements. Based on the information provided, it is difficult to determine the exact issue without more associated error messages.

If you are familiar with the prerequisites for executing the measure plan in ISTA and can verify which prerequisite is not being met, please let me know so we can further investigate the issue.

I checked that it was executed well in the 4.39.20 version. It did not run in 4.39.20 version or later. When I looked at the data compared to 4.40.40, I found that there were new files. I'm sending you a link. https://mega.nz/folder/LtRiRaRZ#WNKkvn-mWifW8qtEzdznmg image

tautcony commented 1 year ago

Yes, I also found the existence of new files in your earlier posting of 4.40 compared to previous version.

In new files RheingoldExternalToolLicense is related to a compile time and current time based check, which is theoretically not related to this feature, such a failed check would cause whole program fail to start.

You may try the latest build from actions to eliminate this doubt.


If there're some other checks were added in 4.40 that we don't know about now, it would be very difficult and time-consuming to find them without related error log.

roadray commented 1 year ago

Yes, I also found the existence of new files in your earlier posting of 4.40 compared to previous version.

In new files RheingoldExternalToolLicense is related to a compile time and current time based check, which is theoretically not related to this feature, such a failed check would cause whole program fail to start.

You may try the latest build from actions to eliminate this doubt.

If there're some other checks were added in 4.40 that we don't know about now, it would be very difficult and time-consuming to find them without related error log.

I tried it with a new patch last night. Implementation results are the same as before. Here's a new log link. https://mega.nz/folder/btYjVQ5I#L6_tW5aJt-KMRff6vZPrFw I hope so.

tautcony commented 1 year ago

Can't find any related error messages in the logs either, and I haven't used the measures plan before. However, based on the current logs, no new authorization-related errors have been found, so I suspect that this patch is not very relevant to the unavailability of this feature

roadray commented 1 year ago

Can't find any related error messages in the logs either, and I haven't used the measures plan before. However, based on the current logs, no new authorization-related errors have been found, so I suspect that this patch is not very relevant to the unavailability of this feature

I knew it had to be set to a separate setting. It hasn't been solved yet, but I hope to find it.

tautcony commented 1 year ago

I compared the 4.40 configuration file ISTAGUI.exe.config with the 4.39 on my side. It may be that the difference in configuration causes the usability of the feature to change, and you may be able to try to go ahead and add tweaks to the configuration to test the feature.

eg:

  <appSettings>
    <!-- ############################################################## -->
    <!-- ############## custom settings for Standalone ################ -->
    <!-- ############################################################## -->
    <!-- disable CheckSystemRequirements -->
    <add key="BMW.Rheingold.ISTAGUI.disableCheckSystemRequirements" value="false" />
    <!-- enable Programming via ENET, don't use it with ICOM Nano! -->
    <add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="false" />
    <!-- ############################################################## -->
    <!-- ########## end of custom settings for Standalone ############# -->
    <!-- ############################################################## -->
    <add key="BMW.Rheingold.Developer.guidebug" value="true" />
    <add key="BMW.Rheingold.ISTAGUI.App.MultipleInstancesAllowed" value="false" />
roadray commented 1 year ago

I compared the 4.40 configuration file ISTAGUI.exe.config with the 4.39 on my side. It may be that the difference in configuration causes the usability of the feature to change, and you may be able to try to go ahead and add tweaks to the configuration to test the feature.

eg:

  <appSettings>
  <!-- ############################################################## -->
  <!-- ############## custom settings for Standalone ################ -->
  <!-- ############################################################## -->
    <!-- disable CheckSystemRequirements -->
  <add key="BMW.Rheingold.ISTAGUI.disableCheckSystemRequirements" value="false" />
    <!-- enable Programming via ENET, don't use it with ICOM Nano! -->
  <add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="false" />
  <!-- ############################################################## -->
  <!-- ########## end of custom settings for Standalone ############# -->
  <!-- ############################################################## -->
  <add key="BMW.Rheingold.Developer.guidebug" value="true" />
  <add key="BMW.Rheingold.ISTAGUI.App.MultipleInstancesAllowed" value="false" />

I used the basic ENET setting as below. add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="true" But it is not implemented now. I'm thinking of adding it directly to the resist and giving it a try. I hope it's settled.

roadray commented 1 year ago

I compared the 4.40 configuration file ISTAGUI.exe.config with the 4.39 on my side. It may be that the difference in configuration causes the usability of the feature to change, and you may be able to try to go ahead and add tweaks to the configuration to test the feature. eg:

  <appSettings>
    <!-- ############################################################## -->
    <!-- ############## custom settings for Standalone ################ -->
    <!-- ############################################################## -->
    <!-- disable CheckSystemRequirements -->
    <add key="BMW.Rheingold.ISTAGUI.disableCheckSystemRequirements" value="false" />
    <!-- enable Programming via ENET, don't use it with ICOM Nano! -->
    <add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="false" />
    <!-- ############################################################## -->
    <!-- ########## end of custom settings for Standalone ############# -->
    <!-- ############################################################## -->
    <add key="BMW.Rheingold.Developer.guidebug" value="true" />
    <add key="BMW.Rheingold.ISTAGUI.App.MultipleInstancesAllowed" value="false" />

I used the basic ENET setting as below. add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="true" But it is not implemented now. I'm thinking of adding it directly to the resist and giving it a try. I hope it's settled.

As expected, it's not working I'll have to look for more.

rocdeng commented 1 year ago

I compared the 4.40 configuration file ISTAGUI.exe.config with the 4.39 on my side. It may be that the difference in configuration causes the usability of the feature to change, and you may be able to try to go ahead and add tweaks to the configuration to test the feature.

eg:

  <appSettings>
  <!-- ############################################################## -->
  <!-- ############## custom settings for Standalone ################ -->
  <!-- ############################################################## -->
    <!-- disable CheckSystemRequirements -->
  <add key="BMW.Rheingold.ISTAGUI.disableCheckSystemRequirements" value="false" />
    <!-- enable Programming via ENET, don't use it with ICOM Nano! -->
  <add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="false" />
  <!-- ############################################################## -->
  <!-- ########## end of custom settings for Standalone ############# -->
  <!-- ############################################################## -->
  <add key="BMW.Rheingold.Developer.guidebug" value="true" />
  <add key="BMW.Rheingold.ISTAGUI.App.MultipleInstancesAllowed" value="false" />

Programming with ENET cable is only available in Sedoy's standalone package, he modified the app to enable this feature, otherwise only iCOM could be used. https://cartechnology.co.uk/showthread.php?tid=77749&pid=611760#pid611760

If you have time, maybe these logs are the clue to find out where to patch the app for using ENET cable.

2023-04-09 21:17:47.504 INFO [T] ISTA: [54] CloseOperationMeasurement - Executing.
2023-04-09 21:17:47.504 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Closing operation measurement.
2023-04-09 21:17:47.505 INFO [T] ISTA: [43] IcomTraceCollector.IcomTraceCollector() - The IcomTraceCollector is not active by ipAddress: '192.168.1.107', vin17: 'XXXXXXXXXXXXXXXXX', devType: 'ENET', Enabled: 'True'
2023-04-09 21:17:47.506 INFO [T] ISTA: [54] StartMeasurementService.DisconnectImib - Disconnecting the Imib...
2023-04-09 21:17:47.510 WARNING [T] ISTA: [54] StartMeasurementService.DisconnectImib - device structure was null or no IMIB
2023-04-09 21:17:47.513 INFO [T] ISTA: [54] StartMeasurementService.SetConnectionState - Setting connection state to reserved: False, and blocked: False
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Operation measurement closed.
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] CloseOperationMeasurement - Executed.
tautcony commented 1 year ago

I compared the 4.40 configuration file ISTAGUI.exe.config with the 4.39 on my side. It may be that the difference in configuration causes the usability of the feature to change, and you may be able to try to go ahead and add tweaks to the configuration to test the feature. eg:

  <appSettings>
    <!-- ############################################################## -->
    <!-- ############## custom settings for Standalone ################ -->
    <!-- ############################################################## -->
    <!-- disable CheckSystemRequirements -->
    <add key="BMW.Rheingold.ISTAGUI.disableCheckSystemRequirements" value="false" />
    <!-- enable Programming via ENET, don't use it with ICOM Nano! -->
    <add key="BMW.Rheingold.ISTAGUI.enableENETprogramming" value="false" />
    <!-- ############################################################## -->
    <!-- ########## end of custom settings for Standalone ############# -->
    <!-- ############################################################## -->
    <add key="BMW.Rheingold.Developer.guidebug" value="true" />
    <add key="BMW.Rheingold.ISTAGUI.App.MultipleInstancesAllowed" value="false" />

Programming with ENET cable is only available in Sedoy's standalone package, he modified the app to enable this feature, otherwise only iCOM could be used. https://cartechnology.co.uk/showthread.php?tid=77749&pid=611760#pid611760

If you have time, maybe these logs are the clue to find out where to patch the app for using ENET cable.

2023-04-09 21:17:47.504 INFO [T] ISTA: [54] CloseOperationMeasurement - Executing.
2023-04-09 21:17:47.504 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Closing operation measurement.
2023-04-09 21:17:47.505 INFO [T] ISTA: [43] IcomTraceCollector.IcomTraceCollector() - The IcomTraceCollector is not active by ipAddress: '192.168.1.107', vin17: 'XXXXXXXXXXXXXXXXX', devType: 'ENET', Enabled: 'True'
2023-04-09 21:17:47.506 INFO [T] ISTA: [54] StartMeasurementService.DisconnectImib - Disconnecting the Imib...
2023-04-09 21:17:47.510 WARNING [T] ISTA: [54] StartMeasurementService.DisconnectImib - device structure was null or no IMIB
2023-04-09 21:17:47.513 INFO [T] ISTA: [54] StartMeasurementService.SetConnectionState - Setting connection state to reserved: False, and blocked: False
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] Logic.CloseOperationMeasurement() - Operation measurement closed.
2023-04-09 21:17:47.516 INFO [T] ISTA: [54] CloseOperationMeasurement - Executed.

Sorry I don't have an account on this forum to view this thread, can I assume that the 4.40 version of the program uploaded in this issue is in fact the original program by BMW, and that Sedoy's standalone edition is currently only updated to 4.39?

In that case, I may be able to compare these two versions to see if I can find the modifications which sedoy had made.

rocdeng commented 1 year ago

Never mind, the post just said the 'enableENETprogramming' setting is only made for the Sedoy's standalone app, the original BMW ISTA and other offline license app doesn't support the setting, no other tech details. 屏幕截图 2023-04-21 220834

BTW: Sedoy only shared the standalone package to 4.37.40(need his free license key). Then he made his iLean offline license package and it's not free. Then someone shared the 4.39.20 standalone package(no need to register, I found your url in the exe and reached here). So infact the 4.39.20 it's your art. My car has been updated to the latest iLevel so I can't confirm whether 4.39.20 could execute the upgrade plan. I think So If you want to compare, you should compare standalone package 4.37.40 or older. I tried to dig today but not found clue yet. If you need old 4.37 program, I could help, feel free to contact me at any time because we're in the same timezone :)

CharlesJung73 commented 1 year ago

sedoy has released ISTA Standalone 4.39.20 and is the latest version. 4.39.20 is patched with ISTA-Patcher and works perfectly until programming. Later, the following versions (4.39.31, 4.40.13, 4.40.20, 4.40.30, 4.40.41) were manually installed and tried patching. I can diagnose and delete errors, but I can't program.

rocdeng commented 1 year ago

I don't think the 4.39.20 standalone package widely spreaded on the forum is published by Sedoy. Sedoy's free standalone post is ended on 4.37.40. Then you could only buy his iLean offline license on his site. Very obvious, Sedoy's package after 4.32.2x need register key from Sedoy but 4.39.20 doesn't. And open the 4.39.20 main exe file, you could find ISTA-Patcher fingerprints. So I think someone use this patcher cracked the 4.39.20 and packed a 'standalone' package.

screenshot-20230422-205639

When you ask him for latest standalone package link in PM, it's 4.37.40. screenshot-20230422-212002

tautcony commented 1 year ago

ISTA is a huge codebase with over 10,000 files and a full comparison would take a long time.

The option BMW.Rheingold.ISTAGUI.enableENETprogramming was been added to the function IsConnectedViaENETAndBrandIsToyota, I replaced the function body with return base.ProgrammingSession.Vehicle.VCI.VCIType == VCIDeviceType.ENET;.

This may enable the ENET programming by patching with ISTA-Patcher.exe patch --enable-enet /path/to/ista, testing required.

rocdeng commented 1 year ago

Great work, I've used the exe from action, patching fine and app running fine, but don't have chance to test the programming function (because my iLevel is up-todate). I'll test while a new PSDZ data released.

CharlesJung73 commented 1 year ago

Looking at the installer version, I think the version of Standalone that Sedoy deployed is correct.

ISTA StandAlone 4.39.2x

https://mega.nz/folder/vkQ2BTYZ#mah2poaMcz0DxoQ1aZgOHw

rocdeng commented 1 year ago

Update: Today I upgrade the program and PSdZ Data to latest version(4.41.13 and 4.41.10) then apply the latest Patcher exe from action. Patching perfect, ISTA+ diag perfect. But there is no update from iLevel 23-03-540 to iLevel 23-03-550, so still have no chance to test the ENET patch, don't know whether it's working now.

tautcony commented 1 year ago
RheingoldProgramming.dll                   11311-----1-------- [8 func patched]

--enable-enet option is included, right? If it still doesn't work, can you find any related information that might be useful in the logs?

But overall, TherapyPlan does not record much information in the log files.

rocdeng commented 1 year ago

Sure, the option is included and output is same as you(8 func patched). The problem is on me because I don’t have any new firmware to program:(

rocdeng commented 1 year ago

Update: Issue could be close. I've tested new patcher with --enable-enet option on my car with newest 23-07 SDP data, the 'execute plan' button is enable now. Later I'll try to execute the plan to see what will happen.

roadray commented 1 year ago

Programming with ENET cable

I tested it a little while ago. However, it is not possible to program with ENET cable. We have confirmed that "icom next" is programmable. How can I enable programming using ENET cable? Can you share a different setup method from the Registry setup?

tautcony commented 1 year ago

Programming with ENET cable

I tested it a little while ago. However, it is not possible to program with ENET cable. We have confirmed that "icom next" is programmable. How can I enable programming using ENET cable? Can you share a different setup method from the Registry setup?

Have you repatched the ista with --enable-enet option, this option is not enabled by default.

roadray commented 1 year ago

Programming with ENET cable

I tested it a little while ago. However, it is not possible to program with ENET cable. We have confirmed that "icom next" is programmable. How can I enable programming using ENET cable? Can you share a different setup method from the Registry setup?

Have you repatched the ista with --enable-enet option, this option is not enabled by default.

I modified it again and ran it, and it became active. I will test if it is programmed later.

roadray commented 1 year ago

Programming with ENET cable

I tested it a little while ago. However, it is not possible to program with ENET cable. We have confirmed that "icom next" is programmable. How can I enable programming using ENET cable? Can you share a different setup method from the Registry setup?

Have you repatched the ista with --enable-enet option, this option is not enabled by default.

I modified it again and ran it, and it became active. I will test if it is programmed later.

I can't activate the program with ICOM NEXT. I hope both ENET cable and ICOM NEXT are activated. Currently, only ENET cable is active when patched. If not patched, only ICOM NEXT is activated. Is it possible to modify it so that it can be both?

rocdeng commented 1 year ago

Did you test your ICOM and ENET on Sedoy's 4.37.4x Standalone package and make sure they both do work? From tautcony's code I can't see any possibility the mod could affect ICOM programming, it did what Sedoy's patch did. Unluckily I don't have an ICOM so I can't test whether ICOM still works after patch.

tautcony commented 1 year ago

Did you test your ICOM and ENET on Sedoy's 4.37.4x Standalone package and make sure they both do work? From tautcony's code I can't see any possibility the mod could affect ICOM programming, it did what Sedoy's patch did. Unluckily I don't have an ICOM so I can't test whether ICOM still works after patch.

The function name is a bit confusing, so I misunderstood the intention of this function. When using ICOM it should also return true to continue the programming session.

protected bool IsConnectedViaENETAndBrandIsToyota()
{
  if (base.ProgrammingSession.Vehicle.VCI.VCIType != VCIDeviceType.ENET || ConfigSettings.IsLightModeActive)
  {
    return true;
  }
  if (base.ProgrammingSession.Vehicle.VCI.VCIType == VCIDeviceType.ENET)
  {
    BrandName? brandName = base.ProgrammingSession.Vehicle.BrandName;
    return (brandName != null) && (brandName.GetValueOrDefault() == BrandName.TOYOTA);
  }
  return false;
}
rocdeng commented 1 year ago

My fault, I thought your code was actually Sedoy 4.37.4x code... So I didn't see anything wrong.

protected bool IsConnectedViaENETAndBrandIsToyota()
{
    if (base.ProgrammingSession.Vehicle.VCI.VCIType != VCIDeviceType.ENET || ConfigSettings.IsLightModeActive)
    {
        return true;
    }
    if (base.ProgrammingSession.Vehicle.VCI.VCIType == VCIDeviceType.ENET)
    {
        BrandName? brandName = base.ProgrammingSession.Vehicle.BrandName;
        if ((brandName.GetValueOrDefault() == BrandName.TOYOTA & brandName != null) || ConfigSettings.getConfigStringAsBoolean("BMW.Rheingold.ISTAGUI.enableENETprogramming", false))
        {
            return true;
        }
    }
    return false;
}
roadray commented 1 year ago

Both work well. Thank you.