Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Huawei k5160 4g usb mobile broadband

    Scheduled Pinned Locked Moved Hardware
    53 Posts 6 Posters 17.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • stephenw10S
      stephenw10 Netgate Administrator
      last edited by

      It may be auto-configured. It may have an management interface that can be used.

      GiaNNG 1 Reply Last reply Reply Quote 0
      • GiaNNG
        GiaNN @stephenw10
        last edited by GiaNN

        @stephenw10 it cannot be autoconfigured because it's a Vodafone USB and i'm using it with another ISP SIM card, if i set it to DHCP and go to it's IP it goes to PFsense.
        EDIT ok it was an error, now it works fine Thank You.

        Now if i can set up from the USB webpage i should set up a script wich force config 0 then usbswitch it.

        Something doesn't work, the webpage is just a static page. Is there a way to use it as a modem in this doc? So i can put manually from PFsense the APN

        1 Reply Last reply Reply Quote 0
        • stephenw10S
          stephenw10 Netgate Administrator
          last edited by

          It will use config index 0 by default. That's what it was using before you set it to 1.

          You can run that usb_modeswitch command using the shellcmd tool/package:
          https://docs.netgate.com/pfsense/en/latest/development/boot-commands.html

          GiaNNG 1 Reply Last reply Reply Quote 1
          • GiaNNG
            GiaNN @stephenw10
            last edited by

            @stephenw10 mmmmh every time i replugged it in it didn't show up as an interface and if i did usb_modeswitch -W -v 12d1 -p 1f1e -J it gave the error that it was already in the alternate mode.
            However if needed for somebody else, i couldn't set up the APN through web interface, i needed to set it up on a Windows machine and the plug it in PFsense

            1 Reply Last reply Reply Quote 0
            • stephenw10S
              stephenw10 Netgate Administrator
              last edited by

              If you check the usbconfig output does it actually show as that PID?

              GiaNNG 1 Reply Last reply Reply Quote 0
              • GiaNNG
                GiaNN @stephenw10
                last edited by

                @stephenw10 nope

                usbconfig
                ugen0.1: <AMD XHCI root HUB> at usbus0, cfg=0 md=HOST spd=SUPER (5.0Gbps) pwr=SAVE (0mA)
                ugen4.1: <AMD EHCI root HUB> at usbus4, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
                ugen3.1: <AMD OHCI root HUB> at usbus3, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA)
                ugen2.1: <AMD EHCI root HUB> at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=SAVE (0mA)
                ugen1.1: <AMD OHCI root HUB> at usbus1, cfg=0 md=HOST spd=FULL (12Mbps) pwr=SAVE (0mA)
                ugen2.2: <Vodafone (Huawei) Vodafone (Huawei)> at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (2mA)
                
                1 Reply Last reply Reply Quote 0
                • stephenw10S
                  stephenw10 Netgate Administrator
                  last edited by

                  You need to actually check the IDs so something like: usbconfig -d ugen0.2 dump_device_desc

                  GiaNNG 1 Reply Last reply Reply Quote 0
                  • GiaNNG
                    GiaNN @stephenw10
                    last edited by GiaNN

                    @stephenw10

                    usbconfig -d ugen2.2 dump_device_desc
                    ugen2.2: <Vodafone (Huawei) Vodafone (Huawei)> at usbus2, cfg=0 md=HOST spd=HIGH (480Mbps) pwr=ON (2mA)
                    
                     bLength = 0x0012 
                     bDescriptorType = 0x0001 
                     bcdUSB = 0x0210 
                     bDeviceClass = 0x0002  <Communication device>
                     bDeviceSubClass = 0x0000 
                     bDeviceProtocol = 0x0000 
                     bMaxPacketSize0 = 0x0040 
                     idVendor = 0x12d1 
                     idProduct = 0x157f 
                     bcdDevice = 0x0102 
                     iManufacturer = 0x0001  <Vodafone (Huawei)>
                     iProduct = 0x0002  <Vodafone (Huawei)>
                     iSerialNumber = 0x0000  <no string>
                     bNumConfigurations = 0x0001 
                    
                    
                    1 Reply Last reply Reply Quote 0
                    • stephenw10S
                      stephenw10 Netgate Administrator
                      last edited by

                      Hmm definitely showing the switched PID, yet no ue0 device is created?

                      GiaNNG 1 Reply Last reply Reply Quote 0
                      • GiaNNG
                        GiaNN @stephenw10
                        last edited by

                        @stephenw10 yes i see the ue0 interface and if i set the USB APN on windows it works, but it's not ideal if i need to change APN have to use a Windows machine. So i was wondering if there was a way to set it up in a way that let's me change APN directly on PFsense.

                        ue0: flags=8802<BROADCAST,SIMPLEX,MULTICAST> metric 0 mtu 1500
                                options=80000<LINKSTATE>
                                ether 0c:5b:8f:27:9a:64
                                media: Ethernet autoselect
                                nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
                        
                        1 Reply Last reply Reply Quote 0
                        • stephenw10S
                          stephenw10 Netgate Administrator
                          last edited by

                          Not in that mode I don't think there is. Unless the modem itself has a mgmt interface you can access. Windows almost certainly does it via an mbim interface and FreeBSD doesn't support that.

                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post
                          Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.