Top Banner
Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy Mestancik, Brian Simakauskas
19

Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

Jan 02, 2016

Download

Documents

Aubrey Pitts
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

Electrical and Computer Engineering

Dynamic Advertising

System Midway Design Review –

December 7, 2009Team Zink

Nicholas Cipriano, Ali Jameel, Jeremy Mestancik, Brian Simakauskas

Page 2: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

2Electrical and Computer Engineering

Background

Dynamic Advertising creates a system that allows organizations to schedule advertising based on time and location on public transportation systems

A user friendly website allows users to select ad space and time with a few clicks of the mouse• Saves time• Ads can begin displaying just minutes later

Advertisements display – still images or animations on LCD screen located inside bus

Page 3: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

3Electrical and Computer Engineering

Block Diagram

Page 4: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

4Electrical and Computer Engineering

User login select.php allows user to:

• View uploaded ads• Upload a new ad• Enter GPS coordinates, enter times, select route,

select ad, submit

Every user submission creates a new table or entry in MySQL database

Web Server – Website

Page 5: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

5Electrical and Computer Engineering

Web Server – MySQL Database

Images stored in a folder• MySQL contains file path

Images

Page 6: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

6Electrical and Computer Engineering

Web Server – PHP and FTP

PHP • Inserts data into MySQL tables• Searches MySQL tables to select which

advertisements busses will need• Helps to create dynamic web pages – can

display to a user available advertising space, times, etc.

FTP (File Transfer Protocol)• Transfers files to bus

Page 7: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

7Electrical and Computer Engineering

Transfer Protocol

Stream Sockets Connection-Based• Sequential and non-duplicated Data transfer

Bus/Client socket connects to Website/Server socket requesting information

Two different requests from buses • Schedule request• Ad request

Page 8: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

8Electrical and Computer Engineering

Transfer Protocol Cont.

Protocol• Bus contacts server and sends identifying information• Server processes info and sends bus required ad

schedule info• Bus processes schedule info and forms a queue of ads

not available in bus memory, starting with the ad needed soonest.

• Bus requests ad from server• Ads written into memory replacing least recently used

ad not in daily schedule

Page 9: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

9Electrical and Computer Engineering

Read Files From Server

Reading Files is done in C Take files from web server and input them into

a .txt file Data taken in for ads is start time, end time, start

latitude, end latitude, start longitude, end longitude, and the advertisement name

We use two 2D arrays to hold the data• One array for integer information (ie. start time… etc)

• Adinformation[ad#][integer data ]• One array for char information (ie. ad name)

• Adname[ad#][ ad name]

Page 10: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

10Electrical and Computer Engineering

Displaying The Advertisement

Ads displayed in a web browser Displayed using HTML and JavaScript

• Able to auto refresh the page at any increment of time• Able to display image in full screen without sidebars• Able to preload images so there is no delay between

changes

If C programs DisplayThisAd.jpg to a file in the advertisement directory the ad is displayed.

If DisplayThisAd.jpg is not in the directory, display a default image

Page 11: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

11Electrical and Computer Engineering

Reading The GPS Information

The COM port is opened in C

The GPS unit displays information in NMEA format

The necessary information needed from the GPS is time, latitude, and longitude

The format of the messages is known, allowing the data to be parsed and stored in arrays

Page 12: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

12Electrical and Computer Engineering

Converting the GPS coordinates

The user inputs the GPS data in ddmmss.ss format, but NMEA format is ddmm.mmmm

The GPS data is read as chars but a conversion is needed to ints

Once the necessary data casted, the information is converted to Decimal Degrees format, and then to Degrees Minutes Seconds format (DMS)

Page 13: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

13Electrical and Computer Engineering

Comparing the GPS coordinates

The GPS coordinates entered by the user are compared to the GPS coordinates found after the conversions

Start latitudes and longitudes are both compared, and when they are equal, a control is sent to display that ad

The control checks the GPS start and end coordinates and decides which ad is to be displayed and which ad is to be replaced

Page 14: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

14Electrical and Computer Engineering

Meeting with Brian Lynn

Brian Lynn worked on Dieselnet, we met with him and received the following info about PVTA busses:

• Bus power: 24 VDC (Two 12 V batteries) => 120 AC

• Dieselnet transformers have at least three available outlets in cabinet behind bus driver

• Internet connectivity is 88% reliable

• Dieselnet can share bus route database

• Power outlets shut off immediately when bus turned off

• Options:

• Install small battery

• Accept immediate shutdown

Page 15: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

15Electrical and Computer Engineering

Prototype Hardware

Intel Mini ITX Board OS: Ubuntu Linux Hitachi 1 TB Hard Drive

Eventually solid state drive Memory 1 GB DDR 2 Power Supply

GPS: Garmin 15XW

Page 16: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

16Electrical and Computer Engineering

MDR Deliverable

Ability to read GPS coordinates and display different images on LCD

Establish communication between server and client (bus) systems

Website with basic functionality• Website allows user to upload advertisement image,

select times of display• Waiting for full functionality before purchasing domain

Page 17: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

17Electrical and Computer Engineering

Next Step

Attach and implement remaining hardware components• GPS Antenna• Wireless Ethernet card

Make web server able to determine and Identify unique bus routes

Efficiently search MySQL tables and determine upcoming Ads.

Rewrite server socket code in PHP and establish a socket connection between the bus and web server.

Page 18: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

18Electrical and Computer Engineering

Team Roles• Nicholas - Responsible for retrieving images on the display unit and formatting them to correctly fit the LCD screen

• Ali - In charge of GPS signal processing and determining the correct advertisement to display.

• Jeremy - Working on configuring the link between the client (bus) and server. Over TCP/IP this involves using a file transfer protocol to send the correct data to each bus

• Brian - Responsible for designing the web server, configuring the MySQL database, and writing PHP code to determine the correct data to send to each bus

Page 19: Electrical and Computer Engineering Dynamic Advertising System Midway Design Review – December 7, 2009 Team Zink Nicholas Cipriano, Ali Jameel, Jeremy.

19Electrical and Computer Engineering

Website – A Primitive Version