We then explained our idea to our professor and he suggested we use Bluetooth communication and that we just track individual tools rather than rolls of tools, which we had been saying we would verify were complete using pressure sensors. These sensors can be sensitive to uneven weight distribution and can be tricky to make work. Rather the focus for this concept is on the core concepts of verifying users and the system having knowledge of what tools have been removed.
To that end we went ahead and ordered a few special components including the following:
-Adafruit Fingerprint Sensor
-Bluetooth LE Breakout - nrf8001 (BLE 4.0)
-Spark Battery Shield
Beyond this we also planned to leverage some Estimote beacons that the lab already on hand in order to do the Bluetooth tracking of tools.
We then attempted to prototype with these times, but ran into some issues with the fingerprint sensor and the Bluetooth breakout. The fingerprint sensor was originally designed to work with an Arduino board, but it should have been possible to port it over to the Spark core, which is the system were were prototyping with. After extensive experimentation there seemed to an issue with the serial communication. At this point we transitioned to using a pin code access system. Ideally we think a biometric system would be best because ID cards get lost and pin codes get forgotten.
To create the pin code system we used a combination of push buttons that have to be pressed in a particular order to match internal pre-programmed codes that are particular to each student. There is also a reset button to start over at any point in the process. The code is complete and shown below along with a diagram of the circuit.
In terms of the code to work with the nrf8001, there was Github code that had been posted by trond-snekvik, which had all the libraries needed. The code ran once any files that were not .h, .cpp or .ino were removed from the folder with the code and #include "nrf8001-ble-uart-spark-io.h" was uncommented. At that point the sample code ran, but with further investigation from our professor that this piece of hardware was actually not the correct one for the functionality we were looking for. We believe that the Red Bear Lab BLE Mini might be a good option going forward based on the documentation posted by krvarma on GitHub. For the purposes of the demonstration we used IFTTT and Yo, so that by hitting Yo when a tool is removed the cabinet the blue light turns on for the corresponding person.
Below is the parts list, circuit diagram and code from our final prototype is below.