---
title: "Discussion on \"7. Tạo một ROS Publisher\" | Hashnode"
description: "Discussion on \"7. Tạo một ROS Publisher\". Hướng dẫn chi tiết tạo một publisher để publish hình ảnh từ camera trong ROS."
url: "https://hashnode.com/posts/tao-ros-publisher/63b748774d6da3dbcf4351c4"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [7\. Tạo một ROS Publisher](https://robodev.blog/tao-ros-publisher?utm_source=hashnode&utm_medium=feed)

Hướng dẫn chi tiết tạo một publisher để publish hình ảnh từ camera trong ROS.

Jan 5, 2023 · 11 min read · robodev.blog  
Updated Jan 10, 2023  
Read the article

-   [#ros](https://hashnode.com/tag/ros)
-   [#robotics](https://hashnode.com/tag/robotics)
-   [#robot-operating-system](https://hashnode.com/tag/robot-operating-system)
-   [#vietnamese](https://hashnode.com/tag/vietnamese)
-   [#tutorial](https://hashnode.com/tag/tutorial)

## Written by

[Trinh Nguyen](https://hashnode.com/@TrinhNC)

@TrinhNC

  
[View profile](https://hashnode.com/@TrinhNC)

#robotics #digitaltwin #ros #python #c++ #computer\_vision #ai #machine\_learning

## Responses

Markdown supported · ⌘↵ to post

[Đức Trần](https://hashnode.com/@TranDuc)

[Nov 26, 2023](https://hashnode.com/posts/tao-ros-publisher/63b748774d6da3dbcf4351c4/comment/65631726585e979b362f291e)

dạ anh ơi, khi chạy lệnh rosrun my\_cam image\_publisher.py thì máy em báo lỗi như thế này Image is being published to the topic /image\_raw ... \[ WARN:0\] global ../modules/videoio/src/cap\_gstreamer.cpp (1758) handleMessage OpenCV | GStreamer warning: Embedded video playback halted; module source reported: Could not read from resource. \[ WARN:0\] global ../modules/videoio/src/cap\_gstreamer.cpp (888) open OpenCV | GStreamer warning: unable to start pipeline \[ WARN:0\] global ../modules/videoio/src/cap\_gstreamer.cpp (480) isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created Traceback (most recent call last): File "/home/ducmatau/catkin\_ws/src/my\_cam/image\_publisher.py", line 30, in <module> publish\_image() File "/home/ducmatau/catkin\_ws/src/my\_cam/image\_publisher.py", line 18, in publish\_image rospy.ERROR() TypeError: 'int' object is not callable. Anh cho em hỏi làm thế nào để fix ạ, em cảm ơn

[Trinh Nguyen](https://hashnode.com/@TrinhNC)

[Nov 29, 2023](https://hashnode.com/posts/tao-ros-publisher/63b748774d6da3dbcf4351c4/comment/65631726585e979b362f291e#reply-656788eb5d000a04d6827a33)

Có vẻ như ko tìm được nguồn video. Em check lại kết nối với camera xem.
