XNA Creators Club Online
Page 1 of 1 (5 items)
Sort Posts: Previous Next

Send Magic packet to Client MAC

Last post 10/16/2009 11:35 AM by Jim Perry. 4 replies.
  • 10/15/2009 3:38 PM

    Send Magic packet to Client MAC

    Hello, does anybody can give me a hint how I can send this piece of code after statup of the XBox to a client?
    Thanks Thomas

    private static void WakeOnLan(byte[] mac) { // WOL packet is sent over UDP 255.255.255.0:40000. UdpClient client = new UdpClient(); client.Connect(IPAddress.Broadcast, 40000); // WOL packet contains a 6-bytes trailer and 16 times a 6-bytes sequence containing the MAC address. byte[] packet = new byte[17*6]; // Trailer of 6 times 0xFF. for (int i = 0; i < 6; i++) packet[i] = 0xFF; // Body of magic packet contains 16 times the MAC address. for (int i = 1; i <= 16; i++) for (int j = 0; j < 6; j++) packet[i*6 + j] = mac[j]; // Send WOL packet. client.Send(packet, packet.Length); }
    Tom ________________________________ XBox 360 Elite Jasper 120GB HDD; WHS 6TB (self made); 2x Windows 7 Ultimate + WMCE; 2x SAMSUNG LE40B650 DLNA; C# programmer since .NET 1.0
  • 10/15/2009 3:49 PM In reply to

    Re: Send Magic packet to Client MAC

    You have no access to the raw UDP functionality on the Xbox.
  • 10/15/2009 4:04 PM In reply to

    Re: Send Magic packet to Client MAC

    That, and you would have to start your game before being able to execute any code; there is no way to have "startup projects" on the Xbox. Keep in mind this would have to be for personal use only too, since there is only LIVE networking in XBLIGs.
    "Software is never finished, it is in varying states of 'less broken'" because "If it ain't broke, it doesn't have enough features yet"

    In Playtest: Avatar Land | The MANLY Game for MANLY Men

    The signature that was too big for the 512 char limit
  • 10/16/2009 8:46 AM In reply to

    Re: Send Magic packet to Client MAC

    OK and Thanks, I understood that we don't have access to the core of the Box, but it should be possible to write a "game" which I can start at startup (like the Media Center). The problem is to get a socket. I want to start a Windows Home Server from hibernat. I could write a client server application but if I install the server on the WHS the server is sleeping too. I believe MS didn't tought deep enough when they dev. the extender of the XBox.
    Tom ________________________________ XBox 360 Elite Jasper 120GB HDD; WHS 6TB (self made); 2x Windows 7 Ultimate + WMCE; 2x SAMSUNG LE40B650 DLNA; C# programmer since .NET 1.0
  • 10/16/2009 11:35 AM In reply to

    Re: Send Magic packet to Client MAC

    TomDooley2005:
    I believe MS didn't tought deep enough when they dev. the extender of the XBox.

    No, it's because there's no reason to be able to do this on the Xbox.
    Jim Perry - Microsoft XNA MVP
    If people spent a minute searching the forums and reading the FAQs before posting I'd be out of a job.
      Got some XNA Game Studio/XNA Framework development info to share with the community? Put it on the XNA Wiki.
        Please mark posts as Answers or Good Feedback when appropriate.
Page 1 of 1 (5 items) Previous Next