How to run Landscape oriented Web-Apps on the Tizen 3.0 Feb milestone under Crosswalk? - open-source

After creating a number of landscape-oriented Tizen Web Applications, and building and installing on the box with the Feb 1 Tizen release image using Crosswalk and other boxes with previous images of Tizen, I've discovered that web-applications on the February image will not launch successfully unless the weston.ini files are set to a transform of 90, or 'portrait orientation'.
I've been unable to get web apps to launch in landscape and I'm looking for clues. I have compared packages from the october image and a great many of them have changed. I get a timeout when launching with "xwalk-launcher". I have also attempted to launch with app_launcher.
Service 'org.crosswalkproject.Runtime1' could not be reached: Timeout was reached
I am able to launch these apps successfully in portrait orientation but not in landscape. If you have any ideas about where this problem could be, please let me know. I am looking to find which packages are responsible for the problem.
If you've gotten web-apps running in landscape orientation on HDMI on a VTC1010, how did you do it? Which packages did you change, add, or uninstall? What did you add to, or remove from your configuration files? How did you change your web-apps to counter this specific problem?

It is not possible to run Landscape oriented Web-Apps on the Tizen 3.0 Feb milestone under Crosswalk at this time.
The Crosswalk team at Intel have verified this as being a Tizen bug. The appropriate JIRA issue numbers are TC-2501 and XWALK-4115.
For more details: "I've been using the VTC1010 for testing. My primary choice for display output is HDMI. I have noticed that crosswalk isn't developed for multi-screen yet and I wonder if this could be part of the problem. I have been able to get the Landscape to work on VGA and this can help us move forward but our target is HDMI.
I have also been able to get Landscape to work on HDMI but only under the right conditions. When the VGA is connected the apps will launch on the VGA screen from the start. Once the VGA is disconnected apps will fail with the same error message. After reconnecting the VGA screen the apps will launch on the HDMI port.
It appears the VGA must remain connected. If you boot the box without VGA and just HDMI the apps won't start on boot. You cannot launch the apps by hand. You then connect the VGA display and the apps will launch on the HDMI display. I have found if you disconnect the VGA display the app will shutdown. This is some kind of hard dependancy on the VGA display for the VTC1010."

I believe the problem is in the fullscreen-shell.so.
I have a working fix going forward. Two changes are required for this to work.
remove the line in /etc/xdg/weston/weston-genivi.ini
shell=fullscreen-shell.so
Your apps will launch now but not in fullscreen. To correct this add --fullscreen to weston call.
Add a parameter --fullscreen to line in /etc/session.d/user-session.
weston -i0 --log=$XDG_RUNTIME_DIR/weston.log --backend=wayland-backend.so --fullscreen
I would like to know if there are any reasons for fullscreen-shell that I am not thinking of.

Related

Can I access an USB HID in Chrome without an App?

I want to use an USB HID from a website. The website will only be accessed by Chrome browsers. The solution should require a minimum amount of extra software and setup for the website user to work.
The USB device presents itself as USB HID to the OS and I need to write and read byte arrays to and from it in order to implement the manufacturers specification for some of the device's features.
My current solution consists of two parts:
A Chrome App that uses the chrome.hid API to talk to the device. This App exposes a Chrome Cross-Extension messaging port to provide and interface for "service calls".
JavaScript code on the website that sends requests to the Chrome App, which then talks to the USB device to process the request.
In order to make it easier for the user I want to get rid of the App, so the user can just surf to the website, grant access to the device if necessary and then be able to use the device.
To be clear, I want the user to be able to use the website without installing any dependency first.
I already tried using the WebUSB navigator.usb API but Chrome blocks access to USB HID devices. Is there another way to accomplish this?
WebHID is being developed for this use case. It has been available behind a feature flag since Chrome 78, with an original trial expected in Chrome 84 (probably later due to current Covid-19 situation), estimated stable August 2020 .
For more details: https://github.com/robatwilliams/awesome-webhid

Run Windows Phone App in background without UI

I am developing a Windows phone 8 app that need to run only in background with UI. Is there any way I can run the app in the background, or without actually being open?
It depends upon what you want to do in the background. Generally speaking you can't implement something like a Windows service that will startup automatically when the phone is launched.
That said you can run your app in the background within given limitations. Check out MSDN for detailed information.
Why all these limitations you might ask yourself? It's to provide a good battery life to the user.
Edit:
For the periodic agent to start running the app must be started once. Further the agent must update a live tile (user must pin it to the start screen) or the app has to be once opened every 14 days.
Another option might be using push notifications to trigger an update..

Create a background service in Windows Store Application

I'm new in development Windows Store applications but I have some experience in Android.
Is there any analog of Android service in Windows Store Apps?
I need some service to run on a background, for example, service that writes to file some information when application is not active.
I read about BackgroundTasks but it's not what I'm looking for.
Windows Runtime was designed for maximum battery life so there are not any Windows Store "service" applications. The closest thing would be Background Tasks, which you have said will not work for you.
From the MSDN Blog article Being Productive When Your App Is Off Screen:
The Windows Runtime does provide facilities for doing things in the background, such as:
Background file download or upload
Background audio
Sharing
Device data sync
Live tiles
Scheduled notifications
Background tasks (mentioned above)
I would suggest taking a look at the above article and see if any of the listed things will work for you.

