Variable Sample & Xmit Periods

Added code to allow for variable sample periods and xmit periods.