Embedded software to control 2G/3G modem and handle IO