How to modify the default ip address of huawei usb modem e3531i-2 - modem

want to change the default lan ip address from "192.168.8.1" to something else of device huawei usb modem e3531i-2 (HiLink), cause if i plug two of the modems there will be ip conflict and the latter will block the first modem, thanks.
"usb stick model" -
"hilink web app"
i want to plug multiple huawei modems e3531i-2 in a single pc without getting ip conflict.

Found the solution !
my os is ubuntu 22.04 LTS, modem huawei e3531i-2, but i hope it can works for other modems.
first list your connected usb using command lsusb | grep Huawei it should look like this: Bus 001 Device 002: ID 12d1:1f01 Huawei Technologies Co., Ltd.
The 12d1:1f01 indicates that the modem is in storage mode and we need to switch it to serial mode. type sudo nano /etc/usb_modeswitch.d/12d1:1f01
Once the file is created now copy paste the text below inside and save :
# Huawei E3531
DisableSwitching=1
TargetVendor=0x12d1
TargetProduct=0x1001
MessageContent="55534243123456780000000000000011062000000100000000000000000000"
NoDriverLoading=1
re-plug your modem again and now if you type lsusb | grep Huawei it should look like this : Bus 001 Device 003: ID 12d1:1001 Huawei Technologies Co.,, If the modem doesn’t switch into 12d1:1001 mode, try rerunning the above command with -I.
now you're able to run AT commands using screen /dev/ttyUSB0 or controlling it using modemmanager "i would recommend not using the GUI but instead use mmcli"

Related

ToupTek XCAM4K8MPA camera connection to Linux computer

I'm trying to connect a ToupTek XCAM4K8MPA camera to a Linux Ubuntu 20.04 64-bit computer to use with their provided ToupLite software for microscopy image capturing. The camera comes with a USB 3.0 cable, HDMI cable and USB WLAN adapter.
I have managed to set up the ToupTek ToupLite software (Link to manual, Link to download page) which, as far as I understand, comes with the SDK included. I have then connected the camera via USB 3.0 and HDMI cable to the computer, but ToupLite shows No device as in, the camera is not recognized or connected. I have tested the camera by simply connecting it to a computer monitor via HDMI cable and it works, but for capture I would like it to be connected to a computer and the WLAN or Wi-Fi connection solution is not really a good option.
Perhaps someone has some ideas of what I am missing.
Note: Relevant tags include touptek, touplite, microscopy
I ended up using the WLAN connection. Made a non-changing IP address for the camera and the ToupLite software recognizes that it is on the local network.

Integrated webcam not connecting to Vmware

I am using Windows 10 on host machine and using VMware workstation
Version
VMware® Workstation 16 Pro
version 16.1.2 build-17966106
I am running windows 8.1 as Guest window on VMware. I have succesfully updated my Guest os(Win 8.1) and installed important updates as well as I installed the Vmware tools succesfully.
When I tries to connect the webcam to Vmware by choosing "Connect(disconnect from Host)", then sometimes it connects succesfully and I could able to use my webcam in VMware but sometimes It gives the error The connection for the USB device "Microdia integrated webcam" was unsuccesfull. Could anyone help me through this ?
My laptop specifications :
Dell vostro 15 3500
Ram 8gb
intel i3 11th gen
I found a type of hack solution for this problem.
When you start the guest machine on VM and a small window will automatically opens like this ->
You need to click ok and instantly try to open Camera app on your main or host machine, and you will see that the camera app is not able to detect camera as it is now connected to host machine in VM. This would magically works everytime for me now.Thanks
Try opening your windows camera, and then run VmWare, click on top left corner, there would be Player->Removable Devices->Select the camera listed, Now you can see the camera will be stopped in your Windows machine and in ubuntu, you can see its connected.
Type lsusb (list usb) and ensure that your camera device name is listed
sami#ubuntu:~/Desk$ lsusb
Bus 001 Device 005: ID 0bda:5539 Realtek Semiconductor Corp. VMware Virtual USB Hub
Bus 001 Device 004: ID 0e0f:0008 VMware, Inc. VMware Virtual USB Mouse
Bus 001 Device 003: ID 0e0f:0002 VMware, Inc. Virtual USB Hub
Bus 001 Device 002: ID 0e0f:0003 VMware, Inc. Virtual Mouse
Bus 001 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
sami#ubuntu:~/Desk$ getfacl /dev/video*
getfacl: Removing leading '/' from absolute path names
# file: dev/video0
# owner: root
# group: video
user::rw-
user:sami:rw-
group::rw-
mask::rw-
other::---
# file: dev/video1
# owner: root
# group: video
user::rw-
user:sami:rw-
group::rw-
mask::rw-
other::---

Phone connected to adb via Wi-Fi disconnects immediately when USB cable is pulled [duplicate]

I develop on my tablet using android studio.
The tablet is connected to the computer by wifi using
adb connect <ip_andress>:5555
My application contains listeners for USB devices attached/detached.
But unfourtunately, when I connect/disconnect usb device to/from the tablet, the adb connection is getting killed, and I can no longer see the device under "adb devices".
It is not a adb-connection-by-wifi what gets killed. It is just that USB enumerations affect the sys.usb.* system properties which on many devices is causing restart of adbd regardless whether it's being used over USB or tcpip.
Do grep "stop adbd" /init*rc to see what I mean.
You could either comment out those stop adbd lines or just disconnect the USB cable before running your adb connect command.
I was never able to connect my cellphone with my computar through wi-fi.
I had already given up. I followed all the instructions and tips, and nothing worked.
Finally, I did what no one said to do.
I've connected the phone to the WiFi network provided by the cable modem itself and not to some (not all) additional networks that are included in the router.
At home I use one of these networks, because I use a Deco Tp-Link router, which propagates the signal to my entire house, but this network is NOT compatible with ADB. It does not identify it as belonging to the same network.
After this, I use the normal procedure described here.
a) Connect cellphone with a USB cable
b) Find the IP_Phone depends on system in the cell phone. Here I use Settings, About Phone, Status and IP address.
c) Run the following adb commands in Command Prompt (Windows) or Terminal (Linux), where IP_Phone is the IP above mentioned. Normally adb.exe is an executable stored in computer path. adb is already included in Android Studio package.
adb tcpip 5555
adb connect IP_Phone
d) Now disconnect USB cable and it's ready. The cellphone model continues to appear in the status line in the top of Android Studio.
-/-
The best wifi is that defined in Cable Modem. It, unlike an any account defined in my router, answers to a ping command.
ping IP_Phone
Disconnect the usb cable just before running adb connect <*ip_address_of_your_phone*>

emulating usb device with another PC

Task: Testing production software on PC notebook without production unit attached via USB and without changing prodcution software.
Goal: Emulate production device with another PC. The test application runs on the second PC to emulate our device commands/responses.
Challenge: Using a USB bridge cable or other device requires that we can change the PID/VID to look like our device.
Suggestions?
You need a hardware device on the second PC to do this type of emulation.
USB ports on a normal PC are USB host ports. Two such ports cannot be connected with each other directly. USB device (or USB OTG - switchable) ports can be found on programmable smartphones (Android, maybe others) and some developer boards like these. I think you probably need to use a smartphone or developer board rather than ordinary PC as the your USB device emulator.

USB port number

I have a device that I need to program from my computer. It uses a serial to usb cable to communicate with my computer. When programming the device I have to provide the port number, ttyUSBn. How do I know the number of the USB port I'm using?
On a MAC/OSX you can use the following in a terminal window: ls /dev/tty.*