• 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. help - skill code for goto xy coordinate

Stats

  • Locked Locked
  • Replies 23
  • Subscribers 146
  • Views 15850
  • 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

help - skill code for goto xy coordinate

zeroskills
zeroskills over 15 years ago

i would like some help on skill code for goto xy coordinate. we used to have this skill code, it does this...

pop up goto xy form, just input x and y coordinate then view size, like how zoom in or out you want it. then there will be an "X" ruler mark on the coordinate.

 

  • Cancel
Parents
  • Guruprasad S
    Guruprasad S over 10 years ago

    Hi ,

    I have set of X Y Coordinates in a text file , that is " coordxy.txt "

    this fie has coordinates in the form of (X Y)

    1.2 6.8


    2.4 4.6


    6.2 2.9


    0.4 6.0


    5.0 8.9

    ....

    ....

    ....

    this is saved in file " coordxy.txt "

    I wrote another skill to load this "coordxy.txt " file in CIW and assigned it to  portt=infile(hiGetCurrentForm()->fileLocation->value)

    /*** Skill to load file in CIW **/

     procedure( loadfile()

        let( (fileLocation loadFileButton y)
            fileLocation = hiCreateFileSelectorField(
                    ?name           'fileLocation
                    ?mode           'existingFile
                    ?prompt         "Choose a file"
                    ?editable       t)

            loadFileButton = hiCreateButton(
                    ?name           'loadFileButton
                    ?buttonText     "Load File"
                    ?callback       "printf(\"Loading file from popup form %s\n\" myForm->fileLocation->value)")

            myForm = hiCreateAppForm(
                    ?name           'myForm
                    ?formTitle      "Load File in CIW"
                    ?buttonLayout   'Close
            ?dontBlock t    ; with this your previous code would have failed
                    ?fields         list( list(fileLocation 10:10 400:20 100)
                                            list(loadFileButton 415:10 80:30))
                    ?unmapAfterCB           t)

            hiDisplayForm(myForm)
        
        ); let
     port=infile(hiGetCurrentForm()->fileLocation->value)
    )

    hiSetBindKey("Layout" "Alt<key>L" "loadfile()")

    ----------------------END-----------------------

    Now i should read this file in CIW line by line, for this i have some code

    fpFile = infile(" 123.txt ")

    gets( line fpFile )

    tokens = parseString( line )

    rexCompile( "[xyXY] *[=:]")

    coord = rexReplace( line " " 0)

    rexCompile( "[(){}=,:]")

    coord = rexReplace( coord " " 0)

    rexCompile( "\\. ")

    coord = rexReplace( coord " " 0)

    coord = parseString(coord)

    coord=mapcar( 'aelNumber coord)

    coord=setof(x coord x)

    X=car(coord)

    Y=cadr(coord)

    -------------------------------------------------

    this will get value of X and Y from file line by line

    Next i need this values to assign in my main code one by one , by pressing NEXT BUTTON in pop up window , and it must go to previous line by Pressing PREVIOUS BUTTON .

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Guruprasad S
    Guruprasad S over 10 years ago

    Hi ,

    I have set of X Y Coordinates in a text file , that is " coordxy.txt "

    this fie has coordinates in the form of (X Y)

    1.2 6.8


    2.4 4.6


    6.2 2.9


    0.4 6.0


    5.0 8.9

    ....

    ....

    ....

    this is saved in file " coordxy.txt "

    I wrote another skill to load this "coordxy.txt " file in CIW and assigned it to  portt=infile(hiGetCurrentForm()->fileLocation->value)

    /*** Skill to load file in CIW **/

     procedure( loadfile()

        let( (fileLocation loadFileButton y)
            fileLocation = hiCreateFileSelectorField(
                    ?name           'fileLocation
                    ?mode           'existingFile
                    ?prompt         "Choose a file"
                    ?editable       t)

            loadFileButton = hiCreateButton(
                    ?name           'loadFileButton
                    ?buttonText     "Load File"
                    ?callback       "printf(\"Loading file from popup form %s\n\" myForm->fileLocation->value)")

            myForm = hiCreateAppForm(
                    ?name           'myForm
                    ?formTitle      "Load File in CIW"
                    ?buttonLayout   'Close
            ?dontBlock t    ; with this your previous code would have failed
                    ?fields         list( list(fileLocation 10:10 400:20 100)
                                            list(loadFileButton 415:10 80:30))
                    ?unmapAfterCB           t)

            hiDisplayForm(myForm)
        
        ); let
     port=infile(hiGetCurrentForm()->fileLocation->value)
    )

    hiSetBindKey("Layout" "Alt<key>L" "loadfile()")

    ----------------------END-----------------------

    Now i should read this file in CIW line by line, for this i have some code

    fpFile = infile(" 123.txt ")

    gets( line fpFile )

    tokens = parseString( line )

    rexCompile( "[xyXY] *[=:]")

    coord = rexReplace( line " " 0)

    rexCompile( "[(){}=,:]")

    coord = rexReplace( coord " " 0)

    rexCompile( "\\. ")

    coord = rexReplace( coord " " 0)

    coord = parseString(coord)

    coord=mapcar( 'aelNumber coord)

    coord=setof(x coord x)

    X=car(coord)

    Y=cadr(coord)

    -------------------------------------------------

    this will get value of X and Y from file line by line

    Next i need this values to assign in my main code one by one , by pressing NEXT BUTTON in pop up window , and it must go to previous line by Pressing PREVIOUS BUTTON .

    • 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