Failing to Connect Remote App to AppleTV (4th Gen), While Screen Sharing Works

I don’t have access to my proper AppleTV remote to control my AppleTV (4th Gen), but that’s no problem because I can use the Remote app on an iPhone and iPad.

The Remote app was working fine until one morning it wouldn’t connect from any iPhone or iPad. The status listed is “offline” — see the attached screenshot.

The AppleTV appears to be still connected to the WiFi network, as I am able to share my iPhone’s screen.

How would screen sharing work but the Remote not work?

I killed the Remote app multiple times (swipe up) and rebooted the AppleTV (power cycle).

enter image description here

All topic

Breaking out of a while loop using IR remote for neopixel

I’ve been piecing together various lighting effects. I am wanting to have each lighting effect loop until another button is pressed to trigger another lighting effect.

I’ve come to a bit of standstill at the moment. I’ve created a loop that doesn’t seem to end. I’ve had a look around but I can’t work out how to fix my code. Sorry in advanced, I’m new to using arduinos but if anyone could help out, it would be much appreciated.
Thanks!

//www.elegoo.com
//2016.12.9

#include "IRremote.h"
#include 
#ifdef __AVR__
#include 
#endif
#define PIN 6


Adafruit_NeoPixel strip = Adafruit_NeoPixel(20, PIN, NEO_GRB + NEO_KHZ800);

int receiver = 11; // Signal Pin of IR receiver to Arduino Digital Pin 11

/*-----( Declare objects )-----*/
IRrecv irrecv(receiver);     // create instance of 'irrecv'
decode_results results;      // create instance of 'decode_results'
int Remote = 0;

/*-----( Function )-----*/
void translateIR() // takes action based on IR code received

// describing Remote IR codes 

{

  switch(results.value)

  {
  case 0xFFA25D: Serial.println("POWER"); 
  ArrowRight(strip.Color(25, 0, 0), 100); //Red
  ArrowRight(strip.Color(0, 0, 25), 100); //Blue
//  Remote = 0xFFA25D;
  break;

  case 0xFFE21D: Serial.println("FUNC/STOP"); 
  ArrowLeft(strip.Color(25, 0, 0), 100); // Red
  ArrowLeft(strip.Color(0, 0, 25), 100); // Blue
//  Remote = 0xFFE21D;
  break;

  case 0xFF629D: Serial.println("VOL+"); break;
  case 0xFF22DD: Serial.println("FAST BACK");    break;
  case 0xFF02FD: Serial.println("PAUSE");    break;
  case 0xFFC23D: Serial.println("FAST FORWARD");   break;
  case 0xFFE01F: Serial.println("DOWN");    break;
  case 0xFFA857: Serial.println("VOL-");    break;
  case 0xFF906F: Serial.println("UP");    break;
  case 0xFF9867: Serial.println("EQ");    break;
  case 0xFFB04F: Serial.println("ST/REPT");    break;
  case 0xFF6897: Serial.println("0");    break;
  case 0xFF30CF: Serial.println("1");    break;
  case 0xFF18E7: Serial.println("2");    break;
  case 0xFF7A85: Serial.println("3");    break;
  case 0xFF10EF: Serial.println("4");    break;
  case 0xFF38C7: Serial.println("5");    break;
  case 0xFF5AA5: Serial.println("6");    break;
  case 0xFF42BD: Serial.println("7");    break;
  case 0xFF4AB5: Serial.println("8");    break;
  case 0xFF52AD: Serial.println("9");    break;
  case 0xFFFFFFFF: Serial.println(" REPEAT");break;  

  default: 
    Serial.println(" other button   ");

  }// End Case

  delay(0); // Do not get immediate repeat


} //END translateIR
void setup()   /*----( SETUP: RUNS ONCE )----*/
{
  Serial.begin(9600);
  Serial.println("IR Receiver Button Decode"); 
  irrecv.enableIRIn(); // Start the receiver
  strip.begin();
  strip.show();
  Remote = 0;

}/*--(end setup )---*/


void loop()   /*----( LOOP: RUNS CONSTANTLY )----*/
{
  if (irrecv.decode(&results)) // have we received an IR signal?

  {
    translateIR(); 
    irrecv.resume(); // receive the next value
  }  
}/* --(end main loop )-- */

void ArrowRight(uint32_t c, uint8_t wait) {
  while (Remote = 0xFFA25D) { 
    for (uint16_t i = strip.numPixels()/2; i < strip.numPixels(); i++) {
      strip.setPixelColor(i, c);
      strip.show();
      delay(wait);
    }
    for (uint16_t i = 0; i < strip.numPixels(); i++) {
      strip.setPixelColor(i, 0);
    }
    strip.show();
    delay(wait);
  }
}

