Gets information about all observed cell towers from all radios on the device.

Usage #

package main

import (
    "fmt"
    t "github.com/hugmouse/gotermux"
)

func main() {
    cellInfo := t.TermuxTelephonyCellInfo()
    for i, cell := range cellInfo {
        fmt.Printf("Cell %d: Type=%s, MCC=%d, MNC=%d\n", 
            i+1, cell.Type, cell.Mcc, cell.Mnc)
    }
}

Return Value #

Returns []TCellInfo - array of cell tower information.

Struct TCellInfo #

FieldTypeDescription
TypestringCell type (GSM, LTE, WCDMA, etc.)
MccintMobile Country Code
MncintMobile Network Code
LacintLocation Area Code
CidintCell ID
SignalStrengthintSignal strength in dBm