General Sony Xperia 10 iii Additional LTE/5G Band Unlocks - Sony Xperia 10 III

Hi,
The 10 iii uses the Snapdragon X51 Modem. This modem seems to be in very few phones at the moment, however, the modem is the same on the OnePlus Nord N10 5G and Nokia X20 . Both of these devices are available in the US and contain some additional bands that the 10 iii does not.
With the Xperia 10 iii most likely not receiving a US Customized firmware in the future, is there any path forward with modifying the bands that are available on the modem?
Currently, my progress is as follows...
1. Root the 10 iii with Magisk -​
This is easily done by downloading firmware with XperiFirm, extracting the boot.sin, "unsinning" it to get a boot.img, patching the boot.img with Magisk, and then flashing the modified boot.img with fastboot. To do this, the bootloader must be first unlocked. Simply use the factory method of unlocking the bootloader. Generate a code for the Sony Xperia 10 ii (as the 10 iii isn't listed yet, but the codes are interchangeable, this applies to all iii devices like the 5 and 1, just use the ii codes). Unlocking the bootloader will wipe the device and lose the Sony DRM keys.​​2. Qualcomm QPST Connection -​
Most Qualcomm modems support their QPST application. This diagnostic application allows you to interface with the modem on your phone and change it's parameters. The process to connect to that application involves installing their modem drivers, opening the com port on your pc to connect to your phone, and initiating the connection.​​Here is a guide on setting it up that pertains to the 1 ii, but is relevant to most Sony devices. Note that the "enable Qualcomm diag" step contains a correction for us.....​"setprop persistent.sub.eng 1" should be "setprop persist.usb.eng 1" and installing the drivers (9018, not 9020) on the device in device manager should contain the "MI_00" hardware ID instead.​​3. Digging in to the files​
Here is where my roadblock begins and expertise falls off. The modem contains many xml files that can be edited to set bands, enable data features, etc. Most relevant files appear to be in the "policyman" folder. However, my efforts on actually having any edits make any impact have been a zero sum game. Making changes to the band_set_01 and carrier_policy files seems to make no difference on enabled bands, how it connects to my network (Verizon), etc.​​​​Any one have any ideas or thoughts? Is this path forward even possible?
Below are links to the policyman files that I extracted from the modem. Feel free to download them and view/modify. If other modem files would like to be looked at, just let me know. Most other files seem to be an unknown file format and not easily modified xml.
Here is a copy of the stock 10 iii policyman folder (note my carrier_policy is standard Verizon) - Download
Here is a copy of a modified band_set_01. I basically added all Verizon bands to all rf_band_lists that could be US related.
I have tried various carrier_policy changes. Also attempted to use generic/pre-made ones from other devices that contain more defined rules. Here is an example of one I tried from a OnePlus 9
Thanks!
​​​​

Hi, were you really able to root the phone the way you described? Or is this just the theoretical steps? Because currently it's not even possible to unlock the bootloader on this phone (yet, hopefully) which would forbid the flashing of a modified boot.img as far as I know.
Looks like we'll have to wait some more before anything really moves for this phone.

combinedfleet said:
Hi, were you really able to root the phone the way you described? Or is this just the theoretical steps? Because currently it's not even possible to unlock the bootloader on this phone (yet, hopefully) which would forbid the flashing of a modified boot.img as far as I know.
Looks like we'll have to wait some more before anything really moves for this phone.
Click to expand...
Click to collapse
Yes, the device is able to be rooted normally with Magisk. To unlock the bootloader, just generate a code for a Xperia 10 ii, they work just fine. Note that unlocking the bootloader will wipe the device and lose DRM keys. https://developer.sony.com/develop/open-devices/get-started/unlock-bootloader/#unlock-code I have edited the OP to include this step.

I can help you to list all devices supported bands and 4G & 5G combinations if you like to contribute log to cacombos.com/contribute. Qualcomm diag option is best for Sony devices when rooted.
You can't edit firmware defined combinations because these are compiled and signed by Qualcomm. To edit these have to recompile from source and sign. And of course the firmware source is not public and signing keys are very secure.

olkitu said:
I can help you to list all devices supported bands and 4G & 5G combinations if you like to contribute log to cacombos.com/contribute. Qualcomm diag option is best for Sony devices when rooted.
You can't edit firmware defined combinations because these are compiled and signed by Qualcomm. To edit these have to recompile from source and sign. And of course the firmware source is not public and signing keys are very secure.
Click to expand...
Click to collapse
I planned on contributing to your website!
I know I stop logging with ctrl+c, but, is there a limit to amount of qmd1 files that are created per proc_type?
The example on ca combos looks like it moves on to the next proc_type automatically? Below is my current terminal.
Code:
XQ-BT52:/sdcard/diag_logs $ su
ogs -f /sdcard/diag_logs/Diag.cfg -m /sdcard/diag_logs/Diag.cfg <
diag_mdlog: command = o
diag_mdlog: command = f
diag_mdlog: command = m
diag:main: kernel supported: NUM_PERIPHERALS = 7, DIAG_CON_ALL: 255
diag: No Session is active for the given mask
diag_mdlog: Closing diag_fd_temp
diag_mdlog: Warning output directory already exists: /sdcard/diag_logs
diag_mdlog: Proceeding...
diag_mdlog: Diag_LSM_Init succeeded.
REMOTE PROCESSOR MASK 0
diag:kernel supported: NUM_PERIPHERALS = 7, DIAG_CON_ALL: 255
logging switched
Output dirs /sdcard/diag_logs --- /sdcard/diag_logs
diag: check_for_diagid_cmd DIAG_GET_DIAG_ID
diag_mdlog: Reading mask for MSM, proc_type: 0
Reading the mask file: /sdcard/diag_logs/Diag.cfg
diag: Determining contents of directory /sdcard/diag_logs for circular logging ...
diag: Determining contents of directory /sdcard/diag_logs for circular logging ...
creating new file /sdcard/diag_logs/diag_log_20210703_1119471625325587206.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1123011625325781935.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1127191625326039079.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1131261625326286642.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1136221625326582083.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1140061625326806999.qmdl

@olkitu I stopped the logging after about 20 minutes. Submitted the logs to cacombos.

Archerpunk said:
@olkitu I stopped the logging after about 20 minutes. Submitted the logs to cacombos.
Click to expand...
Click to collapse
Got it and now supported combinations of this device listed here: https://cacombos.com/device/XQ-BT52 (HW combos).
During logging seems you have only enabled LTE bands 4 and 5.
This device sold in US? This is global model - same sold in Europe too. Device missing US combinations.
Archerpunk said:
I planned on contributing to your website!
I know I stop logging with ctrl+c, but, is there a limit to amount of qmd1 files that are created per proc_type?
The example on ca combos looks like it moves on to the next proc_type automatically? Below is my current terminal.
Code:
XQ-BT52:/sdcard/diag_logs $ su
ogs -f /sdcard/diag_logs/Diag.cfg -m /sdcard/diag_logs/Diag.cfg <
diag_mdlog: command = o
diag_mdlog: command = f
diag_mdlog: command = m
diag:main: kernel supported: NUM_PERIPHERALS = 7, DIAG_CON_ALL: 255
diag: No Session is active for the given mask
diag_mdlog: Closing diag_fd_temp
diag_mdlog: Warning output directory already exists: /sdcard/diag_logs
diag_mdlog: Proceeding...
diag_mdlog: Diag_LSM_Init succeeded.
REMOTE PROCESSOR MASK 0
diag:kernel supported: NUM_PERIPHERALS = 7, DIAG_CON_ALL: 255
logging switched
Output dirs /sdcard/diag_logs --- /sdcard/diag_logs
diag: check_for_diagid_cmd DIAG_GET_DIAG_ID
diag_mdlog: Reading mask for MSM, proc_type: 0
Reading the mask file: /sdcard/diag_logs/Diag.cfg
diag: Determining contents of directory /sdcard/diag_logs for circular logging ...
diag: Determining contents of directory /sdcard/diag_logs for circular logging ...
creating new file /sdcard/diag_logs/diag_log_20210703_1119471625325587206.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1123011625325781935.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1127191625326039079.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1131261625326286642.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1136221625326582083.qmdl
creating new file /sdcard/diag_logs/diag_log_20210703_1140061625326806999.qmdl
Click to expand...
Click to collapse
No limits but file size by default max 100MB and then create new one automatically.

olkitu said:
Got it and now supported combinations of this device listed here: https://cacombos.com/device/XQ-BT52 (HW combos).
During logging seems you have only enabled LTE bands 4 and 5.
This device sold in US? This is global model - same sold in Europe too. Device missing US combinations.
No limits but file size by default max 100MB and then create new one automatically.
Click to expand...
Click to collapse
Yes, it appears this device only supports bands 4 and 5 for the Verizon Network.
It isn't sold in US, but is sold globally. Most other regions (EU, Asia, Etc) seem to have specific customized firmware with mostly similar bands.
Is there a way to export all the CA combos in a format for the Carrier Policy?

Archerpunk said:
Yes, it appears this device only supports bands 4 and 5 for the Verizon Network.
It isn't sold in US, but is sold globally. Most other regions (EU, Asia, Etc) seem to have specific customized firmware with mostly similar bands.
Is there a way to export all the CA combos in a format for the Carrier Policy?
Click to expand...
Click to collapse
For now there is no tool to export Qualcomm format out.

Was hoping this thread would bear some fruit because if band difference is a solely software matter these days, rooting should allow us full access to all the features of any damn phone.

Archerpunk said:
Hi,
The 10 iii uses the Snapdragon X51 Modem. This modem seems to be in very few phones at the moment, however, the modem is the same on the OnePlus Nord N10 5G and Nokia X20 . Both of these devices are available in the US and contain some additional bands that the 10 iii does not.
With the Xperia 10 iii most likely not receiving a US Customized firmware in the future, is there any path forward with modifying the bands that are available on the modem?
Currently, my progress is as follows...
1. Root the 10 iii with Magisk -​
This is easily done by downloading firmware with XperiFirm, extracting the boot.sin, "unsinning" it to get a boot.img, patching the boot.img with Magisk, and then flashing the modified boot.img with fastboot. To do this, the bootloader must be first unlocked. Simply use the factory method of unlocking the bootloader. Generate a code for the Sony Xperia 10 ii (as the 10 iii isn't listed yet, but the codes are interchangeable, this applies to all iii devices like the 5 and 1, just use the ii codes). Unlocking the bootloader will wipe the device and lose the Sony DRM keys.​​2. Qualcomm QPST Connection -​
Most Qualcomm modems support their QPST application. This diagnostic application allows you to interface with the modem on your phone and change it's parameters. The process to connect to that application involves installing their modem drivers, opening the com port on your pc to connect to your phone, and initiating the connection.​​Here is a guide on setting it up that pertains to the 1 ii, but is relevant to most Sony devices. Note that the "enable Qualcomm diag" step contains a correction for us.....​"setprop persistent.sub.eng 1" should be "setprop persist.usb.eng 1" and installing the drivers (9018, not 9020) on the device in device manager should contain the "MI_00" hardware ID instead.​​3. Digging in to the files​
Here is where my roadblock begins and expertise falls off. The modem contains many xml files that can be edited to set bands, enable data features, etc. Most relevant files appear to be in the "policyman" folder. However, my efforts on actually having any edits make any impact have been a zero sum game. Making changes to the band_set_01 and carrier_policy files seems to make no difference on enabled bands, how it connects to my network (Verizon), etc.​​​​Any one have any ideas or thoughts? Is this path forward even possible?
Below are links to the policyman files that I extracted from the modem. Feel free to download them and view/modify. If other modem files would like to be looked at, just let me know. Most other files seem to be an unknown file format and not easily modified xml.
Here is a copy of the stock 10 iii policyman folder (note my carrier_policy is standard Verizon) - Download
Here is a copy of a modified band_set_01. I basically added all Verizon bands to all rf_band_lists that could be US related.
I have tried various carrier_policy changes. Also attempted to use generic/pre-made ones from other devices that contain more defined rules. Here is an example of one I tried from a OnePlus 9
Thanks!
​​​​
Click to expand...
Click to collapse
In lte_feature_ca_mcc entries of each operator, you need to edit them and add combinations for your operator

Related

[GUIDE FOR DEVELOPERS] How to create HOMEBREW apps with NATIVE code on MANGO

When we were back on NoDo there were quite a few homebrew apps that used native code to apply tweaks to WP7 devices. Most of those apps seized to work after the device is upgraded to Mango. There a several reasons for this behavior. I've done research on this, because I wanted to make WP7 Root Tools compatible with Mango. In this topic I'd like to explain how developers can fix their apps to work on Mango again. It has taken me quite some time to compile this guide, but I hope to give the Homebrew development on WP7.5 Mango a boost.
This guide is NOT about creating homebrew executables (exe-files) for WP7. This guide aims to utilize native code DLL's (C++ / ARM) from within your Silverlight app.
Note that with native code you get access to a lot of extra API's. But that does not mean you automatically get access to resources you normally won't have access to. For example, you can use the CopyFile() API. But if you try to copy a file to the \Windows folder, you will get errorcode 0x4ec (1260), which means "Blocked by policy". So you are still bound to the rules of the sandbox of your app. If you want Full Root Access for your app, you have to wait for a new version of WP7 Root Tools, which will allow you to give your app root-access. I'm also working on an SDK for that, which wraps all common task into a neat managed library. But don't hold your breath for that, because it's all taking a bit longer than I expected.
To understand everything in this guide you need basic knowledge of C++, COM-interop and Silverlight for Windows Phone. If you are new to all this, you might want to do some reading on these topics first. Currently there is no way to debug the native code. The only thing you can do is create test-functions which return formatted debug-info. This makes things pretty difficult. Read the guide carefully, because a little mistake can make your app crash easily!
Important note: If you have any long-running tasks, they may work fine while you are debugging. But you need to make sure that you start a new thread to run this code. Because, when you run without debugger the WatchDog will monitor your application and if the User Interface thread is blocked for more than 10 seconds the WatchDog will exit your app ungracefully!
It has been suggested that native homebrew DLL's need to be signed with approved code-signing keys. This is in fact not true! You can use native DLL's on Mango devices, which are not signed at all!
Basically there are two reasons why homebrew apps are not working anymore:
- Interop Lock
- DLL's were built against libraries, which are not supported anymore on Mango
Interop Lock is discussed in this thread. Interop Lock is a new protection mechanism in WP7.5 Mango. Basically it means you can't use apps with ID_CAP_INTEROPSERVICES, unless a device is Interop Unlocked. Without ID_CAP_INTEROPSERVICES an app can't call any drivers. And most homebrew apps call these drivers directly or indirectly. So if an app uses the Interop Capability, it can only run on devices that are Interop Unlocked. If you're going to build an app that uses this capability on Mango, you'll have to give your users instructions on how to apply Interop Unlock on their device.
Most of the native code libraries that were used on NoDo, were based on a hand full of projects. These projects were created and then extended for their own needs by other developers. The result was that most of these projects had the same project-types and library-references. In Mango, a lot of DLL's that were not used anymore by Microsoft, have been removed from the OS. Mostly in the ShellCore. The DLL's were meant for MFC-type functionality, which was never even supported on WP7. Actually, these DLL's are not even used by the homebrew apps either, but there are references to these DLL's in the homebrew libraries, which will cause the library to fail loading into memory. You can see this behavior when you try to run an app with non-Mango-compatible native code on an Interop Unlocked device from within the Visual Studio 2010 development environment. When the COM-class is instantiated it will throw an COMException: "COM object with CLSID '{...}' cannot be created due to the following error: The request is not supported." This is errorcode 0x80070032. This exception is actually caused due to the fact that the previous call to RegisterComDll() failed. If you get the returnvalue of that function you should have 0. In this case the return-value is probably 0x8007007E, which is "Module Not Found". This actually means that you directly or indirectly refer to a DLL, which cannot be found on the device. To fix this we need to create a clean project and add our new or existing native code to that project.
Here are the steps to setup your development environment and create a new, clean project for your native code. Please keep in mind that this guide is still work-in-progress. I may add more detailed instructions and examples later on, when people ask for it.
Update 2011/10/15: Some improvements in the guide, based on comments of rudelm and GoodDayToDie.
Install Visual Studio 2008 with latest service pack and hotfixes. Make sure you install C++. You need Visual Studio 2008, because the necessary SDK does not support Visual Studio 2010.
Install Windows Mobile 6 Professional SDK Refresh.
Install Visual Studio 2010 with latest service pack and hotfixes. You need this to create your Windows Phone Silverlight app.
Install Windows Phone SDK 7.1.
Download the attached Microsoft.Phone.InteropServices.zip. After you downloaded the zip-file, open the file-properties and make sure the file is "unblocked" (Windows will block downloaded files). Some unzippers, including the built-in unzipper from Windows will mark the unzipped files as "blocked", which would give problems later on if you don't unblock first.
If your developmachine is 32-bit you go to "C:\Program Files\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\Profile\WindowsPhone71" or if you have a 64-bit machine you go to "C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\Profile\WindowsPhone71". Extract the DLL from the zip-file in this folder.
Open the Visual Studio Commandprompt and change directory to the folder where you just extracted the DLL. Then enter this command:
Code:
SN -Vr Microsoft.Phone.InteropServices.dll
In the same folder there is a subfolder called "RedistList". Open that folder and open the file "FrameworkList.xml". Add this line to that file:
Code:
<File AssemblyName="Microsoft.Phone.InteropServices" Version="7.0.0.0" Culture="neutral" ProcessorArchitecture="MSIL" InGac="false" />
Thanks to Tom Hounsell for this tip!
Install the latest version of Zune.
Open Visual Studio 2008 and create a new project.
Choose Visual C++ / Smart Device / ATL Smart Device Project and fill in a name and location for your native library. Do NOT choose MFC, or your library won't work on WP7! The name will be the name for the DLL. Later on you will create a COM-class. Choose a different name for your library and for your COM-class!
In the new wizard click "Next".
Remove the "Pocket PC 2003" from the Selected SDK list and add "Windows Mobile 6 Pro SDK" to the selected SDK's. Click "Next".
In "Application Settings" keep everything default and click "Finish".
Set your configuration to "Release", because you won't be able to debug anyway.
Go to Project Properties / Configuration Properties / C/C++ / Preprocessor / Preprocessor Definitions and add this: _CE_ALLOW_SINGLE_THREADED_OBJECTS_IN_MTA
Right-click the project and click "Add" / "Class" and choose "Simple ATL object".
In the new dialog enter the "Short name" for your COM-class. All other names are filled in automatically. Keep those names default to avoid naming-conflicts. Also make sure the name of your COM-class is different from the name of the library. All other options can are default, so you can click "Finish" now.
The basic layout for your native project is now ready. Note that you have these files: for your library you have a header-file (.h), a code-file (.cpp) and a COM-definition-file (.idl) and for your COM-class you have a header-file (.h) and a code-file (.cpp). I will refer to these files in the following steps, so make sure you can identify these files.
The COM-class you have now is based on IDispatch. IDispatch is the COM-interface that supports reflection-like functionality. The COMBridge in WP7 does not support this interface. Instead we should use IUnknown, which is the base-interface for all COM-objects and supports reference-counting.
In the header file of your COM-class you can see the public inheritance of IDispatchImpl. This is no problem and you can leave it as it is. But you can also see this COM-mapping:
Code:
COM_INTERFACE_ENTRY(IDispatch)
You need to remove that line.
In the IDL file of your library you need to change the inheritance of the COM-class from IDispatch to IUnknown.
Your native code layout is now ready to add your methods. A method in COM-class should always have HRESULT as return-type. This value should be 0 or positive in case of success (normally use constant S_OK for success). If you have an errorcode which should throw a COMException do a logical OR with 0x80070000 and return that value. If you want to return a variable, you'll to declare that as parameter of your method and decorate it as returnvalue in the IDL-file. The parameter-types are bound by the definition of COM. You can read about the supported COM-datatypes here and here. Study those parameter-types closely, because any mismatch in your managed and unmanaged declarations will make your app crash definitely. You need to add all your methods in 3 different places: in the COM-class code, in the COM-class interface and in the IDL-file. Later on you need to add an exactly matching interface to your managed code. All the declarations have their own specific format and decoration. I will give an example of two different functions for these 3 files. Note that in these examples, the COM-class was named "Native", so the class implementation is called "CNative" and the interface is called "INative". You have to change that if your class has a different name.
In the COM-class implementation (.cpp-file) add this code:
Code:
STDMETHODIMP CNative::TestMethod1()
{
BOOL result = ::CopyFile(L"\\Windows\\0000_System.Windows.xaml", L"\\Windows\\Test.xaml", TRUE); // This will fail due to insufficient privileges. This is expected behavior to show how errors can be handled.
if (result)
return S_OK;
else
return 0x80070000 | ::GetLastError();
}
STDMETHODIMP CNative::TestMethod2(BSTR InputString, BSTR* OutputString)
{
size_t size = 1000; // in chars
TCHAR* msg = new TCHAR[size];
wcscpy_s(msg, size, L"\0");
LPWSTR value = new WCHAR[20];
_itow((int)wcslen(InputString), value, 10);
wcscat_s(msg, size, L"Length of string is: ");
wcscat_s(msg, size, value);
*OutputString = SysAllocString(msg);
delete[] msg;
delete[] value;
return S_OK;
}
In the interface of the COM-class (.h-file) add this code immediately after END_COM_MAP():
Code:
STDMETHOD(TestMethod1)();
STDMETHOD(TestMethod2)(BSTR InputString, BSTR* OutputString);
Locate your interface in the IDL-file of the library. This may look a bit weird, because there are a lot of attributes that decorate the empty interface. Add these declarations to your interface (note the decoration of the parameters, read more here):
Code:
HRESULT TestMethod1();
HRESULT TestMethod2(BSTR InputString, BSTR* OutputString);
Now we need to locate two GUID's and copy them in a text-file, because we need these GUID's later on. These GUID's are in the IDL-file. We will call the first GUID "interface-GUID". It is the "uuid" in the tag RIGHT ABOVE the interface-declaration. We will call the second GUID "coclass-GUID". It is the "uuid" in the tag RIGHT ABOVE the coclass-declaration. There also a "uuid" in the tag above the library-declaration, but we don't need that one.
Open Visual Studio 2010 and create a new project: Visual C# / Silverlight for Windows Phone and choose a project-type, name and location.
Now go back to your native project in Visual Studio 2008. The compiled result DLL of this project will be used in your Windows Phone app. To make sure you always use the latest version of the native DLL in your Windows Phone app, you can add a Post Build Event to this project. This example assumes you will have a folder with a subfolder for the native solution and a subfolder for the Windows Phone solution. Go to Project Properties / Configuration Properties / Build Events / Post-build Events and add this (change the paths according to the soluton-foilder you will create for your Windows Phone app):
Code:
copy "$(TargetPath)" "$(SolutionDir)..\MyApp
If you checked the option "Create folder for solution" when you created the Windows Phone project, you may want to add another subfolder "\MyApp" to the path.
Now build your native project! The compiled DLL should now also be copied to the folder of your Windows Phone app.
Create a new file called "WPInteropManifest.xml" in the folder of your managed Windows Phone app. Copy this content in the file:
Code:
<?xml version="1.0" encoding="UTF-8"?>
<Interop>
</Interop>
Switch back to Visual Studio 2010. In the solution explorer click on "Show all files". Your native DLL and the "WPInteropManifest.xml" should be shown now.
Select the "WPInteropManifest.xml" file and in the file-properties set "Build action" to "Content" and set "Copy" to "Always". You will always need this file in your project, regardless you will be calling drivers or not. If you don't have this file in your project, you won't be able to use your native DLL.
Select your native DLL and in the file-properties set "Build action" to "Content" and set "Copy" to "Always".
In the solution explorer, right-click on the project and choose "Add Reference". Then select "Microsoft.Phone.InteropServices".
Open the "WMAppManifest.xml" file and add this line below the other capabilities:
Code:
<Capability Name="ID_CAP_INTEROPSERVICES" />
Later on, you can try if your app will work without this capability. If you only use native code without calling drivers (directly or indirectly), you don't need the capability and your app will also work on devices that are not Interop Unlocked then. This specific example does not call any drivers, so in this example the ID_CAP_INTEROPSERVICES can be omitted and then it would run on non-Interop-Unlocked devices.
Now add a code-file to your project and copy this code into the file. You need the the coclass-GUID and interface-GUID you copied into a text-file earlier and you also need to replace the name of the class and interface to the names you used. Also note that the declaration must be an exact match (order and parameters) with the declaration in the IDL-file, although the IDL-file is differently formatted.
Code:
using System.Runtime.InteropServices;
[ComImport, ClassInterface(ClassInterfaceType.None), Guid("YOUR-COCLASS-GUID-GOES-HERE")]
public class CNative
{
}
[ComImport, Guid("YOUR-INTERFACE-GUID-GOES-HERE"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface INative
{
void TestMethod1();
[return : MarshalAs(UnmanagedType.BStr)]
string TestMethod2([MarshalAs(UnmanagedType.BStr)] string InputString);
}
Note that the interface is declared as IUnknown.
Now you need to call the native code. You can add this code to the constructor of your Page or to the eventhandler of a button, or anywhere you like. Be sure to replace the DLL-name, interface-name and class-name and use your coclass-GUID. The exception is a well-known error-code and the exception will be casted to a UnauthorizedAccessException, instead of a COMException.
Code:
uint retval = Microsoft.Phone.InteropServices.ComBridge.RegisterComDll("WP7Native.dll", new Guid("YOUR-COCLASS-GUID-GOES-HERE"));
INative MyNativeCodeInstance = (INative)new CNative();
string result1 = "OK";
try
{
MyNativeCodeInstance.TestMethod1(); // UnauthorizedAccessException is thrown due to insufficient privileges. This is expected behavior to show how errors can be handled.
}
catch (Exception ex)
{
result1 = ex.Message;
}
string result2 = MyNativeCodeInstance.TestMethod2("Hello, Mango!");
MessageBox.Show(result1 + Environment.NewLine + result2);
You can now run your project! Be sure that you deploy it to your device. The emulator won't work, because you project uses native ARM code. The emulator runs on x86, so your native DLL won't load in the emulator.
When you go more advanced, you may need the Marshal-class. For example to copy a native memory-block to a managed byte-array. Be aware that there are actually two "Marshal" classes. There is "Microsoft.Phone.InteropServices.Marshal" and "System.Runtime.InteropServices.Marshal". They both look the same. But be sure you are using "Microsoft.Phone.InteropServices.Marshal", because it will allow you to do a lot more! Most methods in "System.Runtime.InteropServices.Marshal" will throw a MethodAccessException, because they are tagged [SecurityCritical], while the same methods in the other Marshal class will work.
I hope this will help you port your homebrew apps to Mango or create some fresh new homebrew! If you created an app with native code, drop me a line here. Show me your Screen Recorders, Accent Changers and more!
Ciao,
Heathcliff74
looking fwd to the native apps , a universal screenshot apps would be awesome..
Update :
scratch that, just ready that the app will be bound to the rules of the sandbox of your app.I guess that means no universal screenshot app yet
Its time to get native! Thanks Heathcliff.. I think I have a very good idea on something I could use native code for.. Ill pm you =)
Sent from my SGH-i917 using XDA Windows Phone 7 App
Suddenly, awesomesauce! Wow, big thanks Heathcliff74! Eve since you said you'd figured out homebrew native DLLs on Mango, I was really excited to see what people could do. I never guessed the real reason homebrew DLLs didn't work on Mango, although in retrospect this makes sense. You're awesome for investigating this for us.
Thoughts that immediately come to mind:
Update the existing screen capture apps.
Update the existing WebServer app.
(As part of the above) update the sockets DLL so we have server sockets again.
Explore how much filesystem access we have. Can files be copied from one app's isostore to another app's isostore?
Explore accessing drivers. The HTC update breaks filesystem access for HTC homebrew, but maybe there's another driver entry point we can use.
Investigate direct access to the SMS store (message backup?)
... and so much more. Oh, this is going to be fun!
the0ne said:
looking fwd to the native apps , a universal screenshot apps would be awesome..
Update :
scratch that, just ready that the app will be bound to the rules of the sandbox of your app.I guess that means no universal screenshot app yet
Click to expand...
Click to collapse
Hi!
Screenshots apps are definitely possible! The API for this can be called from within the sandbox and using OEM drivers it is possible to switch off dehydration. I already discussed this with fiinix and gave him this info. And I believe he almost has a Mango version ready.
Thanks for writing the article
Ciao,
Heathcliff74
great to hear about the progress
thanks Heathcliff74 for sharing!
Wooohooo nice HowTo! I will definitively try it and will report later. However, that will require that I go back to NoDo and back to Mango first. I'm not looking forward to that procedure... anyways awesome work Heathcliff, thank you!
@GoodDayToDie: you mentioned that the HTC libraries are fixed regarding file access. Julien Schapman from TouchXplorer mentioned something like that a while ago on twitter. Do you have any additional information on that topic? Is it just the DLL files from the HTC apps or is it something with the Mango HTC Update? I'll hope this is reversible, if I go back to NoDo and want to try Heathcliffs instructions :/
@rudelm, I only have experimental knowledge; I haven't dug into the actual update. However, the way that things like ComFileRW.dll work is by calling into some high-permission module in the HTC firmware (probably a driver using an IOCTL, though it could possibly be an RPC call to a privileged process) which then executes the requested action with high permissions. That's why the HTC DLLs don't do anything on other phones; they can't talk to the component that actually does the work.
My guess is that the HTC update simply turned off whatever it was that the COM DLLs are calling into. It could be more complex than that - for example, they could be trying to validate the caller, and prevent it from being used by homebrew - but whatever they did, neither DLL works anymore once you have the HTC update *even though the DLLs themselves did not change.*
Is it reversible? Well, "fixing" whatever component they were calling into is one option. Using Heathcliff74's Root Tools to gain full permissions on a "normal" homebrew app is another. There might be more, but it would need more study.
Thanks. Will try it. Hopefully i can get "GetPhoneNumber" from Windows Mobile 6 SDK to run or maybe trying http://blogs.msdn.com/windowsmobile/archive/2004/11/28/271110.aspx
GoodDayToDie said:
@rudelm, I only have experimental knowledge; I haven't dug into the actual update. However, the way that things like ComFileRW.dll work is by calling into some high-permission module in the HTC firmware (probably a driver using an IOCTL, though it could possibly be an RPC call to a privileged process) which then executes the requested action with high permissions. That's why the HTC DLLs don't do anything on other phones; they can't talk to the component that actually does the work.
My guess is that the HTC update simply turned off whatever it was that the COM DLLs are calling into. It could be more complex than that - for example, they could be trying to validate the caller, and prevent it from being used by homebrew - but whatever they did, neither DLL works anymore once you have the HTC update *even though the DLLs themselves did not change.*
Is it reversible? Well, "fixing" whatever component they were calling into is one option. Using Heathcliff74's Root Tools to gain full permissions on a "normal" homebrew app is another. There might be more, but it would need more study.
Click to expand...
Click to collapse
uhoh... sounds pretty bad for HTC users. If it was a firmware update, we will have a bigger problem. I will try to revert back to Nodo and will try Heathcliffs instructions for Native Code first. InteropUnlock is still something I need to try for Mango
rudelm said:
uhoh... sounds pretty bad for HTC users. If it was a firmware update, we will have a bigger problem. I will try to revert back to Nodo and will try Heathcliffs instructions for Native Code first. InteropUnlock is still something I need to try for Mango
Click to expand...
Click to collapse
No worries. I did some testing with contable and we just got confirmation that my exploits for HTC will still work on HTC Interop Unlocked Mango devices (needs a little adjustment, but No Problem!) Still working on a version of WP7 Root Tools for Samsung/HTC/LG RTM/NoDo/Mango!!
Ciao,
Heathcliff74
A screenshot app is allready there:
TouchXperience for Mango from Schaps.
Atm there is only missing the WPDM Mango update for being able to save the screenshot...
Heathcliff, could you please try to fix that HTC bug first? I am running into this problem with the HTC update and now my old code does not work anymore But at least my phone is finally interop unlocked because I could deploy the app on Mango but I get this error:
COM object with CLSID '{C6BD09B4-96AA-4524-89C4-665A15DD7C9B}' cannot be created due to the following error: The request is not supported. .
Which is one of the errors you mentioned on the first page. So far, so good
rudelm said:
Heathcliff, could you please try to fix that HTC bug first? I am running into this problem with the HTC update and now my old code does not work anymore But at least my phone is finally interop unlocked because I could deploy the app on Mango but I get this error:
COM object with CLSID '{C6BD09B4-96AA-4524-89C4-665A15DD7C9B}' cannot be created due to the following error: The request is not supported. .
Which is one of the errors you mentioned on the first page. So far, so good
Click to expand...
Click to collapse
I don't get what you mean. What HTC bug? What HTC update?
Ok, I will explain it:
There was a HTC Update when I upgraded from Mango B2 Refresh to the Mango RTM from Microsoft. It was followed by a smaller HTC Update. It was called HTC Update for Windows Phone. You can read it here in my blog.
Yesterday, I decided to revert back to NoDo, so that I could Interop Unlock my HD7 before I upgrade to Mango RTM. I did this with these tools and instructions from petbede.
However, ansar found out, that MS changed the update procedure and included the HTC update directly in the 7720.68 update.
Now you mentioned yesterday, that you and contable found a solution to use the HTC DLLs although there was this HTC update on our phones. That was when I already feared that the HTC update will break everything I tried so far.
So I called it the HTC bug, because it breaks my stuff
rudelm said:
Ok, I will explain it:
There was a HTC Update when I upgraded from Mango B2 Refresh to the Mango RTM from Microsoft. It was followed by a smaller HTC Update. It was called HTC Update for Windows Phone. You can read it here in my blog.
Yesterday, I decided to revert back to NoDo, so that I could Interop Unlock my HD7 before I upgrade to Mango RTM. I did this with these tools and instructions from petbede.
However, ansar found out, that MS changed the update procedure and included the HTC update directly in the 7720.68 update.
Now you mentioned yesterday, that you and contable found a solution to use the HTC DLLs although there was this HTC update on our phones. That was when I already feared that the HTC update will break everything I tried so far.
So I called it the HTC bug, because it breaks my stuff
Click to expand...
Click to collapse
I see. Well, I didn't find a solution. I just checked if MY exploit still works. And it does! I don't even know what you use exactly (I assume you use some HTC DLL's, but I don't know which and I don't know which functions). I don't use the HTC DLL's myself. Mainly because I don't want to get copyright issues when releasing WP7 Root Tools. Just look at the current release of WP7 Root Tools. No OEM code in there. So I don't think I can fix that for you.
Ciao,
Heathcliff74
Hm ok, I understand. I was using a HTC dll for changing a registry value (overriding DHCP DNS Server). However, it is interesting to know why the HTC DLLs all of sudden stopped working after this update. The DLLs inside the HTC tools seem to be the same size and should not be changed by the update.
But this shouldn't then influence the DLL made with your instructions in this thread i guess?
@rudelm:
The HTC devices have HSPL support, so why you don´t flash the latest xboxmod rom ? This saves a lot of time and all available types of unlocking can be sent via cab sender.
For writing registry keys or doing file operations you can use DiagProvXML til Heathcliff has finished the next version of WP7 Root Tools.
Is there any other reason why you are updating your phone the official way ?
@rudelm: The HTC DLLs don't actually have elevated permissions by themselves. To do things that an app n ormally lacks permissions for (like accessing the whole filesystem or writing to the registry), it needs to call into a high-permission component (probably a driver or a high-permission process). All HTC had to do to make the registry and filesystem COM DLLs stop working is to change that component so it didn't do what the COM DLLs told it to do.
@contable: I've heard enough reports of things that *should* work on HTC phones not working on the custom ROMs that I'm hesitant to install one. Then there's the risk of bootloader issues. Then there's the lose-all-your-data-because-your-phone-gets-reformatted issue - until I have my backup app working fully, I prefer to avoid the last one in particular.
Edit: If you are looking for working attachments, please look at this posting.
@contable:
I need an unmodified version of WP7 for my master thesis. The other thing is that I don't want to play around with HSPL without having the original SPL or firmware. It's like GoodDayToDie said: I'm still hesitating of the said reasons.
@GoodDayToDie:
The HTC applications still work and they were not updated afaik. So they are using the same DLL files. If there would be some driver running in TCB or ECB and they changed something, then their applications should stop working too. However, they can still be executed without problems. I am not sure what DLLs are used by advancedexplorer, but I think it were also the HTC dlls. My own application which used the HTC dlls stopped also.
@Heathcliff:
I've tried your instructions and found some errors in it:
step 23: *OutpuString = SysAllocString(msg); instead of *OutputString = SysAllocString(msg);
step 25: ; missing after OutputString)
step 28: add \MyApp to path, because VS2010 Solutions always have a subfolder with the same name of the solution
step 36: [return : MarshalAs(UnmanagedType.BSTR)] should be [return : MarshalAs(UnmanagedType.BStr)]
step 37: result 2 needs a type => string result 2 = ...
on first run:
Error 1 Could not load the assembly file:///C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Silverlight\v4.0\Profile\WindowsPhone71\Microsoft.Phone.InteropServices.dll. This assembly may have been downloaded from the Web. If an assembly has been downloaded from the Web, it is flagged by Windows as being a Web file, even if it resides on the local computer. This may prevent it from being used in your project. You can change this designation by changing the file properties. Only unblock assemblies that you trust. See http://go.microsoft.com/fwlink/?LinkId=179545 for more information. NativeTestApp
Click to expand...
Click to collapse
This is because you forgot to register the DLL first. Look here: http://thounsell.co.uk/2010/11/avoi...g-the-interopservices-library-to-the-wp7-sdk/ and then down in the comments:
You must open the visual studio 2010 command prompt as administrator and call:
SN -Vr Microsoft.Phone.InteropServices.dll
then close and reopen Visual Studio, now it should work
Click to expand...
Click to collapse
In addition that, you will have to unblock the file in Windows Explorer, Properties of the file. Otherwise you will get this error in Xaml view:
Could not load file or assembly 'Microsoft.Phone.InteropServices, Version=7.0.0.0, Culture=neutral, PublicKeyToken=24eec0d8c86cda1e' or one of its dependencies. Operation is not supported. (Exception from HRESULT: 0x80131515)
Click to expand...
Click to collapse
This unblock will only work, if you use the Windows Explorer in administrator mode. The DLL file should be copied to a path were every user can access the file. Unblock it there and move it than back to the WindowsPhone71 folder. I've extracted it directly to the WindowsPhone71 folder and I couldn't change its properties there.
I've created a VS2008 and VS2010 sample project on your instructions and tried to add some comments to the sources. I've attached them to this post. Here are a few extra information to my project:
Interface-GUID: D28D8CB9-F8BC-4379-9D0A-FA77C87EF814
coclass-GUID: 7300CD4A-03F4-4569-B2D8-F1515385D46D
COM Class: NativeTestClass
INativeTestClass and CNativeTestClass
Always results in retval 0 and this exception:
System.MethodAccessException was unhandled
Message=Attempt to access the method failed: System.IO.FileInfo..ctor(System.String)
StackTrace:
at Microsoft.Phone.InteropServices.ComBridge.RegisterComDll(String dllFileName, Guid clsid)
at NativeTestApp.MainPage.actionButton_Click(Object sender, RoutedEventArgs e)
at System.Windows.Controls.Primitives.ButtonBase.OnClick()
at System.Windows.Controls.Button.OnClick()
at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
at System.Windows.Controls.Control.OnMouseLeftButtonUp(Control ctrl, EventArgs e)
at MS.Internal.JoltHelper.FireEvent(IntPtr unmanagedObj, IntPtr unmanagedObjArgs, Int32 argsTypeIndex, Int32 actualArgsTypeIndex, String eventName)
Click to expand...
Click to collapse
I've rechecked every step but I am still stuck. The phone itself should be interop unlocked, otherwise I couldn't have deployed the app with the capability activated. Could you please look into it? I know this error from my earlier attempts to access the HTC dll directly, but then I used the NativeLibrary here from XDA which took care of all the GUID things etc.

Huawei E5770 custom firmware & O2 SIM unlock

Custom 21.329.01.00.00 firmware and 17.100.19.01.00 web interface for E5770
The firmware is based on the original global firmware version 21.329.01.00.00. It can be installed on any technological firmware, or updated from a modified firmware.
Flash using balongflash (Windows, Linux).
Attention!
This firmware can render your device unbootable! Use it only if you are aware of all the risks and consequences. In case of any problems, do not wait for help, you're on your own. Do not install firmware by non-tech-savvy people request, and do not sell routers with this firmware preinstalled.
Changes:
Firmware digital signature verification in the firmware server is disabled
Added support for IPv6 on mobile networks (disabled by default, could be activated "ipv6" script)
ADB installed and Telnet activated (disabled by default, controlled from the OLED menu)
The stock versions of busybox, iptables and ip6tables programs are replaced with full-fledged ones
The "atc" utility is installed to send AT commands from the console
Installed "ttl" script for modifying (fixing) TTL (for IPv4) and HL (for IPv6)
Installed "imei" script to change IMEI
A local transparent proxy server "tpws" and a script "anticensorship" are installed to circumvent censorship to sites from the registry of prohibited sites in Russian Federation (IPv4 only)
Added DNS over TLS resolver stubby (version 1.5.1, compiled with OpenSSL 1.0.2p) and DNS-level adblock (IPv4 only)
Added extended menu on OLED screen
Added RNDIS and ECM Ethernet switching functionality without a switch program on a computer
All NVRAM items are unlocked
AT^DATALOCK code is disabled
Added kernel module TUN/TAP (for OpenVPN and other programs)
Added OpenVPN (version 2.4.6, compiled with OpenSSL 1.0.2p) and scripts for DNS redirection
Added curl (version 7.63.0, compiled with OpenSSL 1.0.2p)
Added EXT4 kernel module and swap support
Added script for installing Entware application repository
Added script "adblock_update", for updating the list of advertising domains
Added script to change MAC address of Wi-Fi in Extender mode (script "wifiext_mac") and USB MAC addresses (script "usb_mac")
Removed mobile connection logging (mobile logger) to extend flash memory lifetime
Multilingual web interface with GSM/UMTS/LTE band selection menu
The extended menu on the OLED screen allows you to manage network mode (LTE/3G/GSM), TTL modification, circumvent censorship, ad blocking, IMEI change, USB composition, control access to the web interface, Telnet and ADB.
TTL modification and IMEI change require a reboot. The remaining menu items are applied instantly.
To activate extended menu, press left (WPS) button 7 times on Wi-Fi information screen.
The "anticensorship" script helps to bypass Deep Packet Inspection (DPI) systems on some operators in order to bypass web site blocking. It starts the local proxy server from zapret complex https://github.com/bol-van/zapret, modifying the packets in such a way as to complicate their analysis, and redirects all traffic to ports 80 (for HTTP) and 443 (for HTTPS) to local proxy. The proxy server works autonomously, without any third-party server on the Internet. It is recommended to use it in conjunction with DNS over TLS, in order to prevent possible DNS hijacking by the operator.
Advertisement blocking is performed on DNS level with dnsmasq DNS server. It works with DNS over TLS as upstream, requests for which are redirected if the corresponding menu item is activated from the OLED screen. EasyList and RuAdList https://forums.lanik.us/viewtopic.php?f=102&t=32524 from raletag and AdAway https://adaway.org/hosts.txt are used as an ad lists.
Ad-blocking at the DNS level works worse than full-fledged content blockers in browsers (AdBlock, µBlock), but it works on any device and in any program without additional settings.
You can also control ad blocking with the "dns_over_tls" script.
Domain lists could be updated using "adblock_update" command.
Entware application repository allows you to install additional Linux software from the armv7sf-k3.2 entware repository http://bin.entware.net/armv7sf-k3.2/Packages.html, using "opkg" package manager used in open source firmware for OpenWRT routers. Entware is installed using the "entware install" command. Entware files are installed in /opt, which is mounted in /online/opt. You can install many programs on 30 MB free space after installation on /online partition.
The router and Entware environments are independent of each other, the installed Entware software cannot be called from the router's environment, and the firmware programs and scripts cannot be called from the Entware. This was done to ensure that the installed packages would not conflict with files in the firmware.
To gain access to the Entware environment, use the "entware shell" command, to exit, type exit (or press CTRL+D).
Entware is designed for advanced users who understand how to customize and use installable programs. About 15 MB of free RAM is available in the router, the launch of heavy programs can lead to the crash of important services for the router (especially when DNS over TLS is enabled), remember that.
Download link
https://github.com/Huawei-LTE-routers-mods/Huawei_E5770_mod_fw_webui
More information about Huawei LTE routers (zeronet network): https://zn.amorgan.xyz/1HegcCNqxTuhPaHmjZwPGZ9LY34vXD6H1V/
E5770 O2 FW version 21.200.19.01.405 SIM unlock
Huawei E5770 from British O2 network with firmware version 21.200.19.01.405 could be unlocked for free with a special firmware, without disassembling the device.
This firmware is based on 21.200.19.01.405 version and could be installed without flash code.
E5770s_Update_21.200.19.01.405_o2_simunlock_signed.7z
If you want to install another official firmware or a custom firmware, you need to downgrade 21.200.19.01.405 to a special technological firmware version 21.180.99.10.00, which does not check firmware digital signatures.
E5770s_DOWNGRADE_o2_21.200.19.01.405_to_21.180.99.10.00_signed.7z
To install the firmware, press both RESET button (on the back of the device) and POWER button, connect it to the PC and use balongflash software (Windows, Linux)
More information about Huawei LTE routers (zeronet network): https://zn.amorgan.xyz/1HegcCNqxTuhPaHmjZwPGZ9LY34vXD6H1V/
Thabks for the share. Is it possible to unlock all bands to use it anywhere in the globe?
link not working
Hi I tried downloading the modded firmware but it only goes to 20% every time then hangs. can you fix please or host somewhere else.
many thanks
abiliotiago said:
Thabks for the share. Is it possible to unlock all bands to use it anywhere in the globe?
Click to expand...
Click to collapse
No, that's a hardware limitation. Different hardware modifications have different radio hardware. They could be converted by soldering some components though.
paybelb said:
Hi I tried downloading the modded firmware but it only goes to 20% every time then hangs. can you fix please or host somewhere else.
many thanks
Click to expand...
Click to collapse
You can download ZeroNet and download it from there, because ZeroNet to Internet gateways are unreliable.
E5770 FW version 21.327.01.00.1133, 21.200.19.01.405, 21.318.01.02.07 downgrade to technological 21.180.99.10.00
This special firmware allows installing technological firmware on firmware versions mentioned in the title, without entering OEM code (AT^DATALOCK), and without using test-point (needle method).
Technological firmware allows installing any other firmware (even with incorrect or corrupted signature), without any restrictions.
WARNING: If you flash this firmware, you won't be able to revert your old firmware version because there's no official firmware files of these version available in public access. You can install any other firmware though.
→ E5770s_DOWNGRADE_21.318.01.02.07_to_21.180.99.10.00 ←
→ E5770s_DOWNGRADE_21.327.01.00.1133_to_21.180.99.10.00 ←
→ E5770s_DOWNGRADE_21.200.19.01.405_to_21.180.99.10.00 ←
More information about Huawei LTE routers (zeronet network): https://zn.amorgan.xyz/1HegcCNqxTuhPaHmjZwPGZ9LY34vXD6H1V/
ValdikSS said:
No, that's a hardware limitation. Different hardware modifications have different radio hardware. They could be converted by soldering some components though.
Click to expand...
Click to collapse
Thanks for the explanation.
Which router do you recommend for the most compatibility LTE worldwide?
abiliotiago said:
Thanks for the explanation.
Which router do you recommend for the most compatibility LTE worldwide?
Click to expand...
Click to collapse
Probably something with Qualcomm chipset, which I'm not savvy in.
It depends on LTE bands or countries you're planning to use the device.
ValdikSS said:
Probably something with Qualcomm chipset, which I'm not savvy in.
It depends on LTE bands or countries you're planning to use the device.
Click to expand...
Click to collapse
Not sure right now
I just wanted something that could work for holidays wherever I decided to go
Thanks
unfortunatly balong_flash doesn't seem to work on windows 10
zebignasty said:
unfortunatly balong_flash doesn't seem to work on windows 10
Click to expand...
Click to collapse
worked fine for me on Windows 10 Pro
Version 2.3.1. Based on firmware 21.329.01.00.00 and webui 17.100.19.01.00
Changes since v2.3:
Firmware:
* Fix passwd_def telnet default password file
* Fix OpenVPN NAT scripts: properly remove added FORWARDING and INPUT DROP rules, clarify README
* Clarify net.{down,up} scripts
There are more than one variant of E5770.
Will this firmware work on E5770S-923 model?
BarakOsama said:
There are more than one variant of E5770.
Will this firmware work on E5770S-923 model?
Click to expand...
Click to collapse
Yes it will.
Hi OP,
my device is stuck on download mode.
can you please explain the flashing steps for the custom firmware.
As per your Read-Me the firmware should be flashed by balong_flash FLASH_FILE.BIN command.
Whats unclear to me is which file is to be flashed first. There are 2 .bin files in the custom firmware archive.
It will be a great help if you can give a step-by-step guide.
BarakOsama said:
Hi OP,
my device is stuck on download mode.
Click to expand...
Click to collapse
First of all, to install custom firmware you need to install technological firmware somehow. You can't install it just by flashing, it will require flash code which cannot be obtained easily. To bypass flash code check, I made downgrading firmwares for several firmware versions. You need to install downgrading firmware for your current firmware version, which will downgrade to technological firmware, and from technological firmware you can install any firmware, including custom one.
What exact steps did you perform, what exact result did you get?
ValdikSS said:
First of all, to install custom firmware you need to install technological firmware somehow. You can't install it just by flashing, it will require flash code which cannot be obtained easily. To bypass flash code check, I made downgrading firmwares for several firmware versions. You need to install downgrading firmware for your current firmware version, which will downgrade to technological firmware, and from technological firmware you can install any firmware, including custom one.
What exact steps did you perform, what exact result did you get?
Click to expand...
Click to collapse
After two days of googling I found the original firmware I had on the device and now the device is working again :victory:
Can you provide me a downgrading firmware to E5770s-923 21.316.03.00.1133 firmware version?.
E5770s_UPDATE_21.316.03.00.1133_WEBUI_17.100.13.02.1133_MRE5.zip
I flashed the custom firmware.
But somehow I cannot access the extended menu.
Software version: 21.329.01.00.00
Web UI version: 17.100.19.01.00
BarakOsama said:
I flashed the custom firmware.
But somehow I cannot access the extended menu.
Software version: 21.329.01.00.00
Web UI version: 17.100.19.01.00
Click to expand...
Click to collapse
You need to press left button 7 times on the wi-fi information screen.

HTC u12+ VOLTE activation method in non-released countries

Hello, I am a Korean user who likes htc very much. I have shared how to activate tta-volte volte to the developer of gsi Viper, who develops a lot for htc products, although my English is not good enough, and I'll give you some information now.
It has been 10 years since HTC already closed its business in Korea, so there is no Korean telecommunications company or supplier file, and it does not sell. It's sad. Anyway, let me explain. Originally, HTC products were not allowed to open Qualcomm ports, but only U12+ can open Qualcomm ports
(adb shell - su - setprop sys.usb.config rndis,diag,adb)
Volte in Korea is an independent tta-volte method, so I have the same Qualcomm Snapdragon 845 and I extracted efs files and mbn from Sony Xperia xz2 Korean version firmware, which was officially released in Korea, and pasted them using Qualcomm epsproler.
If the communication company you are using has its own standard like Korea, you can replace the efs file in the same way as I do, and if that doesn't matter, please read the following immediately.
Note the HTC system folder. There is a secret in the system custom folder. First, if you look at customize - MNS folder, it's a number.I see xml. There is a secret in that number. The number is the carrier code. It's very simple. I found this. It was such a pleasure. Please correct the xml title. For example, it is 45008 because it is KT(koreatelecom) mcc:450 mnc:08 You can check the carrier's mcc, mnc(apn) and modify it to 45008.xml and if you look in the custom folder, there is mns_map.xml. Edit the file as text If you enter the 45008th place you changed earlier and reboot, you will be able to create a volte active menu on the existing phone app setup screen.
This is all, simple. When you add an xml (app:mcc+mnc) title in the mns folder, write and save the number that was just added in the custom folder-mns_map_xml text editor, and reboot, the htc phone app settings show the volte activation menu, and there are no other changes to the build-prop In the case of Korea, it was necessary to modify the efs file because it is volte in a nonstandard way.
Modifying directly to root file editor without module It's very simple. My last hope is that volte is possible at gsi and that htc will continue to announce new flagships and that htc users are all healthy, thank you.
*To you in Seoul*
htcmage said:
Hello, I am a Korean user who likes htc very much. I have shared how to activate tta-volte volte to the developer of gsi Viper, who develops a lot for htc products, although my English is not good enough, and I'll give you some information now.
It has been 10 years since HTC already closed its business in Korea, so there is no Korean telecommunications company or supplier file, and it does not sell. It's sad. Anyway, let me explain. Originally, HTC products were not allowed to open Qualcomm ports, but only U12+ can open Qualcomm ports
(adb shell - su - setprop sys.usb.config rndis,diag,adb)
Volte in Korea is an independent tta-volte method, so I have the same Qualcomm Snapdragon 845 and I extracted efs files and mbn from Sony Xperia xz2 Korean version firmware, which was officially released in Korea, and pasted them using Qualcomm epsproler.
If the communication company you are using has its own standard like Korea, you can replace the efs file in the same way as I do, and if that doesn't matter, please read the following immediately.
Note the HTC system folder. There is a secret in the system custom folder. First, if you look at customize - MNS folder, it's a number.I see xml. There is a secret in that number. The number is the carrier code. It's very simple. I found this. It was such a pleasure. Please correct the xml title. For example, it is 45008 because it is KT(koreatelecom) mcc:450 mnc:08 You can check the carrier's mcc, mnc(apn) and modify it to 45008.xml and if you look in the custom folder, there is mns_map.xml. Edit the file as text If you enter the 45008th place you changed earlier and reboot, you will be able to create a volte active menu on the existing phone app setup screen.
This is all, simple. When you add an xml (app:mcc+mnc) title in the mns folder, write and save the number that was just added in the custom folder-mns_map_xml text editor, and reboot, the htc phone app settings show the volte activation menu, and there are no other changes to the build-prop In the case of Korea, it was necessary to modify the efs file because it is volte in a nonstandard way.
Modifying directly to root file editor without module It's very simple. My last hope is that volte is possible at gsi and that htc will continue to announce new flagships and that htc users are all healthy, thank you.
*To you in Seoul*
Click to expand...
Click to collapse
What is the firmware version for your phone, can you support your explanation by images?
htcmage said:
Hello, I am a Korean user who likes htc very much. I have shared how to activate tta-volte volte to the developer of gsi Viper, who develops a lot for htc products, although my English is not good enough, and I'll give you some information now.
It has been 10 years since HTC already closed its business in Korea, so there is no Korean telecommunications company or supplier file, and it does not sell. It's sad. Anyway, let me explain. Originally, HTC products were not allowed to open Qualcomm ports, but only U12+ can open Qualcomm ports
(adb shell - su - setprop sys.usb.config rndis,diag,adb)
Volte in Korea is an independent tta-volte method, so I have the same Qualcomm Snapdragon 845 and I extracted efs files and mbn from Sony Xperia xz2 Korean version firmware, which was officially released in Korea, and pasted them using Qualcomm epsproler.
If the communication company you are using has its own standard like Korea, you can replace the efs file in the same way as I do, and if that doesn't matter, please read the following immediately.
Note the HTC system folder. There is a secret in the system custom folder. First, if you look at customize - MNS folder, it's a number.I see xml. There is a secret in that number. The number is the carrier code. It's very simple. I found this. It was such a pleasure. Please correct the xml title. For example, it is 45008 because it is KT(koreatelecom) mcc:450 mnc:08 You can check the carrier's mcc, mnc(apn) and modify it to 45008.xml and if you look in the custom folder, there is mns_map.xml. Edit the file as text If you enter the 45008th place you changed earlier and reboot, you will be able to create a volte active menu on the existing phone app setup screen.
This is all, simple. When you add an xml (app:mcc+mnc) title in the mns folder, write and save the number that was just added in the custom folder-mns_map_xml text editor, and reboot, the htc phone app settings show the volte activation menu, and there are no other changes to the build-prop In the case of Korea, it was necessary to modify the efs file because it is volte in a nonstandard way.
Modifying directly to root file editor without module It's very simple. My last hope is that volte is possible at gsi and that htc will continue to announce new flagships and that htc users are all healthy, thank you.
*To you in Seoul*
Click to expand...
Click to collapse
Dear htcmage,
Can you post the detailed step by step on how to do this?
Regards,
Brian

Question Engineermode Decryption *#*#5646#*#*

If you own a oneplus phone and have no clue what this is or does ,then do some research first. In my time reversing all of oneplus in general i have made a lil tool that will generate the code for this on the device. If you cant get into diag mode or into *#36446337# then this will decrypt and enable it for 10 min. I still need some phones to test on. Also i have a one line command that will disable it totally but needs root shell.
here is v1.2
One+_TooL.exe | by Ju5t3nc4s3 for OnePlus 7 Pro
Download GApps, Roms, Kernels, Themes, Firmware, and more. Free file hosting for all Android developers.
www.androidfilehost.com
lots added ,and without password
this tool will give you your code without giving up your imei on the internet. i have done all this just with adb shell commands, so know worries. also there is alot of extra tools added to it.
justencase6 said:
If you own a oneplus phone and have no clue what this is or does ,then do some research first. In my time reversing all of oneplus in general i have made a lil tool that will generate the code for this on the device. If you cant get into diag mode or into *#36446337# then this will decrypt and enable it for 10 min. I still need some phones to test on. Also i have a one line command that will disable it totally but needs root shell.
Click to expand...
Click to collapse
What exactly do you want tested? I'm familiar with dialer codes, but I'm not sure what you're looking to find or fix.
Need to see if the script I wrote will work with other OnePlus devices. Does *#36446337# do anything.
justencase6 said:
Need to see if the script I wrote will work with other OnePlus devices. Does *#36446337# do anything.
Click to expand...
Click to collapse
It doesn't appear to do anything.
Then that means engineermode is encrypted. And my script will enable this
.
I tried it on my op9pro a barcode scanner appeared
Mangtas_666 said:
I tried it on my op9pro a barcode scanner appeared
Click to expand...
Click to collapse
The scanner will come up, I can generate the QR code, to decrypt, but I'm working on a script that will do it on the device
No, its not encrypted just download this and it will work normally.
EngineerMode V1.01.0.171117173719.25c8842 APK Download by OnePlus Ltd. - APKMirror
EngineerMode V1.01.0.171117173719.25c8842 APK Download by OnePlus Ltd. - APKMirror Free and safe Android APK downloads
www.apkmirror.com
I use it to edit the efs folder.
I found permanent unlock code generation method, so I created website to generate it.
It looks like QR code scan is just for checking code...
OnePlus Unlock Code Generator
Convert your IMEI to OnePlus FactryMode (EngineeringMode) unlock code.
one.andro.plus
Question what is engineering mode used for?
terlynn4 said:
What exactly do you want tested? I'm familiar with dialer codes, but I'm not sure what you're looking to find or fix.
Click to expand...
Click to collapse
I haven't tried this variant: OnePlus 9 Pro LE2125 | 11.2.9.9 BA | Magisk v23.0 | Omega Kernel
How is it on heavy use?
AndroPlus said:
I found permanent unlock code generation method, so I created website to generate it.
It looks like QR code scan is just for checking code...
OnePlus Unlock Code Generator
Convert your IMEI to OnePlus FactryMode (EngineeringMode) unlock code.
one.andro.plus
Click to expand...
Click to collapse
The code looks like the serial number ?
Steve0007 said:
The code looks like the serial number ?
Click to expand...
Click to collapse
Yes, but it uses password + IMEI to generate so doesn't match with android's serial number
AndroPlus said:
Yes, but it uses password + IMEI to generate so doesn't match with android's serial number
Click to expand...
Click to collapse
Seems to match with the serial number shown on the fastboot first screen.
@AndroPlus
Looking at your mbn module, it replaces some config modem files only for APAC Region.
Could you update for EU and US also ?
Does it improve any data speed as far as you know?
Steve0007 said:
Seems to match with the serial number shown on the fastboot first screen.
Click to expand...
Click to collapse
Didn't match on my device.
Steve0007 said:
@AndroPlus
Looking at your mbn module, it replaces some config modem files only for APAC Region.
Could you update for EU and US also ?
Does it improve any data speed as far as you know?
Click to expand...
Click to collapse
I can't maintain other region's one, please extract mbn from other model's modem.img (can open with 7zip) and put them in the module.
My module has two method to enable VoLTE so most carriers work without mbn.
It doesn't improve speed from my testing.
I created another code generator.
Features:
Pure JavaScript implementation
QR code generation
10 minutes only code (On OnePlus 7T, this is needed) generation
https://jsfiddle.net/nvsofts/vpuqfwhx/
Result only (for mobile devices): https://jsfiddle.net/nvsofts/vpuqfwhx/show
AndroPlus said:
I found permanent unlock code generation method, so I created website to generate it.
It looks like QR code scan is just for checking code...
OnePlus Unlock Code Generator
Convert your IMEI to OnePlus FactryMode (EngineeringMode) unlock code.
one.andro.plus
Click to expand...
Click to collapse
Hi is there an issue with the web site? Running on the desktop, and on the device, same result, no output.
Thank you
gregpilot said:
Hi is there an issue with the web site? Running on the desktop, and on the device, same result, no output.
Thank you
Click to expand...
Click to collapse
On my side it works normally... You can use nvsofts' one since results are same

Question editing a file /priv-app/imsservice/imsservice.apk for adding a profile IMS For VoLTE

some background,
I am after thorough tests on the topic of how it works VoLTE and VoWiFi And what causes it to be activated in some providers and in some not.
The source from which I drew all a lot of information was: https://volteromania.blogspot.com/p/samsung-voltevowifi-settings.html?m=1
Actually, I followed all the steps but got stuck on the most important part.
In order to start communication for VoLTE It is necessary to define a profile IMS.
Samsung chose - unlike APN Not to allow any user to create such a profile, but the profiles are inside files json in the file /system/priv-app/imsservice/imsservice.apk
I am very interested in trying to edit the files json These, but all my attempts were unsuccessful.
I have a Samsung S21 ultra Rooted, on which I perform the tests.
I can't edit the APK without hurting him. Any change in it causes the application not to load - and completely disables the service IMS and the registration.
The files I want to edit are in
/priv-app/imsservice/imsservice.apk/res/raw
It's files json simple.
Maybe someone can help me?
im curruntly trying to enable Volte on Samsung SM-N920L korean phone in defferent region..no luck..im rooting for you..if any succuss please let we know too..
I gave up.
This is Samsung's behavior on purpose to make consumers have to replace the phones.
Anyway, in the technical part,
In Android 13, in my opinion, this is not completely possible, since every change in the application damages the signature, but even in older versions it is necessary to change the Java code as well, And as you know it is compiled.
I spent many hours on this, with several devices, I purchased a Galaxy 7 for the tests, and I failed.
I do not know if this still works, but on my SM-9700 (HK) with Android 10 I made VoLTE work in Germany by copying the "product/omc/DBT/conf" from a SM-970F to the corresponding TGY directory of the SM-9700.
I was able to run volte on the galaxy s7.
It requires a lot of changes.
Including in the smali files of the application imsservice.apk and it was a nightmare.
In my case I had to add a brand new provider that didn't appear anywhere, maybe that's why everything was complicated and maybe if it's a defined operator and just enabling the option is simpler.
Anyway,
It really wasn't easy, but I had most of the information from the first post I wrote, but I was also able to find a lot on my own.
It is not easy.
Maybe Samsung will release the source code (including java) of the imsservice.apk application and then it will be easier..
Have you ever tried just copying the content of the conf directory from another phone?
This made VoLTE work on my Hong Kong Note10 (Snapdragon) in Germany.
ZXR said:
Have you ever tried just copying the content of the conf directory from another phone?
This made VoLTE work on my Hong Kong Note10 (Snapdragon) in Germany.
Click to expand...
Click to collapse
I have nowhere to copy. I don't have a phone that works with the same carrier I wanted to test. I had to write all the settings myself.
Which carrier do you need? We (the forum) might copy it for you.
shmuel0990 said:
I was able to run volte on the galaxy s7.
It requires a lot of changes.
Including in the smali files of the application imsservice.apk and it was a nightmare.
In my case I had to add a brand new provider that didn't appear anywhere, maybe that's why everything was complicated and maybe if it's a defined operator and just enabling the option is simpler.
Anyway,
It really wasn't easy, but I had most of the information from the first post I wrote, but I was also able to find a lot on my own.
It is not easy.
Maybe Samsung will release the source code (including java) of the imsservice.apk application and then it will be easier..
Click to expand...
Click to collapse
Can you please share knowlage with us..im tring for days now..i tried with csc options..added everything in customer.xml ,others.xml
i read the files inside immservice app..there are lines for my carrier.. cant understand what to add..by the way using a activity manager.. i opened a ims settings page..
Is there something i can change for carrier? Photo attached
prasadmanjulago said:
Can you please share knowlage with us..im tring for days now..i tried with csc options..added everything in customer.xml ,others.xml
i read the files inside immservice app..there are lines for my carrier.. cant understand what to add..by the way using a activity manager.. i opened a ims settings page..
Is there something i can change for carrier? Photo attached
Click to expand...
Click to collapse
t what phone is this
I tried Galaxy S7, Android 8.
I don't think the solution I came up with is suitable for every device.
shmuel0990 said:
t what phone is this
I tried Galaxy S7, Android 8.
I don't think the solution I came up with is suitable for every device.
Click to expand...
Click to collapse
thanks. i succeeded yesterday...i didnt edit imsservice.apk
i found enforceskippingpackages.xml file in system/csc_contents folder
in the only couple of lines
imsservices.apk
imslogger.apk
imssettings.apk etc
i removed those ims lines.. then volte worked.. i already added enable volte lines on csc/others.xml and customer.xml before.
i didnt edit anything on the attached screenshot i sent on above reply
thanks,,,
prasadmanjulago said:
thanks. i succeeded yesterday...i didnt edit imsservice.apk
i found enforceskippingpackages.xml file in system/csc_contents folder
in the only couple of lines
imsservices.apk
imslogger.apk
imssettings.apk etc
i removed those ims lines.. then volte worked.. i already added enable volte lines on csc/others.xml and customer.xml before.
i didnt edit anything on the attached screenshot i sent on above reply
thanks,,,
Click to expand...
Click to collapse
Hello, I don't know how it made to work for you. I have the same problem but the ims lines are already no longer present in the enforceskippingpackages.xml file and the volte does not work...
thib66 said:
Hello, I don't know how it made to work for you. I have the same problem but the ims lines are already no longer present in the enforceskippingpackages.xml file and the volte does not work...
Click to expand...
Click to collapse
i already made some changes to others.xml and customer.xml file also..What country are you? Send me telegram or whatsapp no..ill send my files and figure whays wrong
shmuel0990 said:
t what phone is this
I tried Galaxy S7, Android 8.
I don't think the solution I came up with is suitable for every device.
Click to expand...
Click to collapse
I have an S7 and I need to do exactly what you did - add a brand new provider. Can you share more precise details on how you did it?
prasadmanjulago said:
thanks. i succeeded yesterday...i didnt edit imsservice.apk
i found enforceskippingpackages.xml file in system/csc_contents folder
in the only couple of lines
imsservices.apk
imslogger.apk
imssettings.apk etc
i removed those ims lines.. then volte worked.. i already added enable volte lines on csc/others.xml and customer.xml before.
i didnt edit anything on the attached screenshot i sent on above reply
thanks,,,
Click to expand...
Click to collapse
Hi,
I would like to have your guidance
I have a LG v60 L-51a docomo model where field test option (hidden menu ) is disabled.
I am unable to enable volte in India to use jio.
Searched various options seems no way out. However i was able to locate hidden apps by using 3party launcher app. LG ims. But unable to launch hidden menu to changed ims settings. Help me to by pass this application to enable volte.
I don't know if this will help anyone, or if anyone can help me, but...
SM910v, (verizon wireless) with T-Mobile SIM
6.01 Marshmallow (please read the rest anyway)
4G/LTE Data works.
Voice calls fall back to 2G/Edge, ie no VoLTE.
-------- HOWEVER -------
Changing the sales_code.dat from VZW to TMO enables VoLTE, and it works great.
(it breaks the settings pages, though, so it's not a solution)
When sales_code is VZW, then IMS Settings-->IMS Information:
All are "false", Registration Information is "no profile is registered", although the profile "T-Mobile VoLTE/RCS" is available and status is 'on' in the Manage IMS Profiles page.
I can not find a way to 'register' it.
When sales_code is TMB,
then, in IMS Settings-->IMS Information:
All are "true", Registration Information is "T-Mobile VoLTE/RCS",
And, of course, VoLTE works great.
I mention this in this thread because just having the correct profile present & available may not be enough. At least in my case, it appears that the sales_code (or some other CSC function) flips a flag somewhere that allows the profile to become selected/active. I've been trying to find it for six weeks, with no luck yet. Thanks for reading.

Categories

Resources