-
Notifications
You must be signed in to change notification settings - Fork 7
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
ValueError: invalid literal for int() with base 10: ',' #6
Comments
Seems like you get an unexpected data sequence on URC: CEREG What module are you using? Could you enable debug logging and send a complete log. I would like to see the data that is sent and received. |
Hi Henrik,
The full debug log:
DEBUG:ublox.modules:Applying AT Command: AT+CSCON=1
DEBUG:ublox.modules:Sent: b'AT+CSCON=1\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+CEREG=5
DEBUG:ublox.modules:Sent: b'AT+CEREG=5\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+NPSMR=1
DEBUG:ublox.modules:Sent: b'AT+NPSMR=1\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+NCONFIG="CR_0354_0338_SCRAMBLING","TRUE"
DEBUG:ublox.modules:Sent: b'AT+NCONFIG="CR_0354_0338_SCRAMBLING","TRUE"\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+NCONFIG="CR_0859_SI_AVOID","FALSE"
DEBUG:ublox.modules:Sent: b'AT+NCONFIG="CR_0859_SI_AVOID","FALSE"\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+CFUN=0
DEBUG:ublox.modules:Sent: b'AT+CFUN=0\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Received: [b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+CGDCONT=0,"IP","cdp.iot.t-mobile.nl<http://cdp.iot.t-mobile.nl>"
DEBUG:ublox.modules:Sent: b'AT+CGDCONT=0,"IP","cdp.iot.t-mobile.nl<http://cdp.iot.t-mobile.nl>"\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Processing URC: +NPSMR: 0
DEBUG:ublox.modules:Unhandled urc: b'+NPSMR: 0'
DEBUG:ublox.modules:Received: [b'+NPSMR: 0', b'OK']
DEBUG:ublox.modules:AT Command response = []
DEBUG:ublox.modules:Applying AT Command: AT+CFUN=1
DEBUG:ublox.modules:Sent: b'AT+CFUN=1\r\n'
DEBUG:ublox.modules:Recieved ack: b'\r\n'
DEBUG:ublox.modules:Processing URC: +CEREG: 0,"0000","0",7,,,,
Traceback (most recent call last):
File "test.py", line 37, in <module>
module._at_action('AT+CFUN=1')
File "/Users/sammobach/PycharmProjects/nb_iot/venv/lib/python3.7/site-packages/ublox/modules.py", line 246, in _at_action
capture_urc=capture_urc)
File "/Users/sammobach/PycharmProjects/nb_iot/venv/lib/python3.7/site-packages/ublox/modules.py", line 330, in _read_line_until_contains
self._process_urc(line)
File "/Users/sammobach/PycharmProjects/nb_iot/venv/lib/python3.7/site-packages/ublox/modules.py", line 381, in _process_urc
self._update_eps_reg_status_callback(urc)
File "/Users/sammobach/PycharmProjects/nb_iot/venv/lib/python3.7/site-packages/ublox/modules.py", line 428, in _update_eps_reg_status_callback
status = int(chr(urc[-1]))
ValueError: invalid literal for int() with base 10: ','
The module: Ublox N211
RAT: NB-IoT
Board: Arduino
On 28 Sep 2019, at 14:52, Henrik Wahlgren <notifications@github.com<mailto:notifications@github.com>> wrote:
Seems like you get an unexpected data sequence on URC: CEREG
What module are you using?
What RAT? (NB-IoT, LTE-M).
What board are you using?
Could you enable debug logging and send a complete log. I would like to see the data that is sent and received.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#6?email_source=notifications&email_token=AMYJQ2YV3HX7PYHFV4ONAX3QL5HRVA5CNFSM4I3IA2T2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD72ZDBI#issuecomment-536187269>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AMYJQ2YDAW4ORJENBYFTW7LQL5HRVANCNFSM4I3IA2TQ>.
|
But the weird part is, when I use the same commands on the serial monitor on the Arduino application, then It works.
On 28 Sep 2019, at 14:52, Henrik Wahlgren <notifications@github.com<mailto:notifications@github.com>> wrote:
Seems like you get an unexpected data sequence on URC: CEREG
What module are you using?
What RAT? (NB-IoT, LTE-M).
What board are you using?
Could you enable debug logging and send a complete log. I would like to see the data that is sent and received.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#6?email_source=notifications&email_token=AMYJQ2YV3HX7PYHFV4ONAX3QL5HRVA5CNFSM4I3IA2T2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD72ZDBI#issuecomment-536187269>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AMYJQ2YDAW4ORJENBYFTW7LQL5HRVANCNFSM4I3IA2TQ>.
|
OK. Thanks for the logs. You are sending CEREG=5 which enables the URC to send all available data. Do you need all the info? Otherwise I would ask you to just send CEREG=1 Or you can use the You could also use the Hope this helps |
Thanks a lot I fixed it by removing the AT+CEREG=5.
On 28 Sep 2019, at 20:30, Henrik Wahlgren <notifications@github.com<mailto:notifications@github.com>> wrote:
OK. Thanks for the logs.
You are sending CEREG=5 which enables the URC to send all available data.
The program as of now cannot handle the full response URC, I didnt see the need for it in my use cases. (though I have a note that I propably should use regex to handle the URC :P )
Do you need all the info? Otherwise I would ask you to just send CEREG=1
Or you can use the enable_signaling_connection_urc() function.
You could also use the setup() function that will run most of the commands you have used.
Hope this helps
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#6?email_source=notifications&email_token=AMYJQ25L74ANRX3G36RZHEDQL6PCZA5CNFSM4I3IA2T2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD727TXQ#issuecomment-536213982>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AMYJQ23ETEDDR2FZUTOEW5TQL6PCZANCNFSM4I3IA2TQ>.
|
I can't set the T-mobile PDP settings. Also when I try to use module._at_action('AT+CFUN=1') I get the same error as the title of this request.
The text was updated successfully, but these errors were encountered: