2009-11-05 19:26:52 +00:00
|
|
|
/*********/
|
|
|
|
/* CVPCB */
|
|
|
|
/*********/
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-04-05 20:49:15 +00:00
|
|
|
#ifndef __CVPCB_H__
|
|
|
|
#define __CVPCB_H__
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-04-05 20:49:15 +00:00
|
|
|
#include "pcbcommon.h"
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-05-06 11:55:36 +00:00
|
|
|
#include <boost/ptr_container/ptr_vector.hpp>
|
|
|
|
#include <boost/foreach.hpp>
|
|
|
|
|
|
|
|
|
2009-11-05 19:26:52 +00:00
|
|
|
// config for footprints doc file access
|
2009-04-21 17:56:27 +00:00
|
|
|
#define DEFAULT_FOOTPRINTS_LIST_FILENAME wxT( "footprints_doc/footprints.pdf" )
|
|
|
|
|
2008-06-11 11:27:58 +00:00
|
|
|
// Define print format to display a schematic component line
|
2007-10-27 12:24:09 +00:00
|
|
|
#define CMP_FORMAT wxT( "%3d %8s - %16s : %-.32s" )
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
#define FILTERFOOTPRINTKEY "FilterFootprint"
|
|
|
|
|
2009-11-05 19:26:52 +00:00
|
|
|
/* Net list types. */
|
2009-04-05 20:49:15 +00:00
|
|
|
#define TYPE_NON_SPECIFIE 0
|
|
|
|
#define TYPE_ORCADPCB2 1
|
|
|
|
#define TYPE_PCAD 2
|
|
|
|
#define TYPE_VIEWLOGIC_WIR 3
|
|
|
|
#define TYPE_VIEWLOGIC_NET 4
|
|
|
|
|
|
|
|
|
2009-04-23 15:02:18 +00:00
|
|
|
class PIN
|
2007-06-05 12:10:51 +00:00
|
|
|
{
|
|
|
|
public:
|
2009-11-05 19:26:52 +00:00
|
|
|
int m_Index; /* Type of net list. */
|
|
|
|
int m_Type; /* Electrical connection type. */
|
|
|
|
wxString m_Net; /* Name of net. */
|
2009-05-06 11:55:36 +00:00
|
|
|
wxString m_Number;
|
|
|
|
wxString m_Name;
|
2009-11-05 19:26:52 +00:00
|
|
|
wxString m_Repere; /* Formats used by net lister. */
|
2007-10-27 12:24:09 +00:00
|
|
|
|
2009-04-23 15:02:18 +00:00
|
|
|
PIN();
|
2007-10-27 12:24:09 +00:00
|
|
|
};
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-05-06 11:55:36 +00:00
|
|
|
typedef boost::ptr_vector< PIN > PIN_LIST;
|
2009-04-23 15:02:18 +00:00
|
|
|
|
|
|
|
/* PIN object list sort function. */
|
2009-05-06 11:55:36 +00:00
|
|
|
extern bool operator<( const PIN& item1, const PIN& item2 );
|
|
|
|
|
|
|
|
/* PIN uniqueness test function. */
|
|
|
|
extern bool operator==( const PIN& item1, const PIN& item2 );
|
2009-04-23 15:02:18 +00:00
|
|
|
|
|
|
|
extern bool same_pin_number( const PIN* item1, const PIN* item2 );
|
|
|
|
extern bool same_pin_net( const PIN* item1, const PIN* item2 );
|
|
|
|
|
|
|
|
|
|
|
|
class COMPONENT
|
2007-06-05 12:10:51 +00:00
|
|
|
{
|
|
|
|
public:
|
2009-11-05 19:26:52 +00:00
|
|
|
int m_Num; /* Component number. */
|
|
|
|
int m_Multi; /* Part if component has multiple parts. */
|
|
|
|
PIN_LIST m_Pins; /* List of component pins. */
|
|
|
|
wxString m_Reference; /* Reference designator: U3, R5 ... */
|
|
|
|
wxString m_Value; /* Value: 7400, 47K ... */
|
|
|
|
wxString m_TimeStamp; /* Time stamp ("00000000" if absent) */
|
|
|
|
wxString m_Module; /* Footprint (module) name. */
|
|
|
|
wxString m_Repere; /* Net list format */
|
2009-05-06 11:55:36 +00:00
|
|
|
wxArrayString m_FootprintFilter; /* List of allowed footprints (wildcards
|
|
|
|
* allowed ). If empty: no filtering */
|
2007-10-27 12:24:09 +00:00
|
|
|
|
2009-04-23 15:02:18 +00:00
|
|
|
COMPONENT();
|
|
|
|
~COMPONENT();
|
2007-10-27 12:24:09 +00:00
|
|
|
};
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-05-06 11:55:36 +00:00
|
|
|
typedef boost::ptr_vector< COMPONENT > COMPONENT_LIST;
|
2009-04-23 15:02:18 +00:00
|
|
|
|
|
|
|
/* COMPONENT object list sort function. */
|
2009-05-06 11:55:36 +00:00
|
|
|
extern bool operator<( const COMPONENT& item1, const COMPONENT& item2 );
|
2009-04-23 15:02:18 +00:00
|
|
|
|
|
|
|
|
|
|
|
class FOOTPRINT
|
2007-06-05 12:10:51 +00:00
|
|
|
{
|
|
|
|
public:
|
2009-11-05 19:26:52 +00:00
|
|
|
wxString m_Module; /* Module name. */
|
|
|
|
wxString m_LibName; /* Name of the library containing this module. */
|
|
|
|
int m_Num; /* Order number in the display list. */
|
|
|
|
wxString m_Doc; /* Footprint description. */
|
|
|
|
wxString m_KeyWord; /* Footprint key words. */
|
2007-10-27 12:24:09 +00:00
|
|
|
|
2009-04-23 15:02:18 +00:00
|
|
|
FOOTPRINT();
|
2007-06-05 12:10:51 +00:00
|
|
|
};
|
|
|
|
|
2009-05-06 11:55:36 +00:00
|
|
|
typedef boost::ptr_vector< FOOTPRINT > FOOTPRINT_LIST;
|
2009-04-23 15:02:18 +00:00
|
|
|
|
|
|
|
/* FOOTPRINT object list sort function. */
|
2009-05-06 11:55:36 +00:00
|
|
|
extern bool operator<( const FOOTPRINT& item1, const FOOTPRINT& item2 );
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-04-23 15:02:18 +00:00
|
|
|
extern const wxString FootprintAliasFileExtension;
|
2009-04-05 20:49:15 +00:00
|
|
|
extern const wxString RetroFileExtension;
|
|
|
|
extern const wxString ComponentFileExtension;
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-04-05 20:49:15 +00:00
|
|
|
extern const wxString RetroFileWildcard;
|
2009-04-23 15:02:18 +00:00
|
|
|
extern const wxString FootprintAliasFileWildcard;
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-04-05 20:49:15 +00:00
|
|
|
extern const wxString titleLibLoadError;
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2007-10-27 12:24:09 +00:00
|
|
|
void Plume( int state );
|
2009-04-05 20:49:15 +00:00
|
|
|
|
|
|
|
#endif /* __CVPCB_H__ */
|