Worked on reading number of devices from file