• 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. ADE-XL and matlab debugging

Stats

  • Locked Locked
  • Replies 17
  • Subscribers 126
  • Views 22682
  • 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

ADE-XL and matlab debugging

danmc91
danmc91 over 10 years ago

I came across a limitation in the waveform calculator recently and decided to  try out using matlab for processing some simulation results.  I've had some successes and at least as many failures and am hoping to get the failures resolved.

matlab version:  2012B

IC version:  6.1.6.500.6

MMSIM version: 13.11.078

Platform:  RHEL 5.5

  1. Simulate with ADE-L, look at results in matlab.  After using addpath() twice in matlab or setting MATLABPATH to include both .../tools/spectre/matlab and .../tools/spectre/matlab/64bit I was able to read results using cds_srr(), run my analysis, etc.
    1. Is there a way in ADE-L (not -XL) to include a matlab measure in the outputs or launch matlab to produce some plots? 
    2. The documentation seemed to miss me needing to add the .../tools/spectre/matlab/64bit part to MATLABPATH and I was failing to find cds_innersrr at first.
  2. Launch matlab from the CIW window:  shell("matlab &").  Weird.  doesn't seem to work.  I think DISPLAY may not be set but shell("xterm -e matlab &") launches matlab with the gui, no problem.
  3. Simulate in ADE-XL, use a matlab output.  Here is where I totally crash and burn. 
    1. ERROR (ADEXL-4031): Matlab script directory.  It doesn't like a colon in my ADE-XL file structure and I'm told to use:  envSetVal("adexl.setup" "useNMPForMapping" 'boolean t).  However the adexl.setup partition doesn't exist.  adexl.setupdb does exist but making this setting does not make the error go away.
    2. WARNING (ADEXL-4010): No outputs specified in the Matlab script.  Scalar outputs can be specified in 'axlResult' in Matlab script..  But I *do* have axlResult=3.7; in my script (just put in a number to rule out other issues.
    3. I can't find any log of any sort at all related to the matlab script running.  If I watch the output of 'top' I see a matlab process start and then end.  I've tried making my matlab script only open up a text file for writing, printing out "hello, world" to the file and closing it.  Even that doesn't happen.
    4. Then I tried envSetVal("adexl.gui" "copyMeasurementScripts" 'boolean nil) to avoid having the matlab script end up in a directory with ":" in the name.  I put that envSetVal in my .cdsinit and restarted virtuoso and ADE-XL.  Same result as before (script got copied to ADE-XL directory with a ":" in the name and I got a ERROR (ADEXL-4031): Matlab script directory).
    5. If I ever get past this, can I return a waveform (or multiple waveforms) back to ADE-XL from matlab?

This seems very close but close is not good enough.  The lack of any sort of log that I can find is perhaps the most frustrating.  I don't know how ADE-XL is launching matlab, what arguments it may be giving to matlab, what environment it may be giving to matlab, etc.  It makes it very hard to debug.

Thanks

-Dan

  • Cancel
Parents
  • Andrew Beckett
    Andrew Beckett over 10 years ago

    Hi Dan,

    I would suggest that some of these you contact customer support and request them as enhancements. I can give you some references for some of them that I think would be worth following up on, and I'll indicate those that are unlikely to have anything done on:

    1. Log file - excellent idea. Debugging right now is far harder than it should be.
    2. This is probably not that straightforward when you have multiple tests or multiple outputs (or sweeps, corners etc) as all will go through the same matlab; matlab doesn't actually exit. I can see why you want it though...
    3. I think it's highly unlikely Matlab or Ocean script output support will be added to ADE L
    4. Waveform output is an existing enhancement CCR (filed by me): 989142
    5. Multiple outputs - good idea. There are a number of existing requests for this - the master CCR is 1034185
    6. Octave support. There are CCRs for this, but there is little prospect of this. We have looked into it in some detail, but the Octave license  makes this a non-starter for a commercial tool (I won't go into all the details here - but we have looked into this in some depth and tried to find solutions to it). I can entirely see why you'd want this (and some of the CCRs on this are from me), but this is very unlikely to be possible.

    So for 1, 4 and 5 above, I'd suggest contacting support and then either new CCRs or duplicates can be filed. Maybe 2 as well, although that's not so obvious how it could be done.

    Kind Regards,

    Andrew.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 10 years ago

    Hi Dan,

    I would suggest that some of these you contact customer support and request them as enhancements. I can give you some references for some of them that I think would be worth following up on, and I'll indicate those that are unlikely to have anything done on:

    1. Log file - excellent idea. Debugging right now is far harder than it should be.
    2. This is probably not that straightforward when you have multiple tests or multiple outputs (or sweeps, corners etc) as all will go through the same matlab; matlab doesn't actually exit. I can see why you want it though...
    3. I think it's highly unlikely Matlab or Ocean script output support will be added to ADE L
    4. Waveform output is an existing enhancement CCR (filed by me): 989142
    5. Multiple outputs - good idea. There are a number of existing requests for this - the master CCR is 1034185
    6. Octave support. There are CCRs for this, but there is little prospect of this. We have looked into it in some detail, but the Octave license  makes this a non-starter for a commercial tool (I won't go into all the details here - but we have looked into this in some depth and tried to find solutions to it). I can entirely see why you'd want this (and some of the CCRs on this are from me), but this is very unlikely to be possible.

    So for 1, 4 and 5 above, I'd suggest contacting support and then either new CCRs or duplicates can be filed. Maybe 2 as well, although that's not so obvious how it could be done.

    Kind Regards,

    Andrew.

    • 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