Comments: Photon Weather Shield Hookup Guide

Pages

Looking for answers to technical questions?

We welcome your comments and suggestions below. However, if you are looking for solutions to technical questions please see our Technical Assistance page.

  • Member #541104 / about 7 years ago / 1

    How do you do this on a Mac ?

    What You Should See Once everything has uploaded correctly, open your favorite Serial Terminal program at 9600-8-N-1-NONE. Select the serial port your Photon has showed up as, and click connect. You should see something like the following print out in the window.

  • Member #665822 / about 7 years ago / 1

    Hey guys, quick question. Can this photon wheather shield be connected directly to the Sparkfun redboard with Arduino or I must use a photon board with it?

    • Joel_E_B / about 7 years ago / 1

      This shied can be connected to any microcontroller that supports I2C. However, you will need to do some soldering to connect it to anything other than a Photon. Shields are just designed to make connecting sensors to microcontollers easier without having to solder. You can, in theory, connect any shield to any other device if you know what pins to solder together. But if you want to use a RedBoard or Arduino Uno, why not use the SparkFun Weather Shield for Arduino.

  • Member #16458 / about 8 years ago / 1

    Greetings. It seems that some people started having trouble with the Photon Weather Shield code uploading to Weather Underground correctly in early February 2017. If you are having this problem, check out the thread at:

    https://community.particle.io/t/solved-photon-weather-station-not-uploading-to-wunderground/29182/16

    The short story is that it seems that Weather Underground stopped accepting the HTTP GET request as it was formed, but this is easily fixed. I hope it helps someone.

  • Member #830555 / about 8 years ago * / 1

    Hi, Does anyone know if its possible to calibrate the Photon Weather shield? Im using the on-board I2C sensors (same code as in this great tutorial) but the reading are completely wrong.

    I have compared the data from the Photon Weather shield with a SHT15 Humidity and Temperature Sensor. Both placed next to each other. Roughly the average different between the two is 5 degree Celsius. Im sure the SHT1X reading is more accurate by comparing with some other PWS in my local area. (wunderground.com)

    • Joel_E_B / about 8 years ago / 1

      Hi. While it is not possible to calibrate the I2C sensors, you can always program an offset into your code. In most cases, the temperature sensor will read a little higher than the actual temp due to the residual heat that the Photon emits through the Weather Shield. Comparing to an existing temp sensor, as you have already done, is a great way to see how much hotter the Photon readings are. Create a simple algorithm in your code to compensate for the extra heat, and you will have more accurate data. 5 degrees C seems like a big error, even with the extra heat. If the temperature is reading that far off, there may be another issue.

  • Member #745605 / about 8 years ago / 1

    I'm having a problem with wind gust info and Weather Underground. After a while (about an hour) the wind gust (maybe the windgustmpg_10m variable?) shoots off to something way too high, it seem like its not getting reset properly? I'm a pretty novice programmer so I'm not really sure what's going on... any help anyone can provide is greatly appreciated! I've posted over on the Particle forums as well: https://community.particle.io/t/wind-gust-problem-photon-sparkfun-weather-shield-weather-underground/24380/2

    My code is here: https://github.com/bmutari/Particle-WeatherStation/blob/master/weather-station.ino

  • Member #398900 / about 8 years ago / 1

    is there any example mqtt code please ? i really need some sample code to get me going.

    Thanks.

  • -------------------- Tech Support Tips/Troubleshooting/Common Issues --------------------

    Configuring your Bluetooth Device (i.e. RN-42)

    Here's a tip from a customer that clarifies how to connect the BlueSMiRF Silvers (RN-42) together. It was not clear when trying to follow the user manual ( Section 4.1.2 Software Pairing Using Commands - http://cdn.sparkfun.com/datasheets/Wireless/Bluetooth/bluetooth_cr_UG-v1.0r.pdf ) :

    "To configure the master and slave devices, connect your terminal emulator on the host to the devices via the COM port using the settings 115200 baud, 8 bits, no parity, 1 stop bit, and no flow control. This works well using Hyperterminal on the PC. Note: Both BT modules are *slaves* by default.

    A.) Setting Up Your Slave Device

    On the device you want to be the slave device (the LCD), issue the following commands:

    1. Put the device in command mode by sending the "$$$" command. The device returns CMD to indicate it is in command mode.
    
    2. Send "SM,0<cr>" to put the device into slave mode.
    
    3. Verify that the device is in slave mode by issuing the "D" action command. Look for the MODE =Slav message.
    
    4. Reboot the device using the "R,1<cr>" command. The changes do not take effect until the device is rebooted.
    

    B.) Setting Up Your Master Device

    On the master device (the Particle Photon), issue the following commands:

    1. Put the device in command mode by sending the "$$$" command. The device returns CMD to indicate it is in command mode.
    
    2. Send "SM,3<cr>" to put the device into auto mode.
    
    3. Verify that the device is in auto mode by issuing the "D" action command. Look for the MODE =Auto message.
    
    4. Ensure that the slave device is turned on, and send the I<cr> inquire command.
    
    5. Locate the slave's (remote side) Bluetooth address (BTA) in the results of the inquiry command. The BTA is a 6-byte (12 hex-characters) value.
    
     6. Store the remote BTA using the "SR,<address><cr>" command. For example, if the remote BTA is "000666037083," enter the command "SR,000666037083<cr>" to store the remote address.  The "D" command should show the slave's address under "Rem=".
    
    7. Reboot the device using the "R,1<cr>" command. The changes do not take effect until the device is rebooted.
    

    After rebooting, the master device restarts and connects with the remote slave device. A solid green LED indicates that the devices are connected."

    Particle Photon/Photon Weather Shield/Photon Battery Shield?

    There were some customers that wanted to add a barrel jack connector to the Photon Weather Shield [ https://www.sparkfun.com/products/13630 ] to charge a LiPo battery through the Photon Battery Shield [ https://www.sparkfun.com/products/13626 ]. Yes, you can add a barrel jack connector to the bottom of the weather shield to charge a LiPo battery through the battery shield. The VIN will connect to the battery shield when stacked. The MCP73831 charge IC will take the power from the VIN pin and charge a LiPo battery safely. You just need to cut the trace connected to the VREG and add a solder jumper to the center pad and P_VIN as stated in the weather shield's tutorial:

    However, if you would rather have the alternative power source route power through the regulator on the Photon (for lower current consumption during sleep perhaps), simply cut the trace on the Power Select jumper (between the VREG and RAW pads), and add a blob of solder between RAW and P_VIN (Photon VIN) pads. Just be sure to not exceed voltages of 5.5-6V once this alteration has been made.
    

    Looking at the spec for the Particle Photon's VIN [ https://docs.particle.io/datasheets/photon-datasheet/#pin-description ], it indicates that the recommended maximum input is 5.5V. The MCP73831's datasheet [ http://ww1.microchip.com/downloads/en/DeviceDoc/20001984g.pdf ] recommended an input voltage of 6V. You can go slightly higher based on the absolute maximum ratings but I would recommend keeping the barrel jack's input voltage between 5.5V-6V.

  • bwhitman / about 9 years ago / 1

    I could not get the Phant to work on a Sparkfun Photon Redboard, and discovered I had to make a change to the HTTP POSTing code. I discovered the POSTing logic suggested by Sparkfun in their official Particle Phant wrapper is different from the example code in Sparkfun_Photon_Weather_Phant. Precisely, you want the code in postToPhant to look like

    if (client.connect(server, 80))
    {
        Serial.println("Posting!");
        client.print(phant.post());
        int timeout = 1000;
        while (client.available() || (timeout-- > 0))  {
            char c = client.read();
            if (i < 512)
                response[i++] = c;
            delay(1);
        }
    

    Instead of the delay(1000) stuff.

  • Member #579167 / about 9 years ago / 1

    I have been trying this but can't seem to get the code to work without the soil temp or moisture sensors. Using Particle Build is seems to hang on including the various libraries. Does anyone have code for just adding the Wind and Rain variables to the regular weather shield variables? Thanks!

  • Member #688020 / about 9 years ago / 1

    I cannot get the Phant example to post even when hard coding the query string values.

    • Joel_E_B / about 9 years ago * / 1

      Hi, I just tried the Phant example and it is working for me. Make sure your field labels match the labels used in the PostToPhant function exactly. Use phant.add(<field>, <value>) to add data to each field. Phant requires you to update each and every field before posting.

      Also, make sure you have replaced the private and public keys near the top of the sketch with your keys.


If you've found an issue with this tutorial content, please send us your feedback!