Error when PLIN_API_example

The free LIN software API (Application Programming Interface) for Windows® (only for usage with the PCAN-USB Pro CAN/LIN interface)
Post Reply
gagan.k
Posts: 14
Joined: Mon 30. Dec 2024, 09:17

Error when PLIN_API_example

Post by gagan.k » Tue 7. Jan 2025, 13:40

Hello,
I am working on the PLIN API, the samples folder consists of sample GUI which is interfaced with PLIN_View_Pro application.
When I run the code, the GUI is opening successfully, and interface is working fine.
But when I select the button "Initialize", it is showcasing the errors stated below:

Code: Select all

Exception in thread tmrRead:
Traceback (most recent call last):
  File "C:\Users\AppData\Local\Programs\Python\Python38\lib\threading.py", line 932, in _bootstrap_inner
    self.run()
  File "C:\Users\AppData\Local\Programs\Python\Python38\lib\threading.py", line 870, in run
    self._target(*self._args, **self._kwargs)
  File "C:\Users\Desktop\plin-api (1)\Samples\Python\PLIN_API_Example3.pyw", line 920, in _run
    self._target(*self._args, **self._kwargs)
  File "C:\Users\Desktop\plin-api (1)\Samples\Python\PLIN_API_Example3.pyw", line 2176, in tmrRead_Tick
    self.readMessages()
  File "C:\Users\Desktop\plin-api (1)\Samples\Python\PLIN_API_Example3.pyw", line 2784, in readMessages
    self.processMessage(lpMsg)
  File "C:\Users\Desktop\plin-api (1)\Samples\Python\PLIN_API_Example3.pyw", line 2808, in processMessage
    self.insertMsgEntry(linMsg)
  File "C:\Users\Desktop\plin-api (1)\Samples\Python\PLIN_API_Example3.pyw", line 2828, in insertMsgEntry
    self.lstMessages.insert(
  File "C:\Users\AppData\Local\Programs\Python\Python38\lib\tkinter\tix.py", line 1455, in insert
    self.tk.call(self._w, 'insert', index, *self._options(cnf, kw))
RuntimeError: main thread is not in main loop
Provide me the solution which execute the program.
Last edited by M.Gerber on Mon 13. Jan 2025, 15:26, edited 1 time in total.
Reason: Inserted [code] tag for improved readability

M.Maidhof
Support
Support
Posts: 1753
Joined: Wed 22. Sep 2010, 14:00

Re: Error when PLIN_API_example

Post by M.Maidhof » Mon 13. Jan 2025, 12:49

Hi,

which PLIN hardware do you use? Does PLIN-View Pro work on your system correctly?

regards

Michael

gagan.k
Posts: 14
Joined: Mon 30. Dec 2024, 09:17

Re: Error when PLIN_API_example

Post by gagan.k » Wed 15. Jan 2025, 06:46

Hello,
Plin View Pro is working fine, and I am using PLIN USB IPEH-004052-000121

Regards,
Gagan

Post Reply