Brain Machine Interfaces (BMI) combined with lower-limb exoskeletons can assist patients that have difficulties in walking. However, BMI need some calibration to adjust their parameters to each user. This process is time-consuming and can be fatiguing for the users. In this work, the optimal number of recordings needed to adjust a EEG-based BMI to distinguish between MI of gait and rest state has been studied based on three subjects. The results show that the BMI reaches its highest accuracy with 5 recordings.