GoogleVR's PermissionsDemo - permissions always denied at Unity - unity3d

Has anyone managed to get a permission granted through Google VR's gvr-permissions-support library?
A demo that is shipped with Google VR plugin that shows how the gvr-permissions-support library can be used to offer the ability to grant runtime permissions. While I was able to run the demo, I was not fortunate enough to be granted a permission.
Specifically, when I click the "Request Permission" button on the demo scene, I get the following exception:
04-22 15:02:53.476 3034-3034/? E/ActivityThread: Activity com.google.gvr.permissionsupport.TransitionVRActivity has leaked ServiceConnection com.google.vr.ndk.base.DaydreamApi$1#3ed206d that was originally bound here
android.app.ServiceConnectionLeaked: Activity com.google.gvr.permissionsupport.TransitionVRActivity has leaked ServiceConnection com.google.vr.ndk.base.DaydreamApi$1#3ed206d that was originally bound here
at android.app.LoadedApk$ServiceDispatcher.<init>(LoadedApk.java:1336)
at android.app.LoadedApk.getServiceDispatcher(LoadedApk.java:1231)
at android.app.ContextImpl.bindServiceCommon(ContextImpl.java:1450)
at android.app.ContextImpl.bindService(ContextImpl.java:1422)
at android.content.ContextWrapper.bindService(ContextWrapper.java:636)
at com.google.vr.ndk.base.DaydreamApi.init(DaydreamApi.java:838)
at com.google.vr.ndk.base.DaydreamApi.create(DaydreamApi.java:141)
at com.google.gvr.permissionsupport.TransitionVRActivity.onCreate(TransitionVRActivity.java:74)
at android.app.Activity.performCreate(Activity.java:6682)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1118)
at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2619)
at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2727)
at android.app.ActivityThread.-wrap12(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1478)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.app.ActivityThread.main(ActivityThread.java:6121)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:889)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:779)
Please note that I'm using Unity 5.6 (2017.1.0b1) and Google VR SDK for Unity version v1.40 (April 2017). My Unity solution's minimum API level is set to Android 7.0 (API level 24).

Related

Calling ionic/capacitor bridge from another android app

I have created the ionic/capacitor project and generated .aar file to distribute to another android app. But while calling activity from third party app's MainActivity.java getting the below error,
java.lang.NoClassDefFoundError: Failed resolution of: Lcom/getcapacitor/BridgeActivity;
Calling the activity in the following way,
Intent myIntent = new Intent(view.getContext(), io.ionic.starter.MainActivity.class);
myIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
view.getContext().startActivity(myIntent);

Codesys Control RTE V3 - Network Adapter configuration for Ethercat real time bus

