• 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 SKILL
  3. Adding menu to maestro

Stats

  • Locked Locked
  • Replies 4
  • Subscribers 143
  • Views 10875
  • 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

Adding menu to maestro

dragank
dragank over 4 years ago

Hi all.

I am using IC6.1.8-64b.500.10

Here is procedure that i am trying to use for adding new menu item to maestro:

procedure( InternalMaestroAddMenu(@rest args)
let( (item11 item12 item21 item22)
item11 =
hiCreateMenuItem(
?name 'item11
?itemText "Corners plotter"
?callback "setupSignalPlotter()"
)

item12 =
hiCreateMenuItem(
?name 'item12
?itemText "Monte Carlo plotter"
?callback "setupMonteCarloPlotter()"
)

item21 =
hiCreateMenuItem(
?name 'item21
?itemText "Sample outputs"
?callback "setupSampleOutputs()"
)

item22 =
hiCreateMenuItem(
?name 'item22
?itemText "MAV postprocessing"
?callback "setupMAVFilterOutputs()"
)

item23 =
hiCreateMenuItem(
?name 'item23
?itemText "CoI postprocessing"
?callback "setupCoIFilterOutputs()"
)

samplerMenu = hiCreatePulldownMenu(
'samplerMenu
"Sampling"
list(
item21
item22
item23
)
)
plotterMenu = hiCreatePulldownMenu(
'plotterMenu
"Plotting"
list(
item11
item12
)
)

sliderPlot = hiCreateSliderMenuItem(
?name 'sliderPlot
?itemText "Plotters"
?subMenu plotterMenu
)
sliderSample = hiCreateSliderMenuItem(
?name 'sliderSample
?itemText "Sample"
?subMenu samplerMenu
)

mainAddonMenu = hiCreatePulldownMenu(
'mainAddonMenu
"Sampling and Plotters"
list( sliderSample sliderPlot )
)

hiInsertBannerMenu(hiGetCurrentWindow() mainAddonMenu 0)
)
)

So far I am getting error in CIW

*Error* append: argument #1 should be a list or another acceptable type - t

And there is only this new menu item. Common items are not present.

Should this procedure be written differently?

Thank you in advance

Dragan

  • Cancel
Parents
  • mbracht
    mbracht over 4 years ago

    Hi Dragan,

    I don't see any call to append() in this code above - maybe it's in one of your callbacks.
    The error message itself is pretty clear, the first argument of append (and also the second one) must be a list which in your case it obviously isn't.

    Max

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • dragank
    dragank over 4 years ago in reply to mbracht

    Only callbacks i have are for adding to menu:

    deRegUserTriggers("maestro" nil 'InternalMaestroAddMenu)
    deRegUserTriggers("explorer" nil 'InternalMaestroAddMenu)
    deRegUserTriggers("adexl" nil 'InternalMaestroAddMenu)

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to dragank

    Your menu callback is incorrect. User menu callbacks (registered with deRegUserTriggers) should not add the menus themselves. Instead they should return a list of pulldown menus and "de" (Design Editor) takes care of adding them into the banner menus for you.

    So replace the line:

    hiInsertBannerMenu(hiGetCurrentWindow() mainAddonMenu 0)

    with:

    list(mainAddonMenu)

    The error is because it's trying to add the return value of hiInsertBannerMenu - which isn't a list - and hence the error.

    Regards,

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 4 years ago in reply to dragank

    Your menu callback is incorrect. User menu callbacks (registered with deRegUserTriggers) should not add the menus themselves. Instead they should return a list of pulldown menus and "de" (Design Editor) takes care of adding them into the banner menus for you.

    So replace the line:

    hiInsertBannerMenu(hiGetCurrentWindow() mainAddonMenu 0)

    with:

    list(mainAddonMenu)

    The error is because it's trying to add the return value of hiInsertBannerMenu - which isn't a list - and hence the error.

    Regards,

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • dragank
    dragank over 4 years ago in reply to Andrew Beckett

    Thank You Andrew.

    It is working now.

    • Cancel
    • Vote Up 0 Vote Down
    • 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