Protocol Design for Machine-to-Machine Networks