Howdy
5 years 2 months ago - 5 years 2 months ago #4727
by Simomax
\r\n is ascii for 'carriage return' and 'new line' So it looks to me like '19\r\n20\r\n' is the equivalent of:
19
20
Doing a quick search it appears that the error 'invalid literal for int() with base 10' is when it is reading a float value as an integer, or the variable is an integer and the data is something else. It seems strange that you get a few lines OK and boom, it breaks. Is there any way you can test with a different TTL/USB adapter? I would take a stab that the data from the GC10 is somehow being corrupted or read wrong or something. What I mean is that pyradmon is looking for an integer i.e. '19' but is receiving something different. Either some ascii character or something else that is being received by pyradmon that it doesn't like. Oh, Base 10 simply means decimal, 0 - 9. Base 7 is Octal and base 16 is HEX etc to put it into comparison.
Edit; can you fire up a terminal on your Pi and just leave it printing the cpm for some time. Check for bad characters, carriage returns or new lines that are missing. What you want is a constant stream of the CPM being printed on a new line each time and only that. If you are receiving the odd character that isn't a number that could be your issue.
19
20
Doing a quick search it appears that the error 'invalid literal for int() with base 10' is when it is reading a float value as an integer, or the variable is an integer and the data is something else. It seems strange that you get a few lines OK and boom, it breaks. Is there any way you can test with a different TTL/USB adapter? I would take a stab that the data from the GC10 is somehow being corrupted or read wrong or something. What I mean is that pyradmon is looking for an integer i.e. '19' but is receiving something different. Either some ascii character or something else that is being received by pyradmon that it doesn't like. Oh, Base 10 simply means decimal, 0 - 9. Base 7 is Octal and base 16 is HEX etc to put it into comparison.
Edit; can you fire up a terminal on your Pi and just leave it printing the cpm for some time. Check for bad characters, carriage returns or new lines that are missing. What you want is a constant stream of the CPM being printed on a new line each time and only that. If you are receiving the odd character that isn't a number that could be your issue.
Last edit: 5 years 2 months ago by Simomax.
Please Log in or Create an account to join the conversation.
5 years 2 months ago #4740
by Wukong
Bingo! Erm, thanks for all your help, but turns out its my fault entirely!
I just needed to choose netio as the protocol, in the config file, because i have a netio device. Heh.
Seems to be working just fine!
Kingston Tasmania has a rad monitor!
Nice to find a decent use for my pi zero.
I just needed to choose netio as the protocol, in the config file, because i have a netio device. Heh.
Seems to be working just fine!
Kingston Tasmania has a rad monitor!
Nice to find a decent use for my pi zero.
Please Log in or Create an account to join the conversation.
Moderators: Gamma-Man
Time to create page: 0.178 seconds