An ambient interactive trail lighting system that guides the trail runners, cyclists, and other users of the Schenley Park Sportsplex.

Created: December 6th, 2019

0
0

What happens when you're walking on a trail at night and your flashlight doesn't work? Or what happens during winters when the nights are long and the days are short.  Presenting to you, the Trail Guiders.

0

The Sportsplex is a multi-sport activity center where people come to spend time playing and engaging themselves in daily exercise.

On talking to daily users, the sportsplex was commonly used by tennis players and runners. There exists a track, where the runners do their daily practice. But when the tracks are crowded, the runners choose to use the various trails surrounding the sportsplex. These trails have little or no information about them. The sportsplex also has poor connectivity and light systems. Thus, a need for change for such a heavily engaged place was required and what better than a technologically advanced solution which made people’s lives’ easier.

0

Problem Statement:

•Schenley Park has many trails around it which are constantly used for walking, running etc.
•The trail is poorly lit up and due to lack of connectivity, it is easy for a person to get lost.
•Walking the trails during the late evenings could pose to be dangerous.
0

Solution:

•To tackle this issue, we design an ambient interactive path guiding system.
•The path guiding system units are placed throughout the entire trail at various points.
•They light up the path in various colors and patterns.
•Path users are now guided from one point to another with the help of this colorful ambient device. 
0
Story Board
Img 6859.thumb
0

Phases of Project Implementation:

1.SYNTHESIS
2.ANIMATION

3.FORM FACTOR

0

Synthesis:

To provide an ambient, interactive and informative lighting system we use the following data variables:
1.Human factors: 

             Number of people crossing the path

2.Environmental Variables:

             Soil Moisture
             Ambient Light
             Temperature and Humidity

0

Survey:

•To find out which of the factors mattered the most to people walking on trails, we conducted a survey.
•Factor #1: Moisture. People preferred dry paths to walk on.
•Factor #2: Sun Light. People found it safer to walk on a path that had greater ambient light.
•Factor #3: Crowds. People preferred to walk on paths which was more occupied, for safety.
0

Final Weighting System and Percentages:

Based on the survey results, we drew a final weighting system for the raw data available:
•55% for soil moisture
•40% for light

•5% for temperature and humidity

0

Animation:

•Animation involves how we present the raw data in a meaningful way to the users of the path.
•The project involves two types of animation which communicate different meanings based on their state:

                Color

                Pattern

0

Variation in Color:

•The color changes in the path are a factor of the environmental variables collected and weighted according to the survey.
•The data is weighted and mapped to a color variable y.

•This color variable y has color range RED – GREEN.

•GREEN indicates the most favorable factors : Dry path and well lighted.

•RED indicates the least favorable factors:  Wet Path and not well lighted.

0

Mapping Formula:

•y = (0.55 * soil_moisture) +  (0.40 * ambient_light) +  (0.05 *temp_humidtiy)
0

Variation in Pattern:

•While varying color dealt with environmental factors, the pattern indicated the human interaction with the path.
•The patterns ranged from slow strobing to fast strobing based on the number of people who use the path.
•A fast strobing light indicated the path was less frequently used.
•A slow strobing light indicated greater frequency in usage.
0

Meaning behind the color and pattern:

Color:

•Humans have this inane nature to distinguish between red and green.
•They understand red to indicate a sign of danger, while green to be safe.

•The use of the color range from red to green is about this human quality to naturally decode that the path is safe or dangerous.

Pattern:

•Strobing of light is indicative of calming of the human brain.

•A slow strobing light indicates calmness in a human and peace, whereas a fast strobing light indicates panic and frenzy.

•By using light strobes, we try and guide people into the paths of calm (safe, used a lot) and frenzy (less used, uncertain path).

0

Form Factor:

•Form factor is a crucial component of the project as it indicates the scalability and portability of the system as a product.
•We use a cubical box which holds the device and its sensors. This cubical box has holes for sensors to come out and come in contact with the environment.
•The cubical box has a large circular opening in the front.
•A Fresnel lens is places in this opening to disperse light onto the path.
•Thus, we get a light dispersion effect onto the path and by using boxes, we attain portability.
0
Form Factor
Img 0160.thumb
0

Raw Data to User:

