I am configuring my Raspberry Pi to connect to the Hologram network through a Huawei E303 device. I have followed the tutorials and it is connecting successfully. I am able to ping websites and the USB stick shows it is connecting. However whenever I try to use the Hologram Cloud through the Python SDK I get the following error.
Exceptions.HologramError.NetworkError: Modem not detected
Am I missing an important setup step? How can I specify the modem it should use? If I am understanding it correctly the usb device is my modem so since it is working what am I missing for the python SDK? Thanks for any help you can give me.
My test script is the following:
from Hologram.HologramCloud import HologramCloud
hologram = HologramCloud(dict(), network=ācellularā)
result = hologram.network.connect()
response_code = hologram.sendMessage(āhello,worldā)
print hologram.getResultString(response_code)
I have tried both but currently my setup follows the tutorial that installs usb modeswitch but then sets everything up on the website. Is one better than the other?
Looks like itās working. Those RTNETLINK messages are warnings that can be ignored. Weāll remove that in a future release.
The last line is supposed to go inside of a python script so it wonāt work on the command line
i have tried to connect raspberry pi to celluar with huawei e303 modem
seems even with lsusb ā¦
not sure why raspberry pi not seeing the modemā¦
see codeā¦
Thanks!
pi@raspberrypi:~ $ sudo dhclient eth1
Cannot find device "eth1"
pi@raspberrypi:~ $ lsusb
Bus 001 Device 006: ID 046d:c016 Logitech, Inc. Optical Wheel Mouse
Bus 001 Device 005: ID 1c4f:0016 SiGma Micro
Bus 001 Device 008: ID 1546:1102 U-Blox AG
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp. SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Standard Microsystems Corp. SMC9514 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@raspberrypi:~ $
Actually, I think the issue is the inability of the raspberry pi to discover the device either as a storage or as a modemā¦ have tried a few thingsā¦but the modem only works (for me) if I go with the Hologram Nova installation.
I installed the usb_modeswitch like the tutorial stated. In the past I have tried running a long sub_modeswitch command which has not helped. I tried running it again but I get a message that āNo device in target mode or class is found.ā This is the command I found:
Before we go any further verify what lsusb says when you plug the e303 in.
Also confirm that you really have a e303 and not some other variant.
For the e3513 I had to use this usb_modeswitch command:
sudo usb_modeswitch -v 0x12d1 -p 0x1f01 -V 0x12d1 -P 0x1001 -M ā55534243123456780000000000000011062000000100000000000000000000ā
Maybe worth a try, however you want to do another lsusb command after running usb_modeswitch.
The box says its an HUAWEI e303 but all the documentation is not in English and the Raspberry seems to think it is an E353/E3131. It looks like an e303 but I canāt find anything that verifies that. Is there another way to tell?
I tried your new command and got the same message of No devices in target mode
I triedā¦ using the lsusbā¦ sudo nano /etc/networks/interfaces
tired hot plugin of modemā¦
changed the code to allow for hot plug inā¦
Perhapsā¦ someone can write up a script or code something to download?
When I did the Hologram Nova ā¦ i was able to get connectionā¦
but the modem never had the full lights showing actiivityā¦
I am a little confused. I followed those instructions but it seems to have told the USB stick to just be a memory device. After executing that it does not have a light showing it is connected and I am not able to ping hologram.io. Did it do the opposite or is it supposed to be disconnected from the 3G network in order to be used by the SDK?