• 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. Mixed-Signal Design
  3. How to use calcVal for local sweep within the same test...

Stats

  • Locked Locked
  • Replies 0
  • Subscribers 64
  • Views 6776
  • 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

How to use calcVal for local sweep within the same test?

NewScreenName
NewScreenName over 2 years ago

Hello,

I have a test in which I sweep some variables, say A = 0 1 2, and then I define in the outputs an expression, say t_delay. My goal is to have also an output expression is myOutput = t_delay (when A=1) + t_delay (when A=0).

One way to do this would be to define multiple tests, each one with A being assigned a single value, and use calcVal properly I guess, however when the number of values A could assume become high, it would be a cumbersome solution.

Therefore what I tried to do was to use an ocean script which should allow me to retrieve an expression (i.e. t_delay ) from different A swept values (given a fixed corner) from any single run and compute the desired output (i.e. myOutput ). I was not able to find something in the documentation which could work for expressions the same way getData(expression ?result "tran" ?resultDir <path>) would work for signals. (I guess I could again retrieve the signals which are used to compute t_delay and use them to get myOutput right away, but again it would be cumbersome and like doing twice the same thing, as I already wrote the t_delay expression.

So the questions are:

1. How do I apply calcVal on a local sweep within the same test? when I write in the calculator calcVal( "t_delay" "test_name"  ?matchParams list(list("A" 0))) I would expect it to return t_delay for the run where I had A=0, but this is returning an error instead. However according to the documentation it should be possible to define calcVal in the same test where its output has to be retrieved, so I guess this should be possible?

2. what would be the correct syntax for calcVal in ocean? I tried with the following code for test purpose (without any sweep, to verify calcVal in ocean) but it returns error, while the same calcVal("t_delay" "myTest") directly written in the outputs tab of ADE assembler works just fine:

axlAddOutputs( list("t_delay"))

prova = calcVal("t_delay" "myTest")

axlOutputResult( t_delay "t_delay")

Thank you

Best regards

  • Cancel

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