/[gnokii]/gnokii/Docs/gnokii-IrDA-Linux
ViewVC logotype

Contents of /gnokii/Docs/gnokii-IrDA-Linux

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Fri Sep 12 10:51:44 2003 UTC (20 years, 7 months ago) by bozo
Branch: MAIN
CVS Tags: rel_0_6_17, reg_0_6_24, rel_0_5_10, rel_0_6_22, rel_0_6_23, rel_0_6_20, rel_0_6_21, rel_0_6_26, rel_0_6_27, rel_0_6_25, rel_0_5_4, rel_0_5_8, rel_0_5_6, rel_0_5_7, rel_0_5_9, rel_0_5_5, rel_0_6_3, rel_0_6_2, rel_0_6_1, rel_0_6_0, rel_0_6_7, rel_0_6_6, rel_0_6_5, rel_0_6_4, rel_0_6_9, rel_0_6_8, rel_0_6_19, rel_0_6_18, rel_0_6_13, rel_0_6_12, rel_0_6_11, rel_0_6_10, rel_0_6_16, rel_0_6_15, rel_0_6_14, rel_0_5_3, HEAD
Branch point for: devel_0_7
Changes since 1.3: +13 -0 lines
documentation updates

1 Getting gnokii to work with a modern phone over IrDA under linux
2 ================================================================
3
4 The following guide explains how to get a modern phone like a nokia 7110,
5 nokia 6210, siemens s25, ericsson t39 etc to work with gnokii. The guide
6 is divided into 3 parts: kernel configuration and setup, checking the
7 connection and gnokii configuration.
8
9 This guide is not for nokia 6110/6150. See gnokii-ir-howto instead.
10
11 Part 1 Kernel configuration and setup
12 =====================================
13
14 - Compile your kernel with IrDA support for your chipset.
15
16 For me on my VAIO this was:
17 CONFIG_IRDA=m
18 CONFIG_IRCOMM=m
19 CONFIG_IRDA_OPTIONS=y
20 CONFIG_IRDA_DEBUG=y
21
22 CONFIG_IRTTY_SIR=m
23 Use the emulation of serial port part of your IrDA chipset or...
24 CONFIG_NSC_FIR=m
25 Specify the one you have (I have a NSC 87338)
26
27 - Reboot onto new kernel etc.
28 - Check your serial devices don't conflict with the ioport/irq that your
29 chipset driver will try to use:
30 setserial /dev/ttySX (where X is 0 -> 3) should give you the information
31 you need.
32 If you have a device that conflicts with your ioport/irq then you will
33 need to remove the serial driver's control over it with:
34 setserial /dev/ttySX uart none port 0 irq 0
35 (where X is there relevant port mine is /dev/ttyS2)
36 - I used the chipset way to get IrDA working.
37 I needed:
38 options nsc-ircc dongle_id=0x09
39 alias irda0 nsc-ircc
40 in /etc/modules.conf
41 Then just irattach irda0 -s 1 which *should* load all the modules you need
42 and start it doing irda discovery.
43 The modules I have loaded at this point are: nsc-ircc and irda.
44
45 Part 2 Checking the connection
46 ==============================
47
48 On some distributions irdadump is broken and segfaults. If this happens
49 skip the next two steps and go to discovery.
50
51 - Run irdadump to see that it is indeed attempting to discover something.
52 You should see messages like:
53 15:24:07.380360 xid:cmd 0c57083d > ffffffff S=6 s=0 (14)
54 15:24:07.470333 xid:cmd 0c57083d > ffffffff S=6 s=1 (14)
55 15:24:07.560310 xid:cmd 0c57083d > ffffffff S=6 s=2 (14)
56 15:24:07.650283 xid:cmd 0c57083d > ffffffff S=6 s=3 (14)
57 15:24:07.740279 xid:cmd 0c57083d > ffffffff S=6 s=4 (14)
58 15:24:07.830279 xid:cmd 0c57083d > ffffffff S=6 s=5 (14)
59 15:24:07.920311 xid:cmd 0c57083d > ffffffff S=6 s=* langly hint=0400 [ Computer
60 ] (22)
61 - Place the phone in front of it, enable the Infrared parts of it (Menu 90)
62 then it should change to be like:
63 15:26:07.380336 xid:cmd 0c57083d > ffffffff S=6 s=0 (14)
64 15:26:07.470288 xid:cmd 0c57083d > ffffffff S=6 s=1 (14)
65 15:26:07.560284 xid:cmd 0c57083d > ffffffff S=6 s=2 (14)
66 15:26:07.650281 xid:cmd 0c57083d > ffffffff S=6 s=3 (14)
67 15:26:07.740280 xid:cmd 0c57083d > ffffffff S=6 s=4 (14)
68 15:26:07.847192 xid:rsp 0c57083d < d10e0000 S=6 s=4 Nokia 6210 hint=b125 [ PnP Modem Fax Telephony IrCOMM IrOBEX ] (27)
69 15:26:07.830293 xid:cmd 0c57083d > ffffffff S=6 s=5 (14)
70 15:26:07.920283 xid:cmd 0c57083d > ffffffff S=6 s=* langly hint=0400 [ Computer
71 ] (22)
72 - With the phone still in front of your infrared port, check if the discovery
73 of the infrared port works. Do a
74 bash-2.03$ cat /proc/net/irda/discovery
75
76 a response could be:
77
78 IrLMP: Discovery log:
79
80 nickname: T39, hint: 0x9124, saddr: 0xe4fe8166, daddr: 0x48611661
81
82 If this doesn't work try if discovery is on:
83 bash-2.03$ cat /proc/sys/net/irda/discovery
84 this should give:
85 1
86 if it returns:
87 0
88 check if irattach is running:
89 bash-2.03$ ps aux|grep iratt
90 a possible return is:
91 root 271 0.0 0.0 1288 192 ? S 20:49 0:00 irattach /dev/ttyS1
92 if you don't see the irattach process, go back to kernel configuration.
93 - Now try using ircomm to talk to the phone. Try minicom /dev/ircomm0 (you
94 may need to setup a default profile for this port as the root user with
95 minicom -s /dev/ircomm0).
96 - This depends on your distribution having the right lines in modules.conf
97 for ircomm to be loaded:
98 alias tty-ldisc-11 irtty
99 alias char-major-160 irda0
100 alias char-major-161 ircomm-tty
101 And your /dev/ircomm0 should be character device 161,0.
102 Debian testing/unstable gets this right.
103 If these don't work you may need to load ircomm and ircomm-tty manually.
104 - minicom /dev/ircomm0 should now work and AT commands should function.
105 simply type the following in the terminal program:
106 AT<CR>
107 you get the response:
108 OK
109 - If minicom blocks, try a different terminal program. On my box minicom works
110 perfect with a serial cable but not with IrDA. seyon works with both, cable
111 and IrDA.
112
113 Part 3 gnokii configuration
114 ===========================
115
116 Depending on your phone, you need to set some gnokii options. for a nokia 6210
117 or a nokia 7110 you would set (at least) the following in .gnokiirc:
118 [global]
119 port = /dev/ircomm0
120 model = 6210
121 connection = irda
122 For a siemens or a ericsson phone or any phone which supports the AT command
123 set directly, the following should work. Please pay attention to connection
124 which is set to "serial" instead of "irda":
125 [global]
126 port = /dev/ircomm0
127 model = AT
128 connection = serial
129 gnokii --monitor should now function.
130
131 [huggie@langly ~]$ gnokii --monitor
132 Entering monitor mode...
133 RFLevel: 100
134 Battery: 100
135 SIM: Used 5, Free 85
136 etc.
137
138 Not all the functions for 6210 work yet seemingly.
139
140 - If instead gnokii hangs then you may have a version of gnokii that still
141 has recv() in irda_open of common/devices/unixirda.c. Just comment out
142 that line, recompile and try again.
143
144 Possible problems
145 =================
146
147 - If you are absolutly sure you set up everything fine, you are using a
148 FIR driver, your phone can be seen in the discovery log but you are not
149 able to use either minicom or gnokii it can be a speed negotiation
150 problem between your IrDA stack and your phone. Probably the reason is
151 that the FIR driver and your phone support faster communication than
152 115200 baud and they manage to negotiate a speed which one of the parties
153 cannot handle correctly. Try to limit the negotiated speed to 115200 baud:
154
155 echo 115200 > /proc/sys/net/irda/max_baud_rate
156
157
158 Credits
159 =======
160
161 Initial version by:
162 Simon Huggins <huggie-gnokii@earth.li>
163 small enhancements by:
164 Manfred Jonsson <manfred.jonsson@gmx.de>

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26