✏ B2G beta (formerly Firefox OS)

just found that in developer mode you have to activate the USB-Debugging.

1 Like

So did you solve the problem? Can you see the device from the operating system? If not, with high probability, something is missing and we have to inform Mozilla developers. Unfortunately, I do not have the device in order to try to flash.
Insert at the beginning of flash.sh script this line of code set -x in order to track the script execution.

1 Like

seams to me as you built with jdk-6. is that so?
.config - file:


MAKE_FLAGS=-j6
GECKO_OBJDIR=/home/tore/Desktop/B2G/objdir-gecko
DEVICE_NAME=fairphone2
PRODUCT_NAME=FP2

im trying to make a build but its failing… don’t know where until now…
Regards, Novski

Hi erotavlas
I now built my own firefox os and had the exactly same situation. It stats that:
“Unsuported device “FP2”, can’t flash”
So its not something with your build its something in the build…
Can you more clearly describe where and what all i have to paste to the flash.sh script?

Thats a quite long file…
Regards, Novski

edit: add of printscreen for developers…
please don’t be irritated its a macbook pro with native ubuntu 14.4…

1 Like

I don’t know a lot (I’ve never tried it), but the build looks good. It’s just the flashing that fails.

Try:

sh -x flash.sh

or

bash -x flash.sh

(Could be a bash script, I see more and more useless, not portable bashism scripts these days, why?)

And post what the script is trying to do.

ok. both in one screenshoot. Thanks for help…


Regards, Novski

I think the script is looking for the right way to flash a “FP2” but it is not finding a matching device so it bails out and prints this error message (there is no matching device defined for “FP2”).

I would say screw this script and just flash the images by hand. :slightly_smiling: Or see if someone can update this script for you. Flashing by hand is not so hard, but it’s good to know what you do. If you look at your first screenshot you can see where the images are located.

See: “Flashing images” in here:

Hi novski,
yes you correctly built your firefox OS build. Your screenshoot related to flash.sh output confirm that the script is wrong, you have the same output of mine even if I do not have any fairphone 2 connected. Moreover, your system can see an attached device via adb. So if you want to try your build, follow the suggestions of fp1_wo_sw_updates.
I will open an issue on firefox OS.
Thank you for your time. We are slowly converging to a working version :slightly_smiling:

1 Like

hi erotavlas,

I already opend one, https://bugzilla.mozilla.org/show_bug.cgi?id=1244519
Regards, Novski

1 Like

I you can, add something like “I think there is no matching device/function defined for “FP2” in the script, this is why the flashing fails” to your bug report. It’s more about the flashing script, the build works.

The script for FP2 will more or less do the following:

Go to the target out dir for the images and do:
fastboot flashall

if i type terminal code: fastboot flashall it gives out this:
error: neither -p product specified nor ANDROID_PRODUCT_OUT set

and also if i tryed to do manual but
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot -p FP2 boot out/target/product/FP2/boot.img
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot -p FP2 system out/target/product/FP2/system.img
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot -p FP2 recovery out/target/product/FP2/recovery.img

it did not spit out a failure but it als did not seam to make anythng. the phone started up as normal in android like from factory…

how can i flash manual?
Regards, Novski

interesting…
did you copy / paste all commands at once or did you enter them one by one? could you leave the -p FP2 out? It worked for me without specifying the device…
The other way around, did you try fastboot flashall -p FP2 ?

Running these commands is he manual way of flashing :slight_smile:

Thanks for that reply.

Did you manage to start firefox os? because i didn’t until now…
wich way did you do it? i mean what .img did you copy first, and how did you then reboot to firefox os?
Regards, Novski

edit:
thats the output of

Quite interesting…

Other people (including me) had the same problem with the FPOS, see here and here.

PS: Btw, instead of inserting images of your terminal, you could copy and paste the output into your posts here. There is even the possibility to display these as code (the </> icon in the menu or the shortcut Strg+Shift+C or four empty spaces at the beginning of the line). This would save storage space on the server (and probably be faster). :wink:

Didn’t you forget the flash command in here? Like:

$ fastboot flash boot out/target/product/FP2/boot.img
1 Like

Please try

cd out/target/product/FP2/
fastboot flashall

the info fastboot is looking for should be there. But I never used/installed Firefox OS/B2G so I’m just guessing. Make sure you use a terminal that you use for the build, maybe some environment variables/paths/functions need to be around and set as well (just guessing again).

I can confirm this, see my second link above. I described there (see the paragraph “3. Try”) that I had the same problem and needed to run the setup for these environment variables etc. (but not the whole build) again in a new terminal before I could flash.

hi and many thanks to that help here…

seams to be the same…
novski@novski-MacBookPro:~/firefox_os/B2G$ cd out/target/product/FP2/ novski@novski-MacBookPro:~/firefox_os/B2G/out/target/product/FP2$ fastboot flashall error: neither -p product specified nor ANDROID_PRODUCT_OUT set novski@novski-MacBookPro:~/firefox_os/B2G/out/target/product/FP2$ fastboot -p FP2 flashall error: could not load android-info.txt: No such file or directory


flashing manual directly worked somehow, but the phone is now unbootable and it took me a while to get it back to fastboot mode (pressing pwr & vol.down for about 10s while repluged)

`novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot flash boot out/target/product/FP2/boot.img
target reported max download size of 536870912 bytes
sending ‘boot’ (14994 KB)…
OKAY [ 0.473s]
writing ‘boot’…
OKAY [ 0.179s]
finished. total time: 0.652s
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot flash system out/target/product/FP2/system.img
target reported max download size of 536870912 bytes
erasing ‘system’…
OKAY [ 0.284s]
sending ‘system’ (305361 KB)…
OKAY [ 9.715s]
writing ‘system’…
OKAY [ 6.327s]
finished. total time: 16.327s
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot flash recovery out/target/product/FP2/recovery.img
target reported max download size of 536870912 bytes
sending ‘recovery’ (13622 KB)…
OKAY [ 0.436s]
writing ‘recovery’…
OKAY [ 0.156s]
finished. total time: 0.593s
novski@novski-MacBookPro:~/firefox_os/B2G$ fastboot reboot
rebooting…

finished. total time: 0.001s

`
Any ideas? :slightly_smiling:

did you reset cache and userdata after flashing the new system? you should be able to do that from recovery…

no didn’t but i can’t access recovery anyhow. Is that because i flashed also a recovery.img to the phone?

edit:
whent throug some files searching for that android-info.txt (think somewhare must that text apear. Then i found something strange:


the second Line export GECKO_TOOLS_PREFIX=/home/novski/firefox_os/B2G/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8/bin/arm-linux-androideabi- has a unfinished end. and i don’t find that file like that in the folder… Is that normal?

(sorry for the printscreen but it makes it more clear here. will try to not upload pictures anymore where text can do same…)
Regards, Novski

If you did that while booting your phone, you should be in recovery. With that little Android Icon and such? Alternatively try PWR + Vol. Up Key on startup.
If your Recovery partition is really damaged, than you should try to fix that first, before attempting to do anything else, as the recovery is your only option to rescue your phone if someting goes very wrong while flashing your new system…