Added 'qr_lib' to --quick_start

This commit is contained in:
Salvador E. Tropea 2022-04-29 09:00:47 -03:00
parent f3f7517a7f
commit 74d77f037c
2 changed files with 14 additions and 1 deletions

View File

@ -808,7 +808,8 @@ def generate_one_example(dest_dir):
outputs = []
for n, cls in OrderedDict(sorted(outs.items())).items():
o = cls()
if not(o.is_pcb() and GS.pcb_file) and not(o.is_sch() and GS.sch_file):
if ((not(o.is_pcb() and GS.pcb_file) and not(o.is_sch() and GS.sch_file)) or
((o.is_pcb() and o.is_sch()) and (not GS.pcb_file or not GS.sch_file))):
logger.debug('- {}, skipped (PCB: {} SCH: {})'.format(n, o.is_pcb(), o.is_sch()))
continue
# Look for templates

View File

@ -531,3 +531,15 @@ class QR_Lib(BaseOutput): # noqa: F821
""" [dict] Options for the `boardview` output """
self._both_related = True
self._update_mode = False
@staticmethod
def get_conf_examples(name, layers, templates):
gb = {}
gb['name'] = 'basic_qr_lib_example'
gb['comment'] = 'QR code symbol and footprint example'
gb['type'] = name
gb['dir'] = 'QR_libs'
qr1 = {'correction_level': 'medium', 'name': 'QR_data', 'pcb_negative': True}
qr2 = {'correction_level': 'medium', 'name': 'QR_kibot', 'text': 'https://github.com/INTI-CMNB/KiBot/'}
gb['options'] = {'qrs': [qr1, qr2], 'use_sch_dir': False}
return [gb]