annotate doc/NANP-specifics @ 268:d6630a2d6e80

doc: beginning of numbering plan documentation
author Mychaela Falconia <falcon@freecalypso.org>
date Mon, 13 Nov 2023 18:20:57 -0800
parents
children b54fa3e4d81f
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
268
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 North American Numbering Plan (NANP) specifics in ThemWi system sw
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 ==================================================================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 Themyscira Wireless system software, as currently written, is strongly tied to
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 NANP. More precisely, it thoroughly assumes that all local phone numbers are
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 in +1 country code and follow NANP rules, and that all E.164 telephone numbers
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 in country codes other than +1 are foreign - numbers which we can call and
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 receive calls from, but which can never be local to us.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 Why does our software need to have these assumptions baked into it, why can't
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 it be country-agnostic? The present article answers this question, and this
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 long answer needs to be thoroughly understood before there can be any meaningful
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 discussion of how the software could possibly be adapted to other countries and
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 their respective telephone numbering plans.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 In principle, there exists a standardized dialing format on all GSM phones that
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 remains the same no matter which country you happen to be in. If you always
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 enter phone numbers (dialing, SMS manual entry, phone book entries) in full
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 international format beginning with the '+' symbol (press and hold the '0'
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 button before the number in most phone UIs), the phone handset firmware will
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 capture the number with TON=1, NPI=1 attributes (signifying international number
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 format in GSM call control and SMS protocols) and transmit it as such to the
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 GSM network. Every properly designed GSM network, upon seeing a number with
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 these TON=1, NPI=1 attributes, must address the call or message to the country
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 indicated by the country code at the beginning of the full E.164 number, whether
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 that country is your local one or some other. Thus if everyone were to always
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 use only full E.164 numbers in full international format, network software could
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 hypothetically be written in a country-agnostic way, treating full E.164 phone
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 numbers as opaque strings without parsing. However, there are two practical
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 problems with such country-agnostic approach:
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 1) Most human users of mobile phones dial local phone numbers (within their own
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 country) in a way that follows local dialing conventions, rather than in
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 international format beginning with '+' and their own country code. For
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 example, in USA a given 10-digit NANP phone number can be dialed as just the
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 10 digits NPANXXXXXX, as 11-digit 1NPANXXXXXX, or as full international
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 +1NPANXXXXXX - and a proper cellphone network MUST accept all 3 formats as
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 equivalent.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 2) As explained further in this article, a network implementation must be able
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 to look at a telephone number and immediately tell if that number is locally
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 owned ("one of ours") or belongs somewhere outside of the local GSM network.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 Practical implementation of this distinction requires a database of locally
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 owned phone numbers, and the implementation of that database in turn becomes
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 much easier when the local numbering plan is known and fixed.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 Supported dialing formats in ThemWi
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 ===================================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 When themwi-mncc processes a mobile-originated (MO) call from a GSM subscriber,
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 it supports dialing the following classes of numbers:
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 * NANP numbers in any of the 3 standard dialing formats;
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55 * International numbers in any country - an international number beginning
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 with +1 is enforced to be valid NANP, but E.164 numbers in all other country
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 codes are accepted as-is;
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 * Local 4-digit numbers described in (to-be-written) Local-short-numbers
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60 article;
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 * Whatever special numbers are configured in themwi-sip-out, such as 511 and
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 911.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 Only NANP numbers and specially configured 4-digit numbers (see
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 Local-short-numbers) can be local - all E.164 numbers in non-NANP country codes
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 are sent to the outbound call gateway, and all other unrecognized number formats
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 are likewise sent to themwi-sip-out so that the latter process can catch and map
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 special numbers like 511, 911 etc.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 If a dialed number is recognized as NANP, themwi-mncc looks in the database of
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 locally owned numbers to see if the dialed number is one of ours - and the
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 outcome of this look-up determines if the call is handled locally or sent to
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 the outside world via themwi-sip-out.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 No 7-digit dialing support
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 ==========================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 In the olden days of land lines, most localities in USA supported 7-digit
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 dialing: to call Jenny, you would merely dial her local 7-digit number 867-5309,
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 without needing to dial the local area code; full 10-digit numbers (or 11 digits
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82 with leading '1') had to be dialed only when calling someone in a different
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 area code from your own. However, this 7-digit dialing has now been disabled
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 even for land lines in most localities, including the locality where ThemWi
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 currently operates: per official rules, 7-digit dialing gets disabled (full
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 10-digit numbers become mandatory) whenever an area code overlay is implemented,
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87 such as overlay of 760 and 442 area codes in our locality.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89 In the case of mobile phones, 7-digit dialing never made much sense to begin
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 with: if you dial only 7 digits, should the implicit area code be taken from
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 your own number, or should it be the area code of the locality you happen to be
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 traveling through at the moment? The latter option is impossible in the case
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 of localities with two or more overlaid NPA codes, and it appears that official
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94 rules once again call for simply disabling 7-digit dialing.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 Based on these considerations, ThemWi system sw was written from the outset to
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97 not support 7-digit dialing - it is no longer relevant in the current state of
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 telecom culture in USA. We do, however. provide optional support for
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99 abbreviated 4-digit local numbers - see (to-be-written) Local-short-numbers
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 article.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 Database of locally owned numbers
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103 =================================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105 The telecom culture in USA features full number portability - end users can take
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 their phone numbers with them anywhere, from one telecom provider to another,
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 and with mobile phones and VoIP services, from one geographic locality to any
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 other, making the entire country effectively "flat" for local/non-local
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 distinction purposes. Therefore, the set of phone numbers "owned" (or rented
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 in reality) by a small network operator such as Themyscira Wireless does not
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111 constitute any kind of clean-cut digit range partition in the numbering plan -
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 instead we can have a small set of locally owned numbers (say, on the order of
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113 5 to 20 individual numbers), and each of these locally owned numbers can fall
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 anywhere in the whole nationwide 10-digit numbering plan. So how can we tell,
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 by looking at an arbitrary NANP number, whether it is "one of ours" or not?
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117 The implemented solution is an explicitly maintained database of locally owned
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 phone numbers, described in detail in (to-be-written) Number-database article.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 The format of this database (the way numbers are entered, the way the input
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 format is parsed, and the compiled binary format used for fast look-ups) is
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121 specific to NANP - only NANP numbers can be local in the present design.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123 Porting to other national telephone numbering plans
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 ===================================================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 If someone wishes to port ThemWi system sw for use in other countries with
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 respective local phone numbers, the following aspects will need to be changed:
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129 * Based on the structure of your country's national numbering plan, you will
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 need to come up with an appropriate local number database format for your
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131 country, or if the range of numbers belonging to your GSM network forms a
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132 clean-cut digit range partition, implement that scheme instead.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134 * You will need to modify MO call handling to recognize your country code
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135 (rather than +1) as the one calling for parsing and closer scrutiny of the
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136 dialed number, determining if it is local or not.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
138 * Handling of non-international dialing formats (numbers dialed without '+')
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 will need to be changed to whatever is appropriate for your country's telecom
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140 culture and customs.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 * Handle all secondary fallout (throughout the code base) from the previous
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143 essential and necessary changes.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
145 Using fake NANP numbers
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
146 =======================
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
147
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
148 If someone outside of North America wishes to merely play with ThemWi system sw
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
149 on a casual basis, without actually interconnecting to your non-USA PSTN with
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150 non-NANP real phone numbers, the easiest way to bring the software up is to use
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
151 fake NANP numbers. There are two types of guaranteed-fake (can't collide with
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152 real ones) phone numbers in NANP:
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 1) NPA-555-01XX, where NPA is some real area code for some (any) actual locality
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 in USA and XX can be any two digits. This number range is specifically set
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 aside for use in movies etc, with realistic USA settings - the area code can
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
157 be any real one, but 555-01XX numbers are reserved for fake use in every
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
158 area code.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 2) Fake area codes of form N9X (290-299, 390-399, ..., 990-999) are also good
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161 for guaranteed-fake numbers as the middle digit of NPA is not allowed to be
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 '9' per official NANP rules. This method allows large ranges of fake NANP
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
163 numbers.
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
164
d6630a2d6e80 doc: beginning of numbering plan documentation
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
165 See Fake-NANP-numbers article (to be written) for more info.