← Commit history

4 corner machine pins only in the machine-pins layer; play/pause as icons (bars/triangle)

John Lauer ·c8a29854d9 ·3mo ago ·parent 403261d
3 files changed +16−10
package.json+1−1
@@ -2,7 +2,7 @@   "slug": "bq25792-charger",   "title": "BQ25792 Charger",   "type": "component",-  "version": "0.1.53",+  "version": "0.1.54",   "description": "BQ25792 Charger - buck-boost 1S-4S battery charger board by Adonis, with real 3D copper traces and measured stackup.",   "tags": [     "hardware"
page.json+10−3
@@ -4,9 +4,16 @@   "slug": "bq25792-charger",   "title": "BQ25792 Charger",   "brief": "Buck-boost 1S-4S battery charger board (TI BQ25792) with 14 Adom machine pins, by Adonis",-  "version": "0.1.53",+  "version": "0.1.54",   "tags": [-    "hardware"+    "adom",+    "adom-modular",+    "component",+    "charger",+    "battery",+    "bq25792",+    "power",+    "usb-c"   ],   "license": "proprietary",   "component": {@@ -49,7 +56,7 @@     "email": "[email protected]"   },   "visibility": "public",-  "description": "BQ25792 Charger - buck-boost 1S-4S battery charger board by Adonis, with real 3D copper traces and measured stackup.",+  "description": "BQ25792 Charger - a buck-boost 1S-4S battery charger board (Texas Instruments BQ25792) designed by Adonis in Fusion 360, with 14 Adom machine pins for the modular stack. Interactive colored 3D model, schematic and layout views.",   "dependencies": {},   "files": [     "README.md",
readme.html+5−6
@@ -76,7 +76,7 @@     <button class="fbtn" id="btn-fs" type="button" title="Fullscreen">Fullscreen</button>   </div>   <div id="layers-panel"><div class="lp-title"><span class="grip" title="drag">::</span> Layers</div><div id="lp-rows"></div><div id="lp-order">order: -</div></div>-  <div id="scrub-wrap"><button id="btn-play" class="fbtn" type="button" title="Play/pause">Pause</button><input id="scrub" type="range" min="0" max="1000" value="0"></div>+  <div id="scrub-wrap"><button id="btn-play" class="fbtn" type="button" title="Play/pause" style="min-width:34px;font-size:13px">&#10074;&#10074;</button><input id="scrub" type="range" min="0" max="1000" value="0"></div>   <span id="vstatus">starting viewer...</span> </div> </div>@@ -231,8 +231,7 @@ exported bodies + design rules.</p>     // PER-PART components (non-join export keeps each occupant as its own mesh). Classify by     // XY against the 14 machine-pin positions from the CPL: a mesh whose footprint covers an     // MP position is a machine pin -> anchored layer; everything else -> Components.-    const MP=[[1.2,1.2],[1.2,25.2],[49.2,25.2],[49.2,1.2],[19.2,1.2],[21.2,1.2],[23.2,1.2],-              [25.2,1.2],[27.2,1.2],[19.2,15.2],[19.2,17.2],[19.2,11.2],[19.2,9.2]].map(p=>[p[0]*mm,p[1]*mm]);+    const MP=[[1.2,1.2],[1.2,25.2],[49.2,25.2],[49.2,1.2]].map(p=>[p[0]*mm,p[1]*mm]);     const compBytes=await loadPngBytes(R+"grp-components-parts.glb.png");     let pre=sc.meshes.length;     await B().SceneLoader.AppendAsync("", new File([compBytes],"components.glb",{type:"model/gltf-binary"}), sc, null, ".glb");@@ -252,7 +251,7 @@ exported bodies + design rules.</p>         const cx=(mnx+mxx)/2, cy=(mny+mxy)/2, tall=(mxz-mnz)>3*mm, thru=mnz< -0.3*mm;         let isPin=false;         for(const p of MP){ if(mnx-0.8*mm<=p[0]&&mxx+0.8*mm>=p[0]&&mny-0.8*mm<=p[1]&&mxy+0.8*mm>=p[1]){ isPin=true; break; } }-        if(!isPin && tall && thru) isPin=true;   // tall through-hole occurrence = a pin/contact+         (isPin?pins:comps).push.apply(isPin?pins:comps, meshes);       });       attach("components", comps);@@ -468,8 +467,8 @@ exported bodies + design rules.</p>     (card.requestFullscreen?card.requestFullscreen():Promise.reject()).catch?.(function(){ set("fullscreen blocked in the embed - open the readme URL directly"); });   });   const btnPlay=document.getElementById("btn-play");-  function play(){ mode="anim"; dir=(u>=1)?-1:1; holdT=0; setBtns(btnAnim); set("animating"); btnPlay.textContent="Pause"; if(resumeTimer){clearTimeout(resumeTimer);resumeTimer=null;} }-  function pause(){ mode="manual"; setBtns(null); set("paused"); btnPlay.textContent="Play"; }+  function play(){ mode="anim"; dir=(u>=1)?-1:1; holdT=0; setBtns(btnAnim); set("animating"); btnPlay.innerHTML="&#10074;&#10074;"; if(resumeTimer){clearTimeout(resumeTimer);resumeTimer=null;} }+  function pause(){ mode="manual"; setBtns(null); set("paused"); btnPlay.innerHTML="&#9654;"; }   btnPlay.addEventListener("click",function(){ if(mode==="anim") pause(); else play(); });   scrub.addEventListener("input",function(){     pause(); set("scrubbing");