Forum Discussion
Altera_Forum
Honored Contributor
16 years agoQAM modulation technique using verilog
Hi all, Anyone knows how to do Quad amplitude modulation QAM (16 or 64) doesnt matter.. using verilog? Please help me. Thanks.. -John- Kuala Lumpur
Altera_Forum
Honored Contributor
16 years agoHi all Thanks for your feedback. i found some coding bout this. But seems like got error in certain line. Anyone expert to debug this?
module qam16(in,out); input [0:3] in; output out; voltage in,out; parameter real freq = 1.0 from (0:inf); parameter real ampl = 1.0, thresh = 2.5; parameter real tdelay = 0 from [0:inf), ttransit = 1/freq; real x,y,phi; integer row,col; analog begin row = 2*(V(in[3]) > thresh + V(in[2]) > thresh); col = 2*(V(in[1]) > thresh + V(in[0]) > thresh); x = transition(row-1.5,tdelay,ttransit); y = transition(col-1.5,tdelay,ttransit); phi = 2 * `M_PI * freq * $realtime(); V(out) <+ ampl * (x * cos(phi) + y * sin(phi)); end endmodule Thanks. -John-