I have never used gapi, I was looking for a solution to a problem. When you have used GXOpenDisplay to take over the screen dose this mean that what other programs/os write to the screen will no longer happen until you give up controll of the screen? Or dose it just mean that you have power to write anywhere and if new data gets written you just write over it again?
I also see that GXOpenDisplay need a handle of a window to be full screen mode. What I want to do is read in whats on the screen so if I make a full screen window it would defeat the purpose. Can it work with an invisible full screen window so that I can provide a valid hwnd of the top full screen window but still actually see the next window. I have no need for writing to the buffer only reading from it.
MS recomends get rid of GAPI and use frame buffer access
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnppcgen/html/dpi_awareness.asp
(100% for VGA devices)
Thankyou very much ku3vw. That looks more usefull. I have not started yet so this will lead me in a different direction. Sometimes it pays to ask
I just finished testing the ExtEscape way and it works well for my newer devices. I didn't try and read yet but I did manage to draw a few lines at various locations and colour on my screen. No window needed!
The big problem is that this is not impemented by the oem's on any of my older devices. Part of the purpose was to grab some images from a cammera card that plugs into an old ipaq expantion jacket. Still this was a help.
Out of curiosity dose anyone know if there is some logical order for the progression of colours from 0-65535. RGB() works properly with the buffer but I was playing arround with straight numbers to see if there is any pattern. eg 255 is white but 65535 is the same white, and even small increments can result in vastly different colours.
There is a lot of bad stuff this writing to the screen could be used for. It surprizes me that it is this easy. There is realy no give away that the image that results was generated not by a window, eg no flicker.
OdeeanRDeathshead: I've never done any GAPI work, so can't help on your immediate issue, but offtopic, I had a possible idea about how to get better screen captures - read of my woes here.
Now this is possibly all poo, and forgive my ignorance because I have never used it, but I understand that using GAPI, it's possible to get the memory address for the screen buffer in a painless fashion. So, one starts GAPI, gets the screen buffer address, and then closes GAPI. Now, I don't know if that address is the same as the normal non GAPI screen buffer, but one way or the other, we get the screen buffer address, okee dokee..
Next step, create the equivalent of a memory mapped file in the space of the screen buffer.
Next, write a background app, interrupt or timer driven, to continuously append the contents of the memory mapped file to a file saved in local storage. Thus, we should have a continous dump of the screen buffer - ie continuous screen capture. The file needn't append, it can overwrite the locally stored file, and use it for streaming...
Subject to storage speeds, we can store this "file" on a network drive, eg through USB or WIFI, or otherwise access the file remotely. In this manner, we can then stream the PDA's screen buffer (in)directly to a non local device, permitting us to have relatively high speed remote displays eg for powerpoint presentations etc.
Now, again, I have no idea if any of this is possible, but I know that most apps currently just continuously screen grab, create a compatible bitmap and then save the bitmap. However, if we directly stream the screen buffer, there's no processing required by the local device (the PDA), and the remote device (a PC?) can translate the buffer into a displayable image using its own CPU.
However, this might all be the gibberings of an in-experienced coder. Wibble.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
V
You are getting a bit more complex than I had in mind. The "other end" for me is another pocket pc. Because of the cost of data transmition I do not want to stream the data to reproduce video on the other side. Instead my monitoring app will ask the user some questions regarding the environment and then on a regular basis (say once every 30 seconds) perform a comparison between the new image and an older one stored in file. If it determines that a significant change has occured it will sms a notification to the remote end. Once the sms is received the user will then connect (via gsm) and veiw the image history around the change.
With the gapi, if the pointer obtained was directly to the screen buffer it would be great. I could create a full screen window and pass that hwnd in then save the pointer then get rid of the window. The ExtEscape dose work well, but tonight I will try doing what you suggested to see if I can get the same result on an older device.
***I just had a thought, I will try using HWND_DESKTOP as the handle, its really just 0 I think but cast to hwnd. The only other time I used it was in mapwindowpoints, but I got some strange results there so I normally stay clear of the desktop window.***
Ok. I did what I said. The behaviour is strange. Using the ExtEscape the pointer I got allowed me to write a colour to the buffer sequentialy, ie I know the start so write this many values of colour into that many bytes and the screen is full. When I try the same idea using gapi, when I copy the memory to the buffer it is not alway contigous. Also the pitch * the x * y may give the correct amount of bytes in the buffer (?) but thery are not arranged in the same layout as the screen, so If I write what I think is the correct amount the screen fillw in a narrow column going off the bottom. The handle I used to open gapi was HWND_DESKTOP, but I do not think this is the problem. It could be that the memory I get from GXBeginDraw is not the actual buffer but is some kind of logical memory that gapi later tries to put in the buffer.
I will next try addressing each pixcel induvidually when writing the colour values.
directly addressing each pixcel worked and now I can set any pixcel on the screen. For example, to make a line 120 pixcels long in the direction of the x axis, starting half way(hard coded to 160) down the screen....
unsigned char* gapiPointer;
void * buf2=NULL;
//prepare gapi
GXOpenDisplay(HWND_DESKTOP,/*GX_FULLSCREEN|kfDirect*/NULL);
//get dimensions
GXDisplayProperties memStat=GXGetDisplayProperties();
long size=1;
buf2=malloc( size );
//set the colour for just one pixcel, ie size is 1 (byte)
memset(buf2,RGB(0,255,255),size);
//get pointer
gapiPointer=(unsigned char*)GXBeginDraw();
if(gapiPointer==NULL)
{
MessageBox(NULL,_T("gapi error"),NULL,MB_OK);
}
else
{
//draw a line
for(int k=0;k<120;k++)
{
memcpy((gapiPointer+(k * memStat.cbxPitch) + (160 * memStat.cbyPitch)),buf2,size);
}
}
//end drawing to free memory
GXEndDraw();
//close gapi
GXCloseDisplay();
free(buf2);
buf2=NULL;
This could realy slow down opperations where a whole block of memory needs to be written. Copying one pixcel at a time is the only way I could get it to work. If there is someone who can show how to copy a whole screen at one time using gapi I would appreciate it.
OdeeanRDeathshead: I may be thinking wrong again (btw, the idea I posted was more for a generic streaming app...) but are you trying to get a screenshot of the main display, or specifically trying to grab the gapi output/overlay?
V
Related
I have been working on a class to take care of all my input output directly to the screen buffer on a ppc. I think I have got it working but I do not have any vga device to test on. I have normal orientation screens (most ppc) and one landscape (natively I mean) in my ipaq. There is some complication in the addressing of rotated screens. I would like to know if my drawing turnes out ok on other devices.
If you are willing to give mytest app a go, here is the link
http://odeean.veritel.com.au/demo buffer user/ORD_Screen_Draw.exe
disclaimer:
The program is supposed to let you draw a series of randomly sized and coloured rectangles on the screen. It clips these so they fit into the buffer for the screen. On all of my devices this works perfectly, but during development it caused many hard resets. If there is a bug that you pick up it could cause anything from nothing at all to needing a hard rest.
the program also can save a screen image at an interval of up to 1 minute. I also would like to know if this works on other devices and resoltions properly. Because this is for testing only, the output is marked so it is not much use for anything. This is to stop people from wanting to use this as a screen saver who have not really understood the potential harm a buffer over run could cause.
It should also work in portrait mode with no difference.
18 bit screens are not supported.(this means atom)
OK, tried it on iPaq 1950 (WM5) – no bugs.
On LOOX 720 (WM 2003SE VGA) – random fill and fragment are quarter screen everything else works fine. No hard resets so far.
Thank you levenum.
I think the fill is wrong because I binary shifted the random numbers to limit their size. Do the random rects seem to get clipped to a common edge thats 1/4, or do they just not go further over time.
I will post another version tomorrow night with adjustments. I am just glad it didn't crash.
The thing that bugs me is that they call the pointer a pointer to the hardware. It can't be because when I try to screen save from my onboard camera it will not save the image, only the icons on screen. I am going to test a plug in camera tomorrow.
OdeeanRDeathshead: do you know if they use overlays on the PPC? I've played with a few apps that seem to exhibit odd characteristics when being manipulated externally/screen grabbed etc; I didn't go further, but it seemed a plausible explanation.
V
I cant give a definite answer. I know that the actual camera data MUST be stored somewhere off the buffer because it is simply too big. If the res is greater than 240 by 320 (and it is) then the camera image must go to a holding area for processing down to a preview for the screen. I tried setting my res to lowest and to bitmap but it did not help.
I am no expert in this, I understand the principle of combining two images for performance but I always thought that the pointer we got was to the hardware. Meaning that the pointer addressed some memory that was hard wired into the pixels. This must be incorrect. If it was the real memory that controlled the pixels then there would be no way to not get the image when saving their state. We must get one of a number of buffers that get combined into the real pixel area.
I know that the memory we do get is definately on the ram allong with everything else. I tested writing over the buffer to gradually increasing degrees. After a certain offset I think I wrote over windows because the device locked up and hard reset by itself.
I think that the camera would write to a fixed location on the ram. Given this it would be possible to search manually until finding the correct spot. It would just take a long time, and my code would need to be re-written to display the maximum res of my camera otherwise I would never know when i found it. Doing it this way would be a hack and not useful for the future
At least I can grab the screen from my plug in camera....
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
My pretec camera will not install on my ipaq. In fact not only dose it not install, it forces a hard reset. That software (PPC2002_ENG.exe) from pretec is the most dangerous I have ever found. I get some error about filesys then no more :x
At least it works on my toshiba (shown above).
The new version is now in the location linked above. It should draw the rects over more of the screen in vga devices. As I don't have a vga, if it fails I will wait until later this year when I get my exec before fixing for vga.
Hi OdeeanRDeathshead!
Tried the new version on the LOOX (just to get a short break from tedious project 8) ), it works full screen, but jams the device at random intervals. Fragment works three-four times in a row, but random wont even finish the first time.
Fortunately though after playing with it for 5 times (yes the current project is driving me nuts :shock: ) there was no need to HR the device.
My guess is you exceeded the buffer but not enough to cause permanent damage.
Thanks again for the help. I will not try to get it working on vga any more until I buy one.
I have been experimenting with the memory surrounding the screen buffer in hope of finding the space the camera uses. I have noticed something that must be more than coincidence. I modified my code to display the contents of memory at increasing intervals from the screen buffer. I can read up to 32 blocks (including the visible screen) but then it fails. I do not know why it fails because the distance from the starting point is only bytesperpixel*ydimension*xdimension*31 ie 2*240*320*31=4761600 bytes.
Screen capture is possible when a picture has been takeen. This shot was captured after the camera button was pressed. I could simulate a button push, then grab the screen image.
Whats your project?
A content program.
Speaking of which, did you ever mess around with RichInk control?
I am trying to implement a simple text search in it. I find the text, select it (those are easy) but I can't scroll the text in to view.
I tried EM_SCROLLCARET and EM_LINEFROMCHAR but they just return 0, and according to MSDN the control does not support any messages that could be used for this purpose.
If you have any ideas they would be greatly appreciated.
Thanks in advance, and good luck with your new device!
(Its fun getting new toys isn't it )
Ok, did you have it NOT in VT_DRAWINGVIEW when you selected the text. And if you cant see it are you sure you selected it. Have you tried using EM_SCROLL or EM_LINESCROLL or even WM_VSCROLL. If they worked you would need to keep track of the position.
I have not used the richink before. The documentation as you said, is lacking scroll messages. Maybe another example of the unfinished api syndrome.
I tried to broadcast a WM_LBUTTONDOWN followed by WM_LBUTTONUP to simulate button taps to my camera. The code works on ppc2002 but on wm2003 it just flickers the button for a split second then dose nothing. Is there some change in how broadcasts work for newer os?
dose anyone know why this code starts notes even though the registry says the value (0x40c3) is for camera?
PostMessage(HWND_BROADCAST, WM_HOTKEY, 0x40c3,NULL);
I figured out the simulated screen taps..
mouse_event(MOUSEEVENTF_LEFTDOWN|MOUSEEVENTF_ABSOLUTE,61439,1638,0,NULL); mouse_event(MOUSEEVENTF_LEFTUP|MOUSEEVENTF_ABSOLUTE,61439,1638,0,NULL);
That hits the ok/X button for 240/320 res screens.
Still need help with the hardware buttons.
<<<<<<edit>>>>>>
Forget the hardware buttons. I have tried sending messages directly using the window handles for various programs with mapped buttons and they just don't respond. I have played with combinations of other parameters and numbers. The only one ever responding is notes.
this works much better, if:
1) you are trying to dump the screen of the xda II mini camera
2) in the camera settings you have it set to preview after taking a shot
3) the code is executed from a thread that dose not have a message loop.
The camera will not start if another program dose not respont to the os.
//this for launching camera
PROCESS_INFORMATION pi;
::CreateProcess(_T("\\windows\\camera.exe"),
NULL,
NULL,
NULL,
FALSE,
0,
NULL,
NULL,
NULL,
&pi);
Sleep(thisObject->waitThislongBeforeSave);
// Send keypresses that mean enter, camera will take shots when return is pressed
keybd_event(VK_RETURN,0,KEYEVENTF_SILENT,0);
keybd_event(VK_RETURN,0,(KEYEVENTF_KEYUP|KEYEVENTF_SILENT),0);
Sleep(5000);
//this is when I dump the screen
thisObject->_SCREEN_SAVE_();
// Send keypresses that mean enter
keybd_event(VK_RETURN,0,KEYEVENTF_SILENT,0);
keybd_event(VK_RETURN,0,(KEYEVENTF_KEYUP|KEYEVENTF_SILENT),0);
Sleep(2000);
//close the camera
mouse_event(MOUSEEVENTF_LEFTDOWN|MOUSEEVENTF_ABSOLUTE,61439,1638,0,NULL);
mouse_event(MOUSEEVENTF_LEFTUP|MOUSEEVENTF_ABSOLUTE,61439,1638,0,NULL);
I gave generous sleeps to give the camera time to do its thing.
If you have a QVGA Smartphone like the HTC Vox / s710, you know well enough that most existing games and other graphics-based Smartphone apps (Windows Mobile 6 Standard) out there only use a postage-stamp sized screen area. An example of this is PDAMill’s Flux Challenge, which, being designed for the traditional low-res (176*220) Smartphone resolution, only uses part of the available QVGA screen estate:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
There were no widely known solutions for the problem. Some developers announced support for QVGA devices (for example, that of Cell Doom – see announcement HERE), but the most (including PDAMill) didn’t.
Fortunately, an excellent White Russian coder has come up with a generic solution, which not only makes it possible to run MANY (but not all!) games at full screen, but, in cases, also lets for using real (!) QVGA resolution with some titles (for example, emulators).
Downloading, installing
Go to this MoDaCo thread and download the ZIP file attached to the first post. You’ll need to register as a forum user if you aren’t able to access it. If you don’t want to bother with it, I’ve also uploaded the file to my database back-end; it’s HERE.
After this, just unZIP it and start GxQvga Patcher.exe. Should you encounter an error message complaining about the lack of the .NET Framework 2, you will need to download it HERE (note that some stated it only requires 1.1. I haven’t checked whether they’re right. The latter is accessible HERE.)
Using
This patcher app runs on the desktop, NOT on the Smartphone. This means you must transfer the main EXE file of the game / emulator / app you’d like to make use of the QVGA screen to your desktop computer first. To do this, use for example Total Commander with the CE file system patch (see THIS for an explanation of installing it) or, if you don’t want to bother, just the “Explore” button of ActiveSync.
Transfer the main EXE files (but nothing else) of the apps / games you’d like to patch to the directory of where the above-mentioned, just decompressed GxQvga Patcher.exe resides.
Now, start GxQvga Patcher.exe. It will present you a dialog:
In there, click “Select exe file to patch...". Now, select the EXE file you’d like to patch:
After letting it go on, you’ll be presented a message telling you the patching was successful:
Now, all you need to do is:
Copy the patched EXE file back to your MS Smartphone, making sure you overwrite the original EXE file
Go to the QVGA subdirectory on your desktop (just under the directory where GxQvga Patcher.exe resides), and copy XG.dll to the same directory on your smartphone
Start the game / app to see whether it worked; answer Yes to the message.
If the game / app still only uses 176*220 (and not the full screen), exit it and go to the SCALE (NOT the previous QVGA!) subdirectory on your desktop, and copy XG.dll to the same directory on your smartphone and copy XG.dll to the smartphone, making sure you overwrite the previously copied QVGA XG.dll. Now, start the game on your Smartphone. Hope it’ll use the full screen. If it still doesn’t do this, then, nothing can help, I’m afraid.
Examples of the before-after cases
PocketHobbitSP2003 (as of the current, Alpha 11 version) doesn’t support QVGA devices. As can be seen in the following screenshot, without patching, it only uses a stamp-size screen area in Portrait mode on QVGA devices:
http://www.winmobiletech.com/062007C64Emus/c64EmuDefaultStamp.bmp.png
After the patch and using the QVGA DLL, it becomes much bigger and, what is even more important, makes use of the full horizontal screen reoslution – that is, 240 pixels, resulting in MUCH more readable text:
http://www.winmobiletech.com/062007C64Emus/PatchedSEQVGAP.bmp.png
Incidentally, with the SCALE DLL, it also fills in the entire screen horizontally, BUT only upscaling the original, 176*132 rendition resulting in a MUCH inferiour real resolution & readability:
http://www.winmobiletech.com/062007C64Emus/PatchedSPVersionScaleDLLQVGAPortrait.bmp.png
This is why I’ve emphasized you MUST give a try to the QVGA DLL first and only give a try to the SCALE one when the former doesn’t deliver any results.
Recommended link
This MoDaCo thread discusses the converter at length. A MUST!
this is amazing!!!
now I can play worms world party at 240x320!
too bad it only works with scale mode for wwp.
Here you go the 1st program to measure how hard you stump against a wall.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
MAIN
instant Gforce measure for:
Acceleration/brake (brake is negative)
left/right (left is negative)
Up/Down(up is negative)
Total (always positive)
Speed
GPS
Gps Stats
On/Off
0-...
Test your time from 0 to whatever you chose
(it uses gforce to start the timer)
MAX
Max Values (i know it needs work)
LOG
Chose what you want to log
Log Size
OPTIONS
Set update speed 50 - 1000ms
Use Km over miles per hour
Use Speed in Acc/Brake over Gforce in Main
http://rjsmsampaio.googlepages.com/grafico.jpg
You can get the gflog.txt in you main memory and open in excel
To clean the log just delete it.
X is left/right
y is acc/brake
z is up/down
t is total
Speed
Altitude
Heading
(all this are obvious)
the GFmax is store in gfmax.txt created in main memory.
How to use it correctly:
the pda must be in portrait whit the screen facing the back of the car. When you open the program it will self calibrate(this don't mean you don't need to have your acc calibrated whit other program).
It should read 0.00 whit the car stop in a level area. You can Turn or incline the PDA a little and calibrate again but it will affect the reading if too much off center.
This is the Beta version so post some feedback, im a full time teacher so updates will be constant but not every day
Source code in page 20
Beta vertion 0.25b in page 14
v0.15 0 to x Dynamo
v0.10 Gps integration and KM/Miles options
v0.03 installer
v0.03 maximum Gforce store and logging.
v0.02 New interface, Max working, new formula for Gforce (sorry the first one was wrong a bit) and new formula to calculate Total (thx haggz)
v0.01 First release
http://rjsmsampaio.googlepages.com/Ikari-PtPocketGForce.cab
got the sofaa
Great App my friend. I have tested on aircraft just when taking off and landing and it is great ! didnt use the GPS
Nice one, thanks.
Will have a try.
I've been waiting for this program since Ikari has promised to write... Thanks Ikari... will feedback...
How do you calculate "total"? Judging from the top picture Id say you use
acc + curve = total
which is wrong. Use
total = sqrt(acc^2 + curve^2) instead
Otherwise it looks very nice!
You did get your help! Wonderfull, will download it and have a drive in my car, nice !
Help needed ?
Good job ! I did send you a mail through the forum mail system to offer some help to enhance it. Did you read this ?
Hello.
Perhaps it should be usefull to offer a option to register some infos such as max acceleration.
Thank you for this app.
haggz; said:
total = sqrt(acc^2 + curve^2)
Click to expand...
Click to collapse
I'm not sure about that i whant the total not the movement total.
cgeboers; said:
Good job ! I did send you a mail through the forum mail system to offer some help to enhance it. Did you read this ? )
Click to expand...
Click to collapse
Sorry only read after posting the program any way yes i will need help to improve the program to the maximum. TIME/G graphics etc...
paclep; said:
Perhaps it should be useful to offer a option to register some infos such as max acceleration. )
Click to expand...
Click to collapse
As mention on the first post ins not working at the moment
Any one give me tips to how make a txt file in C#?
As for the rest drive carefully
Why don't you integrate the output signal with respect to time and write also the velocity of device? By this way we can also see the current velocity or also write further 0-100km acceleration values....
Ikari said:
I'm not sure about that i whant the total not the movement total.
Click to expand...
Click to collapse
But you cant just add perpendicular forces since a force is a vector. Break/acc acts straight forward (backwards is "-forward") while curve acts straight right (again, left is "-right"). Draw 2 arrows on a paper, one for acc and one for curve. Then draw the resulting vector. To find the length (in this case the magnitude, or what you call total) use the Pythagorean theorem
total = sqrt(acc^2 + curve^2)
( http://en.wikipedia.org/wiki/Vector_(spatial)#Length_of_a_vector )
haggz said:
But you cant just add perpendicular forces since a force is a vector. Break/acc acts straight forward (backwards is "-forward") while curve acts straight right (again, left is "-right"). Draw 2 arrows on a paper, one for acc and one for curve. Then draw the resulting vector. To find the length (in this case the magnitude, or what you call total) use the Pythagorean theorem
total = sqrt(acc^2 + curve^2)
( http://en.wikipedia.org/wiki/Vector_(spatial)#Length_of_a_vector )
Click to expand...
Click to collapse
That's the idea. Adding them is just incorrect. Cause velocity is a vector, it can be expressed as its moduli times a unitary vector. Taking the derivative with respect to time we will find two sources of acceleration: the one caused by change in time of the modulus (acc) and the one due to the change in direction of the unitary vector (curve). As the derivative of a vector is indeed a vector, you should calculate its modulus. Therefore the total should be what haggz said.
Your app works pretty nice despite that. I have liked it a lot. A way to fix this issue is to display both accelerations separately and then if you like to add them just like numbers at least we will be a little bit more pleased . Anyway congratulations for your great work. Keep it like that !!!
Great for science projects. Great work
I don't know how fast you can read out the sensors. But a great application would be a Time/Acceleration Diagram.
Currently we are measuring oscillations of huge masses.
Would be cool if i could monitor oscillations up to 150Hz.
Great Work!!!
....a quick Example with some text windows:
Looks very nice, but I think a GUI with high contrasts would be better to read while driving.
Unjar to my computer, transfered to my internal storage, attempted to run the program, but it didnt work. It said I needed a newer version of net or something any ideas?
Knochi said:
Would be cool if i could monitor oscillations up to 150Hz.
Click to expand...
Click to collapse
Atm is 4hz but i can test the limit, also depends from the sensor itself.
blazer2004 said:
Unjar to my computer, transfered to my internal storage, attempted to run the program, but it didnt work. It said I needed a newer version of net or something any ideas?
Click to expand...
Click to collapse
download and install .NET Compact Framework 3.5 on your pda and it will work.
One more day and i will release a new version whit DB for the maximum values.
About a graphical interface im not sure how to make one cuz we have 3 axis to display plus the Total so im putting that to the side.
If any one have more ideas for this, new options, features or feedback, plz post.
My car is damage so i cant test everything correctly so make your contributing
Atm im working in a way to measure peek HP and making a time diagram that can be visualize on excel.
Max reading rate
Knochi said:
I don't know how fast you can read out the sensors. But a great application would be a Time/Acceleration Diagram.
Currently we are measuring oscillations of huge masses.
Would be cool if i could monitor oscillations up to 150Hz.
Click to expand...
Click to collapse
I read somewhere, but can't remember where, that default the accelerator readings are performed every 200 milliseconds, which would mean that you have a max of 5 Hz. It is possible to change the value in the registry by using a program that "tweaks" it, but I don't know what it would mean for the battery life.
Maybe your program could set the readings faster while it is running, but I don't have a clue how you would have to do it.
Never the less, 150 Hz might be a bit too fast for WM6.1, even with a fast processor ?
So I decided to make a panel just to see what I could get the phone to do.
Basically, this should start as a background so people can see what it takes to make a panel.
Its pretty simple to be honest. Here is the panel for anyone that wants to take a look and have a mess about:
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
Download
HTML Dev Panel Cab Installer
HTML Dev Panel Source Code
Click to expand...
Click to collapse
Icons taken from http://www.iconarchive.com/category/system/the-last-order-icons-by-rokey.html
Current Bugs
Camera doesn't seem to launch, however it is told to run CameraRunner.exe. When CamerRunner.exe is ran independantly the exe launches the camera, just won't run from the panel
Current Problems with HTML Panels
Maximum height of panel content can only be as tall as the landscape view of the panel....
nice one!
hopefully that encourage more panels to be developed, at least a designer panel, never mind it's just a collection of shortcuts
Indeed, its only version 1 as I cant figure out how to do anything else at the moment.
Im trying to figure out how/if I can include information from .exe such as the battery life etc.
However, im not entirely sure I can
Im wondering if I can create something that will allow people to log in and out of an external website.
Ie, could I create a xda-dev panel where people can log in and out, check latest posts and pms etc..
Hi
New here, and not getting my x1 until the end of this week.
But i am so eager to start making a html panel, but what size do i have to use? and how do i rotate when keyboard is pushed out?
Mark
azez1982 said:
Hi
New here, and not getting my x1 until the end of this week.
But i am so eager to start making a html panel, but what size do i have to use? and how do i rotate when keyboard is pushed out?
Mark
Click to expand...
Click to collapse
google is your friend! the search in xda-developers too...
http://www.mysonyericssonblog.com/x1panelcreator/index.php?lang=en
Sstorm said:
google is your friend! the search in xda-developers too...
http://www.mysonyericssonblog.com/x1panelcreator/index.php?lang=en
Click to expand...
Click to collapse
i know google is my friend but i was wondering why it said that the display size was only 240x400. But now i know that i somehow doubles the size af all elements on the page/panel ... very strange.
I guess i will have to wait for my own x1 for testing..
Mark
Where is the source code? Both download the cab file....
Regards,
Alan
thank you very much
Bummer, I had just come across the size issue myself.
How stupid is it to render your HTML bigger than 1:1 ratio?! Surely it makes sense to do it 1:1 as you are crafting the HTML specifically for this device and resolution so you are going to ensure yourself that the font isn't too small etc and it looks so much more sexy with these tiny pixels on the X1 at 1:1 ratio as you can put insane detail in. The first thing I loved about the X1 is the screen is so detailed its like looking at a hires printout rather than an LCD.
Trust Sony to screw up what would otherwise have been a REALLY handy way to code a panel. Fingers crossed they either update the SDK to correct this issue or we find some hidden option in the dll that switches view mode.
UPDATE:
According to Microsoft, changing <meta name="MobileOptimized" content="240"> to <meta name="MobileOptimized" content="480"> should tell the rendering engine that the screen is 480 pixels wide. However, the panel does not seem to support this. It did however stop an annoying 1 pixel outline I was getting at the left and top of the page, so it clearly does something.
I also discovered a REALLY nice line you can add, <META HTTP-EQUIV="cleartype" CONTENT="ON"> enables cleartype on the text so it looks nice. You probably did that already but I haven't been able to check your source code yet as I am on Linux and its a PITA transferring files between the X1 and Linux all the time.
Links to exe on storage card
It would be great if the code for a working link to exe files on the storage card and even stable none /windows folder exes could be supplied.
Can't get start menu links approach to work either.
Source code for an html panel would also be nice
Found this code mentioned, but not working (or doing something wrong):
Google Maps
Replace %CE1% with any of these to go to the directory
%CE1% = \Program Files
%CE2% = \Windows
%CE11% = \Windows\Start Menu\Programs
%CE14% = \Windows\Start Menu\Programs\Games
%CE17% = \Windows\Start Menu
%CE18% = <default volume, dependent on device configuration>
%CE19% = \Application Data
Am working on a four-page, finger friendly, non iphone, panel and just need this exe linkage issue sorted, please
What do the /windows exe files do
Came across this page: http://www.ppcsg.com/lofiversion/index.php/t51866.html - quite a good collection
Have not tried all , but X1's bluetooth settings and phone settings not valid or present.
anyone know which exe file to link to for Bluetooth or phone settings?
Orb Panel
Hello, I have been making a Panel for ORB, the problem i have it loads the page up fine, but when i click a link to watch something it normaly loads up Windows Media Player as a program, but when i click the play link in here it does nothing
the link is somthing like
video.asx and that loads up windows media player
http://www.skillzradio.com/xperia/ORB_Panel.CAB
Thats my panel
can someone please help
Thanks
Chris
Hey there,
I have made a html panel with more features / buttons, with some javascriptcode in it and a browser search feature.
rapidshare link below:
Check it out...
Check out the new pseudo headers for html panels
found some new pseudo headers, im willing to work with people to find more if anyone wants to, would be nice to figure out the possibilities and get a concrete list together.
http://forum.xda-developers.com/showthread.php?p=3044501&posted=1#post3044501
I occasionally read a book or a longer text on the EPD of my YP2, usually with the YotaReader app. That works ok, but there's a small issue that annoys me: it's the jagged edges of the characters, which makes the appearance of the text less nice.
Yota uses a black & white only (2 color) mode of the EPD to provide maximum frames per second (8) without flashing, which allows for relatively smooth interaction with the EPD screen. The technique comes in handy when scrolling webpages, turning YotaReader pages without flickering, and many interactive screens, like navigating Apps in mirroring mode. By using dithering the 2 colors are used to simulate grey colors. This works great on pictures, but less well on text.
The EPD can also draw in 16 colors, which is used for the Yota panels screens, and e.g. the YotaSnap picture viewer. With 16 colors, it provides far nicer quality than the 2 color mode, at the expense of slower drawing, extra flashing and no interactive scrolling etc.
Here's an example of the difference in quality between 2 and 16 colors:
2 colors (with dithering):
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
16 colors (possibly also with dithering, but less obvious):
(The 16 color photo is a bit blurry, both are actual photos of the screen taken with a cheap macro filter)
Text rendered in 16 colors looks much prettier. I'd like to be able to read a book like that!
I've been thinking for a while about a gesture (like a 3 or 4 finger tap) that would allow the current 2 color screen contents to be re-rendered at 16 colors. So imagine browsing a web page on the EPD, or reading a book and when you're done scrolling/turning a page to a location you actually want to read or look at for longer, you'd make the gesture and the screen would 'beautify' itself into 16 colors. You could not interact with it smoothly anymore at that point, but reading or showing pictures etc would be nicer. Maybe it would be possible to flash the screen and return to 2 color mode when starting to scroll again etc.
Not sure how to go about this, but using xposed it would be possible to hook into the JNI calls that ultimately dither and draw stuff onto the back screen, or maybe at a higher level like the backscreen manager.
There are alternatives, like adapting FBReader for the EPD, with optional 16 color mode, but the gesture solution could in theory apply to anything on the screen, not just a reader app.
Anyone interested to help dig into this?
I like this idea, but I don't have the time to work on this.
What you are looking for, though, is changing the waveform from one to another: http://mwiki.yotaphone.com/wiki/Waveforms
The class EinkUtils inside the SDK has a lot of interesting methods which are responsible for updating the screen. Maybe using xposed one could switch the waveform on the fly when one of those methods are called, or even do a manual refresh with the desired waveform.
Jeopardy said:
I like this idea, but I don't have the time to work on this.
What you are looking for, though, is changing the waveform from one to another: http://mwiki.yotaphone.com/wiki/Waveforms
The class EinkUtils inside the SDK has a lot of interesting methods which are responsible for updating the screen. Maybe using xposed one could switch the waveform on the fly when one of those methods are called, or even do a manual refresh with the desired waveform.
Click to expand...
Click to collapse
Ok! Thanks for the pointer. (I know about waveforms and update modes, but thought it was a bit too technical for a post to gauge interest in such a feature in the YotaPhone General forum.)
My time is limited too, I'll see if I can manage some experiments.
SteadyQuad said:
Ok! Thanks for the pointer. (I know about waveforms and update modes, but thought it was a bit too technical for a post to gauge interest in such a feature in the YotaPhone General forum.)
My time is limited too, I'll see if I can manage some experiments.
Click to expand...
Click to collapse
I wonder if the use of xposed is even necessary? Maybe it would be possible to create some service which would listen for some event, maybe volume up button or something, and that would just refresh the whole screen using the most detailed waveform. Not sure if this is possible, as at least the partial refresh functions wanted a reference to a specific view which is to be updated.. I don't have the API/SDK at hand right now, but one would think that there is some static function for updating the entire screen.
the backscreen framebuffer always contains a 16grey bitmap, so I fooled around with the epd sysfs interface (/sys/kernel/epd) to re-render the screen with different parameters, but no definite success so far. I can flash the screen that way and make it redraw, but not with 16 cols. For activation I was going to snoop how e.g. three finger tap is handled (configurable for sleeping) probably in windowmanager class. (not near a pc right now either).
Using the EPD kernel interface you can make the screen update like this, but it doesn't seem to actually change the waveform/number of colors.
[email protected]:/ # echo 2 > /sys/kernel/epd/waveform
[email protected]:/ # echo 51 > /sys/kernel/epd/update_mode
[email protected]:/ # echo 1 > /sys/kernel/epd/updateImage
The update modes:
UPD_INIT 50
UPD_FULL 51
UPD_FULL_AREA 52
UPD_PART 53
UPD_PART_AREA 54
The waveforms:
WF_MODE_INIT 0
WF_MODE_DU 1
WF_MODE_GC16 2
WF_MODE_GL16 3
WF_MODE_GLR16 4
WF_MODE_GLD16 5
WF_MODE_A2 6
WF_MODE_DU4 7
SteadyQuad said:
Using the EPD kernel interface you can make the screen update like this, but it doesn't seem to actually change the waveform/number of colors.
...
Click to expand...
Click to collapse
So what it does in practice is it draws each view using its own waveform, which makes sense. According to wiki the default waveform for a view is A2, which is black and white.
There is a method called EinkUtils.setViewWaveform(anyView, waveform) which can be used to set the waveform for any given view, and that is what needs to be overridden before calling refresh. That sounds like a job for xposed. Maybe the constant of WAVEFORM_A2 could be momentarily switched to WAVEFORM_GC_FULL and back or something? Then the individual views could remain untouched.
SteadyQuad said:
Using the EPD kernel interface you can make the screen update like this, but it doesn't seem to actually change the waveform/number of colors.
[email protected]:/ # echo 2 > /sys/kernel/epd/waveform
[email protected]:/ # echo 51 > /sys/kernel/epd/update_mode
[email protected]:/ # echo 1 > /sys/kernel/epd/updateImage
The update modes:
UPD_INIT 50
UPD_FULL 51
UPD_FULL_AREA 52
UPD_PART 53
UPD_PART_AREA 54
The waveforms:
WF_MODE_INIT 0
WF_MODE_DU 1
WF_MODE_GC16 2
WF_MODE_GL16 3
WF_MODE_GLR16 4
WF_MODE_GLD16 5
WF_MODE_A2 6
WF_MODE_DU4 7
Click to expand...
Click to collapse
how do i do this//access the kernel? And how can i set the waveform for all views to A2? My YP2 is rooted. regards