openc3-cosmos-tool-docs 5.17.1 → 5.18.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (160) hide show
  1. checksums.yaml +4 -4
  2. data/tools/staticdocs/404.html +4 -4
  3. data/tools/staticdocs/assets/css/{styles.8a0f1b26.css → styles.80ddca08.css} +1 -1
  4. data/tools/staticdocs/assets/js/{019369f3.34291acc.js → 019369f3.727d87f1.js} +1 -1
  5. data/tools/staticdocs/assets/js/{058ffc22.8d9049f4.js → 058ffc22.f2d69d72.js} +1 -1
  6. data/tools/staticdocs/assets/js/{0686a885.dde7b18b.js → 0686a885.83641127.js} +1 -1
  7. data/tools/staticdocs/assets/js/078dbab0.945c9f59.js +1 -0
  8. data/tools/staticdocs/assets/js/{0f5d161c.ca02c5b2.js → 0f5d161c.e26d88b8.js} +1 -1
  9. data/tools/staticdocs/assets/js/{0ff569c9.ad025a56.js → 0ff569c9.aa4daee5.js} +1 -1
  10. data/tools/staticdocs/assets/js/{103cc3be.6b6cd0fa.js → 103cc3be.78f97eb1.js} +1 -1
  11. data/tools/staticdocs/assets/js/{13196248.9e7794e3.js → 13196248.ca2e8950.js} +1 -1
  12. data/tools/staticdocs/assets/js/{13c1b4e4.cec67b9c.js → 13c1b4e4.22a0b1d4.js} +1 -1
  13. data/tools/staticdocs/assets/js/{2047b354.bdd2586a.js → 2047b354.25d11993.js} +1 -1
  14. data/tools/staticdocs/assets/js/22b3ac48.7a5ea984.js +1 -0
  15. data/tools/staticdocs/assets/js/{2bb7bf90.043455de.js → 2bb7bf90.fa05d998.js} +1 -1
  16. data/tools/staticdocs/assets/js/3917.1ec7d126.js +1 -0
  17. data/tools/staticdocs/assets/js/{3dd7ef3b.c7c1d93f.js → 3dd7ef3b.d55880a8.js} +1 -1
  18. data/tools/staticdocs/assets/js/{40365d27.7eb3f7b1.js → 40365d27.4b4b2ccd.js} +1 -1
  19. data/tools/staticdocs/assets/js/{411898ad.d5f62a27.js → 411898ad.1d6a609d.js} +1 -1
  20. data/tools/staticdocs/assets/js/{42170351.69a8ed02.js → 42170351.c68b85e1.js} +1 -1
  21. data/tools/staticdocs/assets/js/43652efd.d1e1add3.js +1 -0
  22. data/tools/staticdocs/assets/js/53ca7c5b.c3111020.js +1 -0
  23. data/tools/staticdocs/assets/js/{54d0d530.28ba5be7.js → 54d0d530.d3f9a4ac.js} +1 -1
  24. data/tools/staticdocs/assets/js/{5b233ba7.9c621552.js → 5b233ba7.6fdd6b6c.js} +1 -1
  25. data/tools/staticdocs/assets/js/{5bc719f6.7fa17221.js → 5bc719f6.daa2a049.js} +1 -1
  26. data/tools/staticdocs/assets/js/{5c6ce5ec.5e6ca46b.js → 5c6ce5ec.61a9cae2.js} +1 -1
  27. data/tools/staticdocs/assets/js/5e3ed378.2bee863a.js +1 -0
  28. data/tools/staticdocs/assets/js/5fe211ef.a9f21277.js +1 -0
  29. data/tools/staticdocs/assets/js/6831b732.185eb427.js +1 -0
  30. data/tools/staticdocs/assets/js/{696b4199.0335bd94.js → 696b4199.a5ae3d65.js} +1 -1
  31. data/tools/staticdocs/assets/js/{6b210247.2cbd59e6.js → 6b210247.e96f3982.js} +1 -1
  32. data/tools/staticdocs/assets/js/{6b65133b.87dc7da6.js → 6b65133b.4e84b1c2.js} +1 -1
  33. data/tools/staticdocs/assets/js/6f92e431.65aa0240.js +1 -0
  34. data/tools/staticdocs/assets/js/72c6d8a8.98daa27a.js +1 -0
  35. data/tools/staticdocs/assets/js/{75e64983.932fbc0e.js → 75e64983.6ef0928b.js} +1 -1
  36. data/tools/staticdocs/assets/js/{867640d5.ffd4cf4c.js → 867640d5.48133ad5.js} +1 -1
  37. data/tools/staticdocs/assets/js/{89e76475.97389cc5.js → 89e76475.13ce283b.js} +1 -1
  38. data/tools/staticdocs/assets/js/{8f7843ee.d1ffd5ee.js → 8f7843ee.7a68246a.js} +1 -1
  39. data/tools/staticdocs/assets/js/9424f0b3.61c6bd97.js +1 -0
  40. data/tools/staticdocs/assets/js/{97535711.fc45ced1.js → 97535711.5311ddd9.js} +1 -1
  41. data/tools/staticdocs/assets/js/{99581c43.8e571df8.js → 99581c43.527aab44.js} +1 -1
  42. data/tools/staticdocs/assets/js/{9fb6059a.42881e94.js → 9fb6059a.a5107afb.js} +1 -1
  43. data/tools/staticdocs/assets/js/{a507c363.04b98d2c.js → a507c363.d2cc5d72.js} +1 -1
  44. data/tools/staticdocs/assets/js/{a677c089.b2928bac.js → a677c089.abc52ace.js} +1 -1
  45. data/tools/staticdocs/assets/js/{a9987364.8f065f19.js → a9987364.5ef1644f.js} +1 -1
  46. data/tools/staticdocs/assets/js/{aa6b6c1b.d78e5212.js → aa6b6c1b.c51c044d.js} +1 -1
  47. data/tools/staticdocs/assets/js/{b4596165.6806d46b.js → b4596165.daa24b72.js} +1 -1
  48. data/tools/staticdocs/assets/js/b6d70f94.4923c793.js +1 -0
  49. data/tools/staticdocs/assets/js/b9f60ba6.e55cd937.js +1 -0
  50. data/tools/staticdocs/assets/js/{bd0034eb.b4e3d6c1.js → bd0034eb.6691ccc4.js} +1 -1
  51. data/tools/staticdocs/assets/js/c24eae19.251e0038.js +1 -0
  52. data/tools/staticdocs/assets/js/{cb8c3f08.a0ef4b5f.js → cb8c3f08.b82ad06f.js} +1 -1
  53. data/tools/staticdocs/assets/js/cd879be4.f956406f.js +1 -0
  54. data/tools/staticdocs/assets/js/d1b923aa.d6bafb72.js +1 -0
  55. data/tools/staticdocs/assets/js/{d1bfc316.2d823a88.js → d1bfc316.0a5ff560.js} +1 -1
  56. data/tools/staticdocs/assets/js/{d24bf9b6.53eca5e8.js → d24bf9b6.6c422113.js} +1 -1
  57. data/tools/staticdocs/assets/js/{d57a4b5d.aaa48891.js → d57a4b5d.8f23a506.js} +1 -1
  58. data/tools/staticdocs/assets/js/{d5d77c37.be6fe7b6.js → d5d77c37.70fdbbc6.js} +1 -1
  59. data/tools/staticdocs/assets/js/{d8ca4191.c6632184.js → d8ca4191.2349d796.js} +1 -1
  60. data/tools/staticdocs/assets/js/{d9b92eba.c6a2c7e5.js → d9b92eba.8f82360d.js} +1 -1
  61. data/tools/staticdocs/assets/js/{db8fa1d0.f078bc02.js → db8fa1d0.8f1b2c9f.js} +1 -1
  62. data/tools/staticdocs/assets/js/{dc5f7beb.a4afe7cd.js → dc5f7beb.e3a82d1e.js} +1 -1
  63. data/tools/staticdocs/assets/js/{e501b0d1.d108a8a9.js → e501b0d1.0b407477.js} +1 -1
  64. data/tools/staticdocs/assets/js/ebec1ccb.9bea92b0.js +1 -0
  65. data/tools/staticdocs/assets/js/f15615f1.5c433923.js +1 -0
  66. data/tools/staticdocs/assets/js/{fd886806.a21dd400.js → fd886806.4a41fa80.js} +1 -1
  67. data/tools/staticdocs/assets/js/main.b5390098.js +2 -0
  68. data/tools/staticdocs/assets/js/runtime~main.12d1e41d.js +1 -0
  69. data/tools/staticdocs/docs/configuration/command.html +96 -180
  70. data/tools/staticdocs/docs/configuration/format.html +25 -54
  71. data/tools/staticdocs/docs/configuration/interfaces.html +25 -80
  72. data/tools/staticdocs/docs/configuration/plugins.html +138 -178
  73. data/tools/staticdocs/docs/configuration/protocols.html +91 -110
  74. data/tools/staticdocs/docs/configuration/ssl-tls.html +33 -104
  75. data/tools/staticdocs/docs/configuration/table.html +67 -125
  76. data/tools/staticdocs/docs/configuration/target.html +23 -31
  77. data/tools/staticdocs/docs/configuration/telemetry-screens.html +194 -455
  78. data/tools/staticdocs/docs/configuration/telemetry.html +104 -187
  79. data/tools/staticdocs/docs/configuration.html +4 -4
  80. data/tools/staticdocs/docs/development/curl.html +17 -126
  81. data/tools/staticdocs/docs/development/developing.html +29 -80
  82. data/tools/staticdocs/docs/development/host-install.html +10 -23
  83. data/tools/staticdocs/docs/development/json-api.html +20 -32
  84. data/tools/staticdocs/docs/development/log-structure.html +14 -14
  85. data/tools/staticdocs/docs/development/roadmap.html +15 -15
  86. data/tools/staticdocs/docs/development/streaming-api.html +11 -83
  87. data/tools/staticdocs/docs/development/testing.html +17 -26
  88. data/tools/staticdocs/docs/development.html +4 -4
  89. data/tools/staticdocs/docs/getting-started/generators.html +35 -109
  90. data/tools/staticdocs/docs/getting-started/gettingstarted.html +26 -74
  91. data/tools/staticdocs/docs/getting-started/installation.html +24 -35
  92. data/tools/staticdocs/docs/getting-started/key_concepts.html +35 -35
  93. data/tools/staticdocs/docs/getting-started/podman.html +26 -57
  94. data/tools/staticdocs/docs/getting-started/requirements.html +21 -21
  95. data/tools/staticdocs/docs/getting-started/upgrading.html +12 -17
  96. data/tools/staticdocs/docs/getting-started.html +4 -4
  97. data/tools/staticdocs/docs/guides/bridges.html +19 -63
  98. data/tools/staticdocs/docs/guides/cfs.html +44 -184
  99. data/tools/staticdocs/docs/guides/custom-widgets.html +20 -47
  100. data/tools/staticdocs/docs/guides/little-endian-bitfields.html +5 -14
  101. data/tools/staticdocs/docs/guides/local-mode.html +16 -21
  102. data/tools/staticdocs/docs/guides/logging.html +12 -12
  103. data/tools/staticdocs/docs/guides/monitoring.html +22 -137
  104. data/tools/staticdocs/docs/guides/performance.html +18 -27
  105. data/tools/staticdocs/docs/guides/raspberrypi.html +10 -23
  106. data/tools/staticdocs/docs/guides/script-writing.html +85 -391
  107. data/tools/staticdocs/docs/guides/scripting-api.html +482 -1353
  108. data/tools/staticdocs/docs/guides.html +4 -4
  109. data/tools/staticdocs/docs/meta/contributing.html +14 -19
  110. data/tools/staticdocs/docs/meta/licenses.html +13 -31
  111. data/tools/staticdocs/docs/meta/philosophy.html +4 -4
  112. data/tools/staticdocs/docs/meta/xtce.html +15 -17
  113. data/tools/staticdocs/docs/meta.html +4 -4
  114. data/tools/staticdocs/docs/privacy.html +20 -20
  115. data/tools/staticdocs/docs/tools/autonomic.html +22 -22
  116. data/tools/staticdocs/docs/tools/bucket-explorer.html +13 -13
  117. data/tools/staticdocs/docs/tools/calendar.html +21 -21
  118. data/tools/staticdocs/docs/tools/cmd-sender.html +16 -16
  119. data/tools/staticdocs/docs/tools/cmd-tlm-server.html +23 -23
  120. data/tools/staticdocs/docs/tools/data-extractor.html +27 -27
  121. data/tools/staticdocs/docs/tools/data-viewer.html +13 -13
  122. data/tools/staticdocs/docs/tools/handbooks.html +7 -7
  123. data/tools/staticdocs/docs/tools/limits-monitor.html +19 -19
  124. data/tools/staticdocs/docs/tools/packet-viewer.html +16 -16
  125. data/tools/staticdocs/docs/tools/script-runner.html +36 -75
  126. data/tools/staticdocs/docs/tools/table-manager.html +13 -48
  127. data/tools/staticdocs/docs/tools/tlm-grapher.html +23 -23
  128. data/tools/staticdocs/docs/tools/tlm-viewer.html +18 -18
  129. data/tools/staticdocs/docs/tools.html +4 -4
  130. data/tools/staticdocs/docs.html +14 -14
  131. data/tools/staticdocs/index.html +4 -4
  132. data/tools/staticdocs/lunr-index-1724101625047.json +1 -0
  133. data/tools/staticdocs/lunr-index.json +1 -1
  134. data/tools/staticdocs/markdown-page.html +5 -5
  135. data/tools/staticdocs/search-doc-1724101625047.json +1 -0
  136. data/tools/staticdocs/search-doc.json +1 -1
  137. metadata +71 -71
  138. data/tools/staticdocs/assets/js/078dbab0.b275e04c.js +0 -1
  139. data/tools/staticdocs/assets/js/22b3ac48.0f4fbe9d.js +0 -1
  140. data/tools/staticdocs/assets/js/43652efd.be2c1d02.js +0 -1
  141. data/tools/staticdocs/assets/js/4650.292aca67.js +0 -1
  142. data/tools/staticdocs/assets/js/53ca7c5b.3f1245d5.js +0 -1
  143. data/tools/staticdocs/assets/js/5e3ed378.77db7b87.js +0 -1
  144. data/tools/staticdocs/assets/js/5fe211ef.71dc8326.js +0 -1
  145. data/tools/staticdocs/assets/js/6831b732.5714d508.js +0 -1
  146. data/tools/staticdocs/assets/js/6f92e431.300a9857.js +0 -1
  147. data/tools/staticdocs/assets/js/72c6d8a8.cfccace6.js +0 -1
  148. data/tools/staticdocs/assets/js/9424f0b3.29299bde.js +0 -1
  149. data/tools/staticdocs/assets/js/b6d70f94.f5514e8b.js +0 -1
  150. data/tools/staticdocs/assets/js/b9f60ba6.c3b3046d.js +0 -1
  151. data/tools/staticdocs/assets/js/c24eae19.6b084c7c.js +0 -1
  152. data/tools/staticdocs/assets/js/cd879be4.6f19050a.js +0 -1
  153. data/tools/staticdocs/assets/js/d1b923aa.3f3e186d.js +0 -1
  154. data/tools/staticdocs/assets/js/ebec1ccb.1ded1149.js +0 -1
  155. data/tools/staticdocs/assets/js/f15615f1.f9b655a6.js +0 -1
  156. data/tools/staticdocs/assets/js/main.c2e2b617.js +0 -2
  157. data/tools/staticdocs/assets/js/runtime~main.2bb31799.js +0 -1
  158. data/tools/staticdocs/lunr-index-1719505302032.json +0 -1
  159. data/tools/staticdocs/search-doc-1719505302032.json +0 -1
  160. /data/tools/staticdocs/assets/js/{main.c2e2b617.js.LICENSE.txt → main.b5390098.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkdocs_openc3_com=self.webpackChunkdocs_openc3_com||[]).push([[2577],{1117:(e,n,o)=>{o.r(n),o.d(n,{assets:()=>l,contentTitle:()=>c,default:()=>p,frontMatter:()=>i,metadata:()=>r,toc:()=>a});var s=o(1085),t=o(1184);const i={title:"Developing COSMOS"},c="Developing COSMOS",r={id:"development/developing",title:"Developing COSMOS",description:"So you want to help develop COSMOS? All of our open source COSMOS code is on Github so the first thing to do is get an account. Next clone the COSMOS repository. We accept contributions from others as Pull Requests.",source:"@site/docs/development/developing.md",sourceDirName:"development",slug:"/development/developing",permalink:"/tools/staticdocs/docs/development/developing",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenC3/cosmos/tree/main/docs.openc3.com/docs/development/developing.md",tags:[],version:"current",frontMatter:{title:"Developing COSMOS"},sidebar:"defaultSidebar",previous:{title:"Testing with Curl",permalink:"/tools/staticdocs/docs/development/curl"},next:{title:"Host Install",permalink:"/tools/staticdocs/docs/development/host-install"}},l={},a=[{value:"Development Tools",id:"development-tools",level:2},{value:"Running a Frontend Application",id:"running-a-frontend-application",level:2},{value:"Running a Backend Server",id:"running-a-backend-server",level:2}];function d(e){const n={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",li:"li",ol:"ol",p:"p",pre:"pre",...(0,t.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.h1,{id:"developing-cosmos",children:"Developing COSMOS"}),"\n",(0,s.jsxs)(n.p,{children:["So you want to help develop COSMOS? All of our open source COSMOS code is on ",(0,s.jsx)(n.a,{href:"https://github.com/",children:"Github"})," so the first thing to do is get an ",(0,s.jsx)(n.a,{href:"https://github.com/join",children:"account"}),". Next ",(0,s.jsx)(n.a,{href:"https://docs.github.com/en/repositories/creating-and-managing-repositories/cloning-a-repository",children:"clone"})," the ",(0,s.jsx)(n.a,{href:"https://github.com/openc3/cosmos",children:"COSMOS"})," repository. We accept contributions from others as ",(0,s.jsx)(n.a,{href:"https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-pull-requests",children:"Pull Requests"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"development-tools",children:"Development Tools"}),"\n",(0,s.jsxs)(n.p,{children:["The core COSMOS team develops with the ",(0,s.jsx)(n.a,{href:"https://code.visualstudio.com/",children:"Visual Studio Code"})," editor and we highly recommend it. We also utilize a number of extensions including docker, kubernetes, gitlens, prettier, eslint, python, vetur, and ruby. We commit our ",(0,s.jsx)(n.code,{children:"openc3.code-workspace"})," configuration for VSCode to help configure these plugins. You also need ",(0,s.jsx)(n.a,{href:"https://www.docker.com/products/docker-desktop",children:"Docker Desktop"})," which you should already have as it is a requirement to run COSMOS. You'll also need ",(0,s.jsx)(n.a,{href:"https://nodejs.org/en/download/",children:"NodeJS"})," and ",(0,s.jsx)(n.a,{href:"https://yarnpkg.com/getting-started/install",children:"yarn"})," installed."]}),"\n",(0,s.jsx)(n.h1,{id:"building-cosmos",children:"Building COSMOS"}),"\n",(0,s.jsx)(n.p,{children:"Note: We primarily develop COSMOS in MacOS so the commands here will reference bash scripts but the same files exist in Windows as batch scripts."}),"\n",(0,s.jsxs)(n.p,{children:["Build COSMOS using the ",(0,s.jsx)(n.code,{children:"openc3.sh"})," script:"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"% ./openc3.sh build\n"})}),"\n",(0,s.jsx)(n.p,{children:"This will pull all the COSMOS container dependencies and build our local containers. Note: This can take a long time especially for your first build!"}),"\n",(0,s.jsx)(n.p,{children:"Once the build completes you can see the built images with the following command:"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'% docker image ls | grep "openc3"\nopenc3inc/openc3-cosmos-init latest 4cac7a3ea9d3 29 hours ago 446MB\nopenc3inc/openc3-cosmos-script-runner-api latest 4aacbaf49f7a 29 hours ago 431MB\nopenc3inc/openc3-cosmos-cmd-tlm-api latest 9a8806bd4be3 3 days ago 432MB\nopenc3inc/openc3-operator latest 223e98129fe9 3 days ago 405MB\nopenc3inc/openc3-base latest 98df5c0378c2 3 days ago 405MB\nopenc3inc/openc3-redis latest 5a3003a49199 8 days ago 111MB\nopenc3inc/openc3-traefik latest ec13a8d16a2f 8 days ago 104MB\nopenc3inc/openc3-minio latest 787f6e3fc0be 8 days ago 238MB\nopenc3inc/openc3-node latest b3ee86d3620a 8 days ago 372MB\nopenc3inc/openc3-ruby latest aa158bbb9539 8 days ago 326MB\n'})}),"\n",(0,s.jsxs)(n.admonition,{title:"Offline Building",type:"info",children:[(0,s.jsxs)(n.p,{children:["If you're building in a offline environment or want to use a private Rubygems, NPM or APK server (e.g. Nexus), you can update the following environment variables: RUBYGEMS_URL, NPM_URL, APK_URL, and more in the ",(0,s.jsx)(n.a,{href:"https://github.com/openc3/cosmos/blob/main/.env",children:".env"})," file. Example values:"]}),(0,s.jsxs)(n.p,{children:["ALPINE_VERSION=3.18",(0,s.jsx)("br",{}),"\nALPINE_BUILD=6",(0,s.jsx)("br",{}),"\nRUBYGEMS_URL=",(0,s.jsx)(n.a,{href:"https://rubygems.org",children:"https://rubygems.org"}),(0,s.jsx)("br",{}),"\nNPM_URL=",(0,s.jsx)(n.a,{href:"https://registry.npmjs.org",children:"https://registry.npmjs.org"}),(0,s.jsx)("br",{}),"\nAPK_URL=",(0,s.jsx)(n.a,{href:"http://dl-cdn.alpinelinux.org",children:"http://dl-cdn.alpinelinux.org"}),(0,s.jsx)("br",{})]})]}),"\n",(0,s.jsx)(n.h1,{id:"running-cosmos",children:"Running COSMOS"}),"\n",(0,s.jsxs)(n.p,{children:["Running COSMOS in development mode enables localhost access to internal API ports as well as sets ",(0,s.jsx)(n.code,{children:"RAILS_ENV=development"})," in the cmd-tlm-api and script-runner-api Rails servers. To run in development mode:"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"% ./openc3.sh dev\n"})}),"\n",(0,s.jsx)(n.p,{children:"You can now see the running containers (I removed CONTAINER ID, CREATED and STATUS to save space):"}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:'% docker ps\nIMAGE COMMAND PORTS NAMES\nopenc3/openc3-cmd-tlm-api:latest "/sbin/tini -- rails\u2026" 127.0.0.1:2901->2901/tcp cosmos-openc3-cmd-tlm-api-1\nopenc3/openc3-script-runner-api:latest "/sbin/tini -- rails\u2026" 127.0.0.1:2902->2902/tcp cosmos-openc3-script-runner-api-1\nopenc3/openc3-traefik:latest "/entrypoint.sh trae\u2026" 0.0.0.0:2900->80/tcp cosmos-openc3-traefik-1\nopenc3/openc3-operator:latest "/sbin/tini -- ruby \u2026" cosmos-openc3-operator-1\nopenc3/openc3-minio:latest "/usr/bin/docker-ent\u2026" 127.0.0.1:9000->9000/tcp cosmos-openc3-minio-1\nopenc3/openc3-redis:latest "docker-entrypoint.s\u2026" 127.0.0.1:6379->6379/tcp cosmos-openc3-redis-1\n'})}),"\n",(0,s.jsx)(n.p,{children:"If you go to localhost:2900 you should see COSMOS up and running!"}),"\n",(0,s.jsx)(n.h2,{id:"running-a-frontend-application",children:"Running a Frontend Application"}),"\n",(0,s.jsx)(n.p,{children:"So now that you have COSMOS up and running how do you develop an individual COSMOS application?"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsx)(n.li,{children:"Bootstrap the frontend with yarn"}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"openc3-init % yarn\n"})}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsx)(n.li,{children:"Serve a local COSMOS application (CmdTlmServer, ScriptRunner, etc)"}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"openc3-init % cd plugins/packages/openc3-tool-scriptrunner\nopenc3-tool-scriptrunner % yarn serve\n\nDONE Compiled successfully in 128722ms\nApp running at:\n- Local: http://localhost:2914/tools/scriptrunner/\n- Network: http://localhost:2914/tools/scriptrunner/\n\nNote that the development build is not optimized.\nTo create a production build, run npm run build.\n"})}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Set the ",(0,s.jsx)(n.a,{href:"https://single-spa.js.org/",children:"single SPA"})," override for the application"]}),"\n",(0,s.jsxs)(n.p,{children:["Visit localhost:2900 and Right-click 'Inspect'",(0,s.jsx)("br",{}),"\nIn the console paste:"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-javascript",children:'localStorage.setItem("devtools", true);\n'})}),"\n",(0,s.jsxs)(n.p,{children:["Refresh and you should see ",(0,s.jsx)(n.code,{children:"{...}"})," in the bottom right",(0,s.jsx)("br",{}),"\nClick the Default button next to the application (@openc3/tool-scriptrunner)",(0,s.jsx)("br",{}),"\nPaste in the development path which is dependent on the port returned by the local yarn serve and the tool name (scriptrunner)"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"http://localhost:2914/tools/scriptrunner/js/app.js",children:"http://localhost:2914/tools/scriptrunner/js/app.js"})}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["Refresh the page and you should see your local copy of the application (Script Runner in this example). If you dynamically add code (like ",(0,s.jsx)(n.code,{children:"console.log"}),") the yarn window should re-compile and the browser should refresh displaying your new code. It is highly recommended to get familiar with your browser's ",(0,s.jsx)(n.a,{href:"https://developer.chrome.com/docs/devtools/overview/",children:"development tools"})," if you plan to do frontend development."]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"running-a-backend-server",children:"Running a Backend Server"}),"\n",(0,s.jsx)(n.p,{children:"If the code you want to develop is the cmd-tlm-api or script-runner-api backend servers there are several steps to enable access to a development copy."}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsx)(n.li,{children:"Run a development version of traefik. COSMOS uses traefik to direct API requests to the correct locations."}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"% cd openc3-traefik\nopenc3-traefik % docker ps\n# Look for the container with name including traefik\nopenc3-traefik % docker stop cosmos-openc3-traefik-1\nopenc3-traefik % docker build --build-arg TRAEFIK_CONFIG=traefik-dev.yaml -t openc3-traefik-dev .\nopenc3-traefik % docker run --network=openc3-cosmos-network -p 2900:2900 -it --rm openc3-traefik-dev\n"})}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsx)(n.li,{children:"Run a local copy of the cmd-tlm-api or script-runner-api"}),"\n"]}),"\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-bash",children:"% cd openc3-cosmos-cmd-tlm-api\nopenc3-cosmos-cmd-tlm-api % docker ps\n# Look for the container with name including cmd-tlm-api\nopenc3-cosmos-cmd-tlm-api % docker stop cosmos-openc3-cosmos-cmd-tlm-api-1\n# Run the following on Windows:\nopenc3-cosmos-cmd-tlm-api> dev_server.bat\n# In Linux, set all the environment variables in the .env file, but override REDIS to be local\nopenc3-cosmos-cmd-tlm-api % set -a; source ../.env; set +a\nopenc3-cosmos-cmd-tlm-api % export OPENC3_REDIS_HOSTNAME=127.0.0.1\nopenc3-cosmos-cmd-tlm-api % export OPENC3_REDIS_EPHEMERAL_HOSTNAME=127.0.0.1\nopenc3-cosmos-cmd-tlm-api % bundle install\nopenc3-cosmos-cmd-tlm-api % bundle exec rails s\n"})}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["Once the ",(0,s.jsx)(n.code,{children:"bundle exec rails s"})," command returns you should see API requests coming from interations in the frontend code. If you add code (like Ruby debugging statements) to the cmd-tlm-api code you need to stop the server (CTRL-C) and restart it to see the effect."]}),"\n"]})]})}function p(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(d,{...e})}):d(e)}},1184:(e,n,o)=>{o.d(n,{R:()=>c});var s=o(4041);const t={},i=s.createContext(t);function c(e){const n=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkdocs_openc3_com=self.webpackChunkdocs_openc3_com||[]).push([[407],{2279:(t,o,e)=>{e.r(o),e.d(o,{assets:()=>r,contentTitle:()=>i,default:()=>h,frontMatter:()=>a,metadata:()=>c,toc:()=>d});var s=e(1085),n=e(1184);const a={title:"Handbooks"},i=void 0,c={id:"tools/handbooks",title:"Handbooks",description:"Introduction",source:"@site/docs/tools/handbooks.md",sourceDirName:"tools",slug:"/tools/handbooks",permalink:"/tools/staticdocs/docs/tools/handbooks",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenC3/cosmos/tree/main/docs.openc3.com/docs/tools/handbooks.md",tags:[],version:"current",frontMatter:{title:"Handbooks"},sidebar:"defaultSidebar",previous:{title:"Data Viewer",permalink:"/tools/staticdocs/docs/tools/data-viewer"},next:{title:"Limits Monitor",permalink:"/tools/staticdocs/docs/tools/limits-monitor"}},r={},d=[{value:"Introduction",id:"introduction",level:2}];function l(t){const o={a:"a",h2:"h2",img:"img",p:"p",...(0,n.R)(),...t.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(o.h2,{id:"introduction",children:"Introduction"}),"\n",(0,s.jsxs)(o.p,{children:["Handbooks formats the COSMOS ",(0,s.jsx)(o.a,{href:"/tools/staticdocs/docs/configuration/command",children:"command"})," and ",(0,s.jsx)(o.a,{href:"/tools/staticdocs/docs/configuration/telemetry",children:"telemetry"})," definitions into a nicely formatted webpage that can be exported to a PDF."]}),"\n",(0,s.jsx)(o.p,{children:(0,s.jsx)(o.img,{alt:"Handbooks",src:e(1226).A+"",width:"1270",height:"710"})}),"\n",(0,s.jsx)(o.p,{children:"You can select the targets you want to display and the number of columns to display on the page. You can then use the browser to Print the page. Most browsers have the capability to Save as PDF rather than print to save the resulting page as PDF."})]})}function h(t={}){const{wrapper:o}={...(0,n.R)(),...t.components};return o?(0,s.jsx)(o,{...t,children:(0,s.jsx)(l,{...t})}):l(t)}},1226:(t,o,e)=>{e.d(o,{A:()=>s});const s=e.p+"assets/images/handbooks-948da6f5aad7a4175441235f2aac82668f9233c60412e412439b2e2af0bd1a45.png"},1184:(t,o,e)=>{e.d(o,{R:()=>i});var s=e(4041);const n={},a=s.createContext(n);function i(t){const o=s.useContext(a);return s.useMemo((function(){return"function"==typeof t?t(o):{...o,...t}}),[o,t])}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkdocs_openc3_com=self.webpackChunkdocs_openc3_com||[]).push([[3718],{3236:(e,t,s)=>{s.r(t),s.d(t,{assets:()=>d,contentTitle:()=>l,default:()=>a,frontMatter:()=>r,metadata:()=>o,toc:()=>c});var n=s(1085),i=s(1184);const r={title:"Performance"},l="COSMOS Hardware Requirements",o={id:"guides/performance",title:"Performance",description:"The COSMOS architecture was created with scalability in mind. Our goal is to support an unlimited number of connections and use cloud technologies to scale. Only COSMOS Enterprise Edition supports Kubernetes and the various cloud platforms which allow this level of scalability. While true scalability is only achieved in COSMOS Enterprise, both Open Source and Enterprise have various levels of observability and configuration settings which can affect performance.",source:"@site/docs/guides/performance.md",sourceDirName:"guides",slug:"/guides/performance",permalink:"/tools/staticdocs/docs/guides/performance",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenC3/cosmos/tree/main/docs.openc3.com/docs/guides/performance.md",tags:[],version:"current",frontMatter:{title:"Performance"},sidebar:"defaultSidebar",previous:{title:"Monitoring",permalink:"/tools/staticdocs/docs/guides/monitoring"},next:{title:"Raspberry Pi",permalink:"/tools/staticdocs/docs/guides/raspberrypi"}},d={},c=[{value:"Memory",id:"memory",level:2},{value:"CPU",id:"cpu",level:2},{value:"Performance Comparison",id:"performance-comparison",level:2}];function h(e){const t={a:"a",code:"code",h1:"h1",h2:"h2",li:"li",ol:"ol",p:"p",pre:"pre",section:"section",sup:"sup",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,i.R)(),...e.components};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(t.p,{children:["The COSMOS architecture was created with scalability in mind. Our goal is to support an unlimited number of connections and use cloud technologies to scale. Only ",(0,n.jsx)(t.a,{href:"https://openc3.com/enterprise",children:"COSMOS Enterprise Edition"})," supports Kubernetes and the various cloud platforms which allow this level of scalability. While true scalability is only achieved in COSMOS Enterprise, both Open Source and Enterprise have various levels of observability and configuration settings which can affect performance."]}),"\n",(0,n.jsx)(t.h1,{id:"cosmos-hardware-requirements",children:"COSMOS Hardware Requirements"}),"\n",(0,n.jsx)(t.h2,{id:"memory",children:"Memory"}),"\n",(0,n.jsx)(t.p,{children:"COSMOS can run on a Raspberry Pi up to a Kubernetes cluster in the cloud. On all platforms the key performance factor is the number and complexity of the targets and their defined packets. Targets can vary from simple targets taking 100 MB of RAM to complex targets taking 400 MB. The base COSMOS containers require about 800 MB of RAM. A good rule of thumb is to average about 300 MB of RAM for targets. As an example data point, the COSMOS Demo has 4 targets, two complex (INST & INST2) and two relatively simple (EXAMPLE & TEMPLATED), and requires 800 MB of RAM (on top of the 800 MB of base container RAM)."}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsx)(t.li,{children:"Base RAM MB Calculator = 800 + (num targets) * 300"}),"\n"]}),"\n",(0,n.jsxs)(t.p,{children:["In addition, the Redis streams contain the last 10 min of both raw and decommutated data from all targets. Thus you must wait ~15min to truly see what the high water memory mark will be. In the COSMOS Demo the INST & INST2 targets are fairly simple with four 1Hz packet of ~15 items and one 10Hz packet with 20 items. This only causes 50 MiB of redis RAM usage according to ",(0,n.jsx)(t.code,{children:"docker stats"}),". Installing the COSMOS ",(0,n.jsx)(t.a,{href:"https://github.com/OpenC3/openc3-cosmos-load-sim",children:"LoadSim"})," with 10 packets with 1000 items each at 10Hz pushed the redis memory usage to about 350 MiB."]}),"\n",(0,n.jsx)(t.h2,{id:"cpu",children:"CPU"}),"\n",(0,n.jsx)(t.p,{children:"Another consideration is the CPU performance. In the Open Source Edition, by default COSMOS spawns off 2 microservices per target. One combines packet logging and decommutation of the data and the other performs data reduction. In COSMOS Enterprise Edition on Kubernetes, each process becomes an independent container that is deployed on the cluster allowing horizontal scaling."}),"\n",(0,n.jsxs)(t.p,{children:["The COSMOS command and telemetry API and script running API servers should have a dedicated core while targets can generally share cores. It's hard to provide a general rule of thumb with the wide variety of architectures, clock speeds, and core counts. The best practice is to install COSMOS with the expected load and do some monitoring with ",(0,n.jsx)(t.code,{children:"htop"})," to visualize the load on the various cores. Any time a single core gets overloaded (100%) this is a concern and system slowdown can occur."]}),"\n",(0,n.jsx)(t.h2,{id:"performance-comparison",children:"Performance Comparison"}),"\n",(0,n.jsxs)(t.p,{children:["Performance characterization was performed in Azure on a Standard D4s v5 (4 vcpus, 16 GiB memory) chosen to allow virtualization per ",(0,n.jsx)(t.a,{href:"https://docs.docker.com/desktop/vm-vdi/#turn-on-nested-virtualization-on-microsoft-hyper-v",children:"Docker"}),". COSMOS ",(0,n.jsx)(t.a,{href:"https://github.com/OpenC3/cosmos-enterprise/releases/tag/v5.9.1",children:"5.9.1"})," Enterprise Edition was installed on both Windows 11 Pro ",(0,n.jsx)(t.sup,{children:(0,n.jsx)(t.a,{href:"#user-content-fn-1",id:"user-content-fnref-1","data-footnote-ref":!0,"aria-describedby":"footnote-label",children:"1"})})," and Ubuntu 22. Note: Enterprise Edition was not utilizing Kubernetes, just Docker. Testing involved starting the COSMOS Demo, connecting all targets (EXAMPLE, INST, INST2, TEMPLATED), opening the following TlmViewer screens (ADCS, ARRAY, BLOCK, COMMANDING, HS, LATEST, LIMITS, OTHER, PARAMS, SIMPLE, TABS) and creating two TlmGrapher graphs consisting of INST HEALTH_STATUS TEMP[1-4] and INST ADCS POS[X,Y,Z] and INST ADCS VEL[X,Y,Z]. This was allowed to run for 1hr and results were collected using ",(0,n.jsx)(t.code,{children:"htop"}),":"]}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Platform"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Core CPU %"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"RAM"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Windows 11 Pro"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"12% 12% 10% 10%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"3.9G / 7.7G"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Headless Ubuntu 22"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"7% 7% 8% 6%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"3.2G / 15.6G"})]})]})]}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsxs)(t.li,{children:["Windows was only allocated 8 GB of RAM due to the ",(0,n.jsx)(t.a,{href:"https://learn.microsoft.com/en-us/windows/wsl/wsl-config#configuration-setting-for-wslconfig",children:".wslconfig"})," settings."]}),"\n",(0,n.jsx)(t.li,{children:"Since Ubuntu was running headless, the screens and graphs were brought up on another machine."}),"\n"]}),"\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.code,{children:"docker stats"})," was also run to show individual container cpu and memory usage:"]}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"NAME"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Windows CPU %"}),(0,n.jsx)(t.th,{children:"Ubuntu CPU %"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Windows MEM"}),(0,n.jsx)(t.th,{children:"Ubuntu MEM"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-traefik-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"4.16%"}),(0,n.jsx)(t.td,{children:"1.32%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"43.54MiB"}),(0,n.jsx)(t.td,{children:"51.38MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-cosmos-cmd-tlm-api-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"10.16%"}),(0,n.jsx)(t.td,{children:"6.14%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"401.6MiB"}),(0,n.jsx)(t.td,{children:"392MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-keycloak-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.17%"}),(0,n.jsx)(t.td,{children:"0.13%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"476.8MiB"}),(0,n.jsx)(t.td,{children:"476.8MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-operator-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"21.27%"}),(0,n.jsx)(t.td,{children:"13.91%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"1.214GiB"}),(0,n.jsx)(t.td,{children:"1.207GiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-cosmos-script-runner-api-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.01%"}),(0,n.jsx)(t.td,{children:"0.01%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"127.4MiB"}),(0,n.jsx)(t.td,{children:"117.1MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-metrics-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.01%"}),(0,n.jsx)(t.td,{children:"0.00%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"105.2MiB"}),(0,n.jsx)(t.td,{children:"83.87MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-redis-ephemeral-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"4.05%"}),(0,n.jsx)(t.td,{children:"1.89%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"46.22MiB"}),(0,n.jsx)(t.td,{children:"69.84MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-redis-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"1.56%"}),(0,n.jsx)(t.td,{children:"0.72%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"12.82MiB"}),(0,n.jsx)(t.td,{children:"9.484MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-minio-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.01%"}),(0,n.jsx)(t.td,{children:"0.00%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"152.9MiB"}),(0,n.jsx)(t.td,{children:"169.8MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-postgresql-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.00%"}),(0,n.jsx)(t.td,{children:"0.39%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"37.33MiB"}),(0,n.jsx)(t.td,{children:"41.02MiB"})]})]})]}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsx)(t.li,{children:"memory profiles are similar between the two platforms"}),"\n",(0,n.jsx)(t.li,{children:"redis-ephemeral isn't using much memory on the base Demo with its small packets"}),"\n"]}),"\n",(0,n.jsxs)(t.p,{children:["At this point the COSMOS ",(0,n.jsx)(t.a,{href:"https://github.com/OpenC3/openc3-cosmos-load-sim",children:"LoadSim"})," was installed with default settings which creates 10 packets with 1000 items each at 10Hz (110kB/s). After a 1 hr soak, htop now indicated:"]}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Platform"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Core CPU %"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"RAM"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Windows 11 Pro"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"40% 35% 39% 42%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"4.64G / 7.7G"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"Headless Ubuntu 22"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"17% 20% 16% 18%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"3.74G / 15.6G"})]})]})]}),"\n",(0,n.jsx)(t.p,{children:"The larger packets and data rate of the LoadSim target caused both platforms to dramatically increase CPU utilization but the Linux machine stays quite performant."}),"\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.code,{children:"docker stats"})," was also run to show individual container cpu and memory usage:"]}),"\n",(0,n.jsxs)(t.table,{children:[(0,n.jsx)(t.thead,{children:(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"NAME"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Windows CPU %"}),(0,n.jsx)(t.th,{children:"Ubuntu CPU %"}),(0,n.jsx)(t.th,{style:{textAlign:"left"},children:"Windows MEM"}),(0,n.jsx)(t.th,{children:"Ubuntu MEM"})]})}),(0,n.jsxs)(t.tbody,{children:[(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-traefik-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"4.09%"}),(0,n.jsx)(t.td,{children:"0.01%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"44.3MiB"}),(0,n.jsx)(t.td,{children:"0.34MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-cosmos-cmd-tlm-api-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"17.78%"}),(0,n.jsx)(t.td,{children:"6.18%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"407.9MiB"}),(0,n.jsx)(t.td,{children:"405.8MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-keycloak-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.20%"}),(0,n.jsx)(t.td,{children:"0.12%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"480.2MiB"}),(0,n.jsx)(t.td,{children:"481.5MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-operator-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"221.15%"}),(0,n.jsx)(t.td,{children:"66.72%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"1.6GiB"}),(0,n.jsx)(t.td,{children:"1.512GiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-cosmos-script-runner-api-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.01%"}),(0,n.jsx)(t.td,{children:"0.01%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"136.6MiB"}),(0,n.jsx)(t.td,{children:"127.5MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-metrics-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.01%"}),(0,n.jsx)(t.td,{children:"0.01%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"106.3MiB"}),(0,n.jsx)(t.td,{children:"84.87MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-redis-ephemeral-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"19.63%"}),(0,n.jsx)(t.td,{children:"3.91%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"333.8MiB"}),(0,n.jsx)(t.td,{children:"370.8MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-redis-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"7.42%"}),(0,n.jsx)(t.td,{children:"1.49%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"15.87MiB"}),(0,n.jsx)(t.td,{children:"11.81MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-minio-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.10%"}),(0,n.jsx)(t.td,{children:"0.02%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"167.8MiB"}),(0,n.jsx)(t.td,{children:"179.2MiB"})]}),(0,n.jsxs)(t.tr,{children:[(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"cosmos-enterprise-project-openc3-postgresql-1"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"0.00%"}),(0,n.jsx)(t.td,{children:"0.00%"}),(0,n.jsx)(t.td,{style:{textAlign:"left"},children:"35.4MiB"}),(0,n.jsx)(t.td,{children:"42.93MiB"})]})]})]}),"\n",(0,n.jsxs)(t.ul,{children:["\n",(0,n.jsx)(t.li,{children:"memory profiles are similar between the two platforms"}),"\n",(0,n.jsx)(t.li,{children:"redis-ephemeral is now using much more RAM as it is storing the large LoadSim packets"}),"\n",(0,n.jsx)(t.li,{children:"Windows is using much more CPU power running the operator, cmd-tlm, and redis"}),"\n"]}),"\n",(0,n.jsx)(t.h1,{id:"conclusions",children:"Conclusions"}),"\n",(0,n.jsxs)(t.p,{children:["While it is easy to run COSMOS on any Docker platform, increasing the number and complexity of the targets requires choosing the correct hardware. Sizing can be approximated but the best solution is to install representative targets and use ",(0,n.jsx)(t.code,{children:"docker stats"})," and ",(0,n.jsx)(t.code,{children:"htop"})," to judge the CPU and memory pressure on the given hardware."]}),"\n",(0,n.jsxs)(t.p,{children:[(0,n.jsx)(t.a,{href:"https://openc3.com/enterprise",children:"COSMOS Enterprise Edition"})," on Kubernetes helps to eliminate the hardware sizing issue by scaling the cluster to meet the needs of the system. Check out ",(0,n.jsx)(t.a,{href:"https://openc3.com/news/scaling",children:"this recent talk"})," Ryan gave at GSAW showing how we scaled to over 160 satellites on a 4 node kubernetes cluster on EKS."]}),"\n",(0,n.jsx)("hr",{}),"\n","\n",(0,n.jsxs)(t.section,{"data-footnotes":!0,className:"footnotes",children:[(0,n.jsx)(t.h2,{className:"sr-only",id:"footnote-label",children:"Footnotes"}),"\n",(0,n.jsxs)(t.ol,{children:["\n",(0,n.jsxs)(t.li,{id:"user-content-fn-1",children:["\n",(0,n.jsx)(t.p,{children:"Full specs of the Windows Platform:"}),"\n",(0,n.jsx)(t.pre,{children:(0,n.jsx)(t.code,{children:"Windows 11 Pro\nDocker Desktop 4.22.0\nWSL version: 1.2.5.0\nKernel version: 5.15.90.1\nWSLg version: 1.0.51\nMSRDC version: 1.2.3770\nDirect3D version: 1.608.2-61064218\nDXCore version: 10.0.25131.1002-220531-1700.rs-onecore-base2-hyp\nWindows version: 10.0.22621.2134\n"})}),"\n",(0,n.jsx)(t.a,{href:"#user-content-fnref-1","data-footnote-backref":"","aria-label":"Back to reference 1",className:"data-footnote-backref",children:"\u21a9"}),"\n"]}),"\n"]}),"\n"]})]})}function a(e={}){const{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,n.jsx)(t,{...e,children:(0,n.jsx)(h,{...e})}):h(e)}},1184:(e,t,s)=>{s.d(t,{R:()=>l});var n=s(4041);const i={},r=n.createContext(i);function l(e){const t=n.useContext(r);return n.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkdocs_openc3_com=self.webpackChunkdocs_openc3_com||[]).push([[6417],{2420:(e,s,t)=>{t.r(s),t.d(s,{assets:()=>c,contentTitle:()=>i,default:()=>h,frontMatter:()=>r,metadata:()=>a,toc:()=>d});var n=t(1085),o=t(1184);const r={sidebar_position:5,title:"Key Concepts"},i="OpenC3 COSMOS Key Concepts",a={id:"getting-started/key_concepts",title:"Key Concepts",description:"Projects",source:"@site/docs/getting-started/key_concepts.md",sourceDirName:"getting-started",slug:"/getting-started/key_concepts",permalink:"/tools/staticdocs/docs/getting-started/key_concepts",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenC3/cosmos/tree/main/docs.openc3.com/docs/getting-started/key_concepts.md",tags:[],version:"current",sidebarPosition:5,frontMatter:{sidebar_position:5,title:"Key Concepts"},sidebar:"defaultSidebar",previous:{title:"Upgrading",permalink:"/tools/staticdocs/docs/getting-started/upgrading"},next:{title:"Requirements and Design",permalink:"/tools/staticdocs/docs/getting-started/requirements"}},c={},d=[{value:"Projects",id:"projects",level:2},{value:"Containerization",id:"containerization",level:2},{value:"Images",id:"images",level:3},{value:"Containers",id:"containers",level:3},{value:"Docker Compose",id:"docker-compose",level:3},{value:"Environment File",id:"environment-file",level:3},{value:"Kubernetes",id:"kubernetes",level:3},{value:"Frontend",id:"frontend",level:2},{value:"Vue.js",id:"vuejs",level:3},{value:"Single-Spa",id:"single-spa",level:3},{value:"Astro UX",id:"astro-ux",level:3},{value:"Backend",id:"backend",level:2},{value:"Redis",id:"redis",level:3},{value:"MinIO",id:"minio",level:3},{value:"Ruby on Rails",id:"ruby-on-rails",level:3}];function l(e){const s={a:"a",h1:"h1",h2:"h2",h3:"h3",p:"p",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,o.R)(),...e.components};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(s.h1,{id:"openc3-cosmos-key-concepts",children:"OpenC3 COSMOS Key Concepts"}),"\n",(0,n.jsx)(s.h2,{id:"projects",children:"Projects"}),"\n",(0,n.jsxs)(s.p,{children:["The main COSMOS ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos",children:"repo"})," contains all the source code used to build and run COSMOS. However, users (not developers) of COSMOS should use the COSMOS ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project",children:"project"})," to launch COSMOS. The project consists of the ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/openc3.sh",children:"openc3.sh"})," and ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/openc3.bat",children:"openc3.bat"})," files for starting and stopping COSMOS, the ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/compose.yaml",children:"compose.yaml"})," for configuring the COSMOS containers, and the ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/.env",children:".env"})," file for setting runtime variables. Additionally, the COSMOS project contains user modifiable config files for both Redis and Traefik."]}),"\n",(0,n.jsx)(s.h2,{id:"containerization",children:"Containerization"}),"\n",(0,n.jsx)(s.h3,{id:"images",children:"Images"}),"\n",(0,n.jsxs)(s.p,{children:["Per ",(0,n.jsx)(s.a,{href:"https://docs.docker.com/get-started/overview/#images",children:"Docker"}),', "An image is a read-only template with instructions for creating a Docker container." The base operating system COSMOS uses is called ',(0,n.jsx)(s.a,{href:"https://www.alpinelinux.org/",children:"Alpine Linux"}),". It is a simple and compact image with a full package system that allows us to install our dependencies. Starting with Alpine, we create a ",(0,n.jsx)(s.a,{href:"https://docs.docker.com/engine/reference/builder/",children:"Dockerfile"})," to add Ruby and Python and a few other packages to create our own docker image. We further build upon that image to create a NodeJS image to support our frontend and additional images to support our backend."]}),"\n",(0,n.jsx)(s.h3,{id:"containers",children:"Containers"}),"\n",(0,n.jsxs)(s.p,{children:["Per ",(0,n.jsx)(s.a,{href:"https://www.docker.com/resources/what-container/",children:"Docker"}),', "a container is a standard unit of software that packages up code and all its dependencies so the application runs quickly and reliably from one computing environment to another." Also per ',(0,n.jsx)(s.a,{href:"https://docs.docker.com/guides/walkthroughs/what-is-a-container/",children:"Docker"}),', "A container is an isolated environment for your code. This means that a container has no knowledge of your operating system, or your files. It runs on the environment provided to you by Docker Desktop. Containers have everything that your code needs in order to run, down to a base operating system." COSMOS utilizes containers to provide a consistent runtime environment. Containers make it easy to deploy to local on-prem servers, cloud environments, or air-gapped networks.']}),"\n",(0,n.jsx)(s.p,{children:"The COSMOS Open Source containers consist of the following:"}),"\n",(0,n.jsxs)(s.table,{children:[(0,n.jsx)(s.thead,{children:(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.th,{children:"Name"}),(0,n.jsx)(s.th,{children:"Description"})]})}),(0,n.jsxs)(s.tbody,{children:[(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-cosmos-init-1"}),(0,n.jsx)(s.td,{children:"Copies files to Minio and configures COSMOS then exits"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-operator-1"}),(0,n.jsx)(s.td,{children:"Main COSMOS container that runs the interfaces and target mircoservices"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-cosmos-cmd-tlm-api-1"}),(0,n.jsx)(s.td,{children:"Rails server that provides all the COSMOS API endpoints"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-cosmos-script-runner-api-1"}),(0,n.jsx)(s.td,{children:"Rails server that provides the Script API endpoints"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-redis-1"}),(0,n.jsx)(s.td,{children:"Serves the static target configuration"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-redis-ephemeral-1"}),(0,n.jsxs)(s.td,{children:["Serves the ",(0,n.jsx)(s.a,{href:"https://redis.io/docs/data-types/streams",children:"streams"})," containing the raw and decomutated data"]})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-minio-1"}),(0,n.jsx)(s.td,{children:"Provides a S3 like bucket storage interface and also serves as a static webserver for the tool files"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-openc3-traefik-1"}),(0,n.jsx)(s.td,{children:"Provides a reverse proxy and load balancer with routes to the COSMOS endpoints"})]})]})]}),"\n",(0,n.jsxs)(s.p,{children:["The container list for ",(0,n.jsx)(s.a,{href:"https://openc3.com/enterprise",children:"Enterprise COSMOS"})," consists of the following:"]}),"\n",(0,n.jsxs)(s.table,{children:[(0,n.jsx)(s.thead,{children:(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.th,{children:"Name"}),(0,n.jsx)(s.th,{children:"Description"})]})}),(0,n.jsxs)(s.tbody,{children:[(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-enterprise-openc3-metrics-1"}),(0,n.jsx)(s.td,{children:"Rails server that provides metrics on COSMOS performance"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-enterprise-openc3-keycloak-1"}),(0,n.jsx)(s.td,{children:"Single-Sign On service for authentication"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"cosmos-enterprise-openc3-postgresql-1"}),(0,n.jsx)(s.td,{children:"SQL Database for use by Keycloak"})]}),(0,n.jsxs)(s.tr,{children:[(0,n.jsx)(s.td,{children:"openc3-nfs *"}),(0,n.jsx)(s.td,{children:"Network File System pod only for use in Kubernetes to share code libraries between containers"})]})]})]}),"\n",(0,n.jsx)(s.h3,{id:"docker-compose",children:"Docker Compose"}),"\n",(0,n.jsxs)(s.p,{children:["Per ",(0,n.jsx)(s.a,{href:"https://docs.docker.com/compose/",children:"Docker"}),', "Compose is a tool for defining and running multi-container Docker applications. With Compose, you use a YAML file to configure your application\'s services. Then, with a single command, you create and start all the services from your configuration." OpenC3 uses compose files to both build and run COSMOS. The ',(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/compose.yaml",children:"compose.yaml"})," is where ports are exposed and environment variables are used."]}),"\n",(0,n.jsx)(s.h3,{id:"environment-file",children:"Environment File"}),"\n",(0,n.jsxs)(s.p,{children:["COSMOS uses an ",(0,n.jsx)(s.a,{href:"https://docs.docker.com/compose/environment-variables/env-file/",children:"environment file"})," along with Docker Compose to pass environment variables into the COSMOS runtime. This ",(0,n.jsx)(s.a,{href:"https://github.com/OpenC3/cosmos-project/blob/main/.env",children:".env"})," file consists of simple key value pairs that contain the version of COSMOS deployed, usernames and passwords, and much more."]}),"\n",(0,n.jsx)(s.h3,{id:"kubernetes",children:"Kubernetes"}),"\n",(0,n.jsxs)(s.p,{children:["Per ",(0,n.jsx)(s.a,{href:"https://kubernetes.io/",children:"Kubernetes.io"}),', "Kubernetes, also known as K8s, is an open-source system for automating deployment, scaling, and management of containerized applications. It groups containers that make up an application into logical units for easy management and discovery." ',(0,n.jsx)(s.a,{href:"https://openc3.com/enterprise",children:"COSMOS Enterprise"})," provides ",(0,n.jsx)(s.a,{href:"https://helm.sh/docs/topics/charts/",children:"Helm charts"})," for easy deployment to Kubernetes in various cloud environments."]}),"\n",(0,n.jsxs)(s.p,{children:["COSMOS Enterprise also provides ",(0,n.jsx)(s.a,{href:"https://www.terraform.io/",children:"Terraform"})," scripts to deploy COSMOS infrastructure on various cloud environments."]}),"\n",(0,n.jsx)(s.h2,{id:"frontend",children:"Frontend"}),"\n",(0,n.jsx)(s.h3,{id:"vuejs",children:"Vue.js"}),"\n",(0,n.jsxs)(s.p,{children:["The COSMOS frontend is fully browser native and is implented in the Vue.js framework. Per ",(0,n.jsx)(s.a,{href:"https://vuejs.org/guide/introduction.html",children:"Vue.js"}),', "Vue is a JavaScript framework for building user interfaces. It builds on top of standard HTML, CSS, and JavaScript and provides a declarative and component-based programming model that helps you efficiently develop user interfaces, be they simple or complex." COSMOS utilizes Vue.js and the ',(0,n.jsx)(s.a,{href:"https://vuetifyjs.com/en/",children:"Vuetify"})," Component Framework UI library to build all the COSMOS tools which run in the browser of your choice."]}),"\n",(0,n.jsx)(s.h3,{id:"single-spa",children:"Single-Spa"}),"\n",(0,n.jsxs)(s.p,{children:["While COSMOS itself is written in Vue.js, we utilize a technology called ",(0,n.jsx)(s.a,{href:"https://single-spa.js.org/",children:"single-spa"})," to allow COSMOS developers to create applications in any javascript framework they choose. Single-spa is a micro frontend framework and acts as a top level router to render the application being requested. COSMOS provides sample applications ready to plug into single-spa in Angular, React, Svelt, and Vue."]}),"\n",(0,n.jsx)(s.h3,{id:"astro-ux",children:"Astro UX"}),"\n",(0,n.jsxs)(s.p,{children:["Per ",(0,n.jsx)(s.a,{href:"https://www.astrouxds.com/",children:"AstroUXDS"}),', "The Astro Space UX Design System enables developers and designers to build rich space app experiences with established interaction patterns and best practices." COSMOS utilizes the Astro design guidelines for color, typograpy, and iconograpy. In some cases, e.g. ',(0,n.jsx)(s.a,{href:"https://www.astrouxds.com/components/clock/",children:"Astro Clock"}),", COSMOS directly incorporates Astro components."]}),"\n",(0,n.jsx)(s.h2,{id:"backend",children:"Backend"}),"\n",(0,n.jsx)(s.h3,{id:"redis",children:"Redis"}),"\n",(0,n.jsxs)(s.p,{children:[(0,n.jsx)(s.a,{href:"https://redis.io/",children:"Redis"})," is an in-memory data store with support for strings, hashes, lists, sets, sorted sets, streams, and more. COSMOS uses Redis to store both our configuration and data. If you look back at our ",(0,n.jsx)(s.a,{href:"/docs/getting-started/key_concepts#containers",children:"container list"})," you'll notice two redis containers: cosmos-openc3-redis-1 and cosmos-openc3-redis-ephemeral-1. The ephemeral container contains all the real-time data pushed into ",(0,n.jsx)(s.a,{href:"https://redis.io/docs/data-types/streams/",children:"Redis streams"}),". The other redis container contains COSMOS configuration that is meant to persist. ",(0,n.jsx)(s.a,{href:"https://openc3.com/enterprise",children:"COSMOS Enterprise"})," provides helm charts that setup ",(0,n.jsx)(s.a,{href:"https://redis.io/docs/management/scaling/",children:"Redis Cluster"})," to perform horizontal scaling where data is shared across multiple Redis nodes."]}),"\n",(0,n.jsx)(s.h3,{id:"minio",children:"MinIO"}),"\n",(0,n.jsxs)(s.p,{children:[(0,n.jsx)(s.a,{href:"https://min.io/",children:"MinIO"})," is a high-performance, S3 compatible object store. COSMOS uses this storage technology to host both the COSMOS tools themselves and the long term log files. ",(0,n.jsx)(s.a,{href:"https://openc3.com/enterprise",children:"COSMOS Enterprise"})," deployed in a cloud environment uses the available cloud native bucket storage technology, e.g. AWS S3, GCP Buckets, and Azure Blob Storage. Using bucket storage allows COSMOS to directly serve the tools as a static website and thus we don't need to deploy Tomcat or Nginx for example."]}),"\n",(0,n.jsx)(s.h3,{id:"ruby-on-rails",children:"Ruby on Rails"}),"\n",(0,n.jsxs)(s.p,{children:["The COSMOS API and Script Runner backends are powered by ",(0,n.jsx)(s.a,{href:"https://rubyonrails.org/",children:"Ruby on Rails"}),". Rails is a web application development framework written in the Ruby programming language. Rails (and our familiarity with Ruby) allows us to write less code while accomplishing more than many other languages and frameworks."]})]})}function h(e={}){const{wrapper:s}={...(0,o.R)(),...e.components};return s?(0,n.jsx)(s,{...e,children:(0,n.jsx)(l,{...e})}):l(e)}},1184:(e,s,t)=>{t.d(s,{R:()=>i});var n=t(4041);const o={},r=n.createContext(o);function i(e){const s=n.useContext(r);return n.useMemo((function(){return"function"==typeof e?e(s):{...s,...e}}),[s,e])}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkdocs_openc3_com=self.webpackChunkdocs_openc3_com||[]).push([[3724],{4528:(e,t,i)=>{i.r(t),i.d(t,{assets:()=>a,contentTitle:()=>l,default:()=>o,frontMatter:()=>n,metadata:()=>d,toc:()=>h});var s=i(1085),r=i(1184);const n={sidebar_position:5,title:"Telemetry"},l=void 0,d={id:"configuration/telemetry",title:"Telemetry",description:"Telemetry Definition Files",source:"@site/docs/configuration/telemetry.md",sourceDirName:"configuration",slug:"/configuration/telemetry",permalink:"/tools/staticdocs/docs/configuration/telemetry",draft:!1,unlisted:!1,editUrl:"https://github.com/OpenC3/cosmos/tree/main/docs.openc3.com/docs/configuration/telemetry.md",tags:[],version:"current",sidebarPosition:5,frontMatter:{sidebar_position:5,title:"Telemetry"},sidebar:"defaultSidebar",previous:{title:"Commands",permalink:"/tools/staticdocs/docs/configuration/command"},next:{title:"Interfaces",permalink:"/tools/staticdocs/docs/configuration/interfaces"}},a={},h=[{value:"Telemetry Definition Files",id:"telemetry-definition-files",level:2},{value:"ID Items",id:"id-items",level:3},{value:"Variable Sized Items",id:"variable-sized-items",level:3},{value:"Derived Items",id:"derived-items",level:3},{value:"Received Time and Packet Time",id:"received-time-and-packet-time",level:3},{value:"Example",id:"example",level:4},{value:"TELEMETRY",id:"telemetry",level:2},{value:"TELEMETRY Modifiers",id:"telemetry-modifiers",level:2},{value:"ITEM",id:"item",level:3},{value:"ITEM Modifiers",id:"item-modifiers",level:3},{value:"FORMAT_STRING",id:"format_string",level:4},{value:"UNITS",id:"units",level:4},{value:"DESCRIPTION",id:"description",level:4},{value:"META",id:"meta",level:4},{value:"OVERLAP",id:"overlap",level:4},{value:"KEY",id:"key",level:4},{value:"STATE",id:"state",level:4},{value:"READ_CONVERSION",id:"read_conversion",level:4},{value:"POLY_READ_CONVERSION",id:"poly_read_conversion",level:4},{value:"SEG_POLY_READ_CONVERSION",id:"seg_poly_read_conversion",level:4},{value:"GENERIC_READ_CONVERSION_START",id:"generic_read_conversion_start",level:4},{value:"GENERIC_READ_CONVERSION_END",id:"generic_read_conversion_end",level:4},{value:"LIMITS",id:"limits",level:4},{value:"LIMITS_RESPONSE",id:"limits_response",level:4},{value:"APPEND_ITEM",id:"append_item",level:3},{value:"ID_ITEM",id:"id_item",level:3},{value:"APPEND_ID_ITEM",id:"append_id_item",level:3},{value:"ARRAY_ITEM",id:"array_item",level:3},{value:"APPEND_ARRAY_ITEM",id:"append_array_item",level:3},{value:"SELECT_ITEM",id:"select_item",level:3},{value:"DELETE_ITEM",id:"delete_item",level:3},{value:"META",id:"meta-1",level:3},{value:"PROCESSOR",id:"processor",level:3},{value:"ALLOW_SHORT",id:"allow_short",level:3},{value:"HIDDEN",id:"hidden",level:3},{value:"ACCESSOR",id:"accessor",level:3},{value:"IGNORE_OVERLAP",id:"ignore_overlap",level:3},{value:"SELECT_TELEMETRY",id:"select_telemetry",level:2},{value:"LIMITS_GROUP",id:"limits_group",level:2},{value:"LIMITS_GROUP_ITEM",id:"limits_group_item",level:2},{value:"Example File",id:"example-file",level:2}];function c(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",h4:"h4",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(t.h2,{id:"telemetry-definition-files",children:"Telemetry Definition Files"}),"\n",(0,s.jsxs)(t.p,{children:["Telemetry definition files define the telemetry packets that can be received and processed from COSMOS targets. One large file can be used to define the telemetry packets, or multiple files can be used at the user's discretion. Telemetry definition files are placed in the target's cmd_tlm directory and are processed alphabetically. Therefore if you have some telemetry files that depend on others, e.g. they override or extend existing telemetry, they must be named last. The easist way to do this is to add an extension to an existing file name. For example, if you already have tlm.txt you can create tlm_override.txt for telemetry that depends on the definitions in tlm.txt. Note that due to the way the ",(0,s.jsx)(t.a,{href:"http://www.asciitable.com/",children:"ASCII Table"})," is structured, files beginning with capital letters are processed before lower case letters."]}),"\n",(0,s.jsx)(t.p,{children:"When defining telemetry items you can choose from the following data types: INT, UINT, FLOAT, STRING, BLOCK. These correspond to integers, unsigned integers, floating point numbers, strings and binary blocks of data. Within COSMOS, the only difference between a STRING and BLOCK is when COSMOS reads a STRING type it stops reading when it encounters a null byte (0). This shows up when displaying the value in Packet Viewer or Tlm Viewer and in the output of Data Extractor. You should strive to store non-ASCII data inside BLOCK items and ASCII strings in STRING items."}),"\n",(0,s.jsx)(t.admonition,{title:"Printing Data",type:"info",children:(0,s.jsxs)(t.p,{children:["Most data types can be printed in a COSMOS script simply by doing ",(0,s.jsx)("code",{children:'puts tlm("TGT PKT ITEM")'}),". However, if the ITEM is a BLOCK data type and contains binary (non-ASCII) data then that won't work. COSMOS comes with a built-in method called ",(0,s.jsx)("code",{children:"formatted"})," to help you view binary data. If ITEM is a BLOCK type containing binary try ",(0,s.jsx)("code",{children:'puts tlm("TGT PKT ITEM").formatted'})," which will print the bytes out as hex."]})}),"\n",(0,s.jsx)(t.h3,{id:"id-items",children:"ID Items"}),"\n",(0,s.jsxs)(t.p,{children:["All packets require identification items so the incoming data can be matched to a packet structure. These items are defined using the ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/configuration/telemetry#id_item",children:"ID_ITEM"})," and ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/configuration/telemetry#append_id_item",children:"APPEND_ID_ITEM"}),". As data is read from the interface and refined by the protocol, the resulting packet is identified by matching all the ID fields. Note that ideally all packets in a particular target should use the exact same bit offset, bit size, and data type to identify. If this is not the case, you must set ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/configuration/target#tlm_unique_id_mode",children:"TLM_UNIQUE_ID_MODE"})," in the target.txt file which incurs a performance penalty on every packet identification."]}),"\n",(0,s.jsx)(t.h3,{id:"variable-sized-items",children:"Variable Sized Items"}),"\n",(0,s.jsx)(t.p,{children:"COSMOS specifies a variable sized item with a bit size of 0. When a packet is identified, all other data that isn't explicitly defined will be put into the variable sized item. These items are typically used for packets containing memory dumps which vary in size depending on the number of bytes dumped. Note that there can only be one variable sized item per packet."}),"\n",(0,s.jsx)(t.h3,{id:"derived-items",children:"Derived Items"}),"\n",(0,s.jsx)(t.p,{children:"COSMOS has a concept of a derived item which is a telemetry item that doesn't actually exist in the binary data. Derived items are typically computed based on other telemetry items. COSMOS derived items are very similar to real items except they use the special DERIVED data type. Here is how a derived item might look in a telemetry definition."}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'ITEM TEMP_AVERAGE 0 0 DERIVED "Average of TEMP1, TEMP2, TEMP3, TEMP4"\n'})}),"\n",(0,s.jsxs)(t.p,{children:["Note the bit offset and bit size of 0 and the data type of DERIVED. For this reason DERIVED items should be declared using ITEM rather than APPEND_ITEM. They can be defined anywhere in the packet definition but are typically placed at the end. The ITEM definition must be followed by a CONVERSION keyword, e.g. ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/configuration/telemetry#read_conversion",children:"READ_CONVERSION"}),", to generate the value."]}),"\n",(0,s.jsx)(t.h3,{id:"received-time-and-packet-time",children:"Received Time and Packet Time"}),"\n",(0,s.jsx)(t.p,{children:"COSMOS automatically creates several telemetry items on every packet: PACKET_TIMESECONDS, PACKET_TIMEFORMATTED, RECEIVED_COUNT, RECEIVED_TIMEFORMATTED, and RECEIVED_TIMESECONDS."}),"\n",(0,s.jsx)(t.p,{children:"RECEIVED_TIME is the time that COSMOS receives the packet. This is set by the interface which is connected to the target and is receiving the raw data. Once a packet has been created out of the raw data the time is set."}),"\n",(0,s.jsx)(t.p,{children:"PACKET_TIME defaults to RECEIVED_TIME, but can be set as a derived item with a time object in the telemetry configuration file. This helps support stored telemetry packets so that they can be more reasonably handled by other COSMOS tools such as Telemetry Grapher and Data Extractor. You can set the 'stored' flag in your interface and the current value table is unaffected."}),"\n",(0,s.jsxs)(t.p,{children:["The _TIMEFORMATTED items returns the date and time in a YYYY/MM/DD HH:MM",":SS",".sss format and the _TIMESECONDS returns the Unix seconds of the time."]}),"\n",(0,s.jsx)(t.h4,{id:"example",children:"Example"}),"\n",(0,s.jsx)(t.p,{children:"COSMOS provides a Unix time conversion class which returns a Ruby time object based on the number of seconds and (optionally) microseconds since the Unix epoch. Note: This returns a Ruby Time object and not a float or string!"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{children:'ITEM PACKET_TIME 0 0 DERIVED "Ruby time based on TIMESEC and TIMEUS"\n READ_CONVERSION unix_time_conversion.rb TIMESEC TIMEUS\n'})}),"\n",(0,s.jsx)(t.p,{children:"Definining PACKET_TIME allows the PACKET_TIMESECONDS and PACKET_TIMEFORMATTED to be calculated against an internal Packet time rather than the time COSMOS receives the packet."}),"\n",(0,s.jsx)("div",{style:{clear:"both"}}),"\n",(0,s.jsx)(t.h1,{id:"telemetry-keywords",children:"Telemetry Keywords"}),"\n",(0,s.jsx)(t.h2,{id:"telemetry",children:"TELEMETRY"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a new telemetry packet"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Target"}),(0,s.jsx)(t.td,{children:"Name of the target this telemetry packet is associated with"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Command"}),(0,s.jsx)(t.td,{children:"Name of this telemetry packet. Also referred to as its mnemonic. Must be unique to telemetry packets in this target. Ideally will be as short and clear as possible."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the data in this packet is in Big Endian or Little Endian format",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description of this telemetry packet which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'TELEMETRY INST HEALTH_STATUS BIG_ENDIAN "Instrument health and status"\n'})}),"\n",(0,s.jsx)(t.h2,{id:"telemetry-modifiers",children:"TELEMETRY Modifiers"}),"\n",(0,s.jsx)(t.p,{children:"The following keywords must follow a TELEMETRY keyword."}),"\n",(0,s.jsx)(t.h3,{id:"item",children:"ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a telemetry item in the current telemetry packet"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Offset"}),(0,s.jsx)(t.td,{children:"Bit offset into the telemetry packet of the Most Significant Bit of this item. May be negative to indicate on offset from the end of the packet. Always use a bit offset of 0 for derived item."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of this telemetry item. Zero or Negative values may be used to indicate that a string fills the packet up to the offset from the end of the packet specified by this value. If Bit Offset is 0 and Bit Size is 0 then this is a derived parameter and the Data Type must be set to 'DERIVED'."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of this telemetry item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK, DERIVED"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description for this telemetry item which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the item is to be interpreted in Big Endian or Little Endian format. See guide on ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/guides/little-endian-bitfields",children:"Little Endian Bitfields"}),".",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'ITEM PKTID 112 16 UINT "Packet ID"\nITEM DATA 0 0 DERIVED "Derived data"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"item-modifiers",children:"ITEM Modifiers"}),"\n",(0,s.jsx)(t.p,{children:"The following keywords must follow a ITEM keyword."}),"\n",(0,s.jsx)(t.h4,{id:"format_string",children:"FORMAT_STRING"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Adds printf style formatting"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Format"}),(0,s.jsx)(t.td,{children:"How to format using printf syntax. For example, '0x%0X' will display the value in hex."}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'FORMAT_STRING "0x%0X"\n'})}),"\n",(0,s.jsx)(t.h4,{id:"units",children:"UNITS"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Add displayed units"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Full Name"}),(0,s.jsx)(t.td,{children:"Full name of the units type, e.g. Celsius"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Abbreviated"}),(0,s.jsx)(t.td,{children:"Abbreviation for the units, e.g. C"}),(0,s.jsx)(t.td,{children:"True"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"UNITS Celsius C\nUNITS Kilometers KM\n"})}),"\n",(0,s.jsx)(t.h4,{id:"description",children:"DESCRIPTION"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Override the defined description"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Value"}),(0,s.jsx)(t.td,{children:"The new description"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.h4,{id:"meta",children:"META"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Stores custom user metadata"})}),"\n",(0,s.jsx)(t.p,{children:"Meta data is user specific data that can be used by custom tools for various purposes. One example is to store additional information needed to generate source code header files."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Meta Name"}),(0,s.jsx)(t.td,{children:"Name of the metadata to store"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Meta Values"}),(0,s.jsx)(t.td,{children:"One or more values to be stored for this Meta Name"}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'META TEST "This parameter is for test purposes only"\n'})}),"\n",(0,s.jsx)(t.h4,{id:"overlap",children:"OVERLAP"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)("div",{class:"right",children:"(Since 4.4.1)"}),(0,s.jsx)(t.strong,{children:"This item is allowed to overlap other items in the packet"})]}),"\n",(0,s.jsx)(t.p,{children:"If an item's bit offset overlaps another item, OpenC3 issues a warning. This keyword explicitly allows an item to overlap another and supresses the warning message."}),"\n",(0,s.jsx)(t.h4,{id:"key",children:"KEY"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)("div",{class:"right",children:"(Since 5.0.10)"}),(0,s.jsx)(t.strong,{children:"Defines the key used to access this raw value in the packet."})]}),"\n",(0,s.jsx)(t.p,{children:"Keys are often JsonPath or XPath strings"}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Key string"}),(0,s.jsx)(t.td,{children:"The key to access this item"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"KEY $.book.title\n"})}),"\n",(0,s.jsx)(t.h4,{id:"state",children:"STATE"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a key/value pair for the current item"})}),"\n",(0,s.jsx)(t.p,{children:"Key value pairs allow for user friendly strings. For example, you might define states for ON = 1 and OFF = 0. This allows the word ON to be used rather than the number 1 when sending the telemetry item and allows for much greater clarity and less chance for user error. A catch all value of ANY applies to all other values not already defined as state values."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Key"}),(0,s.jsx)(t.td,{children:"The string state name"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Value"}),(0,s.jsx)(t.td,{children:"The numerical state value or ANY to apply the state to all other values"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Color"}),(0,s.jsxs)(t.td,{children:["The color the state should be displayed as",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"GREEN, YELLOW, RED"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'APPEND_ITEM ENABLE 32 UINT "Enable setting"\n STATE FALSE 0\n STATE TRUE 1\n STATE ERROR ANY # Match all other values to ERROR\nAPPEND_ITEM STRING 1024 STRING "String"\n STATE "NOOP" "NOOP" GREEN\n STATE "ARM LASER" "ARM LASER" YELLOW\n STATE "FIRE LASER" "FIRE LASER" RED\n'})}),"\n",(0,s.jsx)(t.h4,{id:"read_conversion",children:"READ_CONVERSION"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Applies a conversion to the current telemetry item"})}),"\n",(0,s.jsx)(t.p,{children:"Conversions are implemented in a custom Ruby file which should be located in the target's lib folder. The class must require 'openc3/conversions/conversion' and inherit from Conversion. It must implement the initialize method if it takes extra parameters and must always implement the call method. The conversion factor is applied to the raw value in the telemetry packet before it is displayed to the user. The user still has the ability to see the raw unconverted value in a details dialog."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Class Filename"}),(0,s.jsx)(t.td,{children:"The filename which contains the Ruby class. The filename must be named after the class such that the class is a CamelCase version of the underscored filename. For example, 'the_great_conversion.rb' should contain 'class TheGreatConversion'."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Parameter"}),(0,s.jsx)(t.td,{children:"Additional parameter values for the conversion which are passed to the class constructor."}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"READ_CONVERSION the_great_conversion.rb 1000\n\nDefined in the_great_conversion.rb:\n\nrequire 'openc3/conversions/conversion'\nmodule OpenC3\n class TheGreatConversion < Conversion\n def initialize(multiplier)\n super()\n @multiplier = multiplier.to_f\n end\n def call(value, packet, buffer)\n return value * @multiplier\n end\n end\nend\n"})}),"\n",(0,s.jsx)(t.h4,{id:"poly_read_conversion",children:"POLY_READ_CONVERSION"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Adds a polynomial conversion factor to the current telemetry item"})}),"\n",(0,s.jsx)(t.p,{children:"The conversion factor is applied to raw value in the telemetry packet before it is displayed to the user. The user still has the ability to see the raw unconverted value in a details dialog."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"C0"}),(0,s.jsx)(t.td,{children:"Coefficient"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Cx"}),(0,s.jsx)(t.td,{children:"Additional coefficient values for the conversion. Any order polynomial conversion may be used so the value of 'x' will vary with the order of the polynomial. Note that larger order polynomials take longer to process than shorter order polynomials, but are sometimes more accurate."}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"POLY_READ_CONVERSION 10 0.5 0.25\n"})}),"\n",(0,s.jsx)(t.h4,{id:"seg_poly_read_conversion",children:"SEG_POLY_READ_CONVERSION"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Adds a segmented polynomial conversion factor to the current telemetry item"})}),"\n",(0,s.jsx)(t.p,{children:"This conversion factor is applied to the raw value in the telemetry packet before it is displayed to the user. The user still has the ability to see the raw unconverted value in a details dialog."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Lower Bound"}),(0,s.jsx)(t.td,{children:"Defines the lower bound of the range of values that this segmented polynomial applies to. Is ignored for the segment with the smallest lower bound."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"C0"}),(0,s.jsx)(t.td,{children:"Coefficient"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Cx"}),(0,s.jsx)(t.td,{children:"Additional coefficient values for the conversion. Any order polynomial conversion may be used so the value of 'x' will vary with the order of the polynomial. Note that larger order polynomials take longer to process than shorter order polynomials, but are sometimes more accurate."}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"SEG_POLY_READ_CONVERSION 0 10 0.5 0.25 # Apply the conversion to all values < 50\nSEG_POLY_READ_CONVERSION 50 11 0.5 0.275 # Apply the conversion to all values >= 50 and < 100\nSEG_POLY_READ_CONVERSION 100 12 0.5 0.3 # Apply the conversion to all values >= 100\n"})}),"\n",(0,s.jsx)(t.h4,{id:"generic_read_conversion_start",children:"GENERIC_READ_CONVERSION_START"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Start a generic read conversion"})}),"\n",(0,s.jsx)(t.p,{children:"Adds a generic conversion function to the current telemetry item. This conversion factor is applied to the raw value in the telemetry packet before it is displayed to the user. The user still has the ability to see the raw unconverted value in a details dialog. The conversion is specified as ruby code that receives two implied parameters. 'value' which is the raw value being read and 'packet' which is a reference to the telemetry packet class (Note, referencing the packet as 'myself' is still supported for backwards compatibility). The last line of ruby code given should return the converted value. The GENERIC_READ_CONVERSION_END keyword specifies that all lines of ruby code for the conversion have been given."}),"\n",(0,s.jsx)(t.admonition,{type:"warning",children:(0,s.jsx)(t.p,{children:"Generic conversions are not a good long term solution. Consider creating a conversion class and using READ_CONVERSION instead. READ_CONVERSION is easier to debug and higher performance."})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Converted Type"}),(0,s.jsxs)(t.td,{children:["Type of the converted value",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK"})]}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Converted Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of converted value"}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"APPEND_ITEM ITEM1 32 UINT\n GENERIC_READ_CONVERSION_START\n value * 1.5 # Convert the value by a scale factor\n GENERIC_READ_CONVERSION_END\n"})}),"\n",(0,s.jsx)(t.h4,{id:"generic_read_conversion_end",children:"GENERIC_READ_CONVERSION_END"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Complete a generic read conversion"})}),"\n",(0,s.jsx)(t.h4,{id:"limits",children:"LIMITS"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a set of limits for a telemetry item"})}),"\n",(0,s.jsx)(t.p,{children:'If limits are violated a message is printed in the Command and Telemetry Server to indicate an item went out of limits. Other tools also use this information to update displays with different colored telemetry items or other useful information. The concept of "limits sets" is defined to allow for different limits values in different environments. For example, you might want tighter or looser limits on telemetry if your environment changes such as during thermal vacuum testing.'}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Limits Set"}),(0,s.jsx)(t.td,{children:"Name of the limits set. If you have no unique limits sets use the keyword DEFAULT."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Persistence"}),(0,s.jsx)(t.td,{children:"Number of consecutive times the telemetry item must be within a different limits range before changing limits state."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Initial State"}),(0,s.jsxs)(t.td,{children:["Whether limits monitoring for this telemetry item is initially enabled or disabled. Note if you have multiple LIMITS items they should all have the same initial state.",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"ENABLED, DISABLED"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Red Low Limit"}),(0,s.jsx)(t.td,{children:"If the telemetry value is less than or equal to this value a Red Low condition will be detected"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Yellow Low Limit"}),(0,s.jsx)(t.td,{children:"If the telemetry value is less than or equal to this value, but greater than the Red Low Limit, a Yellow Low condition will be detected"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Yellow High Limit"}),(0,s.jsx)(t.td,{children:"If the telemetry value is greater than or equal to this value, but less than the Red High Limit, a Yellow High condition will be detected"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Red High Limit"}),(0,s.jsx)(t.td,{children:"If the telemetry value is greater than or equal to this value a Red High condition will be detected"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Green Low Limit"}),(0,s.jsx)(t.td,{children:'Setting the Green Low and Green High limits defines an "operational limit" which is colored blue by OpenC3. This allows for a distinct desired operational range which is narrower than the green safety limit. If the telemetry value is greater than or equal to this value, but less than the Green High Limit, a Blue operational condition will be detected.'}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Green High Limit"}),(0,s.jsx)(t.td,{children:'Setting the Green Low and Green High limits defines an "operational limit" which is colored blue by OpenC3. This allows for a distinct desired operational range which is narrower than the green safety limit. If the telemetry value is less than or equal to this value, but greater than the Green Low Limit, a Blue operational condition will be detected.'}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"LIMITS DEFAULT 3 ENABLED -80.0 -70.0 60.0 80.0 -20.0 20.0\nLIMITS TVAC 3 ENABLED -80.0 -30.0 30.0 80.0\n"})}),"\n",(0,s.jsx)(t.h4,{id:"limits_response",children:"LIMITS_RESPONSE"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a response class that is called when the limits state of the current item changes"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Response Class Filename"}),(0,s.jsx)(t.td,{children:"Name of the Ruby file which implements the limits response. This file should be in the config/TARGET/lib directory so it can be found by OpenC3."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Response Specific Options"}),(0,s.jsx)(t.td,{children:"Variable length number of options that will be passed to the class constructor"}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"LIMITS_RESPONSE example_limits_response.rb 10\n"})}),"\n",(0,s.jsx)(t.h3,{id:"append_item",children:"APPEND_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a telemetry item in the current telemetry packet"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of this telemetry item. Zero or Negative values may be used to indicate that a string fills the packet up to the offset from the end of the packet specified by this value. If Bit Offset is 0 and Bit Size is 0 then this is a derived parameter and the Data Type must be set to 'DERIVED'."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of this telemetry item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK, DERIVED"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description for this telemetry item which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the item is to be interpreted in Big Endian or Little Endian format. See guide on ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/guides/little-endian-bitfields",children:"Little Endian Bitfields"}),".",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'APPEND_ITEM PKTID 16 UINT "Packet ID"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"id_item",children:"ID_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:'Defines a telemetry item in the current telemetry packet. Note, packets defined without one or more ID_ITEMs are "catch-all" packets which will match all incoming data. Normally this is the job of the UNKNOWN packet.'})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Offset"}),(0,s.jsx)(t.td,{children:"Bit offset into the telemetry packet of the Most Significant Bit of this item. May be negative to indicate on offset from the end of the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of this telemetry item. Zero or Negative values may be used to indicate that a string fills the packet up to the offset from the end of the packet specified by this value."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of this telemetry item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"ID Value"}),(0,s.jsx)(t.td,{children:"The value of this telemetry item that uniquely identifies this telemetry packet"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description for this telemetry item which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the item is to be interpreted in Big Endian or Little Endian format. See guide on ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/guides/little-endian-bitfields",children:"Little Endian Bitfields"}),".",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'ID_ITEM PKTID 112 16 UINT 1 "Packet ID which must be 1"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"append_id_item",children:"APPEND_ID_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a telemetry item in the current telemetry packet"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of this telemetry item. Zero or Negative values may be used to indicate that a string fills the packet up to the offset from the end of the packet specified by this value."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of this telemetry item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"ID Value"}),(0,s.jsx)(t.td,{children:"The value of this telemetry item that uniquely identifies this telemetry packet"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description for this telemetry item which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the item is to be interpreted in Big Endian or Little Endian format. See guide on ",(0,s.jsx)(t.a,{href:"/tools/staticdocs/docs/guides/little-endian-bitfields",children:"Little Endian Bitfields"}),".",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'APPEND_ID_ITEM PKTID 16 UINT 1 "Packet ID which must be 1"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"array_item",children:"ARRAY_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a telemetry item in the current telemetry packet that is an array"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Bit Offset"}),(0,s.jsx)(t.td,{children:"Bit offset into the telemetry packet of the Most Significant Bit of this item. May be negative to indicate on offset from the end of the packet. Always use a bit offset of 0 for derived item."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of each array item"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of each array item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK, DERIVED"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Array Bit Size"}),(0,s.jsx)(t.td,{children:"Total Bit Size of the Array. Zero or Negative values may be used to indicate the array fills the packet up to the offset from the end of the packet specified by this value."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the data is to be sent in Big Endian or Little Endian format",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'ARRAY_ITEM ARRAY 64 32 FLOAT 320 "Array of 10 floats"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"append_array_item",children:"APPEND_ARRAY_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a telemetry item in the current telemetry packet that is an array"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Name"}),(0,s.jsx)(t.td,{children:"Name of the telemety item. Must be unique within the packet."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item Bit Size"}),(0,s.jsx)(t.td,{children:"Bit size of each array item"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item Data Type"}),(0,s.jsxs)(t.td,{children:["Data Type of each array item",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"INT, UINT, FLOAT, STRING, BLOCK, DERIVED"})]}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Array Bit Size"}),(0,s.jsx)(t.td,{children:"Total Bit Size of the Array. Zero or Negative values may be used to indicate the array fills the packet up to the offset from the end of the packet specified by this value."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Description"}),(0,s.jsx)(t.td,{children:"Description which must be enclosed with quotes"}),(0,s.jsx)(t.td,{children:"False"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Endianness"}),(0,s.jsxs)(t.td,{children:["Indicates if the data is to be sent in Big Endian or Little Endian format",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"Valid Values: ",(0,s.jsx)("span",{class:"values",children:"BIG_ENDIAN, LITTLE_ENDIAN"})]}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'APPEND_ARRAY_ITEM ARRAY 32 FLOAT 320 "Array of 10 floats"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"select_item",children:"SELECT_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Selects an existing telemetry item for editing"})}),"\n",(0,s.jsx)(t.p,{children:"Must be used in conjunction with SELECT_TELEMETRY to first select the packet. Typically used to override generated values or make specific changes to telemetry that only affect a particular instance of a target used multiple times."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item"}),(0,s.jsx)(t.td,{children:"Name of the item to select for modification"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"SELECT_TELEMETRY INST HEALTH_STATUS\n SELECT_ITEM TEMP1\n # Define limits for this item, overrides or replaces any existing\n LIMITS DEFAULT 3 ENABLED -90.0 -80.0 80.0 90.0 -20.0 20.0\n"})}),"\n",(0,s.jsx)(t.h3,{id:"delete_item",children:"DELETE_ITEM"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)("div",{class:"right",children:"(Since 4.4.1)"}),(0,s.jsx)(t.strong,{children:"Delete an existing telemetry item from the packet definition"})]}),"\n",(0,s.jsx)(t.p,{children:'Deleting an item from the packet definition does not remove the defined space for that item. Thus unless you redefine a new item, there will be a "hole" in the packet where the data is not accessible. You can use SELECT_TELEMETRY and then ITEM to define a new item.'}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item"}),(0,s.jsx)(t.td,{children:"Name of the item to delete"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"SELECT_TELEMETRY INST HEALTH_STATUS\n DELETE_ITEM TEMP4\n"})}),"\n",(0,s.jsx)(t.h3,{id:"meta-1",children:"META"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Stores metadata for the current telemetry packet"})}),"\n",(0,s.jsx)(t.p,{children:"Meta data is user specific data that can be used by custom tools for various purposes. One example is to store additional information needed to generate source code header files."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Meta Name"}),(0,s.jsx)(t.td,{children:"Name of the metadata to store"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Meta Values"}),(0,s.jsx)(t.td,{children:"One or more values to be stored for this Meta Name"}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'META FSW_TYPE "struct tlm_packet"\n'})}),"\n",(0,s.jsx)(t.h3,{id:"processor",children:"PROCESSOR"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a processor class that executes code every time a packet is received"})}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Processor Name"}),(0,s.jsx)(t.td,{children:"The name of the processor"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Processor Class Filename"}),(0,s.jsx)(t.td,{children:"Name of the Ruby file which implements the processor. This file should be in the config/TARGET/lib directory so it can be found by OpenC3."}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Processor Specific Options"}),(0,s.jsx)(t.td,{children:"Variable length number of options that will be passed to the class constructor."}),(0,s.jsx)(t.td,{children:"False"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"PROCESSOR TEMP1HIGH watermark_processor.rb TEMP1\n"})}),"\n",(0,s.jsx)(t.h3,{id:"allow_short",children:"ALLOW_SHORT"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Process telemetry packets which are less than their defined length"})}),"\n",(0,s.jsx)(t.p,{children:"Allows the telemetry packet to be received with a data portion that is smaller than the defined size without warnings. Any extra space in the packet will be filled in with zeros by OpenC3."}),"\n",(0,s.jsx)(t.h3,{id:"hidden",children:"HIDDEN"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Hides this telemetry packet from all the OpenC3 tools"})}),"\n",(0,s.jsx)(t.p,{children:"This packet will not appear in Packet Viewer, Telemetry Grapher and Handbook Creator. It also hides this telemetry from appearing in the Script Runner popup helper when writing scripts. The telemetry still exists in the system and can received and checked by scripts."}),"\n",(0,s.jsx)(t.h3,{id:"accessor",children:"ACCESSOR"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)("div",{class:"right",children:"(Since 5.0.10)"}),(0,s.jsx)(t.strong,{children:"Defines the class used to read and write raw values from the packet"})]}),"\n",(0,s.jsx)(t.p,{children:"Defines the class that is used too read raw values from the packet. Defaults to BinaryAccessor. Provided accessors also include JsonAccessor, CborAccessor, HtmlAccessor, and XmlAccessor."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Accessor Class Name"}),(0,s.jsx)(t.td,{children:"The name of the accessor class"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.h3,{id:"ignore_overlap",children:"IGNORE_OVERLAP"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)("div",{class:"right",children:"(Since 5.16.0)"}),(0,s.jsx)(t.strong,{children:"Ignores any packet items which overlap"})]}),"\n",(0,s.jsx)(t.p,{children:"Packet items which overlap normally generate a warning unless each individual item has the OVERLAP keyword. This ignores overlaps across the entire packet."}),"\n",(0,s.jsx)(t.h2,{id:"select_telemetry",children:"SELECT_TELEMETRY"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Selects an existing telemetry packet for editing"})}),"\n",(0,s.jsx)(t.p,{children:"Typically used in a separate configuration file from where the original telemetry is defined to override or add to the existing telemetry definition. Must be used in conjunction with SELECT_ITEM to change an individual item."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Target Name"}),(0,s.jsx)(t.td,{children:"Name of the target this telemetry packet is associated with"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Packet Name"}),(0,s.jsx)(t.td,{children:"Name of the telemetry packet to select"}),(0,s.jsx)(t.td,{children:"True"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"SELECT_TELEMETRY INST HEALTH_STATUS\n SELECT_ITEM TEMP1\n # Define limits for this item, overrides or replaces any existing\n LIMITS DEFAULT 3 ENABLED -90.0 -80.0 80.0 90.0 -20.0 20.0\n"})}),"\n",(0,s.jsx)(t.h2,{id:"limits_group",children:"LIMITS_GROUP"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Defines a group of related limits Items"})}),"\n",(0,s.jsx)(t.p,{children:'Limits groups contain telemetry items that can be enabled and disabled together. It can be used to group related limits as a subsystem that can be enabled or disabled as that particular subsystem is powered (for example). To enable a group call the enable_limits_group("NAME") method in Script Runner. To disable a group call the disable_limits_group("NAME") in Script Runner. Items can belong to multiple groups but the last enabled or disabled group "wins". For example, if an item belongs to GROUP1 and GROUP2 and you first enable GROUP1 and then disable GROUP2 the item will be disabled. If you then enable GROUP1 again it will be enabled.'}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsx)(t.tbody,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Group Name"}),(0,s.jsx)(t.td,{children:"Name of the limits group"}),(0,s.jsx)(t.td,{children:"True"})]})})]}),"\n",(0,s.jsx)(t.h2,{id:"limits_group_item",children:"LIMITS_GROUP_ITEM"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Adds the specified telemetry item to the last defined LIMITS_GROUP"})}),"\n",(0,s.jsx)(t.p,{children:"Limits group information is typically kept in a separate configuration file in the config/TARGET/cmd_tlm folder named limits_groups.txt."}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Parameter"}),(0,s.jsx)(t.th,{children:"Description"}),(0,s.jsx)(t.th,{children:"Required"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Target Name"}),(0,s.jsx)(t.td,{children:"Name of the target"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Packet Name"}),(0,s.jsx)(t.td,{children:"Name of the packet"}),(0,s.jsx)(t.td,{children:"True"})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:"Item Name"}),(0,s.jsx)(t.td,{children:"Name of the telemetry item to add to the group"}),(0,s.jsx)(t.td,{children:"True"})]})]})]}),"\n",(0,s.jsx)(t.p,{children:"Example Usage:"}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:"LIMITS_GROUP SUBSYSTEM\n LIMITS_GROUP_ITEM INST HEALTH_STATUS TEMP1\n LIMITS_GROUP_ITEM INST HEALTH_STATUS TEMP2\n LIMITS_GROUP_ITEM INST HEALTH_STATUS TEMP3\n"})}),"\n",(0,s.jsx)(t.h2,{id:"example-file",children:"Example File"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.strong,{children:"Example File: TARGET/cmd_tlm/tlm.txt"})}),"\n",(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-ruby",children:'TELEMETRY TARGET HS BIG_ENDIAN "Health and Status for My Target"\n ITEM CCSDSVER 0 3 UINT "CCSDS PACKET VERSION NUMBER (SEE CCSDS 133.0-B-1)"\n ITEM CCSDSTYPE 3 1 UINT "CCSDS PACKET TYPE (COMMAND OR TELEMETRY)"\n STATE TLM 0\n STATE CMD 1\n ITEM CCSDSSHF 4 1 UINT "CCSDS SECONDARY HEADER FLAG"\n STATE FALSE 0\n STATE TRUE 1\n ID_ITEM CCSDSAPID 5 11 UINT 102 "CCSDS APPLICATION PROCESS ID"\n ITEM CCSDSSEQFLAGS 16 2 UINT "CCSDS SEQUENCE FLAGS"\n STATE FIRST 0\n STATE CONT 1\n STATE LAST 2\n STATE NOGROUP 3\n ITEM CCSDSSEQCNT 18 14 UINT "CCSDS PACKET SEQUENCE COUNT"\n ITEM CCSDSLENGTH 32 16 UINT "CCSDS PACKET DATA LENGTH"\n ITEM CCSDSDAY 48 16 UINT "DAYS SINCE EPOCH (JANUARY 1ST, 1958, MIDNIGHT)"\n ITEM CCSDSMSOD 64 32 UINT "MILLISECONDS OF DAY (0 - 86399999)"\n ITEM CCSDSUSOMS 96 16 UINT "MICROSECONDS OF MILLISECOND (0-999)"\n ITEM ANGLEDEG 112 16 INT "Instrument Angle in Degrees"\n POLY_READ_CONVERSION 0 57.295\n ITEM MODE 128 8 UINT "Instrument Mode"\n STATE NORMAL 0 GREEN\n STATE DIAG 1 YELLOW\n ITEM TIMESECONDS 0 0 DERIVED "DERIVED TIME SINCE EPOCH IN SECONDS"\n GENERIC_READ_CONVERSION_START FLOAT 32\n ((packet.read(\'ccsdsday\') * 86400.0) + (packet.read(\'ccsdsmsod\') / 1000.0) + (packet.read(\'ccsdsusoms\') / 1000000.0) )\n GENERIC_READ_CONVERSION_END\n ITEM TIMEFORMATTED 0 0 DERIVED "DERIVED TIME SINCE EPOCH AS A FORMATTED STRING"\n GENERIC_READ_CONVERSION_START STRING 216\n time = Time.ccsds2mdy(packet.read(\'ccsdsday\'), packet.read(\'ccsdsmsod\'), packet.read(\'ccsdsusoms\'))\n sprintf(\'%04u/%02u/%02u %02u:%02u:%02u.%06u\', time[0], time[1], time[2], time[3], time[4], time[5], time[6])\n GENERIC_READ_CONVERSION_END\n'})})]})}function o(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(c,{...e})}):c(e)}},1184:(e,t,i)=>{i.d(t,{R:()=>l});var s=i(4041);const r={},n=s.createContext(r);function l(e){const t=s.useContext(n);return s.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}}}]);