Open the first device available

Opening the first available device requires only an instance of okCFrontPanel and is done by calling OpenBySerial without a specified serial number. In C++ OpenBySerial can take NULL as an input, but C#, Java, and Python require an empty string.

C/C++

okCFrontPanel dev;
dev.OpenBySerial();Code language: CSS (css)

C#

okCFrontPanel dev = new okCFrontPanel();
dev.OpenBySerial("");Code language: JavaScript (javascript)

Python

dev = ok.okCFrontPanel()
dev.OpenBySerial("")Code language: JavaScript (javascript)

Java

public class example{
     okCFrontPanel dev;
 
     public void OpenDevice(){
          dev = new okCFrontPanel();
          dev.OpenBySerial("");
     }
}Code language: PHP (php)