- Creative thinking
- Tried to make it similar to previous project
- Use weight sensing
- Stock of supermarket shelves
- Not useful, as employees are plentiful enough
- Trash can fill level
- Parking lot fill level
- Most feasible, but already done
- Hardware design
- Sensor type decision
- Passive IR
- Not right for application
- Detects motion
- Laser
- expensive
- Weight
- Expensive: would require digging up the concrete
- Inductive coil
- Expensive: would require drilling into the concrete
- Ultrasonic
- Cheap
- Best choice
- Sensor location decision
- Under car in center of spot looking up
- Would be accurate if unobstructed
- Leaf or debris could change result
- Rain would damage parts
- No way to cover without blocking sound
- Above cars
- Too expensive and unsightly
- In front on a stake
- Easiest to implement
- Also cheapest
- Could be covered from rain
- Connecting sensors
- Initially, we thought 4 wires per sensor
- Would add up very quickly
- Some wires could be combined
- VIN, TRIG, and GND could be connected to same wire
- ECHO must be separate to distinguish between spots
- Problem: arduino cannot provide enough amps to power more than a few sensors
- VIN and GND could be connected to external 5V power supply, such as a wall charger for a phone
- TRIG cannot
- Could use an electronic “switch” to provide power from external power supply and give control to arduino
- Use a MOSFET
- Can allow a very large current to pass through when a small current is applied from Arduino
- Internet connectivity
- Initially, we planned on using WiFi with an ESP8266
- Included in the NodeMCU, which we had already
- Would reduce the wiring necessary to set up the system
- Power outlets are more common outside that ethernet
- Problem: WiFi modules compatible with Arduino do not support WPA2-Enterprise, which PAWS-Secure uses
- Must resort to ethernet
- Works on WPA2-Personal, though, so could test out functionality at home
- Bought a cheap ethernet module for the Arduino
- Tried to connect it to the internet in the classroom with the MAC-address registering service
- Didn’t work
- Got help from help-desk
- Said mac-registering only works in dorms
- Got help from Dr. Johnsen
- Worked with mac-registering in Virtual Experiences Lab
- Software
- Wrote a program in C for the Arduino to read the sensor values
- Takes a reading every second for ten seconds
- Averages the values
- If the values are > 200cm the spot is empty
- If the values are < 200cm the spot is full
- If the values haven’t changed by much, don’t send the values
- Wait 10 seconds
- repeat
- Initially used ThingSpeak to record data online
- Couldn’t customize data visualization
- Must use their website and graph over time
- Made a website from a template on GitHub pages to try to develop our own visualization of parking lot occupation
- Soon found out that GitHub pages does not support PHP, which would be necessary to allow the Arduino to send data
- Learned how to host our own server on a netbook at home
- Port forwarding
- Installing Fedora Server, Apache, PHP, and MySQL
- Learned basic PHP and MySQL to set up interface between Arduino and Server
- Wrote the website completely from scratch, without template
- Has very nice visualization of parking lot that can change color according to database
- Modified Arduino program to send data as a PHP POST request using an additional library for compatibility with the wifi module
- Had to switch the libraries and heavily modify code to work with ethernet module when we found out wifi didn’t work
- Ported to Python to more easily work with the Raspberry Pi (detailed below)
- Testing a prototype
- Getting ethernet from a compatible port to a parking spot would be difficult for this small test
- Would have to use wireless
- Nithin got a Raspberry Pi
- Has WiFi that supports WPA2-Enterprise
- Would have to port all code and hardware connections to the Pi
- Making a PHP POST request would work easiest in Python because of the many examples
- Converting the non-networking code to Python should not be extremely difficult
- developing...
- Total languages used
- C (Arduino)
- Python
- PHP
- SQL
- Lots of config files
- Lots of bash commands
- HTML
- CSS
- English?
List of Responsibilities
Anton:
- Developing web server
- Creating the website
- UI of website
- Hardware engineer
- Power delivery
- Tested sensor in garage
Nithin:
- Converted code from Arduino code to Python
- Provided Rasberry Pi
- Set up the OS on Rasberry Pi
- Learned how to do SSL security stuff
Ryan:
- Wrote essay
- Group leader
- Assigning tasks and organizing work
Challenges we faced:
- Setting up PHP and SQL
- Setting up a server
- Problems with internet
- Ethernet
- Rasbery Pi which uses Wi-Fi
- Figuring out GPIO pins on Rasberry Pi
- Power delivery