removed sleep statement because of Windows troubles. This code will have
to go eventually, anyway.