I am quite new to the Codesys platform and I am experiencing some problems when trying to use the RTE on a Windows IPC as a target device.
I am using an IPC (Windows 7 Embedded) with the following runtime version -> CODESYS Control RTE V3 v3.5.17.0
I run the Codesys Environment in my laptop (Also version v3.5.17.0) and I connect to the IPC runtime without problems, by choosing the right target PLC device (CODESYS Control RTE V3 x64).
I add an "Ethercat Master SoftMotion" device to my project and assign the correspoding IEC task (Bus Cycle Task) in which the stack will run, and select the NIC to be used by the stack without major problems. Just as described in the documentation -> https://help.codesys.com/webapp/_ecat_tutorial;product=core_EtherCAT_Configuration_Editor;version=4.1.0.0
When I Log In and Download the project so that I could start scanning the network to find the different Ethercat Slaves, I get the following messages:
[FATAL ERROR] Unresolved reference: 'SYSETHERNETADAPTERCLOSE'
[FATAL ERROR] Unresolved reference: 'GETNUMBEROFADAPTERS'
[FATAL ERROR] Unresolved reference: 'GETADAPTERINFO'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETADAPTEROPEN'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETETHFRAMESEND'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETETHFRAMERECEIVE'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETFRAMERELEASE'
[FATAL ERROR] Unresolved reference: 'GETIPETHFRAME'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETIPFRAMESEND'
[FATAL ERROR] Unresolved reference: 'SYSETHERNETIPFRAMERECEIVE'
I also get I dialogue box stating:
"Error during download:
10 unserolved reference(s), 0 signature mismatch(es), 0 version mismatch(es) found
The device version on the hardware seems to be different from the device version used in the project. Try to up-/downgrade the device in the project to match the actual version of the hardware.
Please take a look in the messages view for further details".
This error message seems misleading because this is a new project on a new installed environment where both Codesys Development and the runtime both have exactly the same version and the project is therefore created for the right version of the runtime.
I had a look at the manual and I have to select the proper driver -> https://help.codesys.com/webapp/_cds_rtev3_startup_cifx_hil;product=core_codesys_control;version=3.5.17.0
At this point is when I find the problems:
According to the documentation I need to add the CmpHilscherCIFX component in the Component Manager Tab of the PLC Configuration which I did and then restarted the IPC.
Later on, the bootloader and correct firmware must be chosen by modifying the "CODESYSControl.cfg" file. This is a step I also do as you can see in the attachments, I simply add the Ethercat select the Ethercat firmware file according to "_cifX firmware.txt" which I found in "C:\Program Files\CODESYS\CODESYS Control RTE3\HilscherCIFX\Firmware":
[CmpHilscherCIFX]
TraceLevel=0xFFFFFFFF
InterruptMode=0
DMAMode=1
Device.0.BootloaderFilePath=$Firmware$\HilscherCIFX\Firmware\NETX100-BSL.bin
Device.0.Channel.0.FirmwareFile=$Firmware$\HilscherCIFX\Firmware\cifxecm.nxf
[SysFile]
|PlcLogicPrefix=1
PlaceholderFilePath=C:\Program Files\CODESYS\CODESYS Control RTE3, $Firmware$
After applying these changes, I restarted the IPC again. However, I was still getting this Unresolved reference errors, I noticed that there wasn´t any Ethercat firmware file (cifxecm.nxf) in "C:\Program Files\CODESYS\CODESYS Control RTE3\HilscherCIFX\Firmware":
The chosen NIC to run the Ethercat stack on the IPC is an Intel I211, so in theory the Chipset is supported.
How is this possible? I am not sure this is the cause of my problems, but it definitely seems something strange. Also the documentation does not seem to be up to date with the version I am using of the runtime, which I believe is onw of the latest.
I hope someone has some suggestion and if you need further clarification, I will provide more details.
It seems I was following the wrong part of the documentation, since I am not using a HilscherCIFX card.
The solution is explained in the section Available Dynamic Components.
Basically I had to:
Revert the changes I applied, those explained in my previous post.
Make sure secureboot is disabled in the BIOS settings, (this can be done during the installation of the RTE runtime).
I had to install the right Codesys Driver for the Intel I211 NIC which is "CmpEt1000Drv" as described in the documentation. The driver is in "C:\Program Files\CODESYS\CODESYS Control RTE3\Cmpet1000MPD". Personally, uninstalling the previous driver from the NIC I wanted to use for Ethercat from the Windows Device manager and installing the new one from there was enough for me.
Add the CmpEt1000Drv component to the component list (Component Manager tab) of RTE System Configuration.
Stop and then Restart the RTE environment.

CrafterCMS 3.0 - Getting error while trying to access delivery node

I am getting following error while trying to run and access delivery node as per https://github.com/craftercms/craftercms#321-build-start-and-stop-a-specific-environment
org.craftercms.core.exception.StoreException: Root folder ./data/repos/sites/craftercms/ not found (make sure that it has a valid URL prefix (e.g. file:))
org.craftercms.core.store.impl.filesystem.FileSystemContentStoreAdapter.createContext(FileSystemContentStoreAdapter.java:59)
org.craftercms.engine.targeting.impl.TargetedContentStoreAdapter.createContext(TargetedContentStoreAdapter.java:75)
org.craftercms.core.service.impl.ContentStoreServiceImpl.createContext(ContentStoreServiceImpl.java:158)
org.craftercms.engine.service.context.SiteContextFactory.createContext(SiteContextFactory.java:249)
org.craftercms.engine.service.context.SiteContextManager.getContext(SiteContextManager.java:202)
org.craftercms.engine.service.context.SiteContextResolverImpl.getContext(SiteContextResolverImpl.java:65)
org.craftercms.engine.service.context.SiteContextResolverImpl.getContext(SiteContextResolverImpl.java:61)
org.craftercms.engine.servlet.filter.SiteContextResolvingFilter.doFilter(SiteContextResolvingFilter.java:39)
org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:346)
org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:262)
org.craftercms.commons.http.RequestContextBindingFilter.doFilter(RequestContextBindingFilter.java:79)
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:197)
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
These are the steps I followed
Built and started studio
Created a site made some changes
Published the changes
Built and started delivery. Delivery tomcat and Solr started fine
Went back to Studio and made some more changes and published
Went to http://localhost:9080/

Distriqt Facebook ANE won't compile for Android

