-rw-r--r-- | libopie/odevice.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libopie/odevice.cpp b/libopie/odevice.cpp index 9871e80..3bc1e0c 100644 --- a/libopie/odevice.cpp +++ b/libopie/odevice.cpp | |||
@@ -540,30 +540,38 @@ void ODeviceZaurus::init ( ) | |||
540 | d-> m_modelstr = "Zaurus SL5000"; | 540 | d-> m_modelstr = "Zaurus SL5000"; |
541 | d-> m_model = OMODEL_Zaurus_SL5000; | 541 | d-> m_model = OMODEL_Zaurus_SL5000; |
542 | d-> m_vendorstr = "Sharp"; | 542 | d-> m_vendorstr = "Sharp"; |
543 | d-> m_vendor = OVENDOR_Sharp; | 543 | d-> m_vendor = OVENDOR_Sharp; |
544 | 544 | ||
545 | QFile f ( "/proc/filesystems" ); | 545 | QFile f ( "/proc/filesystems" ); |
546 | 546 | ||
547 | if ( f. open ( IO_ReadOnly ) && ( QTextStream ( &f ). read ( ). find ( "\tjffs2\n" ) >= 0 )) { | 547 | if ( f. open ( IO_ReadOnly ) && ( QTextStream ( &f ). read ( ). find ( "\tjffs2\n" ) >= 0 )) { |
548 | d-> m_systemstr = "OpenZaurus"; | 548 | d-> m_systemstr = "OpenZaurus"; |
549 | d-> m_system = OSYSTEM_OpenZaurus; | 549 | d-> m_system = OSYSTEM_OpenZaurus; |
550 | 550 | ||
551 | f. close ( ); | 551 | f. close ( ); |
552 | |||
553 | f. setName ( "/etc/oz_version" ); | ||
554 | if ( f. open ( IO_ReadOnly )) { | ||
555 | QTextStream ts ( &f ); | ||
556 | d-> m_sysverstr = ts. readLine ( ). mid ( 10 ); | ||
557 | f. close ( ); | ||
558 | } | ||
552 | } | 559 | } |
553 | else { | 560 | else { |
554 | d-> m_systemstr = "Zaurus"; | 561 | d-> m_systemstr = "Zaurus"; |
555 | d-> m_system = OSYSTEM_Zaurus; | 562 | d-> m_system = OSYSTEM_Zaurus; |
556 | } | 563 | } |
557 | 564 | ||
565 | |||
558 | d-> m_leds [0] = OLED_Off; | 566 | d-> m_leds [0] = OLED_Off; |
559 | } | 567 | } |
560 | 568 | ||
561 | #include <unistd.h> | 569 | #include <unistd.h> |
562 | #include <fcntl.h> | 570 | #include <fcntl.h> |
563 | #include <sys/ioctl.h> | 571 | #include <sys/ioctl.h> |
564 | 572 | ||
565 | //#include <asm/sharp_char.h> // including kernel headers is evil ... | 573 | //#include <asm/sharp_char.h> // including kernel headers is evil ... |
566 | 574 | ||
567 | #define SHARP_DEV_IOCTL_COMMAND_START 0x5680 | 575 | #define SHARP_DEV_IOCTL_COMMAND_START 0x5680 |
568 | 576 | ||
569 | #defineSHARP_BUZZER_IOCTL_START (SHARP_DEV_IOCTL_COMMAND_START) | 577 | #defineSHARP_BUZZER_IOCTL_START (SHARP_DEV_IOCTL_COMMAND_START) |