.
You can use custom scripts written on python and can use a potential divider circuit on port of a commonly available hardware platform like arduino. I myself developed a very simple you can find on Fritzing. Its a PC based switch but same can be used for DAQ.