1 #ifndef IVL_pcb_priv_H 2 #define IVL_pcb_priv_H 3 /* 4 * Copyright (c) 2011-2014 Stephen Williams (steve@icarus.com) 5 * 6 * This source code is free software; you can redistribute it 7 * and/or modify it in source code form under the terms of the GNU 8 * General Public License as published by the Free Software 9 * Foundation; either version 2 of the License, or (at your option) 10 * any later version. 11 * 12 * This program is distributed in the hope that it will be useful, 13 * but WITHOUT ANY WARRANTY; without even the implied warranty of 14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 15 * GNU General Public License for more details. 16 * 17 * You should have received a copy of the GNU General Public License 18 * along with this program; if not, write to the Free Software 19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 20 */ 21 22 # include <string> 23 # include <set> 24 # include <list> 25 # include <map> 26 # include "ivl_target.h" 27 28 extern int scan_scope(ivl_scope_t scope); 29 30 /* 31 * This nexus_list is a list of all the nets that the scan_scope 32 * collects, wrapped up into a list. The show_netlist dumps that list 33 * as a netlist. 34 */ 35 struct nexus_data { 36 std::string name; 37 std::set<std::string> pins; 38 }; 39 40 extern std::list<struct nexus_data*> nexus_list; 41 42 /* 43 * The element_list is a collection of all the elements that were 44 * located by the scope scan. The key is the refdes for the element, 45 * and the value is the element_data_t structure that describes that 46 * element. 47 */ 48 struct element_data_t { 49 std::string description; 50 std::string value; 51 std::string footprint; 52 }; 53 54 extern std::map <std::string, element_data_t*> element_list; 55 56 extern int load_footprints(void); 57 58 struct fp_pad_t { 59 long rx1, ry1; 60 long rx2, ry2; 61 int thickness; 62 int clearance; 63 int mask; 64 std::string name; 65 std::string number; 66 std::string sflags; 67 }; 68 69 struct fp_element_t { 70 long nflags; 71 std::string description; 72 std::string name; 73 std::string value; 74 long mx, my; 75 long tx, ty; 76 int tdir; 77 int tscale; 78 std::string tsflags; 79 80 std::map<std::string,fp_pad_t> pads; 81 }; 82 83 extern std::map<std::string,fp_element_t> footprints; 84 85 extern void show_netlist(const char*net_path); 86 87 extern void show_pcb(const char*pcb_path); 88 89 #endif /* IVL_pcb_priv_H */ 90