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

ICOc: Crash (Probably After Filling CAN Buffer) #58

Closed
sanssecours opened this issue Jun 19, 2024 · 1 comment
Closed

ICOc: Crash (Probably After Filling CAN Buffer) #58

sanssecours opened this issue Jun 19, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@sanssecours
Copy link
Member

Description

Stack trace from a crash of ICOc:

icoc -1 2 -2 3 -3 4 -v Vfs1V8

from a video conference with @bertlderschreckliche:

Warning: Unable to determine sensor range from EEPROM value — Assuming ± 100 g sensor
Error
—————
☹️ 'utf-8' codec can't decode byte 0xe4 in position 29: invalid continuation byte

Stack Trace
———————————
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Scripts\icoc.exe\__main__.py", line 7, in <module>
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 816, in main
    raise error
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 812, in main
    UserInterface().run()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 806, in run
    wrapper(self.user_interface)
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\curses\__init__.py", line 94, in wrapper
    return func(stdscr, *args, **kwds)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 795, in user_interface
    while self.main_window():
         ^^^^^^^^^^^^^^^^^^
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 781, in main_window
    return self.main_window_key_evaluation()
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 753, in main_window_key_evaluation
    self.sth_window()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 583, in sth_window
    continue_sth, continue_main = self.sth_window_key_evaluation()
                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\ui.py", line 565, in sth_window_key_evaluation
    self.vDataAquisition()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 825, in vDataAquisition
    self.vGetStreamingAccData()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 1005, in vGetStreamingAccData
    self.vGetStreamingAccDataProcess()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 933, in vGetStreamingAccDataProcess
    self.read_streaming()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 885, in read_streaming
    self.read_streaming_messages()
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 907, in read_streaming_messages
    error_message = self.get_can_error_message(
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\mytoolit\old\cli.py", line 857, in get_can_error_message
    error_message = self.Can.pcan.GetErrorText(status)[1].decode()
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe4 in position 29: invalid continuation byte
C:\Users\nleder\AppData\Local\Programs\Python\Python311\Lib\site-packages\tables\file.py:113: UnclosedFileWarning: Closing remaining open file: C:\Users\nleder\Documents\MyT_recordings\Measurement_2024-06-19_15-13-25.hdf5
warnings.warn(UnclosedFileWarning(msg))

Looks like the error message text contains non-UTF-8 (non-ASCII) data.

@sanssecours sanssecours added the bug Something isn't working label Jun 19, 2024
sanssecours added a commit that referenced this issue Jul 1, 2024
Hopefully this commit fixes
[issue 58](#58).
sanssecours added a commit that referenced this issue Jul 1, 2024
Hopefully this commit fixes
[issue 58](#58).
@sanssecours
Copy link
Member Author

I was able to reproduce this problem by running Prime 95 in the background. While the program still crashes, at least the error message on a German system should be displayed (more or less) properly:

Error
—————
☹️ Unable to read streaming message: Die Empfangsqueue wurde zu spät gelesen

Stack Trace
———————————
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\Users\Rene\AppData\Local\Programs\Python\Python312\Scripts\icoc.exe\__main__.py", line 7, in <module>
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\ui.py", line 821, in main
    raise error
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\ui.py", line 817, in main
    UserInterface().run()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\ui.py", line 809, in run
    self.vRunConsoleAutoConnect()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 1123, in vRunConsoleAutoConnect
    self.vDataAquisition()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 841, in vDataAquisition
    self.vGetStreamingAccData()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 1023, in vGetStreamingAccData
    self.vGetStreamingAccDataProcess()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 951, in vGetStreamingAccDataProcess
    self.read_streaming()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 903, in read_streaming
    self.read_streaming_messages()
  File "C:\Users\Rene\Documents\Projects\ICOc\mytoolit\old\cli.py", line 928, in read_streaming_messages
    raise Exception(error_message)
Exception: Unable to read streaming message: Die Empfangsqueue wurde zu spät gelesen
C:\Users\Rene\AppData\Local\Programs\Python\Python312\Lib\site-packages\tables\file.py:113: UnclosedFileWarning: Closing remaining open file: C:\Users\Rene\Documents\Projects\ICOc\Measurement_2024-07-01_14-39-13.hdf5
  warnings.warn(UnclosedFileWarning(msg))

sanssecours added a commit that referenced this issue Jul 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant