Text this: Procedure for Selecting a Transmission Mode Dependent on the State-of-Charge and State-of-Health of a Lithium-ion Battery in Wireless Sensor Networks with Energy Harvesting Devices