Root/
| 1 | #!/bin/bash |
| 2 | |
| 3 | # path relative to ./ben-wpan/atusb |
| 4 | EESCHEMA=../../../../kicad/eeschema/eeschema |
| 5 | PCBNEW=../../../../kicad/pcbnew/pcbnew |
| 6 | |
| 7 | usage() |
| 8 | { |
| 9 | echo "usage: $0 test" 2>&1 |
| 10 | echo " $0 clean" 2>&1 |
| 11 | echo " $0 help" 2>&1 |
| 12 | echo 2>&1 |
| 13 | exit 1 |
| 14 | } |
| 15 | |
| 16 | if [ "$1" == "getsrc" ]; then |
| 17 | git clone git://projects.qi-hardware.com/ben-wpan.git |
| 18 | git clone git://projects.qi-hardware.com/kicad-libs.git |
| 19 | exit |
| 20 | fi |
| 21 | |
| 22 | if [ "$1" == "test" ]; then |
| 23 | cd ben-wpan/atusb |
| 24 | |
| 25 | echo Displaying eeschema help text: |
| 26 | $EESCHEMA --help |
| 27 | echo ----- |
| 28 | echo Listing 3 sheets: |
| 29 | $EESCHEMA --list-sheets atusb.sch |
| 30 | echo ----- |
| 31 | echo Plotting PostScript: |
| 32 | $EESCHEMA --plot=ps atusb.sch |
| 33 | ps2pdf atusb.ps atusb_noopt.pdf |
| 34 | ps2pdf atusb-RF.ps atusb-RF_noopt.pdf |
| 35 | ps2pdf atusb-USB.ps atusb-USB_noopt.pdf |
| 36 | $EESCHEMA --plot=ps --plot-bw atusb.sch |
| 37 | ps2pdf atusb.ps atusb_bw.pdf |
| 38 | ps2pdf atusb-RF.ps atusb-RF_bw.pdf |
| 39 | ps2pdf atusb-USB.ps atusb-USB_bw.pdf |
| 40 | $EESCHEMA --plot=ps --plot-sheetref atusb.sch |
| 41 | ps2pdf atusb.ps atusb_sheetref.pdf |
| 42 | ps2pdf atusb-RF.ps atusb-RF_sheetref.pdf |
| 43 | ps2pdf atusb-USB.ps atusb-USB_sheetref.pdf |
| 44 | ls -la *.pdf |
| 45 | echo ----- |
| 46 | echo Plotting SVG: |
| 47 | $EESCHEMA --plot=svg atusb.sch |
| 48 | $EESCHEMA --plot=svg --plot-bw atusb.sch |
| 49 | $EESCHEMA --plot=svg --plot-sheetref atusb.sch |
| 50 | ls -la *.svg |
| 51 | echo ----- |
| 52 | echo Plotting DXF: |
| 53 | $EESCHEMA --plot=dxf atusb.sch |
| 54 | $EESCHEMA --plot=dxf --plot-bw atusb.sch |
| 55 | $EESCHEMA --plot=dxf --plot-sheetref atusb.sch |
| 56 | ls -la *.dxf |
| 57 | echo ----- |
| 58 | echo Generating BOM: |
| 59 | $EESCHEMA --bom atusb.sch |
| 60 | ls -la *.lst |
| 61 | echo ----- |
| 62 | echo Running ERC: |
| 63 | $EESCHEMA --erc atusb.sch |
| 64 | ls -la *.erc |
| 65 | echo ----- |
| 66 | echo Generating netlist: |
| 67 | $EESCHEMA --netlist atusb.sch |
| 68 | ls -la *.net |
| 69 | echo ----- |
| 70 | |
| 71 | echo Displaying pcbnew help text: |
| 72 | $PCBNEW --help |
| 73 | echo ----- |
| 74 | echo Listing enabled layers: |
| 75 | $PCBNEW --list-layers atusb.brd |
| 76 | echo ----- |
| 77 | echo Generating .drl drill files: |
| 78 | $PCBNEW --drill atusb.brd |
| 79 | ls -la *.drl |
| 80 | echo ----- |
| 81 | # We are currently not testing options affecting plotting operation |
| 82 | # such as --layers --plot-mirror and others. |
| 83 | echo Plotting GERBER: |
| 84 | $PCBNEW --plot=gerber atusb.brd |
| 85 | ls -la *.{gbr,gba,gbs,gbo,gts} |
| 86 | echo ----- |
| 87 | echo Plotting Postscript: |
| 88 | $PCBNEW --plot=ps atusb.brd |
| 89 | ls -la *.ps |
| 90 | echo ----- |
| 91 | echo Plotting DXF: |
| 92 | $PCBNEW --plot=dxf atusb.brd |
| 93 | ls -la *.dxf |
| 94 | echo ----- |
| 95 | echo Plotting SVG: |
| 96 | $PCBNEW --svg=selected atusb.brd |
| 97 | ls -la *.svg |
| 98 | echo ----- |
| 99 | echo Generating .rpt design rule file: |
| 100 | $PCBNEW --drc atusb.brd |
| 101 | ls -la *.rpt |
| 102 | echo ----- |
| 103 | echo Generating .pos position file: |
| 104 | $PCBNEW --pos atusb.brd |
| 105 | ls -la *.pos |
| 106 | echo ----- |
| 107 | echo Generating .csv bom: |
| 108 | $PCBNEW --bom atusb.brd |
| 109 | ls -la *.csv |
| 110 | echo ----- |
| 111 | echo Generating .cmp components for CvPcb: |
| 112 | $PCBNEW --cmp atusb.brd |
| 113 | ls -la *.cmp |
| 114 | echo ----- |
| 115 | echo Generating .wrl vrml board representation: |
| 116 | $PCBNEW --vrml atusb.brd |
| 117 | ls -la *.wrl |
| 118 | echo ----- |
| 119 | cd ../.. |
| 120 | exit |
| 121 | fi |
| 122 | |
| 123 | if [ "$1" == "clean" ]; then |
| 124 | cd ben-wpan/atusb |
| 125 | rm atusb_bw.pdf atusb_noopt.pdf atusb_sheetref.pdf \ |
| 126 | atusb-RF_bw.pdf atusb-RF_noopt.pdf atusb-RF_sheetref.pdf \ |
| 127 | atusb-USB_bw.pdf atusb-USB_noopt.pdf atusb-USB_sheetref.pdf \ |
| 128 | atusb.ps atusb-RF.ps atusb-USB.ps \ |
| 129 | atusb.svg atusb-RF.svg atusb-USB.svg \ |
| 130 | atusb.dxf atusb-RF.dxf atusb-USB.dxf \ |
| 131 | atusb.lst \ |
| 132 | atusb.erc \ |
| 133 | atusb.net \ |
| 134 | atusb.drl atusb-NPTH.drl \ |
| 135 | atusb_all.pos \ |
| 136 | atusb.rpt \ |
| 137 | atusb.cmp \ |
| 138 | atusb.csv \ |
| 139 | atusb.wrl \ |
| 140 | atusb-Front.{gba,ps,dxf,svg} \ |
| 141 | atusb-Back.{gbr,ps,dxf,svg} \ |
| 142 | atusb-Comments.{gbr,ps,dxf} \ |
| 143 | atusb-Drawings.{gbr,ps,dxf} \ |
| 144 | atusb-Mask_Front.{gbr,ps,dxf} \ |
| 145 | atusb-Mask_Back.{gts,ps,dxf} \ |
| 146 | atusb-PCB_Edges.{gbr,ps,dxf} \ |
| 147 | atusb-SilkS_Front.{gbs,ps,dxf,svg} \ |
| 148 | atusb-SoldP_Front.{gbo,ps,dxf} |
| 149 | rmdir shapes3D |
| 150 | cd ../.. |
| 151 | exit |
| 152 | fi |
| 153 |
Branches:
master
