Verilog-A release version.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

21 lines
533 B

//VerilogA for passive,gainbasic,veriloga
`include "constants.vams"
`include "disciplines.vams"
module gainbasic(Ipow,Iphase,Ilam,Opow,Ophase,Olam);
parameter real G = 1 from [0:inf);
// parameter real phaseshift=0;
// parameter real noisefigure=0;
input Ipow,Iphase,Ilam;
output Opow,Ophase,Olam;
electrical Ipow,Iphase,Ilam,Opow,Ophase,Olam;
// real S;
analog begin
// S=(G*pow(10,noisefigure/10)-1)*`P_C*`P_H/V(Ilam);
V(Opow) <+ G*V(Ipow);
V(Ophase) <+ V(Iphase);//+phaseshift;
V(Olam) <+ V(Ilam);
end
endmodule