I have Downloaded the jUART and built according to mentioned steps in readme.md. It generates npjUART.so. Copied this generated .so file to /usr/lib/.mozilla/plugins directory.
I am trying to know com ports present in the ubuntu machine by calling the getports api.
I could able to see COM port ttyUSB0 in the /dev/ directory. However no devices are displayed when i run the html file. Here is the code I am trying.
function ListPorts() {
if ( ser ) ser.close();
console.time("plugin.serial");
ser = plugin().Serial;// Get a Serial object
if ( ser ) { console.log("Got serial object successfully..."); }
else { alert("ERROR: Could not get serial object!"); return; }
console.timeEnd("plugin.serial");
console.time("getports");
ports = ser.getports();
console.timeEnd("getports");
console.log( "Available ports: " + ports);
}
Hi,
I have Downloaded the jUART and built according to mentioned steps in readme.md. It generates npjUART.so. Copied this generated .so file to /usr/lib/.mozilla/plugins directory.
I am trying to know com ports present in the ubuntu machine by calling the getports api.
I could able to see COM port ttyUSB0 in the /dev/ directory. However no devices are displayed when i run the html file. Here is the code I am trying.
function ListPorts() { if ( ser ) ser.close(); console.time("plugin.serial"); ser = plugin().Serial;// Get a Serial object if ( ser ) { console.log("Got serial object successfully..."); } else { alert("ERROR: Could not get serial object!"); return; } console.timeEnd("plugin.serial"); console.time("getports"); ports = ser.getports(); console.timeEnd("getports"); console.log( "Available ports: " + ports); }
Could you please tell if i am missing anything.
Thanks Mahendra.