element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Members
    Members
    • Achievement Levels
    • Benefits of Membership
    • Feedback and Support
    • Members Area
    • Personal Blogs
    • What's New on element14
  • Learn
    Learn
    • eBooks
    • Learning Center
    • Learning Groups
    • STEM Academy
    • Webinars, Training and Events
  • Technologies
    Technologies
    • 3D Printing
    • Experts & Guidance
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Arduino Projects
    • Design Challenges
    • element14 presents
    • Project14
    • Project Groups
    • Raspberry Pi Projects
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Or choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
Autodesk EAGLE
  • Products
  • More
Autodesk EAGLE
EAGLE User Support (English) DRU Embedded in BRD file
  • Blog
  • Forum
  • Documents
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Autodesk EAGLE requires membership for participation - click to join
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 1 reply
  • Subscribers 145 subscribers
  • Views 51 views
  • Users 0 members are here
Related

DRU Embedded in BRD file

Former Member
Former Member over 9 years ago

I noticed that v6.5.0 has the design rules (DRC rules) embedded in the file.  However, when I load the board, it doesn't use those values but rather the last specified DRU file.

1)  How can I use the embedded DRU parameters?

2)  How can I extract the embedded DRU parameters and create an external DRU file?

 

Thanks

Billy

  • Sign in to reply
  • Cancel
  • autodeskguest
    0 autodeskguest over 9 years ago

    On 13/01/2014 23:34, Billy Coleman wrote:

    I noticed that v6.5.0 has the design rules (DRC rules) embedded in the

    file.  However, when I load the board, it doesn't use those values but

    rather the last specified DRU file.

    1)  How can I use the embedded DRU parameters?

    2)  How can I extract the embedded DRU parameters and create an external

    DRU file?

     

    Thanks

    Billy

     

    --

    To view any images and attachments in this post, visit:

    http://www.element14.com/community/message/100791

     

    Actually, quite easy; when the Board is opened, its XML file can be

    read. A code example:

     

    string dr_name[], dr_value[]; int count;

     

    board(B) {

    // read the complete Board description and extract the designrules

     

       string brd_data, dr_lines[], par_list[];

       fileread(brd_data, B.name);

       xmlelements(dr_lines, brd_data, "eagle/drawing/board/designrules");

     

       // The designrules section sits in dr_lines[0]. Extract parameters

     

       count = xmlelements(par_list, dr_lines[0], "designrules/param");

     

       // extract name and value tag data into par_list

     

       for (int i; i < count; i++) {

         dr_name[i] = xmlattribute(par_list[i], "param", "name");

         dr_value[i] = xmlattribute(par_list[i], "param", "value");

         }

    };

     

    Now you have a list of the Name and Value pairs in the two string arrays.

     

    Robert

     

     

     

     

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2023 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube