import{s as fe,n as Ue,o as $e}from"../chunks/scheduler.eb244325.js";import{S as be,i as we,e as M,s as l,c as i,h as Je,a as c,d as s,b as a,f as ye,g as o,j as d,k as de,l as ge,m as n,n as p,t as m,o as r,p as u}from"../chunks/index.3fe63ad3.js";import{C as Te}from"../chunks/CopyLLMTxtMenu.88bde5f2.js";import{C as f}from"../chunks/CodeBlock.934d290d.js";import{H as y,E as je}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.341974a5.js";function he(Ot){let U,pt,it,mt,$,rt,b,ut,w,te="This guide covers setup and usage of Damiao motors with LeRobot via CAN bus communication.",Mt,J,ee="Currently, only Linux is supported, as the OpenArms CAN adapter only has drivers for Linux.",ct,g,yt,T,se="Before using Damiao motors, you need to set up the CAN interface on your Linux system.",dt,j,ft,h,Ut,C,$t,I,ne="For standard CAN FD (recommended for OpenArms):",bt,N,wt,B,le="For standard CAN (without FD):",Jt,x,gt,v,Tt,_,ae="LeRobot provides a utility script to setup and test CAN interfaces:",jt,A,ht,G,Ct,Q,ie="Use the built-in debug tools to test motor communication:",It,S,Nt,D,oe="The test mode will scan for motors (IDs 0x01-0x08) and report which ones respond. Example output:",Bt,R,xt,z,vt,W,_t,E,At,Z,Gt,X,Qt,F,St,V,Dt,q,Rt,k,pe="<thead><tr><th>Parameter</th> <th>Default</th> <th>Description</th></tr></thead> <tbody><tr><td><code>port</code></td> <td>-</td> <td>CAN interface (<code>can0</code>) or serial port (<code>/dev/cu.usbmodem*</code>)</td></tr> <tr><td><code>use_can_fd</code></td> <td><code>True</code></td> <td>Enable CAN FD for higher data rates</td></tr> <tr><td><code>bitrate</code></td> <td><code>1000000</code></td> <td>Nominal bitrate (1 Mbps)</td></tr> <tr><td><code>data_bitrate</code></td> <td><code>5000000</code></td> <td>CAN FD data bitrate (5 Mbps)</td></tr></tbody>",zt,Y,Wt,L,me="Each motor requires:",Et,H,re="<li><code>id</code>: CAN ID for sending commands</li> <li><code>motor_type</code>: One of the supported motor types (e.g., <code>&quot;dm8009&quot;</code>, <code>&quot;dm4340&quot;</code>)</li> <li><code>recv_id</code>: CAN ID for receiving responses</li>",Zt,P,ue="OpenArms default IDs follow the pattern: send ID <code>0x0N</code>, receive ID <code>0x1N</code> where N is the joint number.",Xt,K,Ft,O,Vt,tt,Me="<li><strong>Check power</strong></li> <li><strong>Verify CAN wiring</strong>: Check CAN-H, CAN-L, and GND connections</li> <li><strong>Check motor IDs</strong>: Use Damiao Debugging Tools to verify/configure IDs</li> <li><strong>Test CAN interface</strong>: Run <code>candump can0</code> to see if messages are being received</li> <li><strong>Run diagnostics</strong>: <code>lerobot-setup-can --mode=test --interfaces=can0</code></li>",qt,et,kt,st,ce="If motors were configured with timeout=0, they won’t respond to commands. Use Damiao Debugging Tools to set a non-zero timeout value.",Yt,nt,Lt,lt,Ht,at,Pt,ot,Kt;return $=new Te({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),b=new y({props:{title:"Damiao Motors and CAN Bus",local:"damiao-motors-and-can-bus",headingTag:"h1"}}),g=new y({props:{title:"Linux CAN Setup",local:"linux-can-setup",headingTag:"h2"}}),j=new y({props:{title:"Install CAN Utilities",local:"install-can-utilities",headingTag:"h3"}}),h=new f({props:{code:"c3VkbyUyMGFwdC1nZXQlMjBpbnN0YWxsJTIwY2FuLXV0aWxz",highlighted:"sudo apt-get install can-utils",wrap:!1}}),C=new y({props:{title:"Configure CAN Interface (Manual)",local:"configure-can-interface-manual",headingTag:"h3"}}),N=new f({props:{code:"c3VkbyUyMGlwJTIwbGluayUyMHNldCUyMGNhbjAlMjBkb3duJTBBc3VkbyUyMGlwJTIwbGluayUyMHNldCUyMGNhbjAlMjB0eXBlJTIwY2FuJTIwYml0cmF0ZSUyMDEwMDAwMDAlMjBkYml0cmF0ZSUyMDUwMDAwMDAlMjBmZCUyMG9uJTBBc3VkbyUyMGlwJTIwbGluayUyMHNldCUyMGNhbjAlMjB1cA==",highlighted:`sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 down
sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 <span class="hljs-built_in">type</span> can bitrate 1000000 dbitrate 5000000 fd on
sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 up`,wrap:!1}}),x=new f({props:{code:"c3VkbyUyMGlwJTIwbGluayUyMHNldCUyMGNhbjAlMjBkb3duJTBBc3VkbyUyMGlwJTIwbGluayUyMHNldCUyMGNhbjAlMjB0eXBlJTIwY2FuJTIwYml0cmF0ZSUyMDEwMDAwMDAlMEFzdWRvJTIwaXAlMjBsaW5rJTIwc2V0JTIwY2FuMCUyMHVw",highlighted:`sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 down
sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 <span class="hljs-built_in">type</span> can bitrate 1000000
sudo ip <span class="hljs-built_in">link</span> <span class="hljs-built_in">set</span> can0 up`,wrap:!1}}),v=new y({props:{title:"Configure CAN Interface (Using LeRobot)",local:"configure-can-interface-using-lerobot",headingTag:"h3"}}),A=new f({props:{code:"JTIzJTIwU2V0dXAlMjBtdWx0aXBsZSUyMGludGVyZmFjZXMlMjAoZS5nLiUyQyUyME9wZW5Bcm1zJTIwRm9sbG93ZXJzJTIwd2l0aCUyMDIlMjBDQU4lMjBidXNlcyklMEFsZXJvYm90LXNldHVwLWNhbiUyMC0tbW9kZSUzRHNldHVwJTIwLS1pbnRlcmZhY2VzJTNEY2FuMCUyQ2NhbjE=",highlighted:`<span class="hljs-comment"># Setup multiple interfaces (e.g., OpenArms Followers with 2 CAN buses)</span>
lerobot-setup-can --mode=setup --interfaces=can0,can1`,wrap:!1}}),G=new y({props:{title:"Debugging CAN Communication",local:"debugging-can-communication",headingTag:"h2"}}),S=new f({props:{code:"JTIzJTIwVGVzdCUyMG1vdG9ycyUyMG9uJTIwYWxsJTIwaW50ZXJmYWNlcyUwQWxlcm9ib3Qtc2V0dXAtY2FuJTIwLS1tb2RlJTNEdGVzdCUyMC0taW50ZXJmYWNlcyUzRGNhbjAlMkNjYW4xJTBBJTBBJTIzJTIwUnVuJTIwc3BlZWQlMkZsYXRlbmN5JTIwdGVzdCUwQWxlcm9ib3Qtc2V0dXAtY2FuJTIwLS1tb2RlJTNEc3BlZWQlMjAtLWludGVyZmFjZXMlM0RjYW4w",highlighted:`<span class="hljs-comment"># Test motors on all interfaces</span>
lerobot-setup-can --mode=<span class="hljs-built_in">test</span> --interfaces=can0,can1

<span class="hljs-comment"># Run speed/latency test</span>
lerobot-setup-can --mode=speed --interfaces=can0`,wrap:!1}}),R=new f({props:{code:"Y2FuMCUzQSUyMFVQJTIwKENBTiUyMEZEKSUwQSUyMCUyME1vdG9yJTIwMHgwMSUyMChqb2ludF8xKSUzQSUyMCVFMiU5QyU5MyUyMEZPVU5EJTBBJTIwJTIwJTIwJTIwJUUyJTg2JTkyJTIwUmVzcG9uc2UlMjAweDExJTIwJTVCRkQlNUQlM0ElMjAwMDExMjIzMy4uLiUwQSUyMCUyME1vdG9yJTIwMHgwMiUyMChqb2ludF8yKSUzQSUyMCVFMiU5QyU5MyUyMEZPVU5EJTBBJTIwJTIwTW90b3IlMjAweDAzJTIwKGpvaW50XzMpJTNBJTIwJUUyJTlDJTk3JTIwTm8lMjByZXNwb25zZSUwQSUyMCUyMC4uLiUwQSUyMCUyMFN1bW1hcnklM0ElMjAyJTJGOCUyMG1vdG9ycyUyMGZvdW5k",highlighted:`<span class="hljs-attribute">can0</span><span class="hljs-punctuation">:</span> <span class="hljs-string">UP (CAN FD)</span>
  <span class="hljs-attribute">Motor 0x01 (joint_1)</span><span class="hljs-punctuation">:</span> <span class="hljs-string">✓ FOUND</span>
    <span class="hljs-attribute">→ Response 0x11 [FD]</span><span class="hljs-punctuation">:</span> <span class="hljs-string">00112233...</span>
  <span class="hljs-attribute">Motor 0x02 (joint_2)</span><span class="hljs-punctuation">:</span> <span class="hljs-string">✓ FOUND</span>
  <span class="hljs-attribute">Motor 0x03 (joint_3)</span><span class="hljs-punctuation">:</span> <span class="hljs-string">✗ No response</span>
  <span class="hljs-attribute">...
  Summary</span><span class="hljs-punctuation">:</span> <span class="hljs-string">2/8 motors found</span>`,wrap:!1}}),z=new y({props:{title:"Usage",local:"usage",headingTag:"h2"}}),W=new y({props:{title:"Basic Setup",local:"basic-setup",headingTag:"h3"}}),E=new f({props:{code:"ZnJvbSUyMGxlcm9ib3QubW90b3JzJTIwaW1wb3J0JTIwTW90b3IlMEFmcm9tJTIwbGVyb2JvdC5tb3RvcnMuZGFtaWFvJTIwaW1wb3J0JTIwRGFtaWFvTW90b3JzQnVzJTBBJTBBJTIzJTIwRGVmaW5lJTIweW91ciUyMG1vdG9ycyUyMHdpdGglMjBzZW5kJTJGcmVjZWl2ZSUyMENBTiUyMElEcyUwQW1vdG9ycyUyMCUzRCUyMCU3QiUwQSUyMCUyMCUyMCUyMCUyMmpvaW50XzElMjIlM0ElMjBNb3RvcihpZCUzRDB4MDElMkMlMjBtb3Rvcl90eXBlX3N0ciUzRCUyMmRtODAwOSUyMiUyQyUyMHJlY3ZfaWQlM0QweDExKSUyQyUwQSUyMCUyMCUyMCUyMCUyMmpvaW50XzIlMjIlM0ElMjBNb3RvcihpZCUzRDB4MDIlMkMlMjBtb3Rvcl90eXBlX3N0ciUzRCUyMmRtNDM0MCUyMiUyQyUyMHJlY3ZfaWQlM0QweDEyKSUyQyUwQSUyMCUyMCUyMCUyMCUyMmpvaW50XzMlMjIlM0ElMjBNb3RvcihpZCUzRDB4MDMlMkMlMjBtb3Rvcl90eXBlX3N0ciUzRCUyMmRtNDMxMCUyMiUyQyUyMHJlY3ZfaWQlM0QweDEzKSUyQyUwQSU3RCUwQSUwQSUyMyUyMENyZWF0ZSUyMHRoZSUyMGJ1cyUwQWJ1cyUyMCUzRCUyMERhbWlhb01vdG9yc0J1cyglMEElMjAlMjAlMjAlMjBwb3J0JTNEJTIyY2FuMCUyMiUyQyUyMCUyMCUyMyUyMExpbnV4JTIwc29ja2V0Y2FuJTIwaW50ZXJmYWNlJTBBJTIwJTIwJTIwJTIwbW90b3JzJTNEbW90b3JzJTJDJTBBKSUwQSUwQSUyMyUyMENvbm5lY3QlMEFidXMuY29ubmVjdCgp",highlighted:`<span class="hljs-keyword">from</span> lerobot.motors <span class="hljs-keyword">import</span> Motor
<span class="hljs-keyword">from</span> lerobot.motors.damiao <span class="hljs-keyword">import</span> DamiaoMotorsBus

<span class="hljs-comment"># Define your motors with send/receive CAN IDs</span>
motors = {
    <span class="hljs-string">&quot;joint_1&quot;</span>: Motor(<span class="hljs-built_in">id</span>=<span class="hljs-number">0x01</span>, motor_type_str=<span class="hljs-string">&quot;dm8009&quot;</span>, recv_id=<span class="hljs-number">0x11</span>),
    <span class="hljs-string">&quot;joint_2&quot;</span>: Motor(<span class="hljs-built_in">id</span>=<span class="hljs-number">0x02</span>, motor_type_str=<span class="hljs-string">&quot;dm4340&quot;</span>, recv_id=<span class="hljs-number">0x12</span>),
    <span class="hljs-string">&quot;joint_3&quot;</span>: Motor(<span class="hljs-built_in">id</span>=<span class="hljs-number">0x03</span>, motor_type_str=<span class="hljs-string">&quot;dm4310&quot;</span>, recv_id=<span class="hljs-number">0x13</span>),
}

<span class="hljs-comment"># Create the bus</span>
bus = DamiaoMotorsBus(
    port=<span class="hljs-string">&quot;can0&quot;</span>,  <span class="hljs-comment"># Linux socketcan interface</span>
    motors=motors,
)

<span class="hljs-comment"># Connect</span>
bus.connect()`,wrap:!1}}),Z=new y({props:{title:"Reading Motor States",local:"reading-motor-states",headingTag:"h3"}}),X=new f({props:{code:"JTIzJTIwUmVhZCUyMHNpbmdsZSUyMG1vdG9yJTIwcG9zaXRpb24lMjAoZGVncmVlcyklMEFwb3NpdGlvbiUyMCUzRCUyMGJ1cy5yZWFkKCUyMlByZXNlbnRfUG9zaXRpb24lMjIlMkMlMjAlMjJqb2ludF8xJTIyKSUwQSUwQSUyMyUyMFJlYWQlMjBmcm9tJTIwbXVsdGlwbGUlMjBtb3RvcnMlMEFwb3NpdGlvbnMlMjAlM0QlMjBidXMuc3luY19yZWFkKCUyMlByZXNlbnRfUG9zaXRpb24lMjIpJTIwJTIwJTIzJTIwQWxsJTIwbW90b3JzJTBBcG9zaXRpb25zJTIwJTNEJTIwYnVzLnN5bmNfcmVhZCglMjJQcmVzZW50X1Bvc2l0aW9uJTIyJTJDJTIwJTVCJTIyam9pbnRfMSUyMiUyQyUyMCUyMmpvaW50XzIlMjIlNUQpJTBBJTBBJTIzJTIwUmVhZCUyMGFsbCUyMHN0YXRlcyUyMGF0JTIwb25jZSUyMChwb3NpdGlvbiUyQyUyMHZlbG9jaXR5JTJDJTIwdG9ycXVlKSUwQXN0YXRlcyUyMCUzRCUyMGJ1cy5zeW5jX3JlYWRfYWxsX3N0YXRlcygpJTBBJTIzJTIwUmV0dXJucyUzQSUyMCU3Qidqb2ludF8xJyUzQSUyMCU3Qidwb3NpdGlvbiclM0ElMjA0NS4yJTJDJTIwJ3ZlbG9jaXR5JyUzQSUyMDEuMyUyQyUyMCd0b3JxdWUnJTNBJTIwMC41JTdEJTJDJTIwLi4uJTdE",highlighted:`<span class="hljs-comment"># Read single motor position (degrees)</span>
position = bus.read(<span class="hljs-string">&quot;Present_Position&quot;</span>, <span class="hljs-string">&quot;joint_1&quot;</span>)

<span class="hljs-comment"># Read from multiple motors</span>
positions = bus.sync_read(<span class="hljs-string">&quot;Present_Position&quot;</span>)  <span class="hljs-comment"># All motors</span>
positions = bus.sync_read(<span class="hljs-string">&quot;Present_Position&quot;</span>, [<span class="hljs-string">&quot;joint_1&quot;</span>, <span class="hljs-string">&quot;joint_2&quot;</span>])

<span class="hljs-comment"># Read all states at once (position, velocity, torque)</span>
states = bus.sync_read_all_states()
<span class="hljs-comment"># Returns: {&#x27;joint_1&#x27;: {&#x27;position&#x27;: 45.2, &#x27;velocity&#x27;: 1.3, &#x27;torque&#x27;: 0.5}, ...}</span>`,wrap:!1}}),F=new y({props:{title:"Writing Motor Commands",local:"writing-motor-commands",headingTag:"h3"}}),V=new f({props:{code:"JTIzJTIwRW5hYmxlJTIwdG9ycXVlJTBBYnVzLmVuYWJsZV90b3JxdWUoKSUwQSUwQSUyMyUyMFNldCUyMGdvYWwlMjBwb3NpdGlvbiUyMChkZWdyZWVzKSUwQWJ1cy53cml0ZSglMjJHb2FsX1Bvc2l0aW9uJTIyJTJDJTIwJTIyam9pbnRfMSUyMiUyQyUyMDQ1LjApJTBBJTBBJTIzJTIwU2V0JTIwcG9zaXRpb25zJTIwZm9yJTIwbXVsdGlwbGUlMjBtb3RvcnMlMEFidXMuc3luY193cml0ZSglMjJHb2FsX1Bvc2l0aW9uJTIyJTJDJTIwJTdCJTBBJTIwJTIwJTIwJTIwJTIyam9pbnRfMSUyMiUzQSUyMDQ1LjAlMkMlMEElMjAlMjAlMjAlMjAlMjJqb2ludF8yJTIyJTNBJTIwLTMwLjAlMkMlMEElMjAlMjAlMjAlMjAlMjJqb2ludF8zJTIyJTNBJTIwOTAuMCUyQyUwQSU3RCklMEElMEElMjMlMjBEaXNhYmxlJTIwdG9ycXVlJTBBYnVzLmRpc2FibGVfdG9ycXVlKCk=",highlighted:`<span class="hljs-comment"># Enable torque</span>
bus.enable_torque()

<span class="hljs-comment"># Set goal position (degrees)</span>
bus.write(<span class="hljs-string">&quot;Goal_Position&quot;</span>, <span class="hljs-string">&quot;joint_1&quot;</span>, <span class="hljs-number">45.0</span>)

<span class="hljs-comment"># Set positions for multiple motors</span>
bus.sync_write(<span class="hljs-string">&quot;Goal_Position&quot;</span>, {
    <span class="hljs-string">&quot;joint_1&quot;</span>: <span class="hljs-number">45.0</span>,
    <span class="hljs-string">&quot;joint_2&quot;</span>: -<span class="hljs-number">30.0</span>,
    <span class="hljs-string">&quot;joint_3&quot;</span>: <span class="hljs-number">90.0</span>,
})

<span class="hljs-comment"># Disable torque</span>
bus.disable_torque()`,wrap:!1}}),q=new y({props:{title:"Configuration Options",local:"configuration-options",headingTag:"h2"}}),Y=new y({props:{title:"Motor Configuration",local:"motor-configuration",headingTag:"h2"}}),K=new y({props:{title:"Troubleshooting",local:"troubleshooting",headingTag:"h2"}}),O=new y({props:{title:"No Response from Motors",local:"no-response-from-motors",headingTag:"h3"}}),et=new y({props:{title:"Motor Timeout Parameter",local:"motor-timeout-parameter",headingTag:"h3"}}),nt=new y({props:{title:"Verify CAN FD Status",local:"verify-can-fd-status",headingTag:"h3"}}),lt=new f({props:{code:"aXAlMjAtZCUyMGxpbmslMjBzaG93JTIwY2FuMCUyMCU3QyUyMGdyZXAlMjBmZA==",highlighted:'ip -d <span class="hljs-built_in">link</span> show can0 | grep fd',wrap:!1}}),at=new je({props:{source:"https://github.com/huggingface/lerobot/blob/main/docs/source/damiao.mdx"}}),{c(){U=M("meta"),pt=l(),it=M("p"),mt=l(),i($.$$.fragment),rt=l(),i(b.$$.fragment),ut=l(),w=M("p"),w.textContent=te,Mt=l(),J=M("p"),J.textContent=ee,ct=l(),i(g.$$.fragment),yt=l(),T=M("p"),T.textContent=se,dt=l(),i(j.$$.fragment),ft=l(),i(h.$$.fragment),Ut=l(),i(C.$$.fragment),$t=l(),I=M("p"),I.textContent=ne,bt=l(),i(N.$$.fragment),wt=l(),B=M("p"),B.textContent=le,Jt=l(),i(x.$$.fragment),gt=l(),i(v.$$.fragment),Tt=l(),_=M("p"),_.textContent=ae,jt=l(),i(A.$$.fragment),ht=l(),i(G.$$.fragment),Ct=l(),Q=M("p"),Q.textContent=ie,It=l(),i(S.$$.fragment),Nt=l(),D=M("p"),D.textContent=oe,Bt=l(),i(R.$$.fragment),xt=l(),i(z.$$.fragment),vt=l(),i(W.$$.fragment),_t=l(),i(E.$$.fragment),At=l(),i(Z.$$.fragment),Gt=l(),i(X.$$.fragment),Qt=l(),i(F.$$.fragment),St=l(),i(V.$$.fragment),Dt=l(),i(q.$$.fragment),Rt=l(),k=M("table"),k.innerHTML=pe,zt=l(),i(Y.$$.fragment),Wt=l(),L=M("p"),L.textContent=me,Et=l(),H=M("ul"),H.innerHTML=re,Zt=l(),P=M("p"),P.innerHTML=ue,Xt=l(),i(K.$$.fragment),Ft=l(),i(O.$$.fragment),Vt=l(),tt=M("ol"),tt.innerHTML=Me,qt=l(),i(et.$$.fragment),kt=l(),st=M("p"),st.textContent=ce,Yt=l(),i(nt.$$.fragment),Lt=l(),i(lt.$$.fragment),Ht=l(),i(at.$$.fragment),Pt=l(),ot=M("p"),this.h()},l(t){const e=Je("svelte-u9bgzb",document.head);U=c(e,"META",{name:!0,content:!0}),e.forEach(s),pt=a(t),it=c(t,"P",{}),ye(it).forEach(s),mt=a(t),o($.$$.fragment,t),rt=a(t),o(b.$$.fragment,t),ut=a(t),w=c(t,"P",{"data-svelte-h":!0}),d(w)!=="svelte-40tw70"&&(w.textContent=te),Mt=a(t),J=c(t,"P",{"data-svelte-h":!0}),d(J)!=="svelte-19iafl1"&&(J.textContent=ee),ct=a(t),o(g.$$.fragment,t),yt=a(t),T=c(t,"P",{"data-svelte-h":!0}),d(T)!=="svelte-wyq1dk"&&(T.textContent=se),dt=a(t),o(j.$$.fragment,t),ft=a(t),o(h.$$.fragment,t),Ut=a(t),o(C.$$.fragment,t),$t=a(t),I=c(t,"P",{"data-svelte-h":!0}),d(I)!=="svelte-sr1vqs"&&(I.textContent=ne),bt=a(t),o(N.$$.fragment,t),wt=a(t),B=c(t,"P",{"data-svelte-h":!0}),d(B)!=="svelte-1nhfq5p"&&(B.textContent=le),Jt=a(t),o(x.$$.fragment,t),gt=a(t),o(v.$$.fragment,t),Tt=a(t),_=c(t,"P",{"data-svelte-h":!0}),d(_)!=="svelte-73p0fi"&&(_.textContent=ae),jt=a(t),o(A.$$.fragment,t),ht=a(t),o(G.$$.fragment,t),Ct=a(t),Q=c(t,"P",{"data-svelte-h":!0}),d(Q)!=="svelte-awyrh0"&&(Q.textContent=ie),It=a(t),o(S.$$.fragment,t),Nt=a(t),D=c(t,"P",{"data-svelte-h":!0}),d(D)!=="svelte-13ba7hw"&&(D.textContent=oe),Bt=a(t),o(R.$$.fragment,t),xt=a(t),o(z.$$.fragment,t),vt=a(t),o(W.$$.fragment,t),_t=a(t),o(E.$$.fragment,t),At=a(t),o(Z.$$.fragment,t),Gt=a(t),o(X.$$.fragment,t),Qt=a(t),o(F.$$.fragment,t),St=a(t),o(V.$$.fragment,t),Dt=a(t),o(q.$$.fragment,t),Rt=a(t),k=c(t,"TABLE",{"data-svelte-h":!0}),d(k)!=="svelte-15l1y39"&&(k.innerHTML=pe),zt=a(t),o(Y.$$.fragment,t),Wt=a(t),L=c(t,"P",{"data-svelte-h":!0}),d(L)!=="svelte-1ihn4n2"&&(L.textContent=me),Et=a(t),H=c(t,"UL",{"data-svelte-h":!0}),d(H)!=="svelte-chf6uo"&&(H.innerHTML=re),Zt=a(t),P=c(t,"P",{"data-svelte-h":!0}),d(P)!=="svelte-1p32hel"&&(P.innerHTML=ue),Xt=a(t),o(K.$$.fragment,t),Ft=a(t),o(O.$$.fragment,t),Vt=a(t),tt=c(t,"OL",{"data-svelte-h":!0}),d(tt)!=="svelte-1ghb4qv"&&(tt.innerHTML=Me),qt=a(t),o(et.$$.fragment,t),kt=a(t),st=c(t,"P",{"data-svelte-h":!0}),d(st)!=="svelte-ehpbpi"&&(st.textContent=ce),Yt=a(t),o(nt.$$.fragment,t),Lt=a(t),o(lt.$$.fragment,t),Ht=a(t),o(at.$$.fragment,t),Pt=a(t),ot=c(t,"P",{}),ye(ot).forEach(s),this.h()},h(){de(U,"name","hf:doc:metadata"),de(U,"content",Ce)},m(t,e){ge(document.head,U),n(t,pt,e),n(t,it,e),n(t,mt,e),p($,t,e),n(t,rt,e),p(b,t,e),n(t,ut,e),n(t,w,e),n(t,Mt,e),n(t,J,e),n(t,ct,e),p(g,t,e),n(t,yt,e),n(t,T,e),n(t,dt,e),p(j,t,e),n(t,ft,e),p(h,t,e),n(t,Ut,e),p(C,t,e),n(t,$t,e),n(t,I,e),n(t,bt,e),p(N,t,e),n(t,wt,e),n(t,B,e),n(t,Jt,e),p(x,t,e),n(t,gt,e),p(v,t,e),n(t,Tt,e),n(t,_,e),n(t,jt,e),p(A,t,e),n(t,ht,e),p(G,t,e),n(t,Ct,e),n(t,Q,e),n(t,It,e),p(S,t,e),n(t,Nt,e),n(t,D,e),n(t,Bt,e),p(R,t,e),n(t,xt,e),p(z,t,e),n(t,vt,e),p(W,t,e),n(t,_t,e),p(E,t,e),n(t,At,e),p(Z,t,e),n(t,Gt,e),p(X,t,e),n(t,Qt,e),p(F,t,e),n(t,St,e),p(V,t,e),n(t,Dt,e),p(q,t,e),n(t,Rt,e),n(t,k,e),n(t,zt,e),p(Y,t,e),n(t,Wt,e),n(t,L,e),n(t,Et,e),n(t,H,e),n(t,Zt,e),n(t,P,e),n(t,Xt,e),p(K,t,e),n(t,Ft,e),p(O,t,e),n(t,Vt,e),n(t,tt,e),n(t,qt,e),p(et,t,e),n(t,kt,e),n(t,st,e),n(t,Yt,e),p(nt,t,e),n(t,Lt,e),p(lt,t,e),n(t,Ht,e),p(at,t,e),n(t,Pt,e),n(t,ot,e),Kt=!0},p:Ue,i(t){Kt||(m($.$$.fragment,t),m(b.$$.fragment,t),m(g.$$.fragment,t),m(j.$$.fragment,t),m(h.$$.fragment,t),m(C.$$.fragment,t),m(N.$$.fragment,t),m(x.$$.fragment,t),m(v.$$.fragment,t),m(A.$$.fragment,t),m(G.$$.fragment,t),m(S.$$.fragment,t),m(R.$$.fragment,t),m(z.$$.fragment,t),m(W.$$.fragment,t),m(E.$$.fragment,t),m(Z.$$.fragment,t),m(X.$$.fragment,t),m(F.$$.fragment,t),m(V.$$.fragment,t),m(q.$$.fragment,t),m(Y.$$.fragment,t),m(K.$$.fragment,t),m(O.$$.fragment,t),m(et.$$.fragment,t),m(nt.$$.fragment,t),m(lt.$$.fragment,t),m(at.$$.fragment,t),Kt=!0)},o(t){r($.$$.fragment,t),r(b.$$.fragment,t),r(g.$$.fragment,t),r(j.$$.fragment,t),r(h.$$.fragment,t),r(C.$$.fragment,t),r(N.$$.fragment,t),r(x.$$.fragment,t),r(v.$$.fragment,t),r(A.$$.fragment,t),r(G.$$.fragment,t),r(S.$$.fragment,t),r(R.$$.fragment,t),r(z.$$.fragment,t),r(W.$$.fragment,t),r(E.$$.fragment,t),r(Z.$$.fragment,t),r(X.$$.fragment,t),r(F.$$.fragment,t),r(V.$$.fragment,t),r(q.$$.fragment,t),r(Y.$$.fragment,t),r(K.$$.fragment,t),r(O.$$.fragment,t),r(et.$$.fragment,t),r(nt.$$.fragment,t),r(lt.$$.fragment,t),r(at.$$.fragment,t),Kt=!1},d(t){t&&(s(pt),s(it),s(mt),s(rt),s(ut),s(w),s(Mt),s(J),s(ct),s(yt),s(T),s(dt),s(ft),s(Ut),s($t),s(I),s(bt),s(wt),s(B),s(Jt),s(gt),s(Tt),s(_),s(jt),s(ht),s(Ct),s(Q),s(It),s(Nt),s(D),s(Bt),s(xt),s(vt),s(_t),s(At),s(Gt),s(Qt),s(St),s(Dt),s(Rt),s(k),s(zt),s(Wt),s(L),s(Et),s(H),s(Zt),s(P),s(Xt),s(Ft),s(Vt),s(tt),s(qt),s(kt),s(st),s(Yt),s(Lt),s(Ht),s(Pt),s(ot)),s(U),u($,t),u(b,t),u(g,t),u(j,t),u(h,t),u(C,t),u(N,t),u(x,t),u(v,t),u(A,t),u(G,t),u(S,t),u(R,t),u(z,t),u(W,t),u(E,t),u(Z,t),u(X,t),u(F,t),u(V,t),u(q,t),u(Y,t),u(K,t),u(O,t),u(et,t),u(nt,t),u(lt,t),u(at,t)}}}const Ce='{"title":"Damiao Motors and CAN Bus","local":"damiao-motors-and-can-bus","sections":[{"title":"Linux CAN Setup","local":"linux-can-setup","sections":[{"title":"Install CAN Utilities","local":"install-can-utilities","sections":[],"depth":3},{"title":"Configure CAN Interface (Manual)","local":"configure-can-interface-manual","sections":[],"depth":3},{"title":"Configure CAN Interface (Using LeRobot)","local":"configure-can-interface-using-lerobot","sections":[],"depth":3}],"depth":2},{"title":"Debugging CAN Communication","local":"debugging-can-communication","sections":[],"depth":2},{"title":"Usage","local":"usage","sections":[{"title":"Basic Setup","local":"basic-setup","sections":[],"depth":3},{"title":"Reading Motor States","local":"reading-motor-states","sections":[],"depth":3},{"title":"Writing Motor Commands","local":"writing-motor-commands","sections":[],"depth":3}],"depth":2},{"title":"Configuration Options","local":"configuration-options","sections":[],"depth":2},{"title":"Motor Configuration","local":"motor-configuration","sections":[],"depth":2},{"title":"Troubleshooting","local":"troubleshooting","sections":[{"title":"No Response from Motors","local":"no-response-from-motors","sections":[],"depth":3},{"title":"Motor Timeout Parameter","local":"motor-timeout-parameter","sections":[],"depth":3},{"title":"Verify CAN FD Status","local":"verify-can-fd-status","sections":[],"depth":3}],"depth":2}],"depth":1}';function Ie(Ot){return $e(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ae extends be{constructor(U){super(),we(this,U,Ie,he,fe,{})}}export{Ae as component};
