Hello,
I was wondering if it is possible to connect to a Linux computer and open a terminal in order to send and receive commands and data (inside a vee program of course ).
This is the problem:
DUT is connected to a Linux machine (can be a raspberry pi). My test program connects to the Linux machine, runs some scripts and starts a bridge and ... . As it stands now it uses teraterm macro and/or python (any external program) to manage the job.
I would like to know if there is a way to connect to a computer inside the vee program and keep this connection open until the test ends. I would appreciate any advice.
Thanks
Sima
The Short Answer is "yes" - just open a socket and go at it.
The long answer is of course a lot more involved- and boils down to "you probably don't want to".
What's going on is that opening a socket is the trivial part. Communicating via that socket is the 99+% of the problem since it involves a communications protocol (whatever you choose to use). Since VEE does not natively include comm protocols (SSH/whatever) and noone has contributed libraries for them, you would need to implement them yourself. Certainly doable (see Short Answer) but likely not worth the effort. Instead, as you found for your existing solution, use an environment (python et al) where the chosen protocol has already been implemented in a contributed library. So from inside VEE you would almost certainly want to call an external library of some sort ( win32/dotnet/scripting/etc) that already groks the protocol you choose to use.
Another option for a special case like yours though is to write a program that runs on your Linux box and is capable of doing whatever chores are needed there, plus can be controlled via a socket. That is, write yourself a simple program and create your own simple protocol. If all it does is run a few scripts, maybe save some data, simple stuff like that then your protocol could be very easy- perhaps just a few commands.
You'd of course then be all set to "open a socket and go at it"
Stan