Arduino Uno + XBEE WiFi + GoPro HTTP GET Requests

Hello everyone, I ran into a problem trying to send an HTTP GET request to a GoPro camera via UNO + XBee (not the shield).

I've used the link below on a basis of how to write the program and essentially modified it for my needs.

https://learn.sparkfun.com/tutorials/internet-datalogging-with-arduino-and-xbee-wifi/discuss

Here is the modified code:

#include <SoftwareSerial.h>

const byte XB_RX = 2; // XBee's RX (Din) pin
const byte XB_TX = 3; // XBee's TX (Dout) pin
SoftwareSerial xB(XB_RX, XB_TX); 
const int XBEE_BAUD = 9600; // Your XBee's baud (9600 is default)

const unsigned long UPDATE_RATE = 11000; 
unsigned long lastUpdate = 0; // Keep track of last update time

void setup()
{
  // Set up serial ports:
  Serial.begin(9600);
  xB.begin(XBEE_BAUD);
  
  if (sendData())
    Serial.println("SUCCESS!");
  else
    Serial.println("Failed :(");
}

void loop()
{
  // If current time is UPDATE_RATE milliseconds greater than
  // the last update rate, send new data.
  if (millis() > (lastUpdate + UPDATE_RATE))
  {
    Serial.print("Sending update...");
    if (sendData())
      Serial.println("SUCCESS!");
    else
      Serial.println("Failed :(");
    lastUpdate = millis();
  }
}

byte sendData()
{
  xB.flush(); // Flush data so we get fresh stuff in
  xB.print("GET /bacpac/PW?t=pw&p=%01 HTTP/1.0");
}

Using the browser, I can easily send http://10.5.5.9/bacpac/SH?t=PASSWORD&p= and it would turn on the gopro. However, when I try to do this via Uno, + XBee it simply would not work. Checking the serial monitor, I get Success! and then I get Sending update...SUCCESS! but the gopro stays off.

I have already pre configured the XBEE using XTCU to be an IBSS Joiner (The gopro creates an ad hoc network), gave it a static ip, and set it to TCP. (I used this information here to do that: http://ftp1.digi.com/support/documentation/doc_xbee_wifi_adhoc.pdf). I'm not to sure if I have to change the port to 8080 for just sending an HTTP GET.

Anyone have any idea what the problem might be?

EDIT: I have 4 connections:
Vcc to 3.3v on arduino
Dout to pin 3 of arduino
Din to pin 2 of arduino
GND to GND

I just turned off the GoPro WiFi, and ran the code, I'm still getting success even though the WiFi is off.

You have too many unknowns.

You need to get each part of the system working them bring them together.

Can you get the xbee to connect to any wifi network at all?

Can you connect to the GOPRO using a laptop etc on wifi, then use a browser or a command line tool like wget to send those commands and confirm they work.

When you have confirmed all separate elements are working, you can start to bring them together in the Arduino

Sorry, I should have stated that.

Yes, I have tested the XBee with my home network. When checking the DHCP client table, it recognizes that the XBee is connected.

I have successfully connected my laptop to the GoPro and have successfully used many of the HTTP commands (turning it on, switching to camera mode, take a picture, turn it off.)

The thing I'm not sure about is configuring the XBee to connect to an Ad Hoc Network which GoPro states that is what the camera does, creates an Ad Hoc Network.

When using XTCU to configure the XBee to connect to the GoPro, it automatically fills out the gateway (as well as other parameters) and states "You have successfully connected to this network." However, there are parameters that I thought should have been changed but never was, such as the network type. It still states its infrastructure when I assumed it should have been an IBSS Joiner in order to connect to the GoPro's Ad Hoc Network. Another thing is the destination IP is still 255.255.255.255 when I assumed it should be the same as the Gateway of the GoPro (10.5.5.9). Also, the port of the GoPro is 8080, however when the XBee is configured, it remains unchanged from the default value.

If there was a way if I could check that the XBee module is actually connected to the GoPro, then I can limit the problem to being a code issue. However, I can't find anything online about a way to check what devices are connected to your GoPro.

Have you solved this yet. I too am having the EXACT same issues you are having with connecting it to the gopro to send wifi commands.
Has anyone ever successfully done this yet? I'd love some help if they have.