void ArrowLeft(uint32_t c, uint8_t wait) {
  while (Remote = 0xFFE21D) { // The j<# determines how many cycles
    for (uint16_t i = strip.numPixels()/2-1; i + 1 > 0 ; i--) {
      strip.setPixelColor(i, c);
      strip.show();
      delay(wait);
    }
    for (uint16_t i = strip.numPixels(); i + 1 > 0 ; i--) {
      strip.setPixelColor(i, 0);
    }
    strip.show();
    delay(wait);
  }
}

All topic

Changing scene while joining room and RPC buffer problem

I have a button on my main menu that creates and has the player join a random room. After the client joins this room, I change the scene to the game (main) scene in the OnJoinedRoom method. This works well, until I use the RPC call with buffers.

There are 5 spawn points in the game scene, and every time a player joins the room, they occupy a spawn point, so no-one else can spawn at that point.
So, I have list of spawn points in my code, and every time a player joins, it randomly picks a point from that list and “removes” it from the list. It does this via RPC call, so if a player joins the game late, it removes that point, too.

There is a problem with that RPC’s buffer because of the “scene change”. After OnJoinedRoom, the RPC buffers are called only when the player joins the room, and before the scene change. Because the scene hasn’t changed yet, it has trouble finding the buffered photonview, and it throw outs an error. It doesn’t update the list.

Can I delay the buffer calls, is there a better way to change my scene while joining a room?

All topic

Моожно ли использоваться цикл for внутри while?

Вопрос в заголовке
Прошу сильно не ругать)))

All topic

System.InvalidOperationException Message: formItem Exception while adding WFFM in SXA

I’m getting this exception when I am trying to add WFFM in SXA page (add from wraper > click “add here” > select “MVCform” then i get this exception)

Note: I’m using Sitecore 8.2 update 5, SXA 1.4, WFFM update 5

Server Error in ‘/’ Application. formItem Description: An unhandled
exception occurred during the execution of the current web request.
Please review the stack trace for more information about the error and
where it originated in the code.

Exception Details: System.InvalidOperationException: formItem

Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of
the exception can be identified using the exception stack trace below.

Stack Trace:

[InvalidOperationException: formItem]
Sitecore.Form.Core.Configuration.ThemesManager.RegisterCssScript(Page
page, Item form, Item contextItem) +918
Sitecore.Forms.Shell.UI.CreateFormWizard.OnLoad(EventArgs e) +939
Sitecore.Forms.Shell.UI.InsertFormWizard.OnLoad(EventArgs e) +99

[TargetInvocationException: Exception has been thrown by the target of
an invocation.] System.RuntimeMethodHandle.InvokeMethod(Object
target, Object[] arguments, Signature sig, Boolean constructor) +0
System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj,
Object[] parameters, Object[] arguments) +210
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags
invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
+146 Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj) +89
Sitecore.Web.UI.Sheer.ClientPage.OnLoad(EventArgs e) +589
System.Web.UI.Control.LoadRecursive() +68
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
+1381


This is the log

Exception: System.Web.HttpUnhandledException Message: Exception of
type ‘System.Web.HttpUnhandledException’ was thrown. Source:
System.Web at System.Web.UI.Page.HandleError(Exception e) at
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
at System.Web.UI.Page.ProcessRequest() at
System.Web.UI.Page.ProcessRequest(HttpContext context) at
System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStepImpl(IExecutionStep step)
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step,
Boolean& completedSynchronously)

Nested Exception

Exception: System.Reflection.TargetInvocationException Message:
Exception has been thrown by the target of an invocation. Source:
mscorlib at System.RuntimeMethodHandle.InvokeMethod(Object target,
Object[] arguments, Signature sig, Boolean constructor) at
System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj,
Object[] parameters, Object[] arguments) at
System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags
invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method,
Object[] parameters, Object obj) at
Sitecore.Web.UI.Sheer.ClientPage.OnLoad(EventArgs e) at
System.Web.UI.Control.LoadRecursive() at
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

Nested Exception

Exception: System.InvalidOperationException Message: formItem Source:
Sitecore.Forms.Core at
Sitecore.Form.Core.Configuration.ThemesManager.RegisterCssScript(Page
page, Item form, Item contextItem) at
Sitecore.Forms.Shell.UI.CreateFormWizard.OnLoad(EventArgs e) at
Sitecore.Forms.Shell.UI.InsertFormWizard.OnLoad(EventArgs e)

All topic

How to recover my data which i los while installing ubuntu 18.01?

While installing ubuntu 18.01 i lost my entire data in my harddisk ,previously the system is dual booted with ubuntu 16.01 and windows 10…is there is any possibility to recover my data?? if so kindly suggest me the way to do it.

