author | kergoth <kergoth> | 2002-12-12 00:36:20 (UTC) |
---|---|---|
committer | kergoth <kergoth> | 2002-12-12 00:36:20 (UTC) |
commit | 830a9a484064e0703e7e4e98714e415f5896068c (patch) (side-by-side diff) | |
tree | d464d8b5b8d89102e47edb255286d492529581b4 /libopie | |
parent | cb783a8ddbeb6c85481c5b1a807f21be83817255 (diff) | |
download | opie-830a9a484064e0703e7e4e98714e415f5896068c.zip opie-830a9a484064e0703e7e4e98714e415f5896068c.tar.gz opie-830a9a484064e0703e7e4e98714e415f5896068c.tar.bz2 |
Set vendor to OpenZaurus Team on OZ roms
-rw-r--r-- | libopie/odevice.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libopie/odevice.cpp b/libopie/odevice.cpp index a33d4ad..9fd3ae2 100644 --- a/libopie/odevice.cpp +++ b/libopie/odevice.cpp @@ -675,96 +675,97 @@ bool iPAQ::hasLightSensor ( ) const { return true; } int iPAQ::readLightSensor ( ) { int fd; int val = -1; if (( fd = ::open ( "/proc/hal/light_sensor", O_RDONLY )) >= 0 ) { char buffer [8]; if ( ::read ( fd, buffer, 5 ) == 5 ) { char *endptr; buffer [4] = 0; val = ::strtol ( buffer + 2, &endptr, 16 ); if ( *endptr != 0 ) val = -1; } ::close ( fd ); } return val; } int iPAQ::lightSensorResolution ( ) const { return 256; } /************************************************** * * Zaurus * **************************************************/ void Zaurus::init ( ) { d-> m_vendorstr = "Sharp"; d-> m_vendor = Vendor_Sharp; QFile f ( "/proc/filesystems" ); if ( f. open ( IO_ReadOnly ) && ( QTextStream ( &f ). read ( ). find ( "\tjffs2\n" ) >= 0 )) { + d-> m_vendorstr = "OpenZaurus Team"; d-> m_systemstr = "OpenZaurus"; d-> m_system = System_OpenZaurus; f. close ( ); f. setName ( "/etc/oz_version" ); if ( f. open ( IO_ReadOnly )) { QTextStream ts ( &f ); d-> m_sysverstr = ts. readLine ( );//. mid ( 10 ); f. close ( ); } } else { d-> m_systemstr = "Zaurus"; d-> m_system = System_Zaurus; } f. setName ( "/proc/deviceinfo/product" ); if ( f. open ( IO_ReadOnly ) ) { QTextStream ts ( &f ); QString model = ts. readLine ( ); f. close ( ); if ( model == "SL-5000D" ) { d-> m_model = Model_Zaurus_SL5000; d-> m_modelstr = "Zaurus SL-5000D"; } else if ( model == "SL-5500" ) { d-> m_model = Model_Zaurus_SL5500; d-> m_modelstr = "Zaurus SL-5500"; } } else { d-> m_model = Model_Zaurus_SL5000; d-> m_modelstr = "Zaurus SL-5000D (unverified)"; } m_leds [0] = Led_Off; } #include <unistd.h> #include <fcntl.h> #include <sys/ioctl.h> //#include <asm/sharp_char.h> // including kernel headers is evil ... #define SHARP_DEV_IOCTL_COMMAND_START 0x5680 #define SHARP_BUZZER_IOCTL_START (SHARP_DEV_IOCTL_COMMAND_START) #define SHARP_BUZZER_MAKESOUND (SHARP_BUZZER_IOCTL_START) |