Any Tips for getting Windows Phone 8 Resource Intensive Task to Run?

I have been trying to get a Resource-Intensive Task background agent to run in release mode after deploying to the phone for several days and have never seen it run. Has anyone got this to work outside of the debugger? How long did you have to wait before it ran?
I am able to launch and successfully run the Resource-Intensive Task using the LaunchForTest but have never gotten it to run as it should in release mode even though the task shows that it is scheduled. I have followed the samples and the phone should have met the requirements for launch. I have set the manifest up for auto-upload as well so shouldn't need to set an expiration date on the task.
The phone is plugged in and charging and battery is 100%.
The phone has wifi access.
The phone is on the lock screen and left this way over night for 2 nights.
I have tried this both on a Nokia Lumia 920 and HTC699OL
I am able to get a Periodic Task to run but not the Resource-Intensive Task. If the Periodic runs, I'm assuming I have configured everything correctly in the WMAppManifest and the Resource-Intensive Task should run at some point?
The Resource-Intensive Task shows the following:
IsEnabled = true
IsShceduled = true
LastScheduledTime: 1/1/0001 12:00:00
ExpirationTime: 12/31/9999 11:59:59
LastExitReason: None
The app shows up in the Settings > Background tasks > advanced.
Running the Store Kit test shows no API call problems for the phone application and I have a reference to the agent project from the main phone app project.
Here is my WMAppManifest setting for the agent:
<ExtendedTask Name="BackgroundTask">
<BackgroundServiceAgent Name="SML.Sync.WP8.Agent" Specifier="ScheduledTaskAgent" Source="SML.Sync.WP8.Agent" Type="SML.Sync.WP8.Agent.BackgroundUploadAgent" />
</ExtendedTask>
This seems correct based on the MSDN documentation here: MSDN Task Element documentation
Here is the auto-upload extension, which follows the Tokens node:
<Extensions>
<Extension ExtensionName="Photos_Auto_Upload" ConsumerID="{5B04B775-356B-4AA0-AAF8-6491FFEA5632}" TaskID="_default" />
</Extensions>
I have also tried it without the auto-upload setting and had the same result of never running.
I have also tried getting the example from here http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202941(v=vs.105).aspx to run but after removing the debug_agent and deploying as release mode, I see the same issue, never gets run even though it says its scheduled - periodic does run just not resource-intensive.
I know that the documentation says that it may never run but it seems like 2 days passing and meeting the task requirements should work. Do I need to wait a week to see if this sucker runs?
Would be greatly appreciative of any guidance or tips if you have gotten a Resource-Intensive task to actually run in release mode.
I opened a support incident with Microsoft on February 4th 2013 and heard back from them February 5th with the following:
I collaborated with the internal Windows Phone developers and
confirmed the following:
ResourceIntensiveTask (i.e. Resource Intensive Agent) does not get triggered in the Windows Phone 8 operating system in Release Mode.
FYI, Auto-upload uses ResourceIntensiveTasks, so it does not work in WP8 either.
A fix is scheduled for inclusion in a future Windows OS update, most likely later this spring. The fix needs to propagate through the
OEMs who build their hardware-specific versions of the Windows Phone 8
OS.
There is no known immediate/official workaround.
The recent GDR2 update has fixed this. I verified that Resource-Intensive Task is running on my phone.
If you want to upload something in background, maybe you dont even need this Task. You could give this a try:
http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202955%28v=vs.105%29.aspx
Sample is here:
http://msdn.microsoft.com/en-us/library/windowsphone/develop/hh202959%28v=vs.105%29.aspx

How to disable screen saver in WinRT

This is how you do it on Windows Phone 7 http://blog.jerrynixon.com/2011/11/mango-sample-lock-and-run.html is it possible in Windows 8?
This sample is showing you how to implement the functionality so your app will still "run" when the device is locked. It only seems to work with a kind of "background tasks" which makes it not exactly the same as it is for Windows Phone.
http://code.msdn.microsoft.com/windowsapps/Lock-screen-apps-sample-9843dc3a
Please note that an app that can run when the device is locked should have at least one of the following background tasks:
Control Channel
Timer
Push Notification
Here is some more info on the lockscreen: http://msdn.microsoft.com/library/windows/apps/Hh779720
UPDATE:
As far as I have found there is no exact behaviour like in Windows phone to run your app under the lockscreen. There are a few recent posts on the MSDN blogs which explain the background model http://blogs.msdn.com/b/windowsappdev/archive/2012/05/16/being-productive-when-your-app-is-offscreen.aspx?wa=wsignin1.0
Sorry to see that at this moment there is no way to make it work under the lockscreen