HOW TO GET SIM CARD NUMBER

Hello. How to get the SIM card number on the device wAP LTE, without using USSD command.

/interface lte info 0 once

the look for the uicc

:put ([ / interface lte info [ :pick [ find ] 0 ] once as-value ]->"uicc")

device info: RouterBOARD wAP R-2nD, 6.42.9 (long-term)

[/interface lte info 0 once] command result:
pin-status: no password required
functionality: full
manufacturer: “MikroTik”
model: “R11e-LTE”
revision: “MikroTik_CP_2.160.000_v008”
current-operator: 25020
lac: 29481
current-cellid: 92210699
phy-cellid: 244
access-technology: Evolved 3G (LTE)
session-uptime: 2d22m41s
imei: [hide]
imsi: [hide]
earfcn: 1450 (band 3, bandwidth 15Mhz)
rsrp: -77dBm
rsrq: -10dB
sinr: 5dB
cqi: 13

Need to get a phone number

Mobile device does not have to know own MSISDN (phone number) for proper operations. For data-only MSISDN is not even needed by MNO’s core network.

Written that, mobile device can learn own number through some service exchange, i.e. by receiving an SMS message (which is not data service BTW). You can’t send SMS message to the device without knowing it’s MSISDN obviously, but you can send SMS message from your wAPr to your mobile … and send a reply back to wAPr. Check with wAPr if it knows own number afterwards.

as per experience, uicc is only available in 6.43+

if you’re looking for MSISDN (i.e. the number you dial), as far as i know you can’t.
you can query the IMSI, which consists of these information

  • Mobile Country Code (MCC)
  • Mobile Network Code (MNC)
  • Mobile Subscriber Identity Number (MSIN)

the first two can be looked up here: https://cellidfinder.com/mcc-mnc

for example i have one here:

216301034957618

216 stands for hungary, 30 stands for T-Mobile hungary, and the rest (1034957618) is the MSIN (but NOT the MSISDN)
as you see, this has nothing to do with the +xx phone number notation, but this is the closest you can get to it.
MSISDN is something that is linked to IMSI (the number that is stored in the sim-card) in the MNO’s HLR.

but there’s a knob in “/int lte info 0”, which at least hints something:

subscriber-number: +CME ERROR: 100

sadly i keep getting the same error here (tested on 6.43.4). but you still can send an sms from it to your phone, and you can see the number where the message is coming form.

btw, this translates to:

CME ERROR: 100 Unknown error

source: CME ERROR (GSM Equipment Related errors) - https://www.micromedia-int.com/en/gsm-2/73-gsm/669-cme-error-gsm-equipment-related-errors