In order to drive AGVs autonomously, an AGV must interpret peripheral AGVs' behavior to avoid collisions with them by itself. Knowledge of this interpretation through AGVs' experience is so called a communication protocol. This paper presents the new method to acquire the communication protocol between the AGVs by machine learning. Q-learning is adopted as machine learning. Once the AGVs acquire the communication protocol, they can autonomously move such that they avoid collision between the AGVs when they meet each other, and collaborate with their velocity between themselves when they drive in the same direction. Numerical experiments are performed to verify that the proposed method brings the AGVs to acquire the proper communication protocol and that the acquired protocol instructs the proper behavior to the AGVs.