The interaction between Ricci scalar curvature and the baryon number current, dynamically breaks CPT in an expanding universe and leads to baryon asymmetry. Using this kind of interaction and study the gravitational baryogenesis in the Bianchi type I universe. We find out the effect of anisotropy of the universe on the baryon asymmetry for the case which the equation of state parameter, $\omega$, is dependent to time.