Add phablet-screenshot script

Bug #1238839 reported by Michael Hall on 2013-10-11
52
This bug affects 10 people
Affects Status Importance Assigned to Milestone
Phablet Tools
Fix Released
Undecided
Unassigned
phablet-tools (Ubuntu)
Undecided
Unassigned

Bug Description

Now that the phablet images have switched to using Mir by default, the /system/bin/screencap script no longer works. There is a script that will do the same thing using Mir from a computer connected over USB, and it would be very helpful to include it in phablet-tools package.

lp:~jibel/+junk/phone-tools in directory misc/mirfbdump

I have confirmed that it works on mako with build 92.

Related branches

Barra (barra78) wrote :

on Maguro it capture only black screen:

barra@Saucy:~/Scrivania$ ./cattura -d 111.jpg
+ shift
+ true
+ shift
+ break
+ [ 1 -eq 0 ]
+ DST=111.jpg
+ check_prerequisites
+ cmds=adb convert
+ okay=1
+ type adb
+ type convert
+ [ 1 -ne 1 ]
+ depth=8
+ get_mode
+ adb shell head -1 /sys/devices/virtual/graphics/fb0/modes
+ cut -d: -f2
+ cut -d p -f1
+ size= cannot o
+ echo cannot o
+ grep -qE ^[0-9]+x[0-9]+$
+ get_device
+ adb shell getprop ro.cm.device
+ device=maguro
+ echo maguro
+ tr -d \r
+ device=maguro
+ size=720x1280
+ echo 720x1280
+ size=720x1280
+ [ -z 720x1280 ]
+ CONVERTOPTS=-alpha off -resize 50% -depth 8 -size 720x1280
+ echo I: Dumping fb0 ...
I: Dumping fb0 ...
+ adb shell kill -SIGSTOP $(pidof unity8)
+ adb pull /dev/fb0 /tmp/cattura.1JtyUs/fb
5828 KB/s (16777216 bytes in 2.811s)
+ adb shell kill -SIGCONT $(pidof unity8)
+ convert -alpha off -resize 50% -depth 8 -size 720x1280 rgba:/tmp/cattura.1JtyUs/fb[0] 111.jpg
+ echo I: Done
I: Done
+ cleanup
+ [ -d /tmp/cattura.1JtyUs ]
+ rm -Rf /tmp/cattura.1JtyUs

Michael Hall (mhall119) wrote :

What build number are you using?

Chris Wayne (cwayne18) wrote :

Maguro isn't listed in the supported devices on the linked script"

SUPPORTED="mako manta grouper"

James Henstridge (jamesh) wrote :

The fbgrab script from the fbcat package looks like it should be able to do the same kind of screen capture as this script, but it doesn't seem to handle the pixel format on my device (the image is recognisable, but looks like it only got the red channel).

Jean-Baptiste Lallement (jibel) wrote :

I removed maguro from the list of supported devices because cat'ing /dev/fb kills it. According to tvoss

"2013-10-14 15:24:38 tvoss jibel, yup, that comes down to an issue with the maguro fb driver"

Alejandro J. Cura (alecu) wrote :

Running the script from my desktop, I can confirm that it captured the screenshot very nicely on a Nexus 4 (mako) with Ubuntu Touch saucy build #100.

Marco (jermy-07) on 2013-10-21
Changed in phablet-tools:
status: New → Confirmed
Mark Hebing (markhebing) wrote :

I can confirm it too, works great by running ist from desktop. THX. build #100

Mateo Salta (mateo-salta) wrote :

The script does not work on Nexus 7 grouper - when using multi-boot, will only capture the multiboot screen. Overriding image in framebuffer?

Dimitri John Ledkov (xnox) wrote :

Why shouldn't be packaged and seeded on the images by default?
After all it would be nice to take screenshots without a computer.

description: updated
PS Jenkins bot (ps-jenkins) wrote :

Fix committed into lp:phablet-tools at revision None, scheduled for release in phablet-tools, milestone Unknown

Changed in phablet-tools:
status: Confirmed → Fix Committed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package phablet-tools - 1.0+14.04.20131129-0ubuntu1

---------------
phablet-tools (1.0+14.04.20131129-0ubuntu1) trusty; urgency=low

  [ Jean-Baptiste Lallement ]
  * Add script phablet-screenshot to take screenshots on devices running
    Mir. (LP: #1238839)

  [ Ubuntu daily release ]
  * Automatic snapshot from revision 230
 -- Ubuntu daily release <email address hidden> Fri, 29 Nov 2013 09:47:03 +0000

Changed in phablet-tools (Ubuntu):
status: New → Fix Released
Changed in phablet-tools:
status: Fix Committed → Fix Released
Inoe (inoe-oke) wrote :

How about the problem in maguro? Will it be left out unsupported or are there any plan to fix it?

@Inoe, I don't have a maguro, and it has been reported that cat'ing /dev/fb freezes the device. If anyone knows a safe method to dump a frame buffer on maguro, please stand up or better provide a patch. Thanks.

on Mako it capture only black screen - image#205

Marcel Hörz (marzel) wrote :

To the script of lp:~jibel/+junk/phone-tools

This only show:
E: Device '' is not supported.

Then I saw, that there is no ro.cm.device in getprop.

Now, I'm only getting black pictures...

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments