{"id":19534058,"url":"https://github.com/foxglove/ros1","last_synced_at":"2025-04-26T14:34:50.429Z","repository":{"id":40289020,"uuid":"386372329","full_name":"foxglove/ros1","owner":"foxglove","description":"Standalone TypeScript implementation of the ROS 1 protocol with a pluggable transport layer","archived":true,"fork":false,"pushed_at":"2025-01-08T20:27:21.000Z","size":342,"stargazers_count":13,"open_issues_count":0,"forks_count":7,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-19T00:29:02.446Z","etag":null,"topics":["networking","nodejs","protocol","robotics","ros","ros1","tcp","typescript"],"latest_commit_sha":null,"homepage":"https://foxglove.dev","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/foxglove.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2021-07-15T17:26:52.000Z","updated_at":"2025-01-08T20:27:32.000Z","dependencies_parsed_at":"2024-01-22T05:28:40.827Z","dependency_job_id":"20cb80f1-2537-496f-a957-2f01490baaec","html_url":"https://github.com/foxglove/ros1","commit_stats":{"total_commits":63,"total_committers":9,"mean_commits":7.0,"dds":"0.19047619047619047","last_synced_commit":"732680ea1337926a68135974b8375deb73df74c7"},"previous_names":[],"tags_count":22,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxglove%2Fros1","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxglove%2Fros1/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxglove%2Fros1/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/foxglove%2Fros1/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/foxglove","download_url":"https://codeload.github.com/foxglove/ros1/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251001283,"owners_count":21520919,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["networking","nodejs","protocol","robotics","ros","ros1","tcp","typescript"],"created_at":"2024-11-11T02:12:08.913Z","updated_at":"2025-04-26T14:34:49.285Z","avatar_url":"https://github.com/foxglove.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# @foxglove/ros1\n\n\u003e [!IMPORTANT]\n\u003e This package has moved to https://github.com/foxglove/ros-typescript.\n\n\u003e _Standalone TypeScript implementation of the ROS 1 (Robot Operating System) protocol with a pluggable transport layer_\n\n[![npm version](https://img.shields.io/npm/v/@foxglove/ros1.svg?style=flat)](https://www.npmjs.com/package/@foxglove/ros1)\n\n## Usage\n\n```Typescript\n// An example client that connects to the ROS1 turtlesim node\n\nimport { RosNode } from \"@foxglove/ros1\";\nimport { getEnvVar, getHostname, getNetworkInterfaces, getPid, TcpSocketNode } from \"@foxglove/ros1/nodejs\";\nimport { HttpServerNodejs } from \"@foxglove/xmlrpc/nodejs\";\n\nasync function main() {\n  const name = \"/testclient\";\n  let rosNode: RosNode | undefined;\n\n  try {\n    rosNode = new RosNode({\n      name,\n      rosMasterUri: getEnvVar(\"ROS_MASTER_URI\") ?? \"http://localhost:11311/\",\n      hostname: RosNode.GetRosHostname(getEnvVar, getHostname, getNetworkInterfaces),\n      pid: getPid(),\n      httpServer: new HttpServerNodejs(),\n      tcpSocketCreate: TcpSocketNode.Create,\n      log: console,\n    });\n\n    await rosNode.start();\n\n    const params = await rosNode.subscribeAllParams();\n    console.dir(params);\n\n    const sub = rosNode.subscribe({\n      topic: \"/turtle1/color_sensor\",\n      dataType: \"turtlesim/Color\",\n    });\n\n    sub.on(\"message\", (msg, data, pub) =\u003e {\n      console.log(\n        `[MSG] ${JSON.stringify(msg)} (${\n          data.byteLength\n        } bytes from ${pub.connection.getTransportInfo()})`,\n      );\n    });\n\n    await new Promise((resolve) =\u003e setTimeout(resolve, 1000));\n\n    console.dir(sub.getStats());\n  } catch (err) {\n    const msg = (err as Error).stack ?? `${err}`;\n    console.error(msg);\n  } finally {\n    rosNode?.shutdown();\n  }\n}\n\nvoid main();\n```\n\n### Test\n\n`yarn test`\n\n## License\n\n@foxglove/ros1 is licensed under the [MIT License](https://opensource.org/licenses/MIT).\n\n## Releasing\n\n1. Run `yarn version --[major|minor|patch]` to bump version\n2. Run `git push \u0026\u0026 git push --tags` to push new tag\n3. GitHub Actions will take care of the rest\n\n## Stay in touch\n\nJoin our [Slack channel](https://foxglove.dev/slack) to ask questions, share feedback, and stay up to date on what our team is working on.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxglove%2Fros1","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffoxglove%2Fros1","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffoxglove%2Fros1/lists"}