Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
cf460637
Commit
cf460637
authored
Feb 06, 2008
by
dickelbeck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
beginnings of the 2 specctra imports
parent
822017c7
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
106 additions
and
13 deletions
+106
-13
change_log.txt
change_log.txt
+6
-0
id.h
include/id.h
+4
-3
wxPcbStruct.h
include/wxPcbStruct.h
+19
-1
CMakeLists.txt
pcbnew/CMakeLists.txt
+1
-0
menubarpcb.cpp
pcbnew/menubarpcb.cpp
+19
-0
pcbframe.cpp
pcbnew/pcbframe.cpp
+4
-1
specctra.h
pcbnew/specctra.h
+1
-6
specctra_export.cpp
pcbnew/specctra_export.cpp
+2
-2
specctra_import.cpp
pcbnew/specctra_import.cpp
+50
-0
No files found.
change_log.txt
View file @
cf460637
...
...
@@ -5,6 +5,12 @@ Started 2007-June-11
Please add newer entries at the top, list the date and your name with
email address.
2008-Feb-6 UPDATE Dick Hollenbeck <dick@softplc.com>
================================================================================
+pcbnew
started specctra imports of *.ses and *.dsn, by adding menus to File | Import.
2008-Feb-4 UPDATE Dick Hollenbeck <dick@softplc.com>
================================================================================
+pcbnew
...
...
include/id.h
View file @
cf460637
...
...
@@ -95,9 +95,10 @@ enum main_id {
ID_GEN_EXPORT_SPECCTRA
,
ID_GEN_EXPORT_FILE_GENCADFORMAT
,
ID_GEN_EXPORT_FILE_MODULE_REPORT
,
ID_GEN_EXPORT_FILE_FORMAT_2
,
// Not used
ID_GEN_EXPORT_FILE_FORMAT_3
,
// Not used
ID_GEN_EXPORT_FILE_FORMAT_4
,
// Not used
ID_GEN_IMPORT_FILE
,
ID_GEN_IMPORT_SPECCTRA_SESSION
,
ID_GEN_IMPORT_SPECCTRA_DESIGN
,
ID_EXIT
,
ID_OPTIONS_SETUP
,
...
...
include/wxPcbStruct.h
View file @
cf460637
...
...
@@ -385,8 +385,26 @@ public:
* See http://www.autotraxeda.com/docs/SPECCTRA/SPECCTRA.pdf for the
* specification.
*/
void
ExportToS
PECCTRA
(
wxCommandEvent
&
event
);
void
ExportToS
pecctra
(
wxCommandEvent
&
event
);
/**
* Function ImportSpecctraSession
* will import a specctra *.ses file and use it to relocate MODULEs and
* to replace all vias and tracks in an existing and loaded BOARD.
* See http://www.autotraxeda.com/docs/SPECCTRA/SPECCTRA.pdf for the
* specification.
*/
void
ImportSpecctraSession
(
wxCommandEvent
&
event
);
/**
* Function ImportSpecctraDesign
* will import a specctra *.dsn file and use it to replace an entire BOARD.
* The new board will not have any graphics, only components, tracks and vias.
* See http://www.autotraxeda.com/docs/SPECCTRA/SPECCTRA.pdf for the
* specification.
*/
void
ImportSpecctraDesign
(
wxCommandEvent
&
event
);
/* Fonctions specifiques */
MODULE
*
ListAndSelectModuleName
();
void
Liste_Equipot
(
wxCommandEvent
&
event
);
...
...
pcbnew/CMakeLists.txt
View file @
cf460637
...
...
@@ -121,6 +121,7 @@ SET(PCBNEW_SRCS
solve.cpp
specctra.cpp
specctra_export.cpp
specctra_import.cpp
surbrill.cpp
swap_layers.cpp
tool_modedit.cpp
...
...
pcbnew/menubarpcb.cpp
View file @
cf460637
...
...
@@ -116,6 +116,25 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
m_FilesMenu
,
submenuexport
,
ID_GEN_EXPORT_FILE
,
_
(
"E&xport"
),
_
(
"Export board"
),
export_xpm
);
//-----<Add import menu>-----------------------------------------------
// no separator, keep it next to Import
wxMenu
*
submenuImport
=
new
wxMenu
();
item
=
new
wxMenuItem
(
submenuImport
,
ID_GEN_IMPORT_SPECCTRA_SESSION
,
_
(
"&Specctra Session"
),
_
(
"Import a routed
\"
Specctra Session
\"
(*.ses) file"
)
);
item
->
SetBitmap
(
export_xpm
);
// @todo need better bitmap
submenuImport
->
Append
(
item
);
item
=
new
wxMenuItem
(
submenuImport
,
ID_GEN_IMPORT_SPECCTRA_DESIGN
,
_
(
"&Specctra Design"
),
_
(
"Import a
\"
Specctra Design
\"
(*.dsn) file"
)
);
item
->
SetBitmap
(
export_xpm
);
// @todo need better bitmap
submenuImport
->
Append
(
item
);
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
m_FilesMenu
,
submenuImport
,
ID_GEN_IMPORT_FILE
,
_
(
"Import"
),
_
(
"Import files"
),
export_xpm
);
//-----</Add import menu>----------------------------------------------
// Add archive footprints menu
m_FilesMenu
->
AppendSeparator
();
wxMenu
*
submenuarchive
=
new
wxMenu
();
...
...
pcbnew/pcbframe.cpp
View file @
cf460637
...
...
@@ -56,10 +56,13 @@ BEGIN_EVENT_TABLE( WinEDA_PcbFrame, WinEDA_BasePcbFrame )
EVT_MENU_RANGE
(
ID_LOAD_FILE_1
,
ID_LOAD_FILE_10
,
WinEDA_PcbFrame
::
Files_io
)
EVT_MENU
(
ID_GEN_EXPORT_SPECCTRA
,
WinEDA_PcbFrame
::
ExportToS
PECCTRA
)
EVT_MENU
(
ID_GEN_EXPORT_SPECCTRA
,
WinEDA_PcbFrame
::
ExportToS
pecctra
)
EVT_MENU
(
ID_GEN_EXPORT_FILE_GENCADFORMAT
,
WinEDA_PcbFrame
::
ExportToGenCAD
)
EVT_MENU
(
ID_GEN_EXPORT_FILE_MODULE_REPORT
,
WinEDA_PcbFrame
::
GenModuleReport
)
EVT_MENU
(
ID_GEN_IMPORT_SPECCTRA_SESSION
,
WinEDA_PcbFrame
::
ImportSpecctraSession
)
EVT_MENU
(
ID_GEN_IMPORT_SPECCTRA_DESIGN
,
WinEDA_PcbFrame
::
ImportSpecctraDesign
)
EVT_MENU
(
ID_MENU_ARCHIVE_NEW_MODULES
,
WinEDA_PcbFrame
::
Process_Special_Functions
)
EVT_MENU
(
ID_MENU_ARCHIVE_ALL_MODULES
,
WinEDA_PcbFrame
::
Process_Special_Functions
)
...
...
pcbnew/specctra.h
View file @
cf460637
...
...
@@ -3806,13 +3806,8 @@ public:
* the BOARD given to this function must have all the MODULEs on the component
* side of the BOARD.
*
* See void WinEDA_PcbFrame::ExportToS
PECCTRA
( wxCommandEvent& event )
* See void WinEDA_PcbFrame::ExportToS
pecctra
( wxCommandEvent& event )
* for how this can be done before calling this function.
* @todo
* I would have liked to put the flipping logic into the ExportToSPECCTRA()
* function directly, but for some strange reason,
* void Change_Side_Module( MODULE* Module, wxDC* DC ) is a member of
* of class WinEDA_BasePcbFrame rather than class BOARD.
*
* @param aBoard The BOARD to convert to a PCB.
*/
...
...
pcbnew/specctra_export.cpp
View file @
cf460637
...
...
@@ -43,7 +43,7 @@ using namespace DSN;
// see wxPcbStruct.h
void
WinEDA_PcbFrame
::
ExportToS
PECCTRA
(
wxCommandEvent
&
event
)
void
WinEDA_PcbFrame
::
ExportToS
pecctra
(
wxCommandEvent
&
event
)
{
wxString
fullFileName
=
GetScreen
()
->
m_FileName
;
wxString
std_ext
=
wxT
(
".dsn"
);
...
...
@@ -103,7 +103,7 @@ void WinEDA_PcbFrame::ExportToSPECCTRA( wxCommandEvent& event )
if
(
ok
)
{
// @todo display a message saying the export is complete.
Affiche_Message
(
wxString
(
_
(
"BOARD exported OK."
))
);
}
else
DisplayError
(
this
,
errorText
);
...
...
pcbnew/specctra_import.cpp
0 → 100644
View file @
cf460637
/*
* This program source code file is part of KICAD, a free EDA CAD application.
*
* Copyright (C) 2007-2008 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
* Copyright (C) 2007 Kicad Developers, see change_log.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, you may find one here:
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
* or you may search the http://www.gnu.org website for the version 2 license,
* or you may write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
*/
/* This source is a complement to specctra.cpp and implements the import of
a specctra session file (*.ses), and import of a specctra design file
(*.dsn) file. The specification for the grammar of the specctra dsn file
used to develop this code is given here:
http://www.autotraxeda.com/docs/SPECCTRA/SPECCTRA.pdf
Also see the comments at the top of the specctra.cpp file itself.
*/
#include "specctra.h"
using
namespace
DSN
;
void
WinEDA_PcbFrame
::
ImportSpecctraDesign
(
wxCommandEvent
&
event
)
{
}
void
WinEDA_PcbFrame
::
ImportSpecctraSession
(
wxCommandEvent
&
event
)
{
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment