{"id":28512769,"url":"https://github.com/tzf230201/scara_arm","last_synced_at":"2026-05-09T05:08:37.850Z","repository":{"id":280355799,"uuid":"941710483","full_name":"tzf230201/scara_arm","owner":"tzf230201","description":"A 4-DoF SCARA robot arm on a vertical rail, utilizing Integrated Closed-Loop (ICL) stepper motors for horizontal axis and a servo motor for vertical axis with CAN bus communication","archived":false,"fork":false,"pushed_at":"2026-03-19T07:48:21.000Z","size":161956,"stargazers_count":8,"open_issues_count":0,"forks_count":2,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-03-20T00:52:39.562Z","etag":null,"topics":["arm-robot","can-bus","canopen","moveit","robotics","ros","urdf"],"latest_commit_sha":null,"homepage":"","language":"Python","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/tzf230201.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,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-03-02T22:53:00.000Z","updated_at":"2026-03-19T07:48:25.000Z","dependencies_parsed_at":"2025-09-08T13:05:22.172Z","dependency_job_id":"ddf8ceba-3dfd-422d-b185-80d16f4f8530","html_url":"https://github.com/tzf230201/scara_arm","commit_stats":null,"previous_names":["tzf230201/scara_arm"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/tzf230201/scara_arm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tzf230201%2Fscara_arm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tzf230201%2Fscara_arm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tzf230201%2Fscara_arm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tzf230201%2Fscara_arm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tzf230201","download_url":"https://codeload.github.com/tzf230201/scara_arm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tzf230201%2Fscara_arm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32807870,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"online","status_checked_at":"2026-05-09T02:00:06.633Z","response_time":123,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["arm-robot","can-bus","canopen","moveit","robotics","ros","urdf"],"created_at":"2025-06-09T01:01:05.297Z","updated_at":"2026-05-09T05:08:37.845Z","avatar_url":"https://github.com/tzf230201.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# scara_arm\n\nA 4-DoF SCARA robot arm on a vertical rail, equipped with Integrated Closed-Loop (ICL) stepper motors and a industrial servo motor, all controlled via CAN bus communication.\n\n![Scara Arm](images/picture_1.png)\n\nThe software was running on ROS1-Noetic, utilizing a URDF model and MoveIt, with an option to use a custom Tkinter GUI. but for now, we stop using ROS1 and tring to use another messaging library to get realtime system such as ZMQ, we are moving to ROS2 too.\n\n![MoveIt](images/picture_5.png)\n\nMovelt actually difficult to manage our arm robot, because our robot mechanically different from general arm robot system. each link is connected individually to its motor which is located on the main base instead of the normal, on its parent link. Each link will point to the same global direction regardless of the other link's movement.\n\n![Mechanical Design](images/picture_2.png)\n\nThat's why We are also developing our own motion designer software called [Dancemotion Designer](https://github.com/tzf230201/Dancemotion-Designer), which is also an ongoing project.\n\nanother option, we provide request based system, the request system will run a pre-defined motin if requested, usually the request sended by CAN-BUS, but we provided a UI to test the request sytem, you can find it at `csv_files/task_gui_stream_pvt.py`, and run the `ros2 launch robot_description pvt_viewer.launch.py` to see the movement.\n\n![RVIZ](images/picture_7.png)\n\n\nWe plan to make the real arm move exact as to the simulation with the same organic smoothness (because our arm is very \nsturdy and backlash free)\n\n\n\n\nEach actuator features a built-in smart MCU, allowing users to configure parameters such as starting speed, acceleration and deceleration times, maximum speed, and total pulse count. These settings enable smooth S-curve acceleration and deceleration.\n\n![Diagram](images/picture_3.png)\n\nCommands are sent through the CAN bus using the CANopen protocol. \n\n![MCP2515 module](images/picture_6.jpg)\n\n[2-CH CAN HAT Module Datasheet](https://www.waveshare.com/wiki/2-CH_CAN_HAT)\n\n\n**Used RasPi-4 Pins:**\n\n| Fungsi                   | GPIO (BCM) | Physical Pin (40-pin header) |\n|--------------------------|------------|------------------------------|\n| **SPI MOSI**             | GPIO 10    | Pin 19                       |\n| **SPI MISO**             | GPIO 9     | Pin 21                       |\n| **SPI CLK (SCK)**        | GPIO 11    | Pin 23                       |\n| **CAN0 CS (CE0)**        | GPIO 8     | Pin 24                       |\n| **CAN1 CS (CE1)**        | GPIO 7     | Pin 26                       |\n| **CAN0 Interrupt**       | GPIO 23    | Pin 16                       |\n| **CAN1 Interrupt**       | GPIO 25    | Pin 22                       |\n| **Relay**                | GPIO 2    | Pin 3\n\n\n# Installation\n\n## Boot/Firmware/config.txt\n\n```bash\n# Enable audio, I2C, and SPI\ndtparam=audio=on\ndtparam=i2c_arm=on\ndtparam=spi=on\n\n# Enable MCP2515 CAN interface\ndtoverlay=mcp2515-can1,oscillator=16000000,interrupt=25\ndtoverlay=mcp2515-can0,oscillator=16000000,interrupt=23\ndtoverlay=spi-bcm2835-overlay\n```\n\nafter that\n```\nsudo reboot\n```\n\n## Run this before run the main program\n\n```bash\nsudo ip link set can0 down\nsudo ip link set can0 txqueuelen 1000  # if less then no permission error comes\nsudo ip link set can0 type can bitrate 1000000 loopback off\nsudo ip link set can0 up\n```\n**or run can_begin.sh instead, you can put this in .bashrc, it will automatically check and run if it wasn't running yet**\n\n```bash\n# === Auto-run CAN setup only once per boot ===\nCAN_MARKER=\"/tmp/can_initialized\"\n\nif [ ! -f \"$CAN_MARKER\" ]; then\n    echo \"[INFO] Initializing CAN0...\"\n    bash ~/scara_arm/can_begin.sh \u0026\u0026 touch \"$CAN_MARKER\"\nfi\n\n```\n\n\n\n**Dependencies**\n```bash\nsudo apt install python3_zmq\nsudo apt install python3-can\nsudo apt install python3-tk\nsudo apt install python3-numpy\nsudo apt install python3-matplotlib\nsudo apt install python3-pandas\nsudo apt install can-utils\n```\n\n**Note**\n- candump.py used to record all can communication into text file for debugging\n- about datasheet,there are 2 datahseet for servo, When i purcasea the servo, the seller give me the newer datasheet (DCH_CANopen.pdf), however is not completed yet, there are several commands that not explained there yet (in my case, i want to know current index of PVT buffer in servo, but it's didn't explained there), so they give me the older one, (CANopen\u0026EtherCAT.pdf), that's why we have 2 datahseet now.\n\n\n\n**File System**\n```\nsrc/\n├── gui.py                  # User Interface (Tkinter)\n├── main.py                 # Main entry point\n├── callbacks.py            # Event and callback handlers\n└── robot.py                # Integration vertical and horizontal axis\n    ├── arm.py              # 3 dof scara arm for horizontal axis\n    │   └── stepper.py      # Stepper SDK\n    │       ├── origin.py   # handle origin information \n    │       └── canbase.py  # SimpleCAn3 \u0026 CANOpen protocol\n    │    \n    ├── servo.py            # Servo SDK for vertical axis\n    │   ├── origin.py       # handle origin information\n    │   └── canbase.py      # SimpleCAn3 \u0026 CANOpen protocol\n    └── utility.py          # several tools for debugging\n```\n\n** how to design motion**\n```\ncd csv_files\npython3 motion_designer.py\n```\n\nEven though it's still an ongoing project,  let [**See it in action**](https://drive.google.com/file/d/1y8DbG6vgjGmnc4_ooR9SQvQAt7R12CfX/view?usp=sharing)\n\n\n\nAsk me anything : teukuzikrifatahillah@gmail.com","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftzf230201%2Fscara_arm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftzf230201%2Fscara_arm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftzf230201%2Fscara_arm/lists"}