Could somebody explain the syntax of the ipdialplan.xml, and how to modify it.
I've got the problem, that I can't use my contacts when my phone (Artemis)
is in SIP Mode. My numbers are stored in following format, e.g. for Germany, Hamburg: +49(40)1234567. I've to enter the number manually as 0049401234567 or 040123456 without '+' or '()'.
..........
ipdialplan.xml creating and managing
Dial Plan Regular Expression Engine - Language Summary,
see : http://msdn2.microsoft.com/en-us/library/aa921921.aspx
DialPlan Component ,
see : http://msdn2.microsoft.com/en-us/library/aa921954.aspx
Nice to test your regular expression, if you need to create new one,
see : http://www.roblocher.com/technotes/regexp.aspx
Very important to know : the last matched rule is the selected one, so be careful if a rule can match more than one pattern. It has to be first.
Here is my ipdialplan.xml
Notice :
- With Swiss rule you don't need to dial 00 + international code before the number you want. At least, you have to change 41 by your international code
- Internation rule should be good for anybody beginning his number with 00 (00 41 (12) 345 67 89) or with + (+41 12 345 67 89)
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<!-- IP address rules -->
<rule pattern='\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}'
restrict='Cell,SMS'
/>
<rule pattern='(\d{1,3})\*(\d{1,3})\*(\d{1,3})\*(\d{1,3})'
dial='\1.\2.\3.\4'
display='\1.\2.\3.\4'
transfer='\1.\2.\3.\4'
restrict='Cell,SMS'
/>
<!-- SIP URI rules -->
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*(\d{3})(\d{3})(\d{4})@(.+)'
display='(\1) \2-\3'
restrict='Cell,SMS'
/>
<rule pattern='([Ss][Ii][Pp][Ss]??\s*([a-zA-Z0-9_-]+)@(.+)'
display='\2'
restrict='Cell,SMS'
/>
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*([^@]+)'
display='\1'
restrict='Cell,SMS'
/>
<!-- As the last matched rule is the selected one, Swiss rule has to be first, as it matches also 00...
numbers -->
<!-- Swiss rule -->
<rule pattern='0([1-9])(\d{8})'
dial='sip:0041\1\[email protected]$host$'
display='0\1\2'
transfer='sip:0041\1\[email protected]$host$'
/>
<!-- International rules -->
<rule pattern='\+\D*(\d+)\D*(\d+)\D*(\d*)\D*(\d*)\D*(\d*)\D*(\d*)'
dial='sip:00\1\2\3\4\5\[email protected]$host$'
display='+\1\2\3\4\5\6'
transfer='sip:00\1\2\3\4\5\[email protected]$host$'
/>
<rule pattern='(0{2})\D*(\d+)\D*(\d+)\D*(\d*)\D*(\d*)\D*(\d*)\D*(\d*)'
dial='sip:\1\2\3\4\5\6\[email protected]$host$'
display='\1\2\3\4\5\6\7'
transfer='sip:\1\2\3\4\5\6\[email protected]$host$'
/>
</dialplan>
I'm having a hard time with the syntax as well. I am able to receive voip calls but get an error when making them. I'm sure it has to do with the ipdialplan.xml.
I need for numbers I dial to be passed to SIP directly..ie 17025551212 will dial 17025551212 without changing it. Also it would be nice to have the + translated to 011 for SIP dialing...
Here is my current file, any help would be greatly appreciated.
Code:
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<!-- IP address rules -->
<rule pattern='\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}'
restrict='SMS'
/>
<rule pattern='(\d{1,3})\*(\d{1,3})\*(\d{1,3})\*(\d{1,3})'
dial='\1.\2.\3.\4'
display='\1.\2.\3.\4'
transfer='\1.\2.\3.\4'
restrict='SMS'
/>
<!-- 11-digits rules -->
<rule pattern='1\s*-?\s*(\d{3})\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:1\1\2\[email protected]$host$'
/>
<rule pattern='1\s*-?\s*\((\d{3})\)\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:1\1\2\[email protected]$host$'
/>
<rule pattern='\+\s*1\s*-?\s*(\d{3})\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:1\1\2\[email protected]$host$'
/>
<rule pattern='\+\s*1\s*-?\s*\((\d{3})\)\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:1\1\2\[email protected]$host$'
/>
<!-- 10-digits rules -->
<rule pattern='(\d{3})\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:\1\2\[email protected]$host$'
/>
<rule pattern='\((\d{3})\)\s*(\d{3})\s*-?\s*(\d{4})(\s*[Xx]\s*\d+)?'
dial='sip:\1\2\[email protected]$host$'
display='(\1) \2-\3'
transfer='sip:\1\2\[email protected]$host$'
/>
<!-- 7-digits rules -->
<rule pattern='(\d{3})\s*-?\s*(\d{4})'
dial='sip:262\1\[email protected]$host$'
display='\1-\2'
transfer='sip:262\1\[email protected]$host$'
/>
<!-- SIP URI rules -->
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*(\d{3})(\d{3})(\d{4})@(.+)'
display='(\1) \2-\3'
restrict='SMS'
/>
<rule pattern='([Ss][Ii][Pp][Ss]?:)?\s*([a-zA-Z0-9_-]+)@(.+)'
display='\2'
restrict='SMS'
/>
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*([^@]+)'
display='\1'
restrict='SMS'
/>
<!-- 5-digits rules -->
<rule pattern='(\d{3})-?(\d{2})'
dial='sip:\1\[email protected]$host$'
display='\1\2'
transfer='sip:\1\[email protected]$host$'
/>
<rule pattern='1\s*\((\d{3})\)\s*(\d)'
dial='sip:1\1\[email protected]$host$'
display='1\1\2'
transfer='sip:1\1\[email protected]$host$'
/>
<!-- Only digits -->
<rule pattern='(\d+)'
dial='sip:\[email protected]$host$'
display='\1'
transfer='sip:\[email protected]$host$'
/>
</dialplan>
is it possible through dial plain to remove +39 prefix from the number dialed and replace it with 0?
All my contacts are like this
+39 02 7458412
and it should became
0 02 7458412
Is it possible?
Remove +39 (or any) prefix
alex_time said:
is it possible through dial plain to remove +39 prefix from the number dialed and replace it with 0?
All my contacts are like this
+39 02 7458412
and it should became
0 02 7458412
Is it possible?
Click to expand...
Click to collapse
As you have spaces between numbers' group, this rule will fit your need :
<rule pattern='\+\D*(\d+)\D*(\d+)\D*(\d*)\D*(\d*)\D*(\d* )\D*(\d*)'
dial='sip:0\2\3\4\5\[email protected]$host$'
display='0\2\3\4\5\6'
transfer='sip:0\2\3\4\5\[email protected]$host$'
/>
To pass dialed number directly to SIP
Jayman007 said:
I'm having a hard time with the syntax as well. I am able to receive voip calls but get an error when making them. I'm sure it has to do with the ipdialplan.xml.
Click to expand...
Click to collapse
Unfortunately, yes...
I need for numbers I dial to be passed to SIP directly..ie 17025551212 will dial 17025551212 without changing it.
Click to expand...
Click to collapse
So you have to make your ipdialplan.xml simpler. This one will be enough (only if you don't have space or non-digit):
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<rule pattern='(\d*)'
dial='sip:\[email protected]$host$'
display='\1'
transfer='sip:\[email protected]$host$'
/>
</dialplan>
Also it would be nice to have the + translated to 011 for SIP dialing...
Click to expand...
Click to collapse
Troubles are beginning...
Each way to dial a number as to be fitted by a specific rule (examples: if you want to use spaces, or dots, or parenthesis...)
If your numbers have to be passed directly, except if they have the +, you should try :
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<rule pattern='(\d*)'
dial='sip:\[email protected]$host$'
display='\1'
transfer='sip:\[email protected]$host$'
/>
<rule pattern='\+(\d*)'
dial='sip:011\[email protected]$host$'
display='011 \1'
transfer='sip:011\[email protected]$host$'
/>
</dialplan>
chrcha said:
As you have spaces between numbers' group, this rule will fit your need :
<rule pattern='\+\D*(\d+)\D*(\d+)\D*(\d*)\D*(\d*)\D*(\d* )\D*(\d*)'
dial='sip:0\2\3\4\5\[email protected]$host$'
display='0\2\3\4\5\6'
transfer='sip:0\2\3\4\5\[email protected]$host$'
/>
Click to expand...
Click to collapse
Thank, I will try
chrcha said:
Unfortunately, yes...
So you have to make your ipdialplan.xml simpler. This one will be enough (only if you don't have space or non-digit):
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<rule pattern='(\d*)'
dial='sip:\[email protected]$host$'
display='\1'
transfer='sip:\[email protected]$host$'
/>
</dialplan>
Troubles are beginning...
Each way to dial a number as to be fitted by a specific rule (examples: if you want to use spaces, or dots, or parenthesis...)
If your numbers have to be passed directly, except if they have the +, you should try :
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<rule pattern='(\d*)'
dial='sip:\[email protected]$host$'
display='\1'
transfer='sip:\[email protected]$host$'
/>
<rule pattern='\+(\d*)'
dial='sip:011\[email protected]$host$'
display='011 \1'
transfer='sip:011\[email protected]$host$'
/>
</dialplan>
Click to expand...
Click to collapse
I tried the above configs but still cannot place a call. Not sure why but keep getting network unavailable message when I dial.
Hopefully one day I will figure this out and be able to place calls via VOIP on my phone.
Is there any possibility to dial Jabber contacts? I.e. to call [email protected] from WM6?
I will give $30 by PayPal to anyone who can create a Dial Plan Wizard app for the WM6 devices including the Kaiser, which allows you to specify in simple fields what to dial when, and also crucially to ignore text characters after a number (e.g. +44 20 7841 1234 - Sales).
Anyone care to join me and start a fund to get such an app created? Please reply at the specific thread for this idea here: http://forum.xda-developers.com/showthread.php?p=1769969#post1769969
Trying to develop a dialplan, I found that my HTC TyTN as well as my HP ipaq 514 deletes blanks (spaces) from a phonebook entry before it is subjected to the dialplan ruling. That means that any spaces cannot be used to identify a rule. i.e. 0031 20 ... cannot be caught by requiring a space between the country code and the rest of the number.
Anyone aware of this an/or any registry setting that prevents this blank deletion? It a kind of degrades the power of dialing rules.
I tested this with the following dialplan, after not understanding why a certain rule did not catch a number on my iPAQ514.
So a phonebook entry of 0031 20 123 4567 will display 0031201234567 through the following dialplan that only catches all characters
Code:
<wap-provisioningdoc>
<characteristic type="VoIP">
<parm name="DialPlan"
value="<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<!-- IP address rules -->
<!-- all characters -->
<rule pattern='(.*)'
dial='sip:\[email protected]$host$'
display='todial:\1'
transfer='sip:\[email protected]$host$'
/>
</dialplan> " />
</characteristic>
</wap-provisioningdoc>
chrcha said:
Dial Plan Regular Expression Engine - Language Summary,
see : http://msdn2.microsoft.com/en-us/library/aa921921.aspx
DialPlan Component ,
see : http://msdn2.microsoft.com/en-us/library/aa921954.aspx
Nice to test your regular expression, if you need to create new one,
see : http://www.roblocher.com/technotes/regexp.aspx
Very important to know : the last matched rule is the selected one, so be careful if a rule can match more than one pattern. It has to be first.
[............]
</dialplan>
Click to expand...
Click to collapse
Thanks, that testing site is very handy. About the first/last issue: Though read everywhere I found that WM6 takes the first match, not the last match. I tested that with the following plan. Try a 00 number and it dispalys First:number.
Code:
<wap-provisioningdoc>
<characteristic type="VoIP">
<parm name="DialPlan"
value="<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Dial Plan rules -->
<!-- IP address rules -->
<!-- Only digits -->
<rule pattern='00(.*)'
dial='sip:00\[email protected]$host$'
display='FIRST: 00\1'
transfer='sip:00\[email protected]$host$'
/>
<rule pattern='00(.*)'
dial='sip:00\[email protected]$host$'
display='2ND:00\1'
transfer='sip:00\[email protected]$host$'
/>
<rule pattern='(.*)'
dial='sip:\[email protected]$host$'
display='todial:\1'
transfer='sip:\[email protected]$host$'
/>
</dialplan> " />
</characteristic>
</wap-provisioningdoc>
dick99999 said:
... About the first/last issue: Though read everywhere I found that WM6 takes the first match, not the last match. I tested that with the following plan. Try a 00 number and it dispalys First:number.
Click to expand...
Click to collapse
I red the same. But on my HTC Touch with WM6 it takes the last one. I don't know why.
Concretley, it means that the order of the rules is very important, as the parsing looks for your pattern ANYWHERE in the string. It means that more than one rule can match your string.
dick99999 said:
Trying to develop a dialplan, I found that my HTC TyTN as well as my HP ipaq 514 deletes blanks (spaces) from a phonebook entry before it is subjected to the dialplan ruling. That means that any spaces cannot be used to identify a rule. i.e. 0031 20 ... cannot be caught by requiring a space between the country code and the rest of the number.
Anyone aware of this an/or any registry setting that prevents this blank deletion? It a kind of degrades the power of dialing rules.
Click to expand...
Click to collapse
In a rule :
<rule pattern= ...
dial= ...
display= ...
transfer= ...
/>
what is diplayed is not what is dialed...
So you can keep on your display the spaces (as display= ... is used to format of the string to be displayed to the user) and remove them from the URI (as dial= ... format the string into a URI which will be sent in the SIP INVITE)
(cf. http://msdn2.microsoft.com/en-us/library/aa921954.aspx)
CJSnet said:
I will give $30 by PayPal to anyone who can create a Dial Plan Wizard app for the WM6 devices including the Kaiser, which allows you to specify in simple fields what to dial when, and also crucially to ignore text characters after a number (e.g. +44 20 7841 1234 - Sales).
Click to expand...
Click to collapse
I'm not able to do a Dial Plan Wizard app but :
My country code is +44
My prefix for international calls is 00
My prefix for national calls is 0
From that it should be able to translate the following sort of numbers for dialling out via VoIP using the dialplan file:
+44 20 1234 5678 becomes 020 1234 5678
020 1234 5678 remains 020 1234 5678
+1 404 123 4567 becomes 001 404 123 4567
"+1 404 123 4567 - Sales" becomes 001 404 123 4567
1471 remains 1471
Click to expand...
Click to collapse
shouldn't be to complicated to put in an ipdialplan.xml, except :
And so on...
Click to expand...
Click to collapse
Try this attachment.
PS For me, it's what I did in my ipdialplan, +44 20 1234 5678 remains, but 020 1234 5678 become +44 20 1234 5678
Sorry...
I made correct the attachment of the previous post. This attachment is now for swiss rule plan dialing.
chrcha said:
In a rule :
<rule pattern= ...
dial= ...
display= ...
transfer= ...
/>
what is diplayed is not what is dialed...
So you can keep on your display the spaces (as display= ... is used to format of the string to be displayed to the user) and remove them from the URI (as dial= ... format the string into a URI which will be sent in the SIP INVITE)
(cf. http://msdn2.microsoft.com/en-us/library/aa921954.aspx)
Click to expand...
Click to collapse
Sorry, i did not clarify my point. My remark is not about output ( the dial, diaplay etc). My remark is about INPUT. So the string of the number to parse that stems from the phone book entry, does not contain blanks (spaces). It seesm to be pre parsed, also called normalized.
As a consequence, in one's own dialplan rules that determine which output to generate, one can thus not rely on spaces that exist in the phonebook entry, and let those spaces also determine the dial plan rule.
As an example if the phonebook entry is +31{space}201234567 or it is +3120123{space}4567, those listings generate the same to parse input string for the dialplan. One can thus not determine what the country code is from relying on spaces separating the country code. Another example is for local numbers (after the area code) of 7 or 8 digit numbers like 123{space}4567 and 1234{space}5678
dick99999 said:
... As a consequence, in one's own dialplan rules that determine which output to generate, one can thus not rely on spaces that exist in the phonebook entry, and let those spaces also determine the dial plan rule.
Click to expand...
Click to collapse
You're right. In fact, you cannot even rely on any non digit character!
That's why, it's very complicated to make a dialplan functionning worldwide, when you use non digit characters to make more readable your phonebook entry.
When you don't use non digit character, it's simple: you simply send the string in the SIP INVITE.
Those who are using only this three type of phone entries (with or without any non digit characters inside the number):
- a number beginning with only one 0 (zero) = area code + local number -> in that case, you add the international code (+xx) and suppress the 0 before using it.
- a number beginning with 00 (2 zero) = international number -> in that case, the phone number can be used as it is.
- a number beginning with + = international number -> in that case, you change the + by 00 before using it.
have a very simple ipdialplan and it's simple to make a Dial Plan Wizard app (as you only have to adjust the ipdialplan with your international prefix for numbers beginning with only one 0).
Dialplan for Pennytel or Australia
hi, if anyone of you could help me make a dialplan that would be awesome
my phonebook entry is in (07) xxxx xxxx for local and mobile is (04) xxxx xxxx which are essentially the same
these need to be passed to the VOIP as it is 07xxxxxxxx or 04xxxxxxxx
then my phonebook for international to taiwan is +886 xxx xxxx these needed to be passed as 0011 886 xxx xxxx
does anyone know how to do that? it would be so good if anyone could help
i would post these onto the australian forums to make it easier for everyone here.
thank you all!
Related
Hey all,
I tried searching but couldn't find anything that could answer this question:
Is there some way to backup the WEP keys saved in the WiFi settings so that I can restore them after a ROM flash? Are they encrypted anywhere in the registry? Can they even be ported over from a different rom?
I have a bunch of Access Points saved that I no longer have the key for so losing them after a ROM upgrade is a PITA! =)
Thanks,
Quick bump for an old question...
Anyone here know of the answer?
Thanks,
uhh
try opening up yer perfered notes app and typing them in and saving to storage card...thats what i do...or you could just remember them all
mr_yellow said:
Quick bump for an old question...
Anyone here know of the answer?
Thanks,
Click to expand...
Click to collapse
There may be a way of using RapiConfig, but I think the keys are stored in encrypted format... Might be in the registry though...
Found this the other day on a winmob blog. It might help:
Configuring WiFi connectivity via cab file
Wifi connectivity on supported Windows Mobile 5, 6 & 6.1 devices can use the CSP provided to configure the device automatically.
The XML:
<characteristic type="CM_WiFiEntries">
<characteristic type="Your SSID">
<parm name="DestID" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
</characteristic>
</characteristic>
<characteristic type="Wi-Fi">
<characteristic type="access-point">
<characteristic type="Your SSID">
<parm name="DestId" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
<parm name="Encryption" value="0"/>
<parm name="Authentication" value="0"/>
<parm name="Hidden" value="0"/>
<parm name="KeyProvided" value="0"/>
<parm name="NetworkKey" value="your network key"/>
<parm name="KeyIndex" value="1"/>
<parm name="Use8021x" value="0"/>
</characteristic>
</characteristic>
</characteristic>
There are a couple of values that you will want to change to suit your network environment.
Firstly, DestID. This tells the device if this network is "Work Network" or "The Internet". The possible values are {436EF144-B4FB-4863-A041-8F905A62C572 for The Internet, or {A1182988-0D73-439e-87AD-2A5B369F808B} for Work Network.
Encryption can be one of the following values to suit your network:
0 = Encrypt using 802.11 wired equivalent privacy (WEP) key.
1 = No encryption.
4 = Encrypt using Temporal Key Integrity Protocol (TKIP) sequence counters.
6 = Encrypt using Advanced Encryption Standard (AES).
Authentication can be any of the following:
0 = Open Network
1 = Shared Network
3 = WPA
4 = WPA-PSK
5 = WPA-NONE
6 = WPA2
7 = WPA2-PSK
Put this into NOTEPAD. We cannot have any text formatting on this, so word is out of the question, just straight notepad.
Save this as _setup.xml from the notepad save as menu. If you can't save as xml, then change the file extension after you save it as a .txt.
The name of the file - _setup.xml is important.
You can change around the below instructions, but this should make it easier for people who are new to compiling cabs
1. Save your _setup.xml to a directory called C:\Cabs\ on your computer.
2. Now open up a command prompt window Start>Run>cmd.
3. Type cd C:\Cabs in the command prompt window
4. Type MakeCAB.exe /D COMPRESS=OFF _setup.xml Wifi.cab
Now you will have an Wifi.cab file in your C:\Cabs directory.
Launch this on your device and the settings will be provisioned.
The formatting of the script doesnt show up properly above so download the XML script below - just remove the .txt file extension.
Hi,
you can put the xml in your SDAutorun on SD Card (read more).
wfg
starbase64
Thanks for the info! I was also able to find similar registry keys at:
HKEY_CURRENT_USER/Comm/EAPOL/Config/<SSID>
and
HKEY_LOCAL_MACHINE/Comm/ConnMgr/Providers/{9eefcedf-a6bc-4457-a8ae-fb664a196450}/<SSID>
But I didn't see any reg key that looked like it stored the WEP/WPA key.... Where is this WIFI.cab saving the WEP key?!?
mr_yellow said:
Thanks for the info! I was also able to find similar registry keys at:
HKEY_CURRENT_USER/Comm/EAPOL/Config/<SSID>
and
HKEY_LOCAL_MACHINE/Comm/ConnMgr/Providers/{9eefcedf-a6bc-4457-a8ae-fb664a196450}/<SSID>
But I didn't see any reg key that looked like it stored the WEP/WPA key.... Where is this WIFI.cab saving the WEP key?!?
Click to expand...
Click to collapse
In an encrypted format...
Yeah, but where?... I'd be happy to save the encrypted keys so I can reimport them later... =)
mr_yellow said:
Yeah, but where?... I'd be happy to save the encrypted keys so I can reimport them later... =)
Click to expand...
Click to collapse
Read post #5, it tells you how to create an xml for reinstallation!!!! Its not telling you where to get the info, its an xml config file.
what i do is just copy the key into a txt file and save it on SD card
i have used the file included and even searched msdn, but i get error "Multiple root elements line 7 position 2"
Code:
[B]<characteristic type="CM_WiFiEntries">[/B]
<characteristic type="MY ROUTER NAME HERE">
<parm name="DestID" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
</characteristic>
</characteristic>
[B]<characteristic type="Wi-Fi">[/B]
<characteristic type="access-point">
<characteristic type="MY ROUTER NAME HERE">
<parm name="DestId" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
<parm name="Encryption" value="0"/>
<parm name="Authentication" value="0"/>
<parm name="Hidden" value="0"/>
<parm name="KeyProvided" value="0"/>
<parm name="NetworkKey" value="MY KEY HERE"/>
<parm name="KeyIndex" value="1"/>
<parm name="Use8021x" value="0"/>
</characteristic>
</characteristic>
</characteristic>
Im sure its because of these:
<characteristic type="CM_WiFiEntries">
<characteristic type="Wi-Fi">
but not sure how to make this work. Anyone have any ideas?
shogunmark said:
Read post #5, it tells you how to create an xml for reinstallation!!!! Its not telling you where to get the info, its an xml config file.
Click to expand...
Click to collapse
I didn't mean to be arguementative... I know what post #5 meant. The info is very helpful *if* i knew what the WEP keys were. However I no longer do. I just wanted the location of the encrypted keys in the registry (if it's even stored there) so I can save them, flash my rom, then restore them (if that's even possible since the encryption key might change after the ROM flash).
Thanks,
mr_yellow said:
I didn't mean to be arguementative... I know what post #5 meant. The info is very helpful *if* i knew what the WEP keys were. However I no longer do. I just wanted the location of the encrypted keys in the registry (if it's even stored there) so I can save them, flash my rom, then restore them (if that's even possible since the encryption key might change after the ROM flash).
Thanks,
Click to expand...
Click to collapse
I don't think you can get the keys/encrypted versions back to a usable state... After all, that's the point of the encryption.
l3v5y said:
I don't think you can get the keys/encrypted versions back to a usable state... After all, that's the point of the encryption.
Click to expand...
Click to collapse
Well, that's not totally true.. Even in it's encrypted form, it's still usable since it can still be decrypted by the OS when it's trying to connect to the wifi network. It's just encrypted to prevent human eyes from figuring out what the password is.
But back to my other point of whether moving the encrypted keys from one device to another (or one ROM to another) will work since the key itself might be different (or not)... I'm assuming it's keyed to some HW value (which in that case, moving the keys from one ROM to another ROM will be fine since hte HW is the same).
I did this and the cab was created but when I went to install, it says unsuccessful...any ideas....I am using SJ's newest rom....
chrisnash said:
Found this the other day on a winmob blog. It might help:
Configuring WiFi connectivity via cab file
Wifi connectivity on supported Windows Mobile 5, 6 & 6.1 devices can use the CSP provided to configure the device automatically.
The XML:
<characteristic type="CM_WiFiEntries">
<characteristic type="Your SSID">
<parm name="DestID" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
</characteristic>
</characteristic>
<characteristic type="Wi-Fi">
<characteristic type="access-point">
<characteristic type="Your SSID">
<parm name="DestId" value="{436EF144-B4FB-4863-A041-8F905A62C572}"/>
<parm name="Encryption" value="0"/>
<parm name="Authentication" value="0"/>
<parm name="Hidden" value="0"/>
<parm name="KeyProvided" value="0"/>
<parm name="NetworkKey" value="your network key"/>
<parm name="KeyIndex" value="1"/>
<parm name="Use8021x" value="0"/>
</characteristic>
</characteristic>
</characteristic>
There are a couple of values that you will want to change to suit your network environment.
Firstly, DestID. This tells the device if this network is "Work Network" or "The Internet". The possible values are {436EF144-B4FB-4863-A041-8F905A62C572 for The Internet, or {A1182988-0D73-439e-87AD-2A5B369F808B} for Work Network.
Encryption can be one of the following values to suit your network:
0 = Encrypt using 802.11 wired equivalent privacy (WEP) key.
1 = No encryption.
4 = Encrypt using Temporal Key Integrity Protocol (TKIP) sequence counters.
6 = Encrypt using Advanced Encryption Standard (AES).
Authentication can be any of the following:
0 = Open Network
1 = Shared Network
3 = WPA
4 = WPA-PSK
5 = WPA-NONE
6 = WPA2
7 = WPA2-PSK
Put this into NOTEPAD. We cannot have any text formatting on this, so word is out of the question, just straight notepad.
Save this as _setup.xml from the notepad save as menu. If you can't save as xml, then change the file extension after you save it as a .txt.
The name of the file - _setup.xml is important.
You can change around the below instructions, but this should make it easier for people who are new to compiling cabs
1. Save your _setup.xml to a directory called C:\Cabs\ on your computer.
2. Now open up a command prompt window Start>Run>cmd.
3. Type cd C:\Cabs in the command prompt window
4. Type MakeCAB.exe /D COMPRESS=OFF _setup.xml Wifi.cab
Now you will have an Wifi.cab file in your C:\Cabs directory.
Launch this on your device and the settings will be provisioned.
The formatting of the script doesnt show up properly above so download the XML script below - just remove the .txt file extension.
Click to expand...
Click to collapse
Hello, I'm french user of an SPV E650 (flashed in HTC S710). My Internet Provider (Neuf) offers me a voip solution (neuftalk). Since one week, I try to use the VoipWM6 but I always compare at this problem: the personn called can't hear me.
My rom version is 1.34.406.1, I installed voipWM6.cab of Sleuth's. My _setup.xml contains:
<wap-provisioningdoc>
<characteristic type="VoIP">
<parm name="SIPSettings"
value="<provision key='1232ab01' name='neuftalk'>
<provider name='neuftalk' />
<user account='login' password='passwd'
uri='sip:[email protected]:5060'
allowedauth='digest'/>
<sipsrv addr='voip.wengo.fr' protocol='UDP' role='proxy'>
<session party='First' type='pc2pc' />
<session party='First' type='pc2ph' />
</sipsrv>
<sipsrv addr='voip.wengo.fr' protocol='UDP' role='registrar'/>
</provision>" />
</characteristic>
</wap-provisioningdoc>
I modified the internet calling option by "whenever available" and I open port 5060 on my sphone and on my router (hklm/system/voip/enable5060:0->1)
When I connect my smartphone on Wlan, the Voip logo appears and the line internet calling becames "neuftalk: connexion en cours"
I can call, I hear my correspondent (ont the rear speaker as everybody) but I can't be heard.
If somebody think at a solution for my matter, i will be very happy. Thanks a lot.
NB: excuse me for my bad english, I'm a poor little french!
Hi, I 'm very happy because I succeed to activate correctly Voip client of WM6 with Neuftalk.
In order to be called during my call, I' modify the registry as that:
I create a key "codec" in hklm/comm and I add 2 value in codec:
- "UsePreferredCodec" with DWORD value data 1
- "PreferredAudioCodec" with DWORD value data 8
Now is ok. 4 matters stay:
- The sound is transmitted by the rear speaker but the handless permit using phone correctly.
- For calling, I must dial 0033 + phone number. I must modify ipdialplan.xml
- My correspondent can't hear me immediately at the call beggining. between 2 and 8sec are necessary.
- I can't use the "Neuf WIFI" public hotspot. I can send call but the communication stop automatically at 30sec. During this call, my correspondent and me can't speak.
herveduff said:
- For calling, I must dial 0033 + phone number. I must modify ipdialplan.xml
Click to expand...
Click to collapse
Hi,
I'm french too
Here is my ipdial to have french phone call :
<dialplan xmlns='http://schemas.microsoft.com/embedded/VoIP'>
<dialplan-header>
<host>#use_sipsrv_host_name#</host>
</dialplan-header>
<!-- Regles de Numerotations -->
<!-- Regles de numerotation IP -->
<rule pattern='\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}'
restrict='Cell,SMS'
/>
<rule pattern='(\d{1,3})\*(\d{1,3})\*(\d{1,3})\*(\d{1,3})'
dial='\1.\2.\3.\4'
display='\1.\2.\3.\4'
transfer='\1.\2.\3.\4'
restrict='Cell,SMS'
/>
<!-- Regles de numerotations Francaises -->
<rule pattern='0(\d{9})'
dial='sip:0\[email protected]$host$'
display='0\1'
transfer='sip:0\[email protected]$host$'
/>
<rule pattern='0(\d{1})\s*(\d{2})\s*(\d{2})\s*(\d{2})\s*(\d{2})(\s*[Xx]\s*\d+)?'
dial='sip:0\1\2\3\4\[email protected]$host$'
display='0\1\2\3\4\5'
transfer='sip:0\1\2\3\4\[email protected]$host$'
/>
<!-- Regles de numerotation generiques -->
<rule pattern='(00|+)(\d+)'
dial='sip:00\[email protected]$host$'
display='+\2'
transfer='sip:00\[email protected]$host$'
/>
<rule pattern='(\d+)'
dial='sip:\[email protected]$host$'
display='+\1'
transfer='sip:\[email protected]$host$'
/>
<!-- Regles de numerotation URI SIP -->
<!-- Appels entrants Freephonie -->
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*0(\d{9})@(.+)'
display='0\1'
restrict='Cell,SMS'
/>
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*(\d{3})(\d{3})(\d{4})@(.+)'
display='\1\2\3'
restrict='Cell,SMS'
/>
<rule pattern='([Ss][Ii][Pp][Ss]??\s*([a-zA-Z0-9_-]+)@(.+)'
display='\2'
restrict='Cell,SMS'
/>
<rule pattern='[Ss][Ii][Pp][Ss]?:\s*([^@]+)'
display='\1'
restrict='Cell,SMS'
/>
</dialplan>
Click to expand...
Click to collapse
good luck
THanks for you dial plan! that interest me but before modify my dialplan, I desesperate to make worked my voip client on public hot spot which block all ports except the port 80. If somebody has an idea, tell me please
I'm quit new to android and now following the book "Beginning Android Application Development".
One sample that shows how Android handle activities with same name just didn't work on my linux, which should prompt a dialog and let me choose the default action. I tried a lot and gave it up then. however, the same code behave correctly on a windows XP later. here is the snippet of my AndroidManifest.xml:
<activity android:name=".Activity2"
android:label="Activity 2">
<intent-filter>
<action android:name="com.xxx.ACTIVITY2" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
<activity android:name=".Activity3"
android:label="Activity 3">
<intent-filter>
<action android:name="com.xxx.ACTIVITY2" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
</activity>
the code is like:
onClick() { startActivity(new Intent("com.xxx.ACTIVITY2")); }
on linux, it always shows the "Activity 2", on winxp, it prompts for a choice.
both are using "Eclipse indigo J2EE", Android gingerbread emulator for 2.3.3.
did I miss something? any help is appreciated.
In this post I will be explaining you guys that 'How to make a push notification app through GCM Service on PushBots'
Code is necessary for the implementation can be copied from here and watch the video below for the detail explanation of the implementation. Video will be uploaded soon
Android SDK integration
go to your module build.gradle file add PushBots dependency along with android support library v4:
Step 1: Import the Pushbots library into your project:
Code:
compile 'com.pushbots:pushbots-lib:[email protected]'
compile 'com.android.support:support-v4:21.0.0'
Re-build your project and wait for gradle to finish.
Step 2: Update AndroidManifest.xml file:
Add the following permessions and change com.example.sampleapp with your app identifier.
Code:
<!-- GCM connects to Google Services. -->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<!-- GCM requires a Google account. -->
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<permission android:name="com.example.sampleapp.permission.C2D_MESSAGE" android:protectionLevel="signature" />
<uses-permission android:name="com.example.sampleapp.permission.C2D_MESSAGE" />
<!-- This app has permission to register and receive dataf message. -->
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
The following intent-filter in your main activity:
Code:
<intent-filter>
<action android:name="com.example.sampleapp.MESSAGE" />
<category android:name="android.intent.category.DEFAULT" />
</intent-filter>
Add the following activity, reciever and service before the end of your application tag, and in all of the above code change com.example.sampleapp with your app identifier.
Code:
<receiver
android:name="com.pushbots.google.gcm.GCMBroadcastReceiver"
android:permission="com.google.android.c2dm.permission.SEND" >
<intent-filter>
<!-- Receives the actual messages. -->
<action android:name="com.google.android.c2dm.intent.RECEIVE" />
<!-- Receives the registration id. -->
<action android:name="com.google.android.c2dm.intent.REGISTRATION" />
<category android:name="com.example.sampleapp" />
</intent-filter>
</receiver>
<receiver android:name="com.pushbots.push.DefaultPushHandler" />
<service android:name="com.pushbots.push.GCMIntentService" />
Step 3: Creating pushbots.xml config file:
Go to Res folder -> Values --> Right click and new Resource File and name it pushbots with this content. Change your app ID and Sender ID.
Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- Pushbots Application ID -->
<string name="pb_appid">548ef5901d0ab1</string>
<!-- GCM Sender ID -->
<string name="pb_senderid">48849973</string>
<!-- Pushbots Log Level log Tag "PB2" -->
<string name="pb_logLevel">DEBUG</string>
</resources>
Step 4: Add required code:
in your main Activity add this line:
Code:
Pushbots.sharedInstance().init(this);
That's pretty much it. Run your application now, if all goes well, your device should be registered and ready to recieve push notifications.
Step 5: Custom handler for notifications (Optional):
5.1. Create customHandler class.
Code:
public class customHandler extends BroadcastReceiver
{
private static final String TAG = "customHandler";
@Override
public void onReceive(Context context, Intent intent)
{
String action = intent.getAction();
Log.d(TAG, "action=" + action);
// Handle Push Message when opened
if (action.equals(PBConstants.EVENT_MSG_OPEN)) {
//Check for Pushbots Instance
Pushbots pushInstance = Pushbots.sharedInstance();
if(!pushInstance.isInitialized()){
Log.d("Initializing Pushbots.");
Pushbots.sharedInstance().init(context.getApplicationContext());
}
//Clear Notification array
if(PBNotificationIntent.notificationsArray != null){
PBNotificationIntent.notificationsArray = null;
}
HashMap<?, ?> PushdataOpen = (HashMap<?, ?>) intent.getExtras().get(PBConstants.EVENT_MSG_OPEN);
Log.w(TAG, "User clicked notification with Message: " + PushdataOpen.get("message"));
//Report Opened Push Notification to Pushbots
if(Pushbots.sharedInstance().isAnalyticsEnabled()){
Pushbots.sharedInstance().reportPushOpened( (String) PushdataOpen.get("PUSHANALYTICS"));
}
//Start lanuch Activity
String packageName = context.getPackageName();
Intent resultIntent = new Intent(context.getPackageManager().getLaunchIntentForPackage(packageName));
resultIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK| Intent.FLAG_ACTIVITY_CLEAR_TASK);
resultIntent.putExtras(intent.getBundleExtra("pushData"));
Pushbots.sharedInstance().startActivity(resultIntent);
// Handle Push Message when received
}else if(action.equals(PBConstants.EVENT_MSG_RECEIVE)){
HashMap<?, ?> PushdataOpen = (HashMap<?, ?>) intent.getExtras().get(PBConstants.EVENT_MSG_RECEIVE);
Log.w(TAG, "User Received notification with Message: " + PushdataOpen.get("message"));
}
}
}
5.2. Open AndroidManifest.xml and replace DefaultPushHandler with your custom Handler class.
Code:
<receiver android:name="PACKAGE_NAME.customHandler" />
5.3. Set your customHandler class in MainActivity.
Code:
Pushbots.sharedInstance().setCustomHandler(customHandler.class);
Pls hit the thanks button if i helped you :angel:
For more information-Visit: http://androidtechfreakat.blogspot.in
http://androidtechxdaat,weebly.com
http://advaitt17.github.io
XDA:DevDB Information
[GUIDE]To make a Push Notificaton App via GCM Service by AdvaitT17, App for all devices (see above for details)
Contributors
AdvaitT17, PushBots Developers
Source Code: www.pushbots.com
Version Information
Status: Stable
Created 2016-04-06
Last Updated 2016-05-20
Reserved
If there are any doubts about this process yoi can PM me on Xda
Hi all,
I know there was several questions like mine but i didn´t find a thread till now, where somebody did a little bit more investigation.
So I exported my apk from a PX5 device which I think is the key to send and recive informations with the CAN Bus in the Vehicle.
Sadly im not pretty familiar with reverse engeneering with apps or programming Android apps at all.
Maybe there are some better informed people out there making it happen to send more Informations to the display in the car.
Could be something like:
-Phone numbers
-Musik information from foreign players
-RDS information from a station
-Arrows from a Navigation app (i think a lot more difficult but quite nice)
-..
what i found out!
hi!
yes the apk you postet is really the key, but every app in the HeadUnit is Broadcasting(intent) a message to the canbus.apk. so we have do edit the intent filter from the canbus.apk to recive a custom intent from a selfmade app, to show special informations.
but iam not so good to make one.
In the decompiled file of MusicPlayer2.4.1.apk there is a file with the name "MainActivity.java" at line 329 which the app would send an INTENT with the information TIME of the played Track, i would change this to show the TITLE of the song, i have editet but i cant recompiled with serveral tools.
if i decompile and try to compile the original version, this was not possible, i dont know why.
hopefully
The app can unfortunately be installed on my PX5 Dasaita with Malaysian Rome
Would be cool if we could find an Android developer to program the app for us. I'd pay money for it, too.
folepole said:
hi!
yes the apk you postet is really the key, but every app in the HeadUnit is Broadcasting(intent) a message to the canbus.apk. so we have do edit the intent filter from the canbus.apk to recive a custom intent from a selfmade app, to show special informations.
but iam not so good to make one.
In the decompiled file of MusicPlayer2.4.1.apk there is a file with the name "MainActivity.java" at line 329 which the app would send an INTENT with the information TIME of the played Track, i would change this to show the TITLE of the song, i have editet but i cant recompiled with serveral tools.
if i decompile and try to compile the original version, this was not possible, i dont know why.
hopefully
Click to expand...
Click to collapse
How you decompiled the app?
Every way i found you need an classes.dex file.
Would it be possible to recieve the Intent with an app like Automate or Tasker and Transmitt it to the canbus.apk?
tools
hi, nice to hear some other has the same problem!
i have decompiled with javadecompilers.com/apk and tools that i have found on xda-dev. And i editet with nootepad++.
you can easy extract the classes.dex from musikplayer.apk with 7zip or equals.
yes it must possible, but i dont know how.
shematic function of this i imagine:
musicplayer.apk->recive with an selfmade app, read out the toast that musicplayer.apk made, convert it to 2 lines to the FIS format, an send an intent to canbus.apk.
hopefully
So if i get it wright every app needs to send it Information to the canbus.apk?
So we could trigger every app to do so?
folepole said:
hi, nice to hear some other has the same problem!
i have decompiled with javadecompilers.com/apk and tools that i have found on xda-dev. And i editet with nootepad++.
you can easy extract the classes.dex from musikplayer.apk with 7zip or equals.
yes it must possible, but i dont know how.
shematic function of this i imagine:
musicplayer.apk->recive with an selfmade app, read out the toast that musicplayer.apk made, convert it to 2 lines to the FIS format, an send an intent to canbus.apk.
hopefully
Click to expand...
Click to collapse
Could you show me the MusicApp u used?
Hi,
Im just playing a little bit arround and found this.
Code:
private void SendCanBusinfo() {
Intent it1 = new Intent(MSG_MTC_CANBUS_DISPLAY);
it1.putExtra(MSG_TYPE, "radio");
it1.putExtra("group", (byte) this.band);
if (this.band < 3) {
it1.putExtra("fre", this.currentFreq / 10000);
} else {
it1.putExtra("fre", this.currentFreq / 1000);
}
it1.putExtra("index", (byte) this.channel);
sendBroadcast(it1);
}
It was extracted from an Radio app.
If i get that wright every app could send his Information without any problem to the Canbus app.
So the problem is not to modify the filter in the first step we should try to send the info with additional apps in my mind.
Becasue im not an that good Software Engineer i try to use Automate to make my Plans happen.
MediaPlayer
Intent intent = new Intent("com.microntek.canbusdisplay");
intent.putExtra("type", "music");
intent.putExtra("all", this.ee.size());
intent.putExtra("cur", this.cv + 1);
if (i2 <= 0) {
intent.putExtra("time", 0);
} else {
intent.putExtra("time", i);
}
sendBroadcast(intent);
}
Intent vom Radio
Intent it1 = new Intent(MSG_MTC_CANBUS_DISPLAY);
it1.putExtra(MSG_TYPE, "radio");
it1.putExtra("group", (byte) this.band);
if (this.band < 3) {
it1.putExtra("fre", this.currentFreq / 10000);
} else {
it1.putExtra("fre", this.currentFreq / 1000);
}
it1.putExtra("index", (byte) this.channel);
sendBroadcast(it1);
Use the Boradcast send block.
Action: <whatever MSG_MTC_CANBUS_DISPLAY sands for>
Extras: { "type": "radio", "group" as byte: band, "fre" as int: freq, "index" as byte: channel }
This is where i stand at the moment with the help from Henrik.
9_Mad-Max_5 said:
Becasue im not an that good Software Engineer i try to use Automate to make my Plans happen.
MediaPlayer
Intent intent = new Intent("com.microntek.canbusdisplay");
intent.putExtra("type", "music");
intent.putExtra("all", this.ee.size());
intent.putExtra("cur", this.cv + 1);
if (i2 <= 0) {
intent.putExtra("time", 0);
} else {
intent.putExtra("time", i);
}
sendBroadcast(intent);
}
Intent vom Radio
Intent it1 = new Intent(MSG_MTC_CANBUS_DISPLAY);
it1.putExtra(MSG_TYPE, "radio");
it1.putExtra("group", (byte) this.band);
if (this.band < 3) {
it1.putExtra("fre", this.currentFreq / 10000);
} else {
it1.putExtra("fre", this.currentFreq / 1000);
}
it1.putExtra("index", (byte) this.channel);
sendBroadcast(it1);
Use the Boradcast send block.
Action: <whatever MSG_MTC_CANBUS_DISPLAY sands for>
Extras: { "type": "radio", "group" as byte: band, "fre" as int: freq, "index" as byte: channel }
This is where i stand at the moment with the help from Henrik.
Click to expand...
Click to collapse
yes this ist nice, i have the same infos, i make a app with android studio they look like this: but it dont work.
this was the manifest from the canbus.apk
Code:
<?xml version="1.0" encoding="utf-8" standalone="no"?><manifest xmlns:android="http://schemas.android.com/apk/res/android" android:sharedUserId="android.uid.system" package="android.microntek.canbus" platformBuildVersionCode="26" platformBuildVersionName="8.0.0">
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>
<uses-permission android:name="android.permission.BROADCAST_STICKY"/>
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS"/>
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
<uses-permission android:name="android.permission.WRITE_SETTINGS"/>
<uses-permission android:name="android.permission.WRITE_SECURE_SETTINGS"/>
<uses-permission android:name="android.permission.GET_TASKS"/>
<uses-permission android:name="android.permission.SET_PREFERRED_APPLICATIONS"/>
<uses-permission android:name="android.permission.EXPAND_STATUS_BAR"/>
<uses-permission android:name="android.permission.SET_TIME_ZONE"/>
<uses-permission android:name="android.permission.SERIAL_PORT"/>
<application android:allowBackup="true" android:directBootAware="true" android:icon="@drawable/ic_launcher" android:label="@string/app_name" android:name=".BaseApplication" android:resizeableActivity="false" android:theme="@android:style/Theme.Translucent">
<receiver android:name=".CanBusReceiver">
<intent-filter>
<action android:name="android.intent.action.BOOT_COMPLETED"/>
<action android:name="android.intent.action.LAUNCHER_STARTED"/>
<action android:name="android.intent.action.USER_INITIALIZE"/>
<action android:name="android.intent.action.PRE_BOOT_COMPLETED"/>
</intent-filter>
</receiver>
<service android:name=".CanBusServer" android:persistent="true">
<intent-filter>
<action android:name="com.microntek.canbusserver"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".AirServer">
<intent-filter>
<action android:name="com.microntek.AirServer"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".DoorServer">
<intent-filter>
<action android:name="com.microntek.DoorServer"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".RadarServer">
<intent-filter>
<action android:name="com.microntek.RadarServer"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".Ajxserver">
<intent-filter>
<action android:name="com.microntek.ajxService"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".ParkServer">
<intent-filter>
<action android:name="com.microntek.ParkServer"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<activity android:excludeFromRecents="true" android:label="@string/carinfo" android:name=".Canbus20Activity" android:screenOrientation="landscape">
<intent-filter>
<action android:name="com.microntek.Canbus20Activity"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</activity>
<activity android:excludeFromRecents="true" android:name=".log.CanBusLogActivity" android:screenOrientation="landscape" android:theme="@android:style/Theme.Wallpaper.NoTitleBar">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</activity>
<activity android:excludeFromRecents="true" android:icon="@drawable/ic_air_control" android:label="@string/air_name" android:launchMode="singleTask" android:name=".air.AirControlActivity" android:screenOrientation="landscape" android:theme="@android:style/Theme.Wallpaper.NoTitleBar">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<service android:name=".WarningServer">
<intent-filter>
<action android:name="com.microntek.WarningServer"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
<service android:name=".update.UpdateService">
<intent-filter>
<action android:name="com.microntek.canbus.UpdateService"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
</service>
</application>
</manifest>
Good but i can read out the filter for the Musicplayer, Radio, A2DP or anything usefull.
android studio: i have make a intent sender, but however my app is sending the intent, the app is crashing.
Code:
package com.track.mfa.test10;
import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;
import android.content.BroadcastReceiver;
import android.content.Intent;
import android.content.IntentFilter;
import android.content.SharedPreferences;
import android.content.SharedPreferences.Editor;
import android.os.AsyncTask.Status;
import android.os.Bundle;
import android.os.Environment;
import android.os.Handler;
import android.os.Message;
import android.preference.PreferenceManager;
import android.provider.Settings.System;
import android.view.KeyEvent;
import android.widget.Toast;
import java.io.File;
import java.util.ArrayList;
import java.util.List;
import android.view.View;
public class MainActivity extends AppCompatActivity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
}
public void SendOutBroadoff() {
Intent i = new Intent("com.microntek.canbusdisplay");
i.putExtra("type", "music-off");
sendBroadcast(i);
}
public void SendOutBroadon() {
Intent intent = new Intent("com.microntek.canbusdisplay");
intent.putExtra("type", "music-on");
sendBroadcast(intent);
}
public void SendCustom(){
Intent intent = new Intent("com.microntek.canbusdisplay");
intent.putExtra("type", "music");
intent.putExtra("all", "8");
intent.putExtra("cur", "test");
intent.putExtra("time", "mix");
sendBroadcast(intent);
}
}
i know that malaysk has the answer, he has editet the musik apk with other people, but i think he has many work with his other projekts.
pleas help us @Malaysk
Actually i get it to work to broadcast en intend to my MFA+.
It was pretty basic but it worked.
After a little bit of playing around with the Infos i became i made this 2 Automate Flos:
Recieve Intent it repetly readst the intents to the Can Bus apk and diplays it as Toast.
And Send Broadcast.
It´s yea lets say dumb but it works.
So it opens the Audio menu and Displays Track 1.
These values are hat coded and won´t change with time.
I was able to unpack the canbus app but not able to found the recieve option.
So here is my upacked version
Working example
folepole almost got it right. The problem was that he sent strings in his intent. The CanBus app only deals with integers. The following code works (successfully tested in my Mercedes-Benz W211 on a head unit running Hal9k's Android 7.1.2 ROM).
Code:
public void sendCanBusMusicOn()
{
Log.i("PlaybackService", "sendCanBusMusicOn()");
Intent canBusDisplayIntent = new Intent("com.microntek.canbusdisplay");
canBusDisplayIntent.putExtra("type", "music-on");
sendBroadcast(canBusDisplayIntent);
}
public void sendCanBusMusicOff()
{
Log.i("PlaybackService", "sendCanBusMusicOff()");
Intent canBusDisplayIntent = new Intent("com.microntek.canbusdisplay");
canBusDisplayIntent.putExtra("type", "music-off");
sendBroadcast(canBusDisplayIntent);
}
/**
* Sends track information to the CanBus App
* (to display in car's display)
*/
public void sendCanBusInfo()
{
String methodTag = "PlaybackService";
// send intent to "com.microntek.canbusdisplay"
// "type": "music" (String)
// "all": number of tracks in playlist / queue (int)
// "cur": currentPlayIndex, position of current track in playlist (int)
// "time": either 0 or actual time position in milliseconds (int)
int numberOfTracksInQueue = getTimelineLength(); // e.g. 241 for playlist with 241 tracks
int currentPositionInQueue = getTimelinePosition() + 1; // e.g. 5 for 5th track of current playlist
int currentTimeOffset = getPosition(); // in milliseconds, e.g. 20000 for 00:20
Intent canBusDisplayIntent = new Intent("com.microntek.canbusdisplay");
canBusDisplayIntent.putExtra("type", "music");
canBusDisplayIntent.putExtra("all", numberOfTracksInQueue);
canBusDisplayIntent.putExtra("cur", currentPositionInQueue);
canBusDisplayIntent.putExtra("time", currentTimeOffset);
String hms = String.format("%02d:%02d",
TimeUnit.MILLISECONDS.toMinutes(currentTimeOffset),
TimeUnit.MILLISECONDS.toSeconds(currentTimeOffset) % TimeUnit.MINUTES.toSeconds(1));
String msg = hms + ", " + currentPositionInQueue + "/" + numberOfTracksInQueue;
Log.i(methodTag, msg);
sendBroadcast(canBusDisplayIntent);
}
For the order of calling the methods:
You have to call sendCanBusMusicOn() to let the CanBus app know that it shall "enable" the music mode. (At this point, my display already shows 00:00 and not "Audio off" anymore.)
Call sendCanBusInfo() to show the correct information (current position in the playlist and passed mm:ss in the track). I am calling this method every second to update the information shown.
Call sendCanBusMusicOff() to "leave" music mode. I think this step is optional. You can also just switch to the radio app and the current mode is overridden.
To test this, I have used the open-source media player "Vanilla" and added my code inside the "PlaybackService" class. But you can - of course - write custom apps.
I am currently going through the de-odexed source code of the MTCCanBus.apk to get an understanding of how the communication works and to see if it's possible to display strings in the FIS/MFA/Board computer (whatever you want to call it). So far I don't think it can be done easily. There are 76 different implementations of the "Canbus" class. One for every type of canbus adapter, I guess. And I don't even know which one my head unit is set to use. Plus, I'm no Android/Java developer...
But hey, it's a start.
Sadly in my display it just shows up Track 1. No infromation about the point in the playlist. But i have no idea how to deal with it. Maybe we can look up in a forum like https://www.canhack.de/ to get more information. But saddly i realy don´t get where the information is handed over to the can bus app.
I would definitely be interested in this. Maybe it's possible to use an Xposed module to do what we need?
It would be nice if it could get track information from apps like Spotify or Google Play Music. Just the name of the song or the position in the playlist would be a nice touch
It is really not the problem to get the information.
I already tested it with simple automate flows.
The bottleneck is to define the way it is send to the bus.
Gesendet von meinem G8341 mit Tapatalk
Hi,
I found some new info.
I attached from xbenji the decompiled apks and the source code for an mixed app.
I have a 2010 Jeep Grand Cherokee S-Limited 3.0 CRD (Mercedes Engine) with a specific Xtrons PX5 installed. My car has the "Auto Headlight" function and when they are switched on automatically, the illumination on the HU is OFF. If I manually switch On the headlight then the HU illumination is correctly working. It seems that the issue is related to the Can Bus. Probably the "message" on the Bus when the lights are switched on in "Auto" mode is different from the one in "Manual" mode and is not correctly decoded by the HU. Anyone knows if some modifications could be done to make it work also in "Auto" ?
Hi I decompiled several apps with APKTools but none of them contains the real deal. None of them contains the reciever for the intents.