Nakul
Nakul

Reputation: 31

How to call C functions from python?

I have a scenario where GUI (Developed in VB) is sending commands to the target system application developed in C language (Xilinx).

User on a PC sends the commands to target using GUI.

But now I need to remove the GUI and want to send commands (call C functions in target system application) using Python.

I found some useful info from ctypes but don't know the exact procedure so getting budded up frequently.

Question :

Can anyone tell me the exact procedure to develop a python script for this. I know fair amount of python scripting.

Upvotes: 3

Views: 729

Answers (1)

Sanjay
Sanjay

Reputation: 156

Invoke a SWIG wrapper to make C functions look like Python functions. Take a look at this example.

Upvotes: 1

Related Questions