Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sms newline on Linux #19

Open
GoogleCodeExporter opened this issue Dec 1, 2015 · 1 comment
Open

sms newline on Linux #19

GoogleCodeExporter opened this issue Dec 1, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

On linux the \n\r will not execute the command on my modem. It is expecting to 
receive a carriage return that is not given in this way. Haven't tested it on 
Windows yet. Instead I replaced the \n\r with a chr(13) and that made it work.

\n\r result:

hans@debian:~/phpserial/trunk# php sms-example.php 
string(2) "AT"
string(25) "AT+CMGF=1

NO CARRIER

chr(13) result:

hans@debian:~/phpserial/trunk# php sms-example.php 
string(9) "AT
OK
"
string(16) "AT+CMGF=1
OK

Original issue reported on code.google.com by [email protected] on 26 Jan 2014 at 11:19

@GoogleCodeExporter
Copy link
Author

Tried with Windows and it did not work. Code sent for \r is x8d should be x0d

Original comment by [email protected] on 27 Feb 2014 at 6:50

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant