Initial setup

After getting a Flame there are a couple of steps you should make sure you follow for your particular operating system, before you start trying to update your Flame device, for example by updating your Flame's version of Firefox OS, or pushing apps to your phone. Both are covered in subsequent articles, but you should work through this article first.

All operating systems

You need to install ADB and Fastboot on your computer — these are applications that allow you to interact with your phone from your computer when the two are connected via the phone's USB charger cable. They are needed for Flashing your phone to a new version of Firefox OS, recovering from an unresponsive state, pushing apps to your phone, etc.

Note: If you are on Ubuntu you can install ADB and Fastboot simply by using sudo apt-get install android-tools-adb android-tools-fastboot on the command line.

Note: If you are on Mac OS you can install ADB and Fastboot simply by using Homebrew on the command line. See Installing and using ADB.

ADB and Fastboot are available in the Android Developer Toolkit:

  1. Go to the above link.
  2. Press the Download Eclipse ADT button.
  3. Agree to the license conditions.
  4. Choose between the 32-bit and 64-bit version (32-bit will do if you are not sure).
  5. Click the final Download Eclipse ADT with the Android SDK... button.
  6. Once the download is complete, unzip the zip file's contents onto your computer's desktop.
  7. The folder name is a bit complicated; rename it to just adt.

ADB is a tool that you run from the command line. If you open your terminal/command prompt, go to adt/sdk/platform-tools and run the adb command, you should see a load of information thrown back at you about what you can do with ADB. Running adb devices should return the line List of devices attached, and nothing else, because you haven't got any devices attached yet.

At this point, you need to set the PATH variable to point to the ADB tool, so you can run it from anywhere, not just when you are in the exact directory that ADB is in.

To do this on Windows 8 (Windows 7 will be very similar, but with slightly different menu options):

  • Right click on the Windows button in the bottom left and select Control Panel > System and Security > System > Advanced System settings > Environment Variables.
  • In the System variables list, find the one called Path, select it, then click Edit...
  • In the Variable value text field of the resulting dialog box, make sure you are at the end of the big string of characters in the box, then type a semi colon (;) followed by the location of the adb tool on your system, which should be C:\Users\[YOUR USER NAME]\Desktop\adt\sdk\platform-tools, or for the version of 08/2016 of the SDK on windows 8.1 should be C:\Users\[YOUR USER NAME]\AppData\Local\Android\sdk\platform-tools (if not you should need to update the package since the Android SDK).

    So if your user name is jamessmith, you would enter ;C:\Users\jamessmith\Desktop\adt\sdk\platform-tools.
  • Press OK on all the dialog boxes you opened up in this section.
  • Close your command prompt, open a new one, and test it by typing adb devices. If it comes up with List of devices attached, you are successful! You'll also need to follow the instructions in the Extra steps for Windows section below.

Note: To open command prompt, Right click on the Windows button in the bottom left and select Command Line.

On Mac/Linux:

  • In the Finder app, go to your home folder (the one with the house icon).
  • If you can't already see hidden files (for example, system files with dots (.) at the beginning), go to Terminal and enter the command defaults write com.apple.finder AppleShowAllFiles YES, then restart Finder.
  • Open your .bash_profile or .bashrc file in a plain text editor like Text Wrangler or Sublime Text (it needs to be a plain text editor).
  • Inside the file, add a new line PATH=/Users/[YOUR USER NAME]/Desktop/adt/sdk/platform-tools:$PATH
  • Save and close the file.
  • Restart your terminal, and test it by typing adb devices. If it comes up with List of devices attached, you are successful!

Enable remote debugging

Make sure remote debugging is enabled on your Flame, using the Remote debugging/Debugging via USB option in the device's Developer settings (the option is different, depending on whether you have Firefox 1.3 and under, or Firefox 1.4+ installed).

Extra steps for Linux

Depending on your Linux distro, you will likely need to add a udev rule for your phone.

To discover the vendor ID of your device, attach your phone via USB and use the command lsusb to view the devices detected on the USB subsystem. Find your phone in the list, and note the initial four digits immediately following "ID". A common ID for the Flame is 05c6, so a udev rule in this case would be:

SUBSYSTEM=="usb", ATTRS{idVendor}=="05c6", MODE="0666"

If your device lists a different number, use that instead. For instance:

SUBSYSTEM=="usb", ATTRS{idVendor}=="18d1", MODE="0666"

Make sure to run the udevadm control --reload-rules command (could be automatic depending on your setup), then unplug and replug your device before continuing.

Further adb issues: modeswitch and rule overrides

At this point, Linux users may still fail to see their Flame recognised by adb devices. This is because there's a modeswitch rule for the device, which makes the Flame 'invisible' to adb.

The Flame appears to be a multi-state device. When you plug in a switched-off Flame for example, its USB id is 05c6:f000. There's a udev rule in the 40-usb_modeswitch.rules file  (typically in /lib/udev/rules.d/) that calls usb_modeswitch for this device — this program seems to set the Flame to be a USB modem.

This problem can be fixed by:

  1. Deleting the usb_modeswitch tool.
  2. Commenting out the aforementioned line in the rules file.
  3. Adding the following line to your android.rules file (again, check your udev directory) to disable the call to usb_modeswitch:
    ATTR{idVendor}=="05c6", ATTR{idProduct}=="f000", RUN=""

Solution 3 is the advised option.

For the next part of this solution, note that the order of the udev rule files is important. udev reads all the files with rules and orders them alphabetically. Whatever comes later overwrites earlier rules.

The Android rules file will probably be named 51_android.rules (as described in Using Hardware Devices.) On some distributions (such as Debian 8) there's a file named 69_libmtp.rules, which contains a rule for 05c6:9025 that treats your Flame like a media player and puts it into the group audio, stopping it being recognised by adb. You can fix this problem by renaming your android.rules file to start with a higher number, like 99_android.rules.

Extra steps for Windows

To access the Flame device with the ADB and Mozilla dev tools like App Manager/WebIDE, a USB driver is required. Follow the steps outlined in the below sections to install it.

Downloading the driver

Download the Windows driver from this location. Once downloaded, extract the contents of the ZIP file to a suitable place on your hard drive.

Note: The Android Debug Bridge (ADB) must be installed first: see instructions above if you've not already done this.

Installing the USB Driver

At this point, connect your Flame device to your computer using a USB cable.

To install the driver, open the Alcatel_USB_Driver_Q_4.0.0_2013_11_11_noinstall directory within the extracted ZIP file and double click on the DriverInstaller.exe executable. You may receive a warning at this point that the executable is from an unknown publisher. If so, select the Yes button and the executable will be launched.

Simple dialog box showing a picture of a phone along with install and uninstall buttons.

Click on the Install button to install the driver.

After the driver installs, you can check that it is working by opening a command line window and typing adb devices.

This should list the connected device with an output something like:

List of devices attached
3561d02a          device

If your device is not showing up here, check in the Windows Device Manager. Your Flame may be showing up as "ACER ADB Interface". You can confirm this by unplugging the device and seeing if it disappears from the device manager. Uninstall the driver software by right-clicking on "ACER ADB Interface" and clicking uninstall.  Be sure to check the box in the dialog to delete the driver software. Now re-run the installer above. It is advisable to set the screen timeout on your Flame to something high (Settings > Display > Screen timeout) as Windows sometimes appears to reinstall the default drivers when the screen turns off.

Document Tags and Contributors

 Contributors to this page: chrisdavidmills, Nowic, miguel-perez, ChrisL
 Last updated by: chrisdavidmills,