I am trying to display ngspice output via PHP.
I am able to display the terminal output but i am unable to display the graph. I get an error saying:
"ERROR: (internal) This operation is not defined for display type printf. Can't open viewport for graphics. Note: No ".plot", ".print", or ".fourier" lines; no simulations run "
THis is my netlist file:
*ngspice netlist*
v1 1 0 dc 5v
r1 1 0 1k
.tran 1e-03 11e-03 1e-03
.control
run
plot allv
.endc
.end
When this executed separately on terminals gives graph but I am unable to display graph via PHP. I run this code in HP by this code:
$output=shell_exec(' ngspice /var/www/html/eSIM/netlist.txt 2>&1 ' );