summaryrefslogtreecommitdiff
authorerik <erik>2007-02-08 21:33:21 (UTC)
committer erik <erik>2007-02-08 21:33:21 (UTC)
commit63f64a9733d5504bb04d5f06cdf52b42a4b8006c (patch) (side-by-side diff)
tree7101166c3fac37e2ff1fd1ce3b52bb61b9f618c9
parent41dce553a418765d5075fc249c636104a2a82329 (diff)
downloadopie-63f64a9733d5504bb04d5f06cdf52b42a4b8006c.zip
opie-63f64a9733d5504bb04d5f06cdf52b42a4b8006c.tar.gz
opie-63f64a9733d5504bb04d5f06cdf52b42a4b8006c.tar.bz2
Commit of GoXbox Live HTC Universal patch. This should make backlight
work with current kernel versions. It also changes the mixer name to the rightful name for most modern kernels. It is rumored that the mixer in most HTC devices does not work. But at least it points at the right device now. Thanks GoXbox Live!
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiecore/device/odevice_htc.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/libopie2/opiecore/device/odevice_htc.cpp b/libopie2/opiecore/device/odevice_htc.cpp
index 4e5200b..a6ade11 100644
--- a/libopie2/opiecore/device/odevice_htc.cpp
+++ b/libopie2/opiecore/device/odevice_htc.cpp
@@ -165,56 +165,56 @@ void HTC::init(const QString& cpu_info)
d->m_modelstr = "HTC Beetles";
}
if ( model == "HTC Blueangel" ) {
d->m_model = Model_HTC_Blueangel;
d->m_modelstr = "HTC Blueangel";
}
if ( model == "HTC Himalaya" ) {
d->m_model = Model_HTC_Himalaya;
d->m_modelstr = "HTC Himalaya";
}
if ( model == "HTC Magician" ) {
d->m_model = Model_HTC_Magician;
d->m_modelstr = "HTC Magician";
}
// set path to backlight device
switch ( d->m_model )
{
case Model_HTC_Universal:
case Model_HTC_Magician:
case Model_HTC_Alpine:
case Model_HTC_Beetles:
case Model_HTC_Apache:
- m_backlightdev = "/sys/class/backlight/pxa2xx-fb/";
+ m_backlightdev = "/sys/class/backlight/corgi-bl/";
break;
case Model_HTC_Blueangel:
case Model_HTC_Himalaya:
m_backlightdev = "/sys/class/backlight/w100fb/";
break;
default:
- m_backlightdev = "/sys/class/backlight/pxafb/";
+ m_backlightdev = "/sys/class/backlight/corgi-bl/";
}
// set initial rotation
switch( d->m_model )
{
case Model_HTC_Universal:
initHingeSensor();
d->m_rotation = rotation();
d->m_direction = direction();
break;
default:
d->m_rotation = Rot270;
}
// set default qte driver
switch( d->m_model )
{
default:
d->m_qteDriver = "Transformed";
}
m_leds[0] = Led_Off;
qDebug( "HTC::init() - Using the 2.6 Xanadux on a %s", (const char*) d->m_modelstr );
@@ -279,49 +279,49 @@ void HTC::buzzer( int sound )
switch ( sound ){
case SHARP_BUZ_TOUCHSOUND: {
static Sound touch_sound("touchsound");
snd = &touch_sound;
}
break;
case SHARP_BUZ_KEYSOUND: {
static Sound key_sound( "keysound" );
snd = &key_sound;
}
break;
case SHARP_BUZ_SCHEDULE_ALARM:
default: {
static Sound alarm_sound("alarm");
snd = &alarm_sound;
}
break;
}
}
// If a soundname is defined, we expect that this device has
// sound capabilities.. Otherwise we expect to have the buzzer
// device..
if ( snd && snd->isFinished() ){
- changeMixerForAlarm( 0, "/dev/sound/mixer", snd );
+ changeMixerForAlarm( 0, "/dev/mixer", snd );
snd->play();
} else if( !snd ) {
int fd = ::open ( "/dev/sharp_buz", O_WRONLY|O_NONBLOCK );
if ( fd >= 0 ) {
::ioctl ( fd, SHARP_BUZZER_MAKESOUND, sound );
::close ( fd );
}
}
#endif
}
void HTC::playAlarmSound()
{
buzzer( SHARP_BUZ_SCHEDULE_ALARM );
}
void HTC::playTouchSound()
{
buzzer( SHARP_BUZ_TOUCHSOUND );
}