• 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

    Dan,

    For me, axlDebugFlag works, but looking again at the code, it probably should have been _axlDebugFlag=t (with a leading underscore). I can't test the matlab interface as I'm not using my work computer (where I have access to matlab), but I'm pretty sure that should do it. It's more verbose however and prints far more other things.

    You're right though - copyMeasurementScripts set to nil doesn't seem to be working. I just tried it. I filed CCR 1422706 to get this fixed. It appears initially that the path is preserved, but as soon as it saves the adexl view (either via save or by running a sim), it changes it to be in the adexl view.

    Regards,

    Andrew.

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

    Dan,

    For me, axlDebugFlag works, but looking again at the code, it probably should have been _axlDebugFlag=t (with a leading underscore). I can't test the matlab interface as I'm not using my work computer (where I have access to matlab), but I'm pretty sure that should do it. It's more verbose however and prints far more other things.

    You're right though - copyMeasurementScripts set to nil doesn't seem to be working. I just tried it. I filed CCR 1422706 to get this fixed. It appears initially that the path is preserved, but as soon as it saves the adexl view (either via save or by running a sim), it changes it to be in the adexl view.

    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