In this paper, we are interested in path optimization for robotic communication operations in obstacle environments. Consider a robot that needs to perform a given communication task (e.g., data uploading, broadcasting, or relaying) while navigating from a start position to a designated final position, avoiding obstacles, and minimizing its total motion and communication costs. Our goal is to develop a general path planning algorithm applicable to various robotic communication scenarios in which a robot operates in realistic channel fading environments and in the presence of obstacles. We show how we can adapt the traditional Rapidly-Exploring Random Tree Search Star (RRT*) path planning algorithm to jointly consider both communication and motion objectives in realistic channel environments that contain obstacles. We further show that our proposed approach can provide theoretical optimality guarantees while being computationally efficient. We extensively evaluate our proposed approach in realistic wireless channel environments for various transmission settings and communication tasks. The results demonstrate the efficacy of our proposed approach.