All the data is available to the user on the mobile app.

0

Prototype Subsystems:

1. Counter System:

      Using an IR detector to count the number of people passing by a certain route, and updating the trail path guiders accordingly.

2. Environmental Factors:
     Temperature/Humidity: Using a DHT 11 sensor.

     Soil Moisture Sensor

     Ambient Light: Using a TEMT6000 sensor.

3. Path lighting system: Neopixels

0

Bill of Materials:

Single System:

S. No

Component

Quantity

Price

1

Particle Argon

1

27.50

2

DHT 11

1

7.00

3

Soil Moisture Sensor

1

9.50

4

Ambient Light Sensor

1

5.00

5

IR Sensor

1

10.00

6

Neopixel Strips

2

21.00

7

Acrylic Enclosure

1

10.00

8

Frensel Lens

1

5.00

Schenley Park Trail maps: http://www.cs.cmu.edu/~smagill/schenley.html


0
Block Diagram
Block.thumb
0

Connections:

1. DHT Sensor:

The DHT sensor has three pins, VCC Ground and Digital Pin. We connect VCC and ground to that of the particle Argon and connect the digital pin to the digital pin D2.

2. Soil Moisture Sensor:
The Soil Moisture sensor has three pins, VCC Ground and Analog Pin. We connect VCC and ground to that of the particle Argon and connect the digital pin to the analog pin A4.

3. Ambient Light Sensor:

The Ambient Light sensor has three pins, VCC Ground and Analog Pin. We connect VCC and ground to that of the particle Argon and connect the digital pin to the analog pin A1.

4. IR Sensor:
The IR sensor has three pins, VCC Ground and Analog Pin. We connect VCC and ground to that of the particle Argon and connect the digital pin to the analog pin A0.

5. NeoPixel Strips: 
The NeoPixel Strips has three pins, VCC Ground and Digital Pin. We connect VCC and ground to that of the particle Argon and connect the digital pin to the digital pin D4.  

  

0
Connection Diagram
Whatsapp image 2019 12 08 at 01.00.50.thumb
0

Working:

The sensor data are obtained from the appropriate pins. Once we obtain the individual sensor data, we normalize them. 
Humidity = humidity/100;

Temperature = temp/75 (optimal temperature);
Soil Moisture = moisture/100;
Ambient Light = light/1024;

After normalizing the values, we map them to our color variable y.

The mapping weights are decided by the survey and we obtain our color variable y. 

Y ranges from 0 to 1, we map it to the color range from 0-255.
Thus, we obtain a color range by varying the red and green parameters of the LED strip.

The IR detector detects a person in front of it.

Everytime it spots some, we increment our counter variable and change our blinking variable.

The blinking variable changes the speed at which the lights blink and thus we range from 10ms to 1s. 

As more number of people pass by, the speed decreases and becomes a near constant.

All the variable data is uploaded onto the particle cloud, and is subscribed by thingspeak.

The data from thingspeak is downloaded onto the mobile application where users can obtain raw data.


0
Trail Guider Individual System
Img 0148.thumb
0

For the data-oriented, the mobile application shows information in the following format,

0

Code:

0
// This #include statement was automatically added by the Particle IDE.
#include <Adafruit_DHT.h>
// This #include statement was automatically added by the Particle IDE.
#include <SharpIR.h>
// This #include statement was automatically added by the Particle IDE.
#include <neopixel.h>
#include <math.h>

#define PIXEL_PIN D3
#define PIXEL_COUNT 41
#define PIXEL_TYPE WS2812B
#define LEDCOUNT 41
// air condition
#define DHTPIN 2     // what pin we're connected to
#define DHTTYPE DHT22 // DHT 22 (AM2302)
DHT dht(DHTPIN, DHTTYPE);
// light sensor 
int temt6000Pin = A0;
//soil sensor
int soil_moisture_pin = A4;


Adafruit_NeoPixel strip(PIXEL_COUNT, PIXEL_PIN, PIXEL_TYPE);

