Home > Community > Forums > Custom IC SKILL > How to register a trigger with first edit event?

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 How to register a trigger with first edit event? 

Last post Thu, Jul 4 2013 7:08 AM by Andrew Beckett. 3 replies.
Started by kumarb1975 02 Jul 2013 12:51 AM. Topic has 3 replies and 558 views
Page 1 of 1 (4 items)
Sort Posts:
  • Tue, Jul 2 2013 12:51 AM

    • kumarb1975
    • Not Ranked
    • Joined on Mon, May 28 2012
    • Posts 2
    • Points 40
    How to register a trigger with first edit event? Reply
    Here is the background of my requirement:

    I’ve some sanity checks which are run on design to make sure some guidelines are followed.(Eg: design should not have any bi-directional pins unless waived..etc.etc.)

    I’ve created a custom toolbar icon for sanity check. So,

    1) when I open a design, application trigger will run sanity check and change the toolbar icon to ‘red’ or ‘green’ color which indicates last saved design was sanity clean/dirty.
    2) Now, the moment I modify the design, I want to toolbar color to “yellow” which indicates that design is modified after last sanity run.
    3) Now, if user run the sanity check, it will turn again to “red” or “green” based on design updates.

    Here, I’m not able to find how to accomplish task 2)

    Thanks a lot in advance for any pointer.

    Best regards,
    Bhupendra

     

     

    • Post Points: 20
  • Tue, Jul 2 2013 3:39 AM

    Re: How to register a trigger with first edit event? Reply

    Bhupendra,

    Wouldn't it be simplest to incorporate this into the "Check" capability in the schematic editor? For example, in IC615 this can easily be done with code such as below (you didn't say which version you're using - there are slightly different strategies possible in earlier versions):

    /* abExampleSchematicCheckNew.ils
    
    Author     A.D.Beckett
    Group      Custom IC (UK), Cadence Design Systems Ltd.
    Language   SKILL
    Date       Oct 28, 2011 
    Modified   
    By         
    
    This is a reimplementation of some of the checks in abExampleSchematicCheck.ils
    but taking advantage of the new interface in IC615 to register checks with
    the system. As a result it is much simpler, and does not have to take care
    of creating marker objects itself; also gives the user the ability to override
    the check, or change the severity if needed.
    
    To register, call:
    
    abRegExampleSchematicCheckNew("Your Customer Name")
    
    (with no arguments, it just calls the rule group "Customer")
    
    ***************************************************
    
    SCCS Info: @(#) abExampleSchematicCheckNew.ils 10/28/11.10:55:00 1.1
    
    */
    
    ;------------------------------------------------------------------------
    ; The let is to create a lexical scope, so that there can be
    ; private functions which are used for some of the implementation
    ;------------------------------------------------------------------------
    let(()
    
        /***************************************************************
        *                                                              *
        *  abRegExampleSchematicCheckNew([?customerName "Customer"])   *
        *                                                              *
        * PUBLIC GLOBAL function used to register the new check group  *
        * and any specific check - in this case an example of a naming *
        *                         convention.                          *
        *                                                              *
        ***************************************************************/
        defglobalfun(abRegExampleSchematicCheckNew (@optional (customerName "Customer"))
            ;----------------------------------------------------------------
            ; This registers a new tab on Check->Rules Setup
            ;----------------------------------------------------------------
            schRegisterCheckGroup(
                ?name concat(customerName)
                ?description strcat(customerName " checks")
            )
            ;----------------------------------------------------------------
            ; This registers the specific rule and default severity
            ;----------------------------------------------------------------
            schRegisterCheckRule(
                ?title "Naming conventions"
                ?name 'namingConventions
                ?groupName concat(customerName)
                ?severity 'error
                ?checkCB checkNamingConventions
            )
        )
    
        /*********************************************************************
        *                                                                    *
        *               checkNamingConventions(cv ruleObject)                *
        *                                                                    *
        * INTERNAL function used to actually implement the naming convention *
        *                               check.                               *
        *                                                                    *
        *********************************************************************/
        defun(checkNamingConventions (cv ruleObject)
            let((obj label netTable signals sigTable)
                ;------------------------------------------------------------
                ; Check that terminal names are in upper case
                ;------------------------------------------------------------
                foreach(term cv~>terminals
                    unless(term~>name==upperCase(term~>name)
                        ;----------------------------------------------------
                        ; Place the marker on the first pin - no need to
                        ; put it on every pin if there are multiple pins
                        ;----------------------------------------------------
                        obj=car(term~>pins~>fig) || cv
                        schReportCheckFailure(
                            ?object obj
                            ?checkRule ruleObject
                            ?short "Terminals not upper case"
                            ?message
                                sprintf(nil "Terminals must be in upper case: %s" 
                                    term~>name
                                ) 
                        ) 
                    ) ; unless
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for internal nets which have a lower case name
                ;------------------------------------------------------------
                foreach(net cv~>nets
                    ;--------------------------------------------------------
                    ; Only worry about nets which have a label
                    ;--------------------------------------------------------
                    label=car(exists(fig net~>figs fig~>objType=="label"))
                    when(label
                        when(exists(sig net~>signals 
                            ;------------------------------------------------
                            ; Check that the signal is not part of a 
                            ; terminal, and is not in lowercase
                            ;------------------------------------------------
                            !sig~>memTerms && sig~>name!=lowerCase(sig~>name))
                            schReportCheckFailure(
                                ?object label
                                ?checkRule ruleObject
                                ?short "Internal nets not lower case"
                                ?message
                                    sprintf(nil "Internal net names must be in lower case: %s"
                                        net~>name
                                    ) 
                            ) 
                        ) ; when there is a lower internal net name on net
                    ) ; when there's a label
                ) ; foreach
                ;------------------------------------------------------------
                ; Check for any nets which only differ in case
                ;------------------------------------------------------------
                ;------------------------------------------------------------
                ; record all the signals together in a table indexed by
                ; the flattened case. Then use a table to record all
                ; member nets which have a mixed-case problem
                ;------------------------------------------------------------
                sigTable=makeTable('sigTable nil)
                netTable=makeTable('netTable nil)
                foreach(sig cv~>signals
                    sigTable[lowerCase(sig~>name)]=
                        cons(sig sigTable[lowerCase(sig~>name)])
                ) ; foreach
                foreach(tableEntry sigTable
                    signals=sigTable[tableEntry]
                    ;--------------------------------------------------------
                    ; If there was more than one signal with the
                    ; same flattened case, then there's
                    ; a mixed name problem. Record the member nets
                    ; in a table (to avoid duplication)
                    ;--------------------------------------------------------
                    when(cdr(signals)
                        foreach(sig signals
                            foreach(memNet sig~>memNets
                                netTable[car(memNet)]=signals
                            ) ; foreach memNet
                        ) ; foreach sig
                    ) ; when
                ) ; foreach 
                foreach(net netTable
                    ;--------------------------------------------------------
                    ; Find something suitable to put the marker on
                    ;--------------------------------------------------------
                    cond(
                        ;----------------------------------------------------
                        ; Use the pin if there is one
                        ;----------------------------------------------------
                        (net~>term~>pins
                            obj=car(net~>term~>pins~>fig)
                        )
                        ;----------------------------------------------------
                        ; Otherwise use the label
                        ;----------------------------------------------------
                        (obj=car(
                            exists(shape net~>figs 
                                shape~>objType=="label"))
                            t
                        )
                        ;----------------------------------------------------
                        ; Next try a wire
                        ;----------------------------------------------------
                        (obj=car(
                                exists(shape net~>figs
                                    shape~>objType=="line" ||
                                    shape~>objType=="path")
                            )
                            t
                        )
                        ;----------------------------------------------------
                        ; Finally, if nothing else, use the cellView
                        ;----------------------------------------------------
                        (t
                            obj=cv
                        )
                    ) ; cond
                    schReportCheckFailure(
                        ?object obj 
                        ?checkRule ruleObject
                        ?short "Net differing only in case"
                        ?message
                            sprintf(nil 
                                "Net %L cannot differ only in case from others: %L" 
                                net~>name
                                netTable[net]~>name
                            )
                    )
                ) ; foreach
            ) ; let
        ) ; defun checkNamingConventions
    
    )

     

    Kind Regards,

    Andrew.

    • Post Points: 20
  • Tue, Jul 2 2013 4:07 AM

    • kumarb1975
    • Not Ranked
    • Joined on Mon, May 28 2012
    • Posts 2
    • Points 40
    Re: How to register a trigger with first edit event? Reply

    Hi Andrew,

    Thanks for the quick reply and schematic 'check' capability update. This is something new learning for me. Thanks :)

    But, unfortunately, this will not serve my purpose. Reason being as I've such sanity checks for layout and symbol as well. Also, I do not expect user to run these checks but just make him/her aware of the sanity status at every point of time.

    I was wondering if somehow, we can get a pointer how 'save' button becomes enabled when we start editing the design and when we save the design, it is grayed out.

    I'm using IC615ISR11

    Best regards,

    Bhupendra

     

     

     

     

    • Post Points: 20
  • Thu, Jul 4 2013 7:08 AM

    Re: How to register a trigger with first edit event? Reply

    As you are dealing with this via customer support, I won't duplicate effort and answer it here too.

    Regards,

    Andrew.

    • Post Points: 5
Page 1 of 1 (4 items)
Sort Posts:
Started by kumarb1975 at 02 Jul 2013 12:51 AM. Topic has 3 replies.