PopufareHousingFrontAngle.scad 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112
  1. // License: CC0
  2. //
  3. // To the extent possible under law, Clementine Computing LLC has waived
  4. // all copyright and related or neighboring rights to this file.
  5. //
  6. // This work is published from: United States.
  7. //
  8. include <PopufareHousingCommon.scad>
  9. module PopufareHousingFrontAnglePlate_resistive() {
  10. dh = POPUFARE_HOUSING_HEIGHT - POPUFARE_FRONT_HEIGHT;
  11. w = POPUFARE_HOUSING_WIDTH;
  12. h = sqrt(2.0)*dh;
  13. bx = POPUFARE_BRACKET_CX;
  14. br = POPUFARE_BRACKET_D/2.0;
  15. de = POPUFARE_BRACKET_DE;
  16. des = POPUFARE_BRACKET_DE_SHORT;
  17. lip = _MATERIAL_THICKNESS;
  18. screen_w = POPUFARE_SCREEN_WIDTH_RESISTIVE;
  19. screen_h = POPUFARE_SCREEN_HEIGHT_RESISTIVE;
  20. screen_cx = 0;
  21. screen_cy = 0;
  22. screen_attach_dw = POPUFARE_INNER_PLATE_HOLE_WIDTH;
  23. screen_attach_dh = POPUFARE_INNER_PLATE_HOLE_HEIGHT;
  24. difference() {
  25. union() {
  26. square([w + 2*lip,h + 2*lip + 2*lip], center=true);
  27. };
  28. // attach to side plate brackets
  29. //
  30. translate([ -(w/2 - bx), -(h/2-des) ]) circle(br);
  31. translate([ -(w/2 - bx), (h/2-des) ]) circle(br);
  32. translate([ (w/2 - bx), -(h/2-des) ]) circle(br);
  33. translate([ (w/2 - bx), (h/2-des) ]) circle(br);
  34. // screen center
  35. //
  36. translate([screen_cx, screen_cy]) square([screen_w, screen_h], center=true);
  37. translate([screen_cx, screen_cy]) translate([ screen_attach_dw/2, screen_attach_dh/2]) circle(_M3r);
  38. translate([screen_cx, screen_cy]) translate([ screen_attach_dw/2,-screen_attach_dh/2]) circle(_M3r);
  39. translate([screen_cx, screen_cy]) translate([-screen_attach_dw/2,-screen_attach_dh/2]) circle(_M3r);
  40. translate([screen_cx, screen_cy]) translate([-screen_attach_dw/2, screen_attach_dh/2]) circle(_M3r);
  41. }
  42. }
  43. module PopufareHousingFrontAnglePlate_capacitive() {
  44. dh = POPUFARE_HOUSING_HEIGHT - POPUFARE_FRONT_HEIGHT;
  45. lip = _MATERIAL_THICKNESS;
  46. w = POPUFARE_HOUSING_WIDTH;
  47. h = sqrt(2.0)*dh ;
  48. bx = POPUFARE_BRACKET_CX;
  49. br = POPUFARE_BRACKET_D/2.0;
  50. de = POPUFARE_BRACKET_DE;
  51. des = POPUFARE_BRACKET_DE_SHORT;
  52. lip = _MATERIAL_THICKNESS;
  53. screen_w = POPUFARE_SCREEN_WIDTH_CAPACITIVE;
  54. screen_h = POPUFARE_SCREEN_HEIGHT_CAPACITIVE;
  55. screen_cx = 0;
  56. screen_cy = 0;
  57. screen_attach_dw = POPUFARE_INNER_PLATE_HOLE_WIDTH;
  58. screen_attach_dh = POPUFARE_INNER_PLATE_HOLE_HEIGHT;
  59. difference() {
  60. union() {
  61. square([w + 2*lip,h + 4*lip], center=true);
  62. }
  63. // attach to side plate brackets
  64. //
  65. translate([ -(w/2 - bx), -(h/2-des) ]) circle(br);
  66. translate([ -(w/2 - bx), (h/2-des) ]) circle(br);
  67. translate([ (w/2 - bx), -(h/2-des) ]) circle(br);
  68. translate([ (w/2 - bx), (h/2-des) ]) circle(br);
  69. // screen center
  70. //
  71. translate([screen_cx, screen_cy]) square([screen_w, screen_h], center=true);
  72. translate([screen_cx, screen_cy]) translate([ screen_attach_dw/2, screen_attach_dh/2]) circle(_M3r);
  73. translate([screen_cx, screen_cy]) translate([ screen_attach_dw/2,-screen_attach_dh/2]) circle(_M3r);
  74. translate([screen_cx, screen_cy]) translate([-screen_attach_dw/2,-screen_attach_dh/2]) circle(_M3r);
  75. translate([screen_cx, screen_cy]) translate([-screen_attach_dw/2, screen_attach_dh/2]) circle(_M3r);
  76. }
  77. }
  78. module PopufareHousingFrontAnglePlate() {
  79. //PopufareHousingFrontAnglePlate_resistive();
  80. PopufareHousingFrontAnglePlate_capacitive();
  81. }
  82. //PopufareHousingFrontAnglePlate();