• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC Design
  3. Verilog -A amp

Stats

  • Locked Locked
  • Replies 5
  • Subscribers 125
  • Views 9513
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Verilog -A amp

black tea
black tea over 9 years ago

I want to design an Amp in cadence by verilog-A code. I write code like blow, but I don't know how to define two input value vin_offset and vin_high. the input signal is a sine wave, the vin_offset is offset value of the sine wave, and the vin_high is the largest value of sine wave, I want to know how to define these two input value in verilog-A code. Thank you very much.

//--------------------
// amp
//
// -  amplifer
//
// sigin:    input    (val,flow)
// sigout:    output    (val,flow)
//
// INSTANCE parameters
//    gain          = gain between input and output []
//    sigin_offset  = subtracted from 'sigin' before amplification (val)
//
// MODEL parameters
//    {none}
//

module amp(sigin, sigout);
input sigin;
output sigout;
electrical sigin, sigout;
parameter real gain = 0.5/(vin_high - vin_offset);


   analog
      V(sigout) <+ gain*V(sigin) + 0.5*gain - gain*vin_offset;

endmodule



  • Cancel
Parents
  • black tea
    black tea over 9 years ago
    thanks but the signal before the amp is produced by a circuit, so the vin_offset and vin_high value is not fixed, their values will changed by the circuit~ so I want to know how to define it, thanks again
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • black tea
    black tea over 9 years ago
    thanks but the signal before the amp is produced by a circuit, so the vin_offset and vin_high value is not fixed, their values will changed by the circuit~ so I want to know how to define it, thanks again
    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information