I am having trouble compiling the Distriqt Facebook ANE for Android.
It works fine on iOS but not on Android.
The error message is:
dx tool failed:
UNEXPECTED TOP-LEVEL ERROR: java.lang.OutOfMemoryError: Java heap
space at
com.android.dx.cf.code.ExecutionStack.copy(ExecutionStack.java:66) at
com.android.dx.cf.code.Frame.copy(Frame.java:98) at
com.android.dx.cf.code.Ropper.processBlock(Ropper.java:786) at
com.android.dx.cf.code.Ropper.doit(Ropper.java:742) at
com.android.dx.cf.code.Ropper.convert(Ropper.java:349) at
com.android.dx.dex.cf.CfTranslator.processMethods(CfTranslator.java:280)
at
com.android.dx.dex.cf.CfTranslator.translate0(CfTranslator.java:137)
at com.android.dx.dex.cf.CfTranslator.translate(CfTranslator.java:93)
at com.android.dx.command.dexer.Main.processClass(Main.java:729) at
com.android.dx.command.dexer.Main.processFileBytes(Main.java:673) at
com.android.dx.command.dexer.Main.access$300(Main.java:83) at
com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:602)
at
com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:284)
at
com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
at
com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
at com.android.dx.command.dexer.Main.processOne(Main.java:632) at
com.android.dx.command.dexer.Main.processAllFiles(Main.java:510) at
com.android.dx.command.dexer.Main.runMonoDex(Main.java:280) at
com.android.dx.command.dexer.Main.run(Main.java:246) at
com.android.dx.command.dexer.Main.main(Main.java:215) at
com.android.dx.command.Main.main(Main.java:106)
ADT command line:
...
Tried with AIR18 and AIR 16 (updated dx.jar from distriqt tutorial).
My manifest includes all 3 needed extensions:
<extensionID>com.distriqt.Core</extensionID>
<extensionID>com.distriqt.GooglePlayServices</extensionID>
<extensionID>com.distriqt.FacebookAPI</extensionID>
Removing GooglePlayServices makes compilation possible but app crashes when initializing the FacebokAPI.
Using AIR16 without the updated dx.jar also crashes the app directly at startup. The catlog states the following exception:
08-23 14:53:14.793 E/AndroidRuntime(3178): java.lang.RuntimeException:
Unable to get provider com.facebook.FacebookContentProvider:
java.lang.ClassNotFoundException: com.facebook.FacebookContentProvider
in loader
dalvik.system.PathClassLoader[/data/app/air.my.com.zas.lefiner-1.apk]
08-23 14:53:14.793 E/AndroidRuntime(3178): Caused by:
java.lang.ClassNotFoundException: com.facebook.FacebookContentProvider
in loader
dalvik.system.PathClassLoader[/data/app/air.my.com.zas.lefiner-1.apk]
Oddly enough the Distriqt GooglePlusANE which uses Core and GooglePlayServices works fine on both platforms. So i strongly assume there is something wrong with the FacebookAPI extension.
Any help is very much appreciated!
If You are using Intellij IDEA increase Compiler heap size in Actionscript & Flex compiler. This fixed the issue for me.

Jenkins tag name is invalid

Has anyone seen the following exception from Jenkins?
FATAL: org.eclipse.jgit.api.errors.InvalidTagNameException: tag name jenkins-Push Notifications API (Master)-3 is invalid
hudson.plugins.git.GitException: org.eclipse.jgit.api.errors.InvalidTagNameException: tag name jenkins-Push Notifications API (Master)-3 is invalid
at org.jenkinsci.plugins.gitclient.JGitAPIImpl.tag(JGitAPIImpl.java:179)
at hudson.plugins.git.GitAPI.tag(GitAPI.java:220)
at hudson.plugins.git.GitSCM$4.invoke(GitSCM.java:1239)
at hudson.plugins.git.GitSCM$4.invoke(GitSCM.java:1196)
at hudson.FilePath.act(FilePath.java:865)
at hudson.FilePath.act(FilePath.java:838)
at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1196)
at hudson.model.AbstractProject.checkout(AbstractProject.java:1353)
at hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:689)
at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:594)
at hudson.model.Run.execute(Run.java:1567)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:237)
Caused by: org.eclipse.jgit.api.errors.InvalidTagNameException: tag name jenkins-Push Notifications API (Master)-3 is invalid
at org.eclipse.jgit.api.TagCommand.processOptions(TagCommand.java:198)
at org.eclipse.jgit.api.TagCommand.call(TagCommand.java:112)
at org.jenkinsci.plugins.gitclient.JGitAPIImpl.tag(JGitAPIImpl.java:175)
... 14 more
This is a Scala project and we are using SBT 12.1 to build it. My googling has only returned issues with older versions of Jenkins which I am past. We have 1.506.
We have a ton of other projects building just fine and some of them are also Scala.
I got this error building a Java project. I'm not sure why this would suddenly crop up, but I was able to work around it by doing the following:
Go to the Advanced... config settings for the Source Code Management section of the build config and check "Skip Internal Tag".
(upgraded from comment)