1.1 --- a/src/aica/aica.c Tue Mar 14 12:45:53 2006 +0000
1.2 +++ b/src/aica/aica.c Thu Mar 30 11:27:11 2006 +0000
1.5 - * $Id: aica.c,v 1.17 2006-03-14 12:45:53 nkeynes Exp $
1.6 + * $Id: aica.c,v 1.18 2006-03-30 11:27:11 nkeynes Exp $
1.8 * This is the core sound system (ie the bit which does the actual work)
1.12 #define MODULE aica_module
1.16 #include "dreamcast.h"
1.18 @@ -219,6 +220,30 @@
1.22 +/* 20 years in seconds */
1.23 +#define RTC_OFFSET 631152000
1.25 +int32_t mmio_region_AICARTC_read( uint32_t reg )
1.27 + struct timeval tv;
1.31 + if( gettimeofday( &tv, NULL ) == 0 ) {
1.32 + return ((uint32_t)(tv.tv_sec + RTC_OFFSET)) >> 16;
1.36 + if( gettimeofday( &tv, NULL ) == 0 ) {
1.37 + return ((uint32_t)(tv.tv_sec + RTC_OFFSET)) & 0xFFFF;
1.44 +MMIO_REGION_WRITE_STUBFN( AICARTC )
1.47 * Translate the channel frequency to a sample rate. The frequency is a
1.48 * 14-bit floating point number, where bits 0..9 is the mantissa,