float light=0;
float humidity = 0;
float temp_F = 0;
float moisture = 0;
float distance_value = 0.0;
bool seeingPerson = false;
long lastCount = millis();
int passCount = 0;
int totalCount = 0;
int IR = A1;
int fade=0;
int max_delay_ON = 1000;
int delayON = 10;
void setup() {
    
    pinMode(IR, INPUT);
    Serial.begin(9600);
    strip.begin();
    strip.show();
    Serial.begin(9600);
    Serial.println("ready");
    pinMode(soil_moisture_pin, INPUT); 
    pinMode(temt6000Pin, INPUT); 
    dht.begin();
}

void loop() {
    light = ambient_light();
    humidity = air_condition2();
    temp_F = air_condition1();
    moisture = soil_moisture();
    bool x = person_detected();
    Particle.publish("Moisture", String(moisture));
    Particle.publish("Light", String(light));
    Particle.publish("Total people crossing this point", String(totalCount));
    float light_mod = light/1024;
    float temp_F_mod = (temp_F-20)/70;
    float humidity_mod = humidity/100;
    float moisture_mod = 1-(moisture/100);
    float y;
    y = (light_mod*0.40) + (moisture_mod*0.55) + (temp_F_mod*0.025) + (humidity_mod*0.025);
    fade = map(y, 0.0, 1.0, 0.0, 255.0);
    fade = int(fade);
    seeingPerson = false;
    if (x == true){
        //fade = max(passCount * 30, 0);
        delayON = delayON + 10;
        if (delayON > max_delay_ON){
            delayON = max_delay_ON;
        }
    }    // ON
        for(int j = 0; j<LEDCOUNT;j++){
            strip.setPixelColor(j, 255 - fade, fade, 0);
        }
        strip.show();
        delay(delayON);
        //OFF
        for(int j = 0; j<LEDCOUNT;j++){
                strip.setPixelColor(j, 0,0,0);
            }
        strip.show();
        delay(delayON);
    
}

bool person_detected(){
    // Determine IR sensor distance
    float volts = float(analogRead(IR))*0.0048828125; 
    int distance = 13 * pow(volts, -1);
    distance_value = (distance_value * 0.7) + (distance * 0.3);
    if (distance_value <= 5){
        if(!seeingPerson && (millis() - lastCount > 2000)){
            lastCount = millis();
            if (passCount < 40) {
                totalCount++;
                passCount++;
                }
            else{
                totalCount++;
            }
            }
            seeingPerson = true;
        return true;
    }
    else{
        return false;
    }
}

float ambient_light(){
    float light;
    // Read sensor
    int light_value = analogRead(temt6000Pin);
    light = light_value * 0.0976;// percentage calculation
    
    return light;
}
float air_condition1(){
    float temp_F = dht.getTempFarenheit();
    return temp_F;
}
float air_condition2(){
    float humidity = dht.getHumidity();
    return humidity;
}

float soil_moisture(){
    float moisture_percentage;
    int sensor_analog;
    // Read sensor
    sensor_analog = analogRead(soil_moisture_pin);
    moisture_percentage = (100 - ( (sensor_analog/4095.00) * 100 ));
    return moisture_percentage;
}
Click to Expand
0

User flow:

1. Scott is an active runner. He uses the trails to run in the evenings. To challenge himself, Scott would love to take on longer and harder trails. Thus, the lighting system indicates which trail to pursue to achieve maximum efficiency and happiness.

2. Anne is a middle-aged woman who wants a safe path to walk daily. The trail lights show her the least rugged and highly used path to show her that she will have a safe and energetic walk.

3. Micheal is an 11-year-old who uses the trail to cycle every day. He needs to know the moisture and temperature before embarking on a particular trail in order to protect himself from slipping and dirt marks.

4. Sarah has just moved into the city. She finds the trails to be an exciting part of her daily exercise but isn’t sure about how to use them properly. The routing system of the trail lights guide her to a proper destination and Sarah can now feel at home

0
Trail Guiders - Example
Harshine Visvanathan - https://youtu.be/hYU6LCQX1lc
x
Share this Project

Courses

49313 Designing for the Internet of Things

· 11 members

Thermostats, locks, power sockets, and lights are all being imbued with smarts making them increasingly aware and responsive to their environment and users. This course will chart the emergence of ...more


About

An ambient interactive trail lighting system that guides the trail runners, cyclists, and other users of the Schenley Park Sportsplex.