Thanks in Advance.. strong text

All topic

How to disable storing data in index while pd.read_csv in Python?

I am reading a txt file which looks like:

        Time    Node    AppId   SeqNo   Name     Type   HopCount
         0      0         0       0    abc/p1/    abc     1
         0.8    1         12      0    abc/p1/    abc     0

The values in txt file are tab separated.

I have used the following code to read txt file and store in data frame:

df1=pd.read_csv(pathname,delimiter='t')

The output dataframe stores the value of time as index which shouldn’t happen.

The dataframe looks like:

file:///home/iolie/Pictures/Screenshot%20from%202018-09-19%2017-45-38.png

The results should look like:

       Time   Node  AppId   SeqNo   Name     Type   HopCount
         0      0     0       0    abc/p1/    abc     1

All topic

Getting error while doing ng serve in visual studio code

I was creating an angular application and project was created successfully but when I try to run ng serve then I get error. Version are as @angular/core”: “^6.1.0”, node version is v8.11.3, npm version is 6.4.1 and

Angular CLI: 6.2.2
Node: 8.11.3
OS: win32 x64
Angular:
...

Package                      Version
-------------------------------------
@angular-devkit/architect    0.8.2
@angular-devkit/core         0.8.2
@angular-devkit/schematics   0.8.2
@schematics/angular          0.8.2
@schematics/update           0.8.2
rxjs                         6.2.2
typescript                   2.9.2

and the error I’m getting on ng serve is as follows-

Local workspace file ('angular.json') could not be found.
Error: Local workspace file ('angular.json') could not be found.
    at WorkspaceLoader._getProjectWorkspaceFilePath (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsworkspace-loader.js:44:19)
    at WorkspaceLoader.loadWorkspace (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsworkspace-loader.js:31:21)
    at ServeCommand._loadWorkspaceAndArchitect (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsarchitect-command.js:201:32)
    at ServeCommand. (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsarchitect-command.js:53:25)
    at Generator.next ()
    at C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsarchitect-command.js:7:71
    at new Promise ()
    at __awaiter (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsarchitect-command.js:3:12)
    at ServeCommand.initialize (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelsarchitect-command.js:52:16)
    at Object. (C:Users142443AppDataRoamingnpmnode_modules@angularclimodelscommand-runner.js:127:23)

Note: I’ve installed npm globally and I’m creating project on D:
drive.

All topic

Getting 502 proxy error while trying to write rewriterule

I have a domain int.business.com. When I hit this I want the browser to show the contents in the domain www.data.business.com but the users should still see int.business.com in the address bar. Here is my vhost configuration

RewriteEngine on
SSLProxyEngine on 
RewriteRule ^/(.*)$ int.business.com [P]
ProxyPassReverse / data.newbusiness.com

With this configuration, I am getting a 502 proxy error

Proxy Error
The proxy server received an invalid response from an upstream server.
The proxy server could not handle the request GET /.

Reason: Error reading from remote server

Any suggestions on how to solve this.

All topic

Backing up Linux Filesystem while running

A few years ago when I was using Windows 7 and I needed a free Backup solution I found Macrium Reflect. There were three things I liked about it:

  • It could run while my machine was running i.e. without shutting down my machine or booting it into a separate mode
  • I could write/restore the backup image to a fresh disk, and in the few tests/experiments I attempted I found these restored disks bootable and readily replaceable with my original disk
  • The disk images were compressed in some way i.e. imaging a 200 GB drive that was only half full would result in an image of about 100 GB
  • I could explore/mount the backup disk images and copy out files necessary.
  • Finally, it was free i.e. as in costed no money

    I’m now looking at Linux, particularly Ubuntu and I’m wondering if I can find any solution that would give me the features I liked about Macrium Reflect. (I’m open to using other distro’s if they have better tools/support for what I’m looking for. So please suggest if my choice is wrong.)

    If I understand what I read online, the two solutions that I found seem to be close to my requirements are:

  • LVM: This seems to be the closet solution to the Microsoft Volume Shadow Copy Service that Macrium Reflect uses. However there seem to be complaints that LVM has issues with SSD write caching and gets easily corrupted in case of a power loss.

    I’d be grateful if someone who has more experience with using LVMs on SSDs can comment on how bad these issues are?

  • Rsync: On Windows, a direct copy of the filesystem on a new drive would not result in a bootable disk i.e. you needed to copy the MBR and other things that I don’t understand. Hence there was a need to image one disk to another to get a bootable disk. Is this different on Linux?

    My understanding of Linux is bad, but I’m curious if I copied/did an rsync of the entire filesystem from my existing drive to a new drive, would this result in a bootable disk?

All topic