This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TSC2017: Can't access the TSC2017 from software using visa

Part Number: TSC2017
Other Parts Discussed in Thread: TSC2003, TSC2007

Hello

I have a TSC2017 touchpad (TSC2017EVM-PDK), connected to my computer on USB. I am trying to access it from my software using the visa library on python.

My problem is that the device seems to be undetected by the python/visa.

I run the following code to detect the devices connected to the computer:

import visa

rm = visa.ResourceManager("C:\windows\SysWOW64\visa32.dll")

rm.list_resources()

The last line returns an empty list, as if the connected device was not detected.

The device is connected properly to the computer - when I run the TSC2017EVM software, it detects the touch and shows it on screen.

I am using Windows 10 and running python 32-bit (to be compatible with the 32-bit visa.dll).

Any help would be great

Thanks,

Dror

  • Hello Dror Dotan,

    Welcome to E2E, thanks for your interest in our products.
    Unfortunately, TI's resistive touch screen controllers can't work in Windows 10. They can work in Windows 7 and lower versions.

    Best Regards
    José Luis Figueroa
    Applications Engineer

  • Thank you José,

    I now tried connecting the device to windows 7 but I still get the same problem: Python's resource_manager.list_resources() command does not detect the device.

    Any ideas perhaps?

    Thanks!

    Dror

  • Hi Dror Dotan,

    The firmware of these kinds of devices was done with C/C++, I can provide it to you so that you rewrite to Python.
    Let me know your thoughts.

    Best Regards
    José Luis Figueroa
    Applications Engineer
  • Thanks again, José,

    Does it matter that the firmware is C? Can't the device can communicate over VISA protocol, in which case I can connect to it via Python?

    Thanks
    Dror
  • Dror Dotan,

    I think that it is possible the communication in your application. Perhaps there is an error in the source code.

    Best Regards
    José Luis Figueroa
    Applications Engineer
  • Thank you José

    I now managed to connect to the device using NI-VISA, is there an available description of the protocol I should use to read the touch position?

    Thanks
    Dror
  • Hello Dror,

    Not really, but you can have a look at the application report called Operation Schemes of Touch Screen Controller here can find some information about as the communication is performed.

    Best Regards
    José Luis Figueroa
    Application Engineer

  • Thanks!

    The TSC2017 is register-based, right?

    Perhaps there is some example for code that runs on windows an communicates with the device?

    The problem is that all these documentation are at the physical level, and I'm trying to figure out how to turn this into PC software. Also, I don't fully understand which of this information is things implemented by the USB-MODEVM card, which is implemented by the NI-VISA software that runs on the PC, and which should be implemented by my own code that calls the NI-VISA interface. Any ideas for where I can get hints from?

    Thanks again

    Dror

  • Hi Dror,

    TSC2017 is compatible with TSC2003 and TSC2007, therefore TSC2017 should be Advanced Command-Based.
    You can find an example code in the next link: Reference Firmware.

    Best Regards
    José Luis Figueroa
    Application Engineer

  • Thanks.

    Few questions about this app:
    1. What does it do? Is it used in the GUI application that I received with the TSC2017?
    2. Does it run on windows?
    3. Is it an app or a driver?
    4. Is it possible to compile it on my computer? What does it require to compile?

    Also, it seems that your application (the one I installed with the TSC2017 drivers) communicates with your device using NI-VISA (e.g., it installed NI-VISA on my computer, and if VISA is not set up properly, the GUI app can't start). Could I get information about how to communicate with the device over VISA, like your application does?

    Thanks!
    Dror
  • Hi Dror,

    1) Yes, it is. This firmware is used in the GUI application and TSC2017.
    2) Yes, it does.
    3) It is the used firmware to set the communication between the TSC2017 and the PC.
    4) Yes, it is. I think whatever compile of C/C++ should be able to use it.

    The device uses the firmware code to communicate with the PC (VISA).

    Best Regards
    José Luis Figueroa
    Application Engineer
  • Dror,

    Probably you have already figured it out by now. In any case, I thought clarifying this might help

    1. What does it do? Is it used in the GUI application that I received with the TSC2017?
    >> The link to source code Jose provided above is the TSC2017 firmware that runs on TAS1020B (streaming audio USB controller with an 8051-based core) in USB-MODEVM card. Basically it reads touch data from the device (over i2c) and sends it to the GUI for display. You can understand a little more of the GUI/firmware communication by going through Section 6.3 (GUI and Operation Description) of the PDK user manual
    www.ti.com/.../slau305

    2. Does it run on windows?
    >>No

    3. Is it an app or a driver?
    >>It's a firmware that runs on the TAS1020B controller in USB-MODEVM card.

    4. Is it possible to compile it on my computer? What does it require to compile?
    >>Yes, you can compile it using IAR work bench. So you do cross compilation on the windows platform and generate the code to load into the TAS1020B controller.

    Thanks,
    Vishy