A framework for modeling wireless embedded control systems