This paper proposes an adaptive MAC (CBA-MAC) protocol for clustering based wireless sensor networks. In CBA-MAC, sensor nodes are divided into cluster head node and normal node. Cluster head node collects traffic information from normal nodes and calculates appropriate duty cycle according to current traffic, then broadcasts duty cycle information to normal nodes, so sensor nodes can fit for variable traffic occasions well. Furthermore, a proper sleep scheme is also proposed for energy saving consideration. We have implemented CBAMAC in ns-2, and the simulation results show that the energy consumption and latency is reduced well.