ZTE MF636 update

Despite getting home at 6am this morning after a night of clubbing, I’ve had a productive day hacking around with the troublesome modem.
I’ve produced a patch against 2.6.34-rc6 which blacklists the MF636 such that option_send_setup doesn’t send a the RTS and DTR states to the first three serial ports, ttyUSB[0-2].
Examining the contents of the Windows INF files in the files on the ZeroCD device, I’ve found the following nuggets:

  • Interface 00 is a USB Diagnostic interface, which is probably why it doesn’t respond to AT commands
  • Interface 01 is an NMEA interface, and interface 02 is an extended NMEA interface – I don’t know what this means
  • Interface 03 is a Mass Storage device which appears when you first plug in the device
  • Interface 04 is the modem itself

I’ve also made a breakthrough in the initialization string – this must be AT&F&D2&C1, which:

  • &F: Revert to factory defaults
  • &D2: Set the DTR behaviour to terminate the call gracefully upon a DTR on/off tranisition
  • &C1: Sets the Received Line Signal Detect (RLSD – is this DCD/Carrier Detect?) on until all data is received from the remote modem
  • S0=0: Do not automatically answer an incoming call

Another little gem I found – the moment you dial ATD*99#, you cannot terminate the connection unless you send a PPP LCP TermReq. You can’t send the usual escape sequence +++, then ATH, nor can you cause the modem to disconnect by sending ATH via another port. It appears it must be done via PPP. This seems a bit brain-damaged.
Finally, the best bit – if you don’t set the initialization string correctly, the modem will crash and disconnect itself from the USB bus. Very handy, and painfully difficult to debug. NetworkManager doesn’t send the correct initialization string, hence the modem crashes.
I’m hating this device less the more I learn about it. I could still do with something that ‘just works’ without all this faff – but I get a lovely warm feeling knowing I’m helping out other people who have had the MF636 imposed on them.

Mass-market USB modems and the ZTE MF636

Way back when, I had a Huawei E220. This was moderately usable under Linux, more so after a firmware upgrade and usb_modeswitch. A great little device, installation of a long USB cable meant I could put the dongle where the signal was best. I still have it, although it’s likely locked to Vodafone.
For reasons unknown, the company I worked for ceased the contract on this and gave me a GlobeTrotter iCON 7.2 modem. Again, after some fiddling, success. The only problem was its shape – like a plastic ice lolly. It wiggled in whichever USB port I used it in, and I never really got on with it. However, it worked.
The iCON broke, and I now have a ZTE MF636. This is an aesthetically pleasing device, with one big flaw – it’s utter rubbishness under Linux.
I’ve spent a considerable amount of time battling these little gems:

  • ZeroCD support – great for Windows and Mac machines as your drivers are forced upon you. It can be turned off permanently with the AT+ZCDRUN=8 command (and turned on with AT+ZCDRUN=9), or ejecting the SCSI CD-ROM device.
  • option.ko support – of the four serial ports presented, ttyUSB3 (the final one) under Linux 2.6.32 is the only one accessible. I think I have a workaround.
  • modemmanager support – right now, I can’t dial out using NetworkManager. With wvdial, I can poke commands at ttyUSB3 and connect successfully, but that’s ugly in my eyes.
  • Random USB resetsreset high speed USB device using ehci_hcd and address 33 is not a welcome message, especially when I have to unplug and replug the USB device to get it to work again.

I’m not overly comfortable with delving down to the low level of these sorts of problems – but looking on the positive side, it’s a great learning experience. Yeah 🙂

Retrocomputing

And so, dusting off my knowledge of Novell Netware from years ago, I started to install NetWare 4.11 in VirtualBox.
Apparently this doesn’t work, but with some hackery thus, it’s fine:
1. Copy all the files off the installation CD in to a directory
2. Download updated NetWare ATA drivers with UDMA support
3. Assuming you unpacked the ZIP file above to /tmp/a, and the contents of the installation CD are in the current directory, do:
cp /tmp/a/NW3X-4X/NBI.NLM ./products/nw411/_/411/syspre/nbi.nlm
cp /tmp/a/NW3X-4X/NBI.NLM ./products/nw411/_/411/boot/nbi.nlm
cp /tmp/a/NW3X-4X/NWPALOAD.NLM ./products/nw411/ibm/411/diskdrv/nwpaload.nlm
cp /tmp/a/NW3X-4X/NWPA.NLM ./products/nw411/ibm/411/diskdrv/nwpa.nlm
cp /tmp/a/IDEATA.HAM ./products/nw411/ibm/411/diskdrv/ideata.ham
cp /tmp/a/IDEATA.DDI ./products/nw411/ibm/411/diskdrv/ideata.ddi
cp /tmp/a/IDECD.CDM ./products/nw411/ibm/411/diskdrv/idecd.cdm
cp /tmp/a/IDECD.DDI ./products/nw411/ibm/411/diskdrv/idecd.ddi
cp /tmp/a/IDEHD.CDM ./products/nw411/ibm/411/diskdrv/idehd.cdm
cp /tmp/a/IDEHD.DDI ./products/nw411/ibm/411/diskdrv/idehd.ddi
This will update the drivers on the installation CD with those supporting UDMA.
4. Create an ISO image of these files using “mkisofs -D -l . > ../netware411-patched.iso”
5. Install the server. INSTALL.NLM will throw up some errors, and you will need to enter slot 10002 for the IDEATA Disk Driver, but other than that, it’s fine.
Now if you’ll excuse me, I’m off to install Word 6 🙂

A mixed bag of 3ware

Right after I upgraded the firmware on a 3ware 9650SE RAID controller in my desktop, the card failed. ‘lspci’ would recognise it, but nothing else.
I RMA’d it with 3ware, and within a week and a half – bearing in mind there was New Year in the middle – I had a new card couriered to me. Superb service.
My desktop machine has been reformatted and reinstalled, and it’s running much faster than before. The only downside is 3ware seem to insist I download 57Mb of JVM and InstallShield to install 3dm2 and tw_cli… why? Why can’t I just have the files and install them myself? Why do I have to run a JVM as root? That scares me a little.

3ware and NTP

For some years, I’ve been paranoid enough to run RAID-1 on my desktop machine to protect against a single hard drive failure. Backups are to another drive on a separate controller.
A couple of weeks ago, I flashed the firmware on my 3ware 9650SE, rebooted, and the BIOS wouldn’t see the controller at all. ‘lspci’ under Linux showed the card, but nothing else – the 3w-9xxx driver in the kernel didn’t recognise it, nor did 3dm2 nor tw_cli. Strange – although it’s within the year’s warranty, so I’m RMAing it on Monday.
On a separate, slightly strange matter, I’ve had an Asus P5WDG2 WS Professional motherboard with some DDR2-667 RAM for a couple of years now. Sometimes the machine boots and it recognises the RAM as DDR2-667, and sometimes as DDR2-533. Why, I don’t know. Anyway, fiddling around in the BIOS to determine whether I had a dead PCI Express slot, I managed to turn on some automatic overclocking functions – things that I don’t usually touch.
The results were strange – over the course of 24 hours, my machine gained a whole hour. Naturally, this was going to be down to something I’d fiddled with, so I turned overclocking off and in the past couple of hours, the clock keeps the correct time.
Here’s a lesson for you – change one thing at a time and check it works 🙂

Getting home in 2009

I can sit in a club and decide I want to go home. I can pull out my mobile phone from my pocket, visit a certain website and book a taxi home. I receive a text message when my taxi is near, then stand outside and hop in. This clever use of basic-for-2009 technologies impresses me somewhat. This is what technology should be about!
It may cost a bit more than trying to hail a black cab, but I really appreciate the freedom of paying a couple of quid more for a near-enough chauffeur service. And of course, it avoids having to take a night bus.

Catalyst 6500 Supervisor 32 modular software

I’m on my way back from a few days in Milan, setting up a network for one of our customers. Standard equipment – a pair of Cat6504Es, some ASAs, a couple of ACE4710 load balancers.
As usual with anything I haven’t used before, problems occur. The biggest and most infuriating wasn’t the failed Sup32 (which was eventually replaced by Cisco after quite some work on our supplier’s behalf), but the fact I couldn’t get the Sup32 to boot from the image I’d downloaded.
Here’s what happened – each time I booted, the boot image loaded and spewed the following:
MAC based EOBC installed
Waiting (slot 1) for supervisor to come online in other slot. iteration
= 0

Next Retry will be done after 6 seconds
This repeated for what seemed like an eternity, then the Supervisor crashed and rebooted.
What fixed it? It turns out I had a modular image copied in to flash, not installed. That's not amazingly obvious, especially as the modular image has -mz in its name, and the image I wanted has -jz.
See this article on Cisco IOS Software Modularity on cisco.com for more information.