Skip to content

Commit

Permalink
[KiCad2Step] KiCad 7 support
Browse files Browse the repository at this point in the history
  • Loading branch information
set-soft committed Feb 7, 2023
1 parent 59c3787 commit 398a654
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
3 changes: 1 addition & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [2.2.0] - UNRELEASED
### Added
- eeschema_do support for KiCad 7
- pcbnew_do: export_gencad, ipc_netlist, export_vrml, export support for KiCad 7
- KiCad 7 support

## [2.1.1] - 2023-01-11
### Added
Expand Down
3 changes: 3 additions & 0 deletions kiauto/misc.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,9 @@ def __init__(self, logger, input_file=None, args=None, is_pcbnew=False):
self.ki5 = self.kicad_version < KICAD_VERSION_5_99
self.ki6 = not self.ki5 and self.kicad_version < KICAD_VERSION_6_99
self.ki7 = not self.ki5 and not self.ki6
if self.ki7:
# Now part of the kicad-cli tool
self.kicad2step = self.kicad_cli
# Config file names
if not self.ki5:
self.kicad_conf_path = pcbnew.GetSettingsManager().GetUserSettingsPath()
Expand Down
4 changes: 3 additions & 1 deletion src/kicad2step_do
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,8 @@ if __name__ == '__main__':
logger.info('KiCad to STEP wrapper')

cmd = [cfg.kicad2step]
if cfg.ki7:
cmd.extend(['pcb', 'export', 'step'])
if args.output_filename:
fname = args.output_filename[0]
if os.path.basename(fname) == fname:
Expand All @@ -145,7 +147,7 @@ if __name__ == '__main__':

flog_out, flog_err, _ = get_log_files(output_dir, 'kicad2step')

if cfg.kicad_version_major == 5:
if cfg.kicad_version_major == 5 or cfg.ki7:
res = run_cli_version(cmd, cfg)
else:
res = run_gui_version(cmd, cfg, flog_out, flog_err)
Expand Down

0 comments on commit 398a654

Please sign in to comment.