Mapping opaque and confined environments such as caves and pipes is a challenging problem for mobile robots because sensor information is severely limited to the immediate proximity of the robot due to the extreme environmental conditions. The robot must also be flexible and agile in unstructured environments while still providing accurate pose estimation. This paper presents a solution to mapping a 2-dimensional tube by using only a snake robot's proprioceptive joint angle sensors. We assume that the tube is sufficiently smooth and that we know the tube width. We propose techniques for (1) pose estimation of a snake robot by using a self-posture motion model, (2) correcting error in pose estimation using only the snake's internal configuration over time, and (3) building environmental features using only self-occupancy and contact detection. Our goal is to use the minimal amount of sensor information possible to build an accurate spatial map of the environment. We have teste...