From 2a89e7d1226f0a01025b5cbcb0470b6280d29257 Mon Sep 17 00:00:00 2001 From: Jens Arnold Date: Sat, 20 Nov 2004 00:15:12 +0000 Subject: New players: switch on the HD in ata_init() git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5443 a1c6a512-1295-4272-9138-f99709370657 --- firmware/drivers/ata.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'firmware') diff --git a/firmware/drivers/ata.c b/firmware/drivers/ata.c index 60b6a87488..40d3da2f98 100644 --- a/firmware/drivers/ata.c +++ b/firmware/drivers/ata.c @@ -1131,6 +1131,15 @@ int ata_init(void) or_b(0x02, &PAIORH); /* output for ATA reset */ or_b(0x02, &PADRH); /* release ATA reset */ PACR2 &= 0xBFFF; /* GPIO function for PA7 (IDE enable) */ + +#ifdef HAVE_LCD_CHARCELLS + if (read_rom_version() > 451) /* new player: power on the HD */ + { + PBCR2 &= ~0x0300; /* Set PB4 (IDE power) to GPIO */ + or_b(0x10, &PBDRL); /* ... high */ + or_b(0x10, &PBIORL); /* ... and output */ + } +#endif #elif defined HAVE_SCF5249 #endif -- cgit v1.2.3