BricxCC EV3 Screen Capture Tool

Discussion specific to NXT-G, NXC, NBC, RobotC, Lejos, and more.
Post Reply
renchiou
Posts: 7
Joined: 29 Sep 2010, 14:38

BricxCC EV3 Screen Capture Tool

Post by renchiou »

Hi!

I can capture the EV3 screen with test_release20130813.

Image

Now I try to use the screen capture tool of BricxCC (test_release20130822) , the "EV3 Buttons" works fine, but there is blank in "EV3 screen".

Image

Is this my computer's problem? :(

Hunter Chiou
afanofosc
Site Admin
Posts: 1256
Joined: 26 Sep 2010, 19:36
Location: Nashville, TN
Contact:

Re: BricxCC EV3 Screen Capture Tool

Post by afanofosc »

In the previous test release you had to manually put the snapshot executable in the root of the micro SD card either using Windows or via the BricxCC Explorer tool. And then so long as it was in /media/card/ (i.e., the root of the micro SD card) then BricxCC could execute the snapshot executable using the System opcode in that path, i.e., it would call System("/media/card/snapshot -f1") which would write snapshot.raw to the /media/card folder. Then it would upload snapshot.raw and use the data in the file to draw the screen image.

In the newer test release I tried to make this more flexible and to not require the user to manually place the snapshot executable onto the micro SD card in the correct folder. Now, the very first time you try to take a snapshot of the screen it checks to see if the snapshot folder has been determined yet. If it has not (i.e., if the folder name is blank, which it is every time you start BricxCC) then it first lists all files at /media/card/snapshot/*.* looking for a file in that folder called snapshot. If it finds one then it sets the snapshot folder to /media/card/snapshot/. If it didn't find it there then it lists all the files in /mnt/ramdisk/prjs/snapshot/*.* looking for a file in that folder called snapshot. If it finds one with that name then it sets the snapshot folder to /mnt/ramdisk/prjs/snapshot/. If it doesn't find it in either place then it downloads snapshot from the BricxCC folder to /mnt/ramdisk/prjs/snapshot/snapshot and sets the snapshot folder to /mnt/ramdisk/prjs/snapshot/. Finally, it goes on with the normal snapshot taking process.

What may be happening on your EV3 is that there might not be room in the ramdisk for the snapshot executable or the ~3kb file that it tries to create whenever you take a snapshot. You could use the Explorer tool to see if you have a snapshot folder in ../prjs/ or whether you have a snapshot folder in ../prjs/SD_Card/.

One of the reasons for the changes I made was so that that even if you did not have a micro SD card in your EV3 you could still use the Screen Capture tool since it tries to use the ramdisk as the "fallback" location if it does not find an existing snapshot folder with a snapshot executable in the folder. I think that what I will do is have BricxCC check the free memory in the ramdisk whenever you open the EV3 communication layer and if it is too small I can have the Screen Capture tool default to the micro SD card unless it is not present, in which case, I can disable the tool.

You can use the Explorer tool in BricxCC to delete some folders from the ramdisk if you want and see if after closing and reopening the EV3 usb connection whether the Screen Capture tool starts working. Right now you can't create folders via the Explorer tool - something I will add in a future BricxCC release - but you could also manually create the snapshot folder in the micro SD card root using Windows Explorer and copy the snapshot executable into that folder. Then BricxCC will use your SD card instead of trying to use the ramdisk memory, which is perhaps too full on your EV3.

John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
afanofosc
Site Admin
Posts: 1256
Joined: 26 Sep 2010, 19:36
Location: Nashville, TN
Contact:

Re: BricxCC EV3 Screen Capture Tool

Post by afanofosc »

The 20130822 test release zip has an old version of the snapshot binary in it which should be replaced by the one at this link:

https://dl.dropboxusercontent.com/u/534 ... 3/snapshot

I will replace the test release zip soon with one containing the correct binary.

John Hansen
Multi-platform LEGO MINDSTORMS programming
http://bricxcc.sourceforge.net/
Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests