Added HD3 support and corrected some warnings