MDN and User Agent question | developer.brewmp.com MDN and User Agent question | developer.brewmp.com

Developer

MDN and User Agent question

Forums:

Hi,

1. I want to get MDN and the device User Agent from the phone. I used the following codes to obtain MDN:

ITAPI_GetStatus(pApp->m_pITAPI,&ts);
ISHELL_GetDeviceInfoEx(pApp->a.m_pIShell,AEE_DEVICEITEM_MOBILE_ID, pBuff, sizeof(pBuff));
Is this right? When I run it on the emulator, it complains access violation. Does that mean I have to test it on real device, not on emulator? If not, how do I test it on emulator?

2. What is device User Agent? I looked over NetDiagnostics example,

#define WEBBER_USERAGENT "NetDiagnostics/1.0 (built on "__DATE__")\r\n"
Is this it? Does it include the application info or what? How do I get this data?

3. Finally, I need to send both User Agent and MDN to server. How do I do that? Do I use IWEB_Response? Some code snippets would help a lot.

Thank you.

What version of the emulator are you using?
User agent information can be found through a Google search.

What version of the emulator are you using?
User agent information can be found through a Google search.

mohlendo wrote:What version of the emulator are you using?
User agent information can be found through a Google search.
2.1. Does it matter? I just want to know whether MDN can be obtained in emulator.
I know you can find info about anything in Google, but can you just give me some idea about what User Agent contains? This is not a useful tip.
Thank you.

mohlendo wrote:What version of the emulator are you using?
User agent information can be found through a Google search.
2.1. Does it matter? I just want to know whether MDN can be obtained in emulator.
I know you can find info about anything in Google, but can you just give me some idea about what User Agent contains? This is not a useful tip.
Thank you.

Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.

Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.

mohlendo wrote:Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.
Ok, thanks.
About MDN, it is supposedly supported on 2.1.3. But I can't find this update that contains refernece to AEE_DEVICEITEM_MDN. Here's the page:
https://brewx.qualcomm.com/bws/content/gi/products/sdk/2.1/en/2.1.0.20/u...
Which patch should I download? Because I downloaded them all, but none contains AEE_DEVICEITEM_MDN.
Also, could you give me a rough idea on how to get User Agent info? And how to pack MDN and User Agent together and send?
THank you.

mohlendo wrote:Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.
Ok, thanks.
About MDN, it is supposedly supported on 2.1.3. But I can't find this update that contains refernece to AEE_DEVICEITEM_MDN. Here's the page:
https://brewx.qualcomm.com/bws/content/gi/products/sdk/2.1/en/2.1.0.20/u...
Which patch should I download? Because I downloaded them all, but none contains AEE_DEVICEITEM_MDN.
Also, could you give me a rough idea on how to get User Agent info? And how to pack MDN and User Agent together and send?
THank you.

2.1.3 of the SDK has not been released yet, but you should be able to fetch the MDN on 3.0.1.
For more information on user agent strings, check this page - basically, you'll be defining your own user agent string.

2.1.3 of the SDK has not been released yet, but you should be able to fetch the MDN on 3.0.1.
For more information on user agent strings, check this page - basically, you'll be defining your own user agent string.

mohlendo wrote:Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.
Is MDN really implemented in 2.1.3 ?
I have a LGE VX4700 with 2.1.3.8 and I use the following code to get MDN
AECHAR wszBuf[MDN_TEST_BUF_LEN];
int iLen = MDN_TEST_BUF_LEN;
int ret = SUCCESS;
wszBuf[0] = 0;
ret = ISHELL_GetDeviceInfoEx(pme->a.m_pIShell, /*AEE_DEVICEITEM_CHIP_ID*/ 25, (void*) wszBuf, &iLen);
ret isn't SUCCEESS on return. MDN_TEST_BUF_LEN is 1024.
It doesn't even work for AEE_DEVICEITEM_CHIP_ID on device (works on simulator).
Also, simulator 3.0.1 fails too... is this something to do with privileges?
I saw // This privilege level required to access MDN
#define AEECLSID_MDN 0x0101b3ad
in a AEEShell.h. Could you, please, explain this define?

mohlendo wrote:Try running in version 3.0.1 of the Simulator - the MDN should be a dummy hardcoded value (like 1234567...). MDN is not implemented prior to 2.1.3 or 3.0.1.
Is MDN really implemented in 2.1.3 ?
I have a LGE VX4700 with 2.1.3.8 and I use the following code to get MDN
AECHAR wszBuf[MDN_TEST_BUF_LEN];
int iLen = MDN_TEST_BUF_LEN;
int ret = SUCCESS;
wszBuf[0] = 0;
ret = ISHELL_GetDeviceInfoEx(pme->a.m_pIShell, /*AEE_DEVICEITEM_CHIP_ID*/ 25, (void*) wszBuf, &iLen);
ret isn't SUCCEESS on return. MDN_TEST_BUF_LEN is 1024.
It doesn't even work for AEE_DEVICEITEM_CHIP_ID on device (works on simulator).
Also, simulator 3.0.1 fails too... is this something to do with privileges?
I saw // This privilege level required to access MDN
#define AEECLSID_MDN 0x0101b3ad
in a AEEShell.h. Could you, please, explain this define?

Is the return value EPRIVLEVEL?
Try declaring a dependency on AEECLSID_MDN in your MIF.

Is the return value EPRIVLEVEL?
Try declaring a dependency on AEECLSID_MDN in your MIF.