home *** CD-ROM | disk | FTP | other *** search
/ HAM Radio 1 / HamRadio.cdr / tech / pcbsrcs2 / plcc.c < prev    next >
C/C++ Source or Header  |  1991-02-07  |  5KB  |  183 lines

  1. #include "custom.h"
  2.  
  3. static pin  plcc20[] =
  4.  {
  5.     {0,0},  {2,0},  {0,-2},
  6.     {2,-4}, {2,-2}, {4,-4},
  7.     {4,-2}, {6,-4}, {8,-2},
  8.     {6,-2}, {8,0},  {6,0},
  9.     {8,2},  {6,4},  {6,2},
  10.     {4,4},  {4,2},  {2,4},
  11.     {0,2},  {2,2}
  12.  };
  13. #define plcc20_len  sizeof(plcc20)/sizeof(plcc20[0])
  14.  
  15. static pin  plcc28[] =
  16.  {
  17.     {0,0},   {-2,-2}, {0,-2},
  18.     {-2,-4}, {0,-6},  {0,-4},
  19.     {2,-6},  {2,-4},  {4,-6},
  20.     {4,-4},  {6,-6},  {8,-4},
  21.     {6,-4},  {8,-2},  {6,-2},
  22.     {8,0},   {6,0},   {8,2},
  23.     {6,4},   {6,2},   {4,4},
  24.     {4,2},   {2,4},   {2,2},
  25.     {0,4},   {-2,2},  {0,2},
  26.     {-2,0}
  27.  };
  28. #define plcc28_len  sizeof(plcc28)/sizeof(plcc28[0])
  29.  
  30. static pin  plcc32[] =
  31.  {
  32.     {0,0},   {-2,-2}, {0,-2},
  33.     {-2,-4}, {0,-6},  {0,-4},
  34.     {2,-6},  {2,-4},  {4,-6},
  35.     {4,-4},  {6,-6},  {6,-4},
  36.     {8,-6},  {10,-4}, {8,-4},
  37.     {10,-2}, {8,-2},  {10,0},
  38.     {8,0},   {10,2},  {8,4},
  39.     {8,2},   {6,4},   {6,2},
  40.     {4,4},   {4,2},   {2,4},
  41.     {2,2},   {0,4},   {-2,2},
  42.     {0,2},   {-2,0}
  43.  };
  44. #define plcc32_len  sizeof(plcc32)/sizeof(plcc32[0])
  45.  
  46. static pin  plcc44[] =
  47.  {
  48.     {0,0},   {-2,-2}, {0,-2},
  49.     {-2,-4}, {0,-4},  {-2,-6},
  50.     {0,-8},  {0,-6},  {2,-8},
  51.     {2,-6},  {4,-8},  {4,-6},
  52.     {6,-8},  {6,-6},  {8,-8},
  53.     {8,-6},  {10,-8}, {12,-6},
  54.     {10,-6}, {12,-4}, {10,-4},
  55.     {12,-2}, {10,-2}, {12,0},
  56.     {10,0},  {12,2},  {10,2},
  57.     {12,4},  {10,6},  {10,4},
  58.     {8,6},   {8,4},   {6,6},
  59.     {6,4},   {4,6},   {4,4},
  60.     {2,6},   {2,4},   {0,6},
  61.     {-2,4},  {0,4},   {-2,2},
  62.     {0,2},   {-2,0}
  63.  };              
  64. #define plcc44_len  sizeof(plcc44)/sizeof(plcc44[0])
  65.  
  66. static pin  plcc52[] =
  67.  {
  68.     {0,0},   {2,0},   {0,-2},
  69.     {2,-2},  {0,-4},  {2,-4},
  70.     {0,-6},  {2,-8},  {2,-6},
  71.     {4,-8},  {4,-6},  {6,-8},
  72.     {6,-6},  {8,-8},  {8,-6},
  73.     {10,-8}, {10,-6}, {12,-8},
  74.     {12,-6}, {14,-8}, {16,-6},
  75.     {14,-6}, {16,-4}, {14,-4},
  76.     {16,-2}, {14,-2}, {16,0},
  77.     {14,0},  {16,2},  {14,2},
  78.     {16,4},  {14,4},  {16,6},
  79.     {14,8},  {14,6},  {12,8},
  80.     {12,6},  {10,8},  {10,6},
  81.     {8,8},   {8,6},   {6,8},
  82.     {6,6},   {4,8},   {4,6},
  83.     {2,8},   {0,6},   {2,6},
  84.     {0,4},   {2,4},   {0,2},
  85.     {2,2}
  86.  };
  87. #define plcc52_len  sizeof(plcc52)/sizeof(plcc52[0])
  88.  
  89. static pin  plcc68[] =
  90.  {
  91.     {0,0},    {2,0},    {0,-2},
  92.     {2,-2},   {0,-4},   {2,-4},
  93.     {0,-6},   {2,-6},   {0,-8},
  94.     {2,-10},  {2,-8},   {4,-10},
  95.     {4,-8},   {6,-10},  {6,-8},
  96.     {8,-10},  {8,-8},   {10,-10},
  97.     {10,-8},  {12,-10}, {12,-8},
  98.     {14,-10}, {14,-8},  {16,-10},
  99.     {16,-8},  {18,-10}, {20,-8},
  100.     {18,-8},  {20,-6},  {18,-6},
  101.     {20,-4},  {18,-4},  {20,-2},
  102.     {18,-2},  {20,0},   {18,0},
  103.     {20,2},   {18,2},   {20,4},
  104.     {18,4},   {20,6},   {18,6},
  105.     {20,8},   {18,10},  {18,8},
  106.     {16,10},  {16,8},   {14,10},
  107.     {14,8},   {12,10},  {12,8},
  108.     {10,10},  {10,8},   {8,10},
  109.     {8,8},    {6,10},   {6,8},
  110.     {4,10},   {4,8},    {2,10},
  111.     {0,8},    {2,8},    {0,6},
  112.     {2,6},    {0,4},    {2,4},
  113.     {0,2},    {2,2}
  114.  };
  115. #define plcc68_len  sizeof(plcc68)/sizeof(plcc68[0])
  116.  
  117. static pin  plcc84[] =
  118.  {
  119.     {0,0},    {2,0},    {0,-2},
  120.     {2,-2},   {0,-4},   {2,-4},
  121.     {0,-6},   {2,-6},   {0,-8},
  122.     {2,-8},   {0,-10},  {2,-12},
  123.     {2,-10},  {4,-12},  {4,-10},
  124.     {6,-12},  {6,-10},  {8,-12},
  125.     {8,-10},  {10,-12}, {10,-10},
  126.     {12,-12}, {12,-10}, {14,-12},
  127.     {14,-10}, {16,-12}, {16,-10},
  128.     {18,-12}, {18,-10}, {20,-12},
  129.     {20,-10}, {22,-12}, {24,-10},
  130.     {22,-10}, {24,-8},  {22,-8},
  131.     {24,-6},  {22,-6},  {24,-4},
  132.     {22,-4},  {24,-2},  {22,-2},
  133.     {24,0},   {22,0},   {24,2},
  134.     {22,2},   {24,4},   {22,4},
  135.     {24,6},   {22,6},   {24,8},
  136.     {22,8},   {24,10},  {22,12},
  137.     {22,10},  {20,12},  {20,10},
  138.     {18,12},  {18,10},  {16,12},
  139.     {16,10},  {14,12},  {14,10},
  140.     {12,12},  {12,10},  {10,12},
  141.     {10,10},  {8,12},   {8,10},
  142.     {6,12},   {6,10},   {4,12},
  143.     {4,10},   {2,12},   {0,10},
  144.     {2,10},   {0,8},    {2,8},
  145.     {0,6},    {2,6},    {0,4},
  146.     {2,4},    {0,2},    {2,2},
  147.  };
  148. #define plcc84_len  sizeof(plcc84)/sizeof(plcc84[0])
  149.  
  150. static pin to5[]   = { {0,0}, {2,2}, {4,0} };
  151. #define to5_len sizeof(to5)/sizeof(to5[0])
  152.  
  153. static pin to18[]  = { {0,0}, {1,1}, {2,0} };
  154. #define to18_len sizeof(to18)/sizeof(to18[0])
  155.  
  156. static pin pot_p[] = { {0,0}, {6,-2}, {10,0} };
  157. #define pot_p_len sizeof(pot_p)/sizeof(pot_p[0])
  158.  
  159. static pin pot_w[] = { {0,0}, {6,-4}, {10,0} };
  160. #define pot_w_len sizeof(pot_w)/sizeof(pot_w[0])
  161.  
  162. static pin pot_y[] = { {0,0}, {8,-2}, {14,0} };
  163. #define pot_y_len sizeof(pot_y)/sizeof(pot_y[0])
  164.  
  165. cust_table custom[] =
  166. {
  167.    {"PLCC20",      plcc20_len,  plcc20},
  168.    {"PLCC28",      plcc28_len,  plcc28},
  169.    {"PLCC32",      plcc32_len,  plcc32},
  170.    {"PLCC44",      plcc44_len,  plcc44},
  171.    {"PLCC52",      plcc52_len,  plcc52},
  172.    {"PLCC68",      plcc68_len,  plcc68},
  173.    {"PLCC84",      plcc84_len,  plcc84},
  174.    {"TO5",         to5_len,     to5   },
  175.    {"TO18",        to18_len,    to18  },
  176.    {"TRIMMERW",    pot_w_len,   pot_w },
  177.    {"TRIMMERP",    pot_p_len,   pot_p },
  178.    {"TRIMMERY",    pot_y_len,   pot_y },
  179. };
  180.  
  181. unsigned custom_len = sizeof(custom)/sizeof(custom[0]);
  182.            
  183.