Implemented discovery

The discovery is almost done ,-)