FAB DATA GLASS

- A Low Cost Augmented display.

Overview of Project Requirement

  • Design and fabricate your own parts instead of buying off-the-shelf components.
  • Prove mastery of the skills gained during the program.
  • select and apply appropriate additive and subtractive techniques
  • demonstrate competence in design, fabrication and programming of your own fabbed microcontroller PCB, including an input & output device
  • demonstrate 2D & 3D modelling capabilities applied to your own designs
  • create your own integrated design
  • ASSIGNMENT

    Project Development

    Have you answered these questions:

    • what is the deadline? How much time do I have left?
    • what tasks have been completed, and what tasks remain?
    • how will I complete the remaining tasks in time?
    • what has worked?
    • what hasn't?
    • what questions still need to be resolved?
    • what have you learned?

    This week i started my final project development, ordered the componenets for my Fab DATA GLASS and started designing. My final project presentation page is shown beside introduction tab


    1. What is the deadline? How much time do I have left?

    For doing the entire project i have made a shedule in tabular format. Our project presentation is on 19 June 2017, this is 7th June 2017 and we have only 12 days to present. I am planning to finish it by 17th June 2017.

    2. What tasks have been completed, and what tasks remain?

    I will share the shedule here in that you can find what is the time limit i have given to complete each task.

    FAB DATA GLASS Work Schedule

    Sl.No Activity Sheduled date Status
    1 Components collection 28 May 2017 completed on 01 June 2017
    2 PCB designing 05 June 2017 Completed on 10 June 2017
    3 PCB Milling and soldering 07 June 2017 On going process
    4 Programming and Testing 10 June 2017 NA
    5 Case Design and 3D printing 12 June 2017 NA
    6 Integration & Testing 14 June 2017 NA
    7 Carry Case design and fabrication 16 June 2017 NA
    8 Documentation and poster making 17 June 2017 NA

    3. How will I complete the remaining tasks in time?

    As per the above shedules, currently i am delayed by almost three days, Actually my PCB Designing took more time because i was thinking to design the board in small formfactor and that took me time and i was able to get the size as expected Our presentation is on 19th June and i am planned to finish it on 17th june, so maximum with in 18th june i have time to finish it. I planned to work extra time on each day to counter balance the delays. Currently i am spending almost 15 hours per day for the development .

    4. What has worked?

    soldering and continuity checks are on going. Started the programming on the arduino pro mini to understand the programming ,easy to port on the board which i am going to build, i am able to program the board to display test on the OLED which is showed in my project documentation. Now i have to go to the actual board and to do learning, edit and finally to program the board.

    5. What hasn't?

    I am currently going through the 3D Designing , once the board is designed and solderd perfectly i can design the case for my data glass it was little problematic ,and also i was unable to find the optics sutable so i had to figure out in which way i can make my optics workout.

    6. What questions still need to be resolved?

    I have to make the reflective surface and also i have to find a mirror to make the optics perfect,i am still figuring out it,I thought to finish basic functions as only display the data from sensors and will do implimentation of bluetooth later.

    7. What have you learned?

    Still i am continuing in working with different processes and machines, what i learned in this week is to make a double side board in modela machine. The 3D design of my case is going in rhinoceros and finding correct refelctor material is on going. It was a different experience from regular college experience.

    Introduction

    I had intially thought to make a access control system for the fablab tools and machines using NodeMCU and but later i have changed my idea to build a Low Cost Augmented display and the previous ideas concept image and current project Concept image can be found Here

    I wanted to know the current temprature and Humidity ,Pressure and Altitude and Light Intensity data with out looking into the mobile and also i wanted to connect my device with the my fellow fabber Ajith's Project to get the data from the Easy Tester via bluetooth but due to lack of time i am doing it in a spiral development so i have planned to restrict myself till the getting data from the sensors,but in future i am going to continue the project that can be found here on my Github Repo.The process and the skills shown in the fabrication are fulfilling the Requirements of the complete final Project .



    Processed Involved

    Here i am going to explain what all process i have gone through to fabricate my FAB DATA GLASS

    Electronic Design

    I have designed a board using the ATMega328P AU ,in the form factor of the 30mmx80mm and i was able to design the board using the Autodesk Eagle Software i have decided to make the double sided PCB as the formfactor is small ,i have applied the DRC accordingly and i have done the auto route then i was able to sucessfully design the board

    Schematic Design of the board
    Routed Design of the board

    Now i have to design my sensor and switch board for which i have placed the all components and done the manual routing as there are very less components here you can see the schematics and board design

    Schematic Design of the sensor board
    Routed Design of the sensor board

    Electronics Production

    Then i had planned to make the double sided pcb on Modela MDX-20,I have learned how to mill from Ajith Kumar as he already made a double sided PCB board for his project i was able to learn it easily from him.I made a setup for making the double sided pcb's. First we need to fix the X and Y origins so that it won't change while doing the bottom layer.

    setting up the bed for milling

    After fixing the X and Y origins i have done some trials to findout the exact coordinates by drilling a 0.8mm hole on the top and bottom of the pcb, for that i have created a small circular dot in gimp and exported into png file. checked the orientation of the holes and done some more trials to match the hole orientations. Finally i found the X and Y origins and then fixed actual pcb.

    placed the double sided board for milling Top Side

    The top layer png image were opened in fab modules and milled the board using 1/64 (0.4mm) bit. The pcb milling of top layer and after the completion of toplayer is shown in the below image.

    Top Side Routing
    Using the fab modules milling
    after milling Completed for the Top Side

    In this step i need to mill the bottom layer of the pcb, for that what i did is i flipped the bottom layer mill traces image horizontally and rotated it to 90 degree clockwise as shown below and like wise i placed the pcb on the bed of modela.

    bottom Side Routing
    Using the fab modules milling bottom side

    After milling the top and bottom layers, placed the top layer back on to the bed of modela. Then opened the cutout image(png) file in fab modules and changed the bit to 1/32mil(0.8mm) and processed. The final pcb after milling and cutting is given below. In this you can see that slight variations in the hole is there, but as it is very small i can adjust it. Some tarcks were shorted in the usb connector area due to the clearence issue. I seperated it using a knief

    cutting and Drilling holes Trace
    Using the fab modules cutting and Drilling holes

    Now i have also designed a seprate board for the switches and sensors that also i have designed in the eagle and i have manually routed it that also i have milled

    Traces for the sensor board
    cut part for the sensor board
    Using the fab modules Traces
    Milled board

    Soldering the Electronic Components

    After completing the pcb milling, i did the via soldering . All the top and bottom traces were interconnected with vias and these vias need to be connected using wires. I have used the Single Strand Wire which is took from the Networking wire and i have sucessfully completed the vias and continutity checked using the multimeter

    Soldering the vias
    The Componets List sheet
    Soldering the board
    Soldering the board

    After soldering i have thought i can upload the frimware and program from the ftdi and i was not aware its not possible without having a frimware in it i haven't added a ISP header to my board to reduce the size ,then i got to understand all my 4days hardwork is gone. i also tried to tap the vies from SCK and MOSI to get the pins required for the programming but unfortunately something went wrong and i was unable to upload the frimware and code so i have decided to make a single sided board for the time constrain ,i have made changes in the board design and DRC and have rearranged the components and routed manually and selected autoroute process.

    Mean while i have soldered the small board which has the sensors and switches

    Soldering the sensor board

    Now i have milled the new main board as per the changed design and i have soldered it

    New Milled main board

    i had slight issue in the connecting some wires in this as single sided board i have made some manual vias under the board and sucessfully soldered the board

    Vias

    Now sucessfully i have completed the soldering and i can program the board that can be found under the programming section

    Finall Soldered Main board

    Thus the electronic production is come to an end i was able to complete the main controller board part

    Computer Adided Design

    Before going into the Computer aided design i had done the paper prototyping to understand how i can best fit the components in the case.That was very useful

    Used a Scale to understand the size of the actual case required

    I have used Rhino Software for creating the casing for my data glass and i have shown the design files screenshots here and i have attached the design files for download

    Final design of the cad models
    Top plate of the design
    optics holder

    3D Printing

    I have used the Ultimaker 2 for 3D Printing the parts which i have designed in the Rhino software are saved as STL files.and those are available in the download section in conclusion

    3D Printing using the White Filament
    Failed 3D printed Top case

    I had an issue with the design of the top layer which thickness is very low and the optics holder has light coming from outside because it is white so i had reprented

    3D Printing using the Blue Filament
    Cleaning the 3D Printed parts

    Now Finally i have compeleted the 3D Printing so almost the projects to be done are completed

    Integration

    I have Integrated all components to fit insde the case and i had done the connections between switches and the main board with ribbon cable the setp by step setup

    connected before putting before in caseing to do final check
    First placed the battery and the charging circuit
    Then connected the main board on top
    The Complete assembly of FAB DATA GLASS

    I have put the lense as per the focal length tested

    optics holder placing

    LASER Cutting

    I have planned to put the screws to fasten the Data Glass two parts due to space constrain i am unable so,i have designed a C-clamp which can hold the top and botton parts together and also the buttons went inside to i have designed the small cylinders shapes so i can stick them on top of buttons.and also glass holder small c-clamps also i have designed the reflector with 2mm acrylic sheet and i have cutted using the Laser Cutter. The original design files are added in conclusion page.

    C-clamp and switch extender Design
    Laser Cutted parts

    Finshing and Packaging

    Vinyl Cutting

    I have designed a top layer to cut on vinyl sheet to cover wide holes and make it neat for final stickering.

    Top layer for cutting on vinyl sheet

    Finally the product is almost ready

    FAB DATA GLASS
    Names to cutting on vinyl sheet
    Loading the png to fabmodules

    Finally i have made the my project looks completed

    Loading the png to fabmodules

    Laser Cutted carrying/Storage case

    i thought to make a storage case for FAB DATA GLASS for making it safe.

    Designed using the inkscape
    Storage Case for the FAB DATA GLASS

    With this my project completes and i have used all the skills and also i have uploaded the necessary download files in the conclusion page.

    Bill Of Materials

    Sl.No Components Qty(Nos) Cost per Item ₹ (INR) Total Price
    1 Atmega328P-AU 1 110.00 110.00
    2 AMSS117 3.0 1 35.00 35.00
    3 Resistor 4.9k 10 0.25 2.5
    4 Resistor 499Ohms 2 0.25 0.50
    5 Resistor 10kOhms 2 0.25 0.50
    6 Capacitor- 0.1uF, 1206SMD 5 4.00 20.00
    7 Capacitor- 10uF, 1206SMD 2 4.00 8.00
    8 tactile switch, 1206SMD 5 3.00 15.00
    9 Capacitor-22pF, 1206SMD 2 4.00 8.00
    10 Crystal-16MHz SMD/Leaded 1 15.00 15.00
    11 LED's Red 2 1.00 2.00
    12 LED's Green 1 1.00 1.00
    13 DHT11 Sensor 1 200 200
    14 BMP180 Sensor 1 310 310
    15 LDR 1 15 15
    16 Li-Po3.3V 280mAh Battery 1 100 100
    17 Li-Po Battery Charger 1 75 75
    19 Acrlic Mirror 1SqFeet 1 150 150
    20 pin header 20 5 5
    21 slide switch 1 10 10
    22 Push button switch SMD 1 30.00 30.00
    23 ISP Header 1 10.00 10.00
    24 Lens 1 45.00 45.00
    Total Cost Of componenets in ₹ (INR) ₹ 1017.50 or 16 USD

    Programming and Output

    i have gone through all the basic sample codes for the DHT11,BMP180 ,Reading Lux values from LDR and finally able to compile the code and made it up and running.

    Here is the code which i have used to programming the FAB DATA GLASS

    1. #include <Wire.h>
    2. #include <Adafruit_BMP085.h>
    3. #include <DHT.h>
    4. #include "U8glib.h"
    5. U8GLIB_SSD1306_128X64 u8g(U8G_I2C_OPT_NO_ACK); // Display which does not send AC
    6. #define DHTPIN 2
    7. #define DHTTYPE DHT11
    8. DHT dht(DHTPIN, DHTTYPE);
    9. Adafruit_BMP085 bmp;
    10. // define pins to be used
    11. int S1 = 3; //switch 1
    12. int S2 = 4;
    13. int S3 = 5;
    14. bool first = true;
    15. float hum = 0.0;
    16. float temp = 0.0;
    17. float hIndex = 0.0;
    18. bool dht_test(float* humPerc, float* tempF, float* heatIndex);
    19. int sensorValue = 0;
    20. unsigned int curOutputValue = 0;
    21. unsigned int lastOutputValue;
    22. float pressure = 0.0;
    23. float tempC = 0.0;
    24. float altitude = 0.0;
    25. void BmpSensorRead(float* pressure, float* tempC, float* altitude);
    26. void DisplayPresTemp(float* pressure, float* tempC, float* altitude);
    27. void setup() {
    28. // initialize the digital pins.
    29. // assume switches will wire from ground to input pins
    30. pinMode(S1, INPUT_PULLUP);
    31. pinMode(S2, INPUT_PULLUP);
    32. pinMode(S3, INPUT_PULLUP);
    33. Serial.begin(9600);
    34. dht.begin();
    35. lastOutputValue = ~curOutputValue;
    36. // assign default color value
    37. if (u8g.getMode() == U8G_MODE_R3G3B2)
    38. {
    39. u8g.setColorIndex(255); // white
    40. }
    41. else if (u8g.getMode() == U8G_MODE_GRAY2BIT)
    42. {
    43. u8g.setColorIndex(3); // max intensity
    44. }
    45. else if (u8g.getMode() == U8G_MODE_BW)
    46. {
    47. u8g.setColorIndex(1); // pixel on
    48. }
    49. else if (u8g.getMode() == U8G_MODE_HICOLOR)
    50. {
    51. u8g.setHiColorByRGB(255, 255, 255);
    52. }
    53. for (int a = 0; a < 30; a++)
    54. {
    55. u8g.firstPage();
    56. do
    57. {
    58. u8g.setFont(u8g_font_fub11);
    59. u8g.setFontRefHeightExtendedText();
    60. u8g.setDefaultForegroundColor();
    61. u8g.setFontPosTop();
    62. u8g.drawStr(4, a, "FAB DATA GLASS");
    63. }
    64. while (u8g.nextPage());
    65. }
    66. delay(3000);
    67. if (!bmp.begin())
    68. {
    69. u8g.firstPage();
    70. do
    71. {
    72. u8g.setFont(u8g_font_fub11);
    73. u8g.setFontRefHeightExtendedText();
    74. u8g.setDefaultForegroundColor();
    75. u8g.setFontPosTop();
    76. u8g.drawStr(4, 0, "FAB DATA GLASS");
    77. u8g.drawStr(4, 20, " ERROR!");
    78. }
    79. while (u8g.nextPage());
    80. Serial.println("FAB DATA GLASS, ERROR!");
    81. while (1) {}
    82. }
    83. }
    84. void HumMeter(float* humPerc, float* temp, float* heatIndex)
    85. {
    86. u8g.setFont(u8g_font_fub11);
    87. u8g.setFontRefHeightExtendedText();
    88. u8g.setDefaultForegroundColor();
    89. u8g.setFontPosTop();
    90. u8g.drawStr(4, 0, "Hum %");
    91. u8g.setPrintPos(80, 0);
    92. u8g.print(*humPerc);
    93. #ifdef METRIC
    94. // if metric system, display Celsius
    95. u8g.drawStr(4, 20, "Temp C");
    96. #else
    97. //display Farenheit
    98. u8g.drawStr(4, 20, "Temp F");
    99. #endif
    100. u8g.setPrintPos(80, 20);
    101. u8g.print(*temp);
    102. u8g.drawStr(4, 40, "Heat Ind");
    103. u8g.setPrintPos(80, 40);
    104. u8g.print(*heatIndex);
    105. }
    106. bool dht_test(float* humPerc, float* temp, float* heatIndex)
    107. {
    108. // Wait a few seconds between measurements.
    109. delay(2000);
    110. *humPerc = 0;
    111. *temp = 0;
    112. *heatIndex = 0;
    113. // Reading temperature or humidity takes about 250 milliseconds!
    114. // Sensor readings may also be up to 2 seconds 'old' (its a very slow sensor)
    115. float h = dht.readHumidity();
    116. // Read temperature as Celsius (the default)
    117. float t = dht.readTemperature();
    118. // Read temperature as Fahrenheit (isFahrenheit = true)
    119. float f = dht.readTemperature(true);
    120. // Check if any reads failed and exit early (to try again).
    121. if (isnan(h) || isnan(t) || isnan(f))
    122. {
    123. Serial.println("Failed to read from DHT sensor!");
    124. return false;
    125. }
    126. // Compute heat index in Fahrenheit (the default)
    127. float hif = dht.computeHeatIndex(f, h);
    128. // Compute heat index in Celsius (isFahreheit = false)
    129. float hic = dht.computeHeatIndex(t, h, false);
    130. Serial.print("Humidity: ");
    131. Serial.print(h);
    132. Serial.print(" %\t");
    133. Serial.print("Temperature: ");
    134. Serial.print(t);
    135. Serial.print(" *C ");
    136. Serial.print(f);
    137. Serial.print(" *F\t");
    138. Serial.print("Heat index: ");
    139. Serial.print(hic);
    140. Serial.print(" *C ");
    141. Serial.print(hif);
    142. Serial.println(" *F");
    143. *humPerc = h;
    144. #ifdef METRIC
    145. // metric system, load degree celsius
    146. *temp = t;
    147. *heatIndex = hic;
    148. #else
    149. *temp = f;
    150. *heatIndex = hif;
    151. #endif
    152. return true;
    153. }
    154. void LightMeter(uint16_t percentLight)
    155. {
    156. u8g.setFont(u8g_font_fub17);
    157. u8g.setFontRefHeightExtendedText();
    158. u8g.setDefaultForegroundColor();
    159. u8g.setFontPosTop();
    160. u8g.drawStr(4, 0, "Light %");
    161. u8g.drawStr(4, 20, "Meter");
    162. u8g.drawFrame(4, 40, 122, 24);
    163. u8g.drawBox(8, 44, (114 * percentLight / 100), 16);
    164. //
    165. if (percentLight > 99)
    166. {
    167. u8g.setPrintPos(90, 15);
    168. }
    169. else
    170. {
    171. u8g.setPrintPos(100, 15);
    172. }
    173. u8g.print(percentLight);
    174. }
    175. void DisplayPresTemp(float* pressure, float* tempC, float* altitude)
    176. {
    177. u8g.firstPage();
    178. do
    179. {
    180. u8g.setFont(u8g_font_fub11);
    181. u8g.setFontRefHeightExtendedText();
    182. u8g.setDefaultForegroundColor();
    183. u8g.setFontPosTop();
    184. u8g.drawStr(2, 0, "Pressure");
    185. u8g.setPrintPos(75, 0);
    186. u8g.print(*pressure);
    187. u8g.drawStr(4, 20, "Temp C");
    188. u8g.setPrintPos(75, 20);
    189. u8g.print(*tempC);
    190. u8g.drawStr(4, 40, "Altitude");
    191. u8g.setPrintPos(75, 40);
    192. u8g.print(*altitude);
    193. }
    194. while (u8g.nextPage());
    195. }
    196. void BmpSensorRead(float* pressure, float* tempC, float* altitude)
    197. {
    198. *tempC = bmp.readTemperature();
    199. Serial.print("Temperature = ");
    200. Serial.print(*tempC);
    201. Serial.println(" *C");
    202. *pressure = bmp.readPressure() / 100.0;
    203. Serial.print("Pressure = ");
    204. Serial.print(*pressure / 100.0);
    205. Serial.println(" hPa");
    206. // Calculate altitude assuming 'standard' barometric
    207. // pressure of 1013.25 millibar = 101325 Pascal
    208. *altitude = bmp.readAltitude();
    209. Serial.print("Altitude = ");
    210. Serial.print(*altitude);
    211. Serial.println(" meters");
    212. }
    213. void loop() {
    214. if (!digitalRead(S1))
    215. {bool result = dht_test(&hum, &temp, &hIndex);
    216. if (first)
    217. {
    218. // skip displaying readings first time, as its stale data.
    219. first = false;
    220. }
    221. else
    222. {
    223. if(result == false)
    224. {
    225. u8g.firstPage();
    226. do
    227. {
    228. // sensor error
    229. u8g.setFont(u8g_font_fub11);
    230. u8g.setFontRefHeightExtendedText();
    231. u8g.setDefaultForegroundColor();
    232. u8g.setFontPosTop();
    233. u8g.drawStr(10, 30, "Sensor Error");
    234. }
    235. while (u8g.nextPage());
    236. }
    237. else
    238. {
    239. u8g.firstPage();
    240. do
    241. {
    242. HumMeter(&hum, &temp, &hIndex);
    243. }
    244. while (u8g.nextPage());
    245. }
    246. }
    247. }
    248. if (!digitalRead(S2))
    249. { BmpSensorRead(&pressure, &tempC, &altitude);
    250. DisplayPresTemp(&pressure, &tempC, &altitude);
    251. delay(1000);
    252. }
    253. if (!digitalRead(S3))
    254. {
    255. sensorValue = analogRead(A0);
    256. Serial.print("input :");
    257. Serial.println(sensorValue);
    258. // map input values between 0 t0 100%
    259. curOutputValue = map(sensorValue, 0, 690, 0, 100);
    260. if (curOutputValue > 100)
    261. {
    262. curOutputValue = 100;
    263. }
    264. if (lastOutputValue != curOutputValue)
    265. {
    266. lastOutputValue = curOutputValue;
    267. u8g.firstPage();
    268. do
    269. {
    270. LightMeter(curOutputValue);
    271. }
    272. while (u8g.nextPage());
    273. }
    274. }
    275. }

    Output

    i have tested output of the device

    output can seen on the relector

    here you see the intial testing

    When Intially tested the Display Using the board made by me

    here you see the final output after programming and i had a problem with recording from reflector as the intensity is very less that is easily visble to naked eye but difficult to capture from mobile phone camera so i have opened the case and recorded the video

    Conclusion and Design Files

    Here video and the poster used for the final presentation is depicted in this page.


    Design Files

    Here you can download all the files to reproduce the work













    © 2017, made with by scitechindian

    Creative Commons License

    This work done by SYED JUNAID AHMED is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.