author | zecke <zecke> | 2002-10-24 20:43:25 (UTC) |
---|---|---|
committer | zecke <zecke> | 2002-10-24 20:43:25 (UTC) |
commit | 81a2bb8073b95d438911a62a7f4d8244ef58e20a (patch) (unidiff) | |
tree | 2521c88de626caf818b715776934da204d6b0f8f /noncore/apps/opie-console/io_modem.cpp | |
parent | 0fc598a0ee9151f82f5a78383645a758d5f6cad9 (diff) | |
download | opie-81a2bb8073b95d438911a62a7f4d8244ef58e20a.zip opie-81a2bb8073b95d438911a62a7f4d8244ef58e20a.tar.gz opie-81a2bb8073b95d438911a62a7f4d8244ef58e20a.tar.bz2 |
Modem is now working
Kindly called from Germany to Switzerland
via rfcomm( affix) + Nokia6210 + Vodafone...
But now it's working
might be a hangup problem somewhere
Diffstat (limited to 'noncore/apps/opie-console/io_modem.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/io_modem.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/noncore/apps/opie-console/io_modem.cpp b/noncore/apps/opie-console/io_modem.cpp index b7901b9..896c24f 100644 --- a/noncore/apps/opie-console/io_modem.cpp +++ b/noncore/apps/opie-console/io_modem.cpp | |||
@@ -1,47 +1,49 @@ | |||
1 | 1 | ||
2 | #include "io_modem.h" | 2 | #include "io_modem.h" |
3 | 3 | ||
4 | #include "dialer.h" | 4 | #include "dialer.h" |
5 | 5 | ||
6 | IOModem::IOModem( const Profile &profile ) | 6 | IOModem::IOModem( const Profile &profile ) |
7 | : IOSerial( profile ) { | 7 | : IOSerial( profile ) { |
8 | m_profile = profile; | 8 | m_profile = profile; |
9 | } | 9 | } |
10 | 10 | ||
11 | 11 | ||
12 | IOModem::~IOModem() { | 12 | IOModem::~IOModem() { |
13 | 13 | ||
14 | } | 14 | } |
15 | 15 | ||
16 | 16 | ||
17 | void IOModem::close() { | 17 | void IOModem::close() { |
18 | // Hangup, discarding result | 18 | // Hangup, discarding result |
19 | int fd = rawIO(); | 19 | //int fd = rawIO(); |
20 | Dialer d(m_profile, fd); | 20 | internDetach(); |
21 | Dialer d(m_profile, m_fd); | ||
21 | d.setHangupOnly(); | 22 | d.setHangupOnly(); |
22 | d.exec(); | 23 | //d.exec(); |
23 | closeRawIO(fd); | 24 | internAttach(); |
25 | //closeRawIO(fd); | ||
24 | 26 | ||
25 | IOSerial::close(); | 27 | IOSerial::close(); |
26 | } | 28 | } |
27 | 29 | ||
28 | bool IOModem::open() { | 30 | bool IOModem::open() { |
29 | bool ret = IOSerial::open(); | 31 | bool ret = IOSerial::open(); |
30 | if(!ret) return false; | 32 | if(!ret) return false; |
31 | 33 | ||
32 | //int fd = rawIO(); | 34 | //int fd = rawIO(); |
33 | internDetach(); | 35 | internDetach(); |
34 | Dialer d(m_profile, m_fd); | 36 | Dialer d(m_profile, m_fd); |
35 | 37 | ||
36 | int result = d.exec(); | 38 | int result = d.exec(); |
37 | internAttach(); | 39 | internAttach(); |
38 | //closeRawIO(fd); | 40 | //closeRawIO(fd); |
39 | if(result == QDialog::Accepted) | 41 | if(result == QDialog::Accepted) |
40 | { | 42 | { |
41 | return true; | 43 | return true; |
42 | } | 44 | } |
43 | else | 45 | else |
44 | { | 46 | { |
45 | close(); | 47 | close(); |
46 | return false; | 48 | return false; |
47 | } | 49 | } |