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

International characters #1

Closed
GoogleCodeExporter opened this issue Mar 13, 2015 · 1 comment
Closed

International characters #1

GoogleCodeExporter opened this issue Mar 13, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

What steps will reproduce the problem?
1. Send an SMS to the E220 that contains international characters (å,ä,ö)
2. Reading the SMS from the device using sms_read() returns the SMS 
without the international characters.
3.

What is the expected output? What do you see instead?
I send:
Testar att skicka ett sms med övriga tecken som inte används i 
engelskspråkiga länder.

sms_read() returns:
Testar att skicka ett sms med vriga tecken som inte anvnds i 
engelsksprkiga lnder.


What version of the product are you using? On what operating system?
pyhumod 0.03 on Slackware 13.0 with Linux 2.6.33.1

Please provide any additional information below.

Sending SMS with international characters:

>>> m.sms_send('+46xxxxxxxxx', 'Testar att skicka med å och ä och ö.')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python2.6/site-packages/humod/at_commands.py", line 
136, in sms_send
    result = self.ctrl_port.return_data()
  File "/usr/lib64/python2.6/site-packages/humod/humodem.py", line 179, in 
return_data
    input_line = self.readline().rstrip()
  File "/usr/lib64/python2.6/site-packages/serial/serialutil.py", line 62, 
in readline 
    c = self.read(1)
  File "/usr/lib64/python2.6/site-packages/serial/serialposix.py", line 
353, in read buf = os.read(self.fd, size-len(read))
OSError: [Errno 11] Resource temporarily unavailable

Original issue reported on code.google.com by tom.leht...@gmail.com on 21 May 2010 at 11:20

@fmalina
Copy link
Collaborator

fmalina commented Mar 27, 2015

I would expect that your network operator at the time converted Unicode to safe ASCII and this is not an issue with PyHumod.

Texts containing international characters usually arrive gsm0338 encoded and need to be decoded using decode_gsm(message) function from siminfo.py or using gsm0338 codec message.decode('gsm0338').

@fmalina fmalina closed this as completed Mar 27, 2015
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

2 participants