ussd

Send USSD code to modem in C# and ERROR in return always

痴心易碎 提交于 2019-12-02 00:04:25
I am sending USSD code on modem through serial port. But always it is giving ERROR in response. AT commands I am sending are: in sequence: serialPort.Write("AT+CMGF=0" + "\r\n"); serialPort.Write("AT+CUSD=1,\"*135#\"" + "\r\n"); when I am configuring message format in first AT command, it is giving 'OK' response. But on sending USSD code, response is always 'ERROR'. Why is it so? pumaikar Don't use \n in end of command, use only \r . Form of CUSD command is: AT+CUSD=1,"*135#",15 . In C# it should be: serialPort.Write("AT+CMGF=0" + "\r"); serialPort.Write("AT+CUSD=1,\"*135#\",15" + "\r");

Error on checking balance via USSD

a 夏天 提交于 2019-12-01 10:42:30
I've been trying to check my balance from by 3g modem via AT commands and seem to be stuck. The device infomation is as follows: Manufacturer: QUALCOMM INCORPORATED Model: M6281 Revision: SSD_M6281A-0.0.1 1 [Oct 02 2008 07:00:00] The modem has USSD capability (advertised and also present in the factory installed dashboard). I am connecting via putty to COM4 serial port which is my modems application port. All AT commands are working fine but I am getting an error on issuing the following via putty: AT+CUSD=1,"*111#",15 This returns a simple "ERROR". *111# is my carrier's balance check code. I

How to read USSD Message response in android

偶尔善良 提交于 2019-12-01 08:04:48
问题 i want to store my balance in sqlite database i am successfully dial the USSD String balance_check="*444"; String encodedHash = Uri.encode("#"); String ussd = balance_check + encodedHash; startActivityForResult(new Intent("android.intent.action.CALL",Uri.parse("tel:" + ussd)), 1); Here is onActivityResult function @Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); if (requestCode == 1) { if

Error on checking balance via USSD

*爱你&永不变心* 提交于 2019-12-01 07:28:59
问题 I've been trying to check my balance from by 3g modem via AT commands and seem to be stuck. The device infomation is as follows: Manufacturer: QUALCOMM INCORPORATED Model: M6281 Revision: SSD_M6281A-0.0.1 1 [Oct 02 2008 07:00:00] The modem has USSD capability (advertised and also present in the factory installed dashboard). I am connecting via putty to COM4 serial port which is my modems application port. All AT commands are working fine but I am getting an error on issuing the following via

Run USSD Code in Android and Keep the App in the firstground

房东的猫 提交于 2019-11-30 22:28:17
I am creating a App in Android, which required run USSD Code in background. without send my application in background, Whenever I am using Intent.ACTION_CALL to run USSD String ussdCode = "*" + "123" + Uri.encode("#"); startActivity(new Intent("android.intent.action.CALL", Uri.parse("tel:" + ussdCode))); it send my application in background, and open dialer Interface on my application. So it is possible to run USSD code without open Dialer Interface in front. Thanks. Use following code: String ussdCode = "*123#"; Intent intent = new Intent(Intent.ACTION_CALL); intent.setData(ussdToCallableUri

hash key “#” stripped from ussd code in “tel:” links on html pages

 ̄綄美尐妖づ 提交于 2019-11-30 20:12:14
Good day all. I have a simple link on a webpage, in where the user can call an USSD number: <a href="tel:*111*2#" class="phoneCallButtonLink">*CLICK HERE AND CALL *111*2#</a> this is pretty straight forward; now, if I test it on desktop browser, it popups an alert asking me if I want to call (with skype) the number *111*2# , and thats ok. with my Android phone (S Note 3), when testing this page, the phone (or something) stripped out the last "#" (only the last) from the link, resulting in a call to *111*2 . does anyone has experienced this? or knows how to prevent this? Use URL encoding for

What is the maximum number of characters in an USSD message?

孤者浪人 提交于 2019-11-30 20:03:53
I've understood that an USSD message consists of 160 bytes. For 7 bit data coding schemes, the maximum number of characters is 160*8/7 which gives 182 characters. It's unclear to me what is the maximum number of characters for UCS2 encoding. Normally, it would be something like 160/2, but I have some mixed information on this. The maximum size of a USSD message is 160 bytes. For GSM 7 Bit messages you are correct in saying the limit is 182 characters. UC2 encoding per definition is fixed 2 bytes per character so you will have a maximum of 80 characters. 来源: https://stackoverflow.com/questions

design pattern suggestion for ussd

折月煮酒 提交于 2019-11-30 16:04:11
问题 I'm using php to create a USSD page. I've done this before and it was quite the time-constrained hack-job; basically one huge file with a switch statement for all the possible states that the cellphone user can be in (which is then saved in a DB and retrieved upon the next USSD request) -- a state machine of sorts. This time round I have a bit more time and would like to use something more professional . Are there any design patterns or best practices that I can use for this kind of scenario?

How to send a USSD code containing decimal floating point (.)?

坚强是说给别人听的谎言 提交于 2019-11-30 07:56:42
问题 I need to send a USSD code containing a double value, that represents the balance account amount to be transferred. This value is composed by an integer number, and optionally a decimal separator and 2 more digits. My code looks as follows: double doubleValue = 0.70; String phoneNumber = "51234567", pincode = "1234"; String ast = Uri.encode("*"); String baseUssd = ast + "234" + ast + "1" + ast + phoneNumber + ast + pincode + ast; StringBuilder builder = new StringBuilder(); builder.append

Java USSD menu tree generation - how to

萝らか妹 提交于 2019-11-30 07:23:34
I want to generate a tree-based menu using Java that will appear on a USSD browser. Each node may have children, ending with leaf nodes. I will also have to maintain state regarding each user who accesses this menu (like his current position on the menu) to facilitate navigation. Any ideas on how I may achieve the tree generation and state management? I assume that you get a message from the gateway such as: (Session#, UserInput) and you need to compute the next information to send to the user ? I propose: table CURRENTSTATE: Session# State table STATES: State Title table CHOICES: State Choice