Added basic timeout handling; not tested for RTU