SLAM (Simultaneous Localization and Mapping) is a key technique in robotics, which finds its application in diverse fields such as autonomous driving, exploration, and augmented and virtual reality. To utilize SLAM for various applications and environments, different types of sensors or devices must be considered. In particular, for augmented and virtual reality applications, it is necessary to operate on mobile devices such as smartphones and tablet PCs. Therefore, we propose a SLAM algorithm for mobile devices that can estimate the pose of a mobile device in real-time. This algorithm utilizes point and line features together for good performance in indoor environments. Furthermore, since the proposed algorithm enables the saving of a pose graph, the user can obtain a map of a given environment and localize the pose based on the obtained map. The algorithm has been tested on Android mobile devices, and the results indicate that the proposed algorithm works effectively in various environments.