Skip to main content

Week 4 (Sept. 19, 2018): Skimming through the Python Program


Today, after a visit from Colin, who was a tremendous wealth of knowledge as he was on the Small-Scale Controls team last year, I began sifting through the Python Programming in order to prepare for understanding how the Raspberry Pi operating the LCD touchscreen for user interface is programmed. I plan on taking the lead on the software aspect of the controls system, while David will be in charge of hardware for the most part. However, we will work together as much as we can as the two aspects are dependent on each other: the hardware cannot function properly with the software, while the software is useless if it has nothing to be implemented upon.

Last year’s Python code is found on the team’s Google document “Small Scale Controls ME 195B Term Paper” in Appendix 4 on page 55.

I was able to read and understand the first half of the program due to Python’s simple syntax as well as its similarity with Java, C, and Arduino. For example, the purpose of the first chunk of “if-elif” statements is as follows: if the XBee module has checked in a Station 1, display “01” on the LCD touchscreen. The XBee module is the wireless communication module used to communicate between the Arduino, located inside each podcar, and the Raspberry Pi, located inside the LCD touchscreen for the mobile application.
To make this happen, the RFID tag and receiver will determine if the pod car has arrived at that station; this signal will be sent to the Arduino in the pod car; the Arduino will communicate with the XBee module #1 attached to it; XBee module #1 will wirelessly communicate with XBee module #2 on the Raspberry Pi within the LCD touchscreen; lastly, XBee module #2 will tell the Raspberry Pi if the podcar is indeed at Station 1.

Comments

Popular posts from this blog

Week 29 (May 1, 2019): CAD of Induction Charger Hub & Podcar Door, then 3D Printing

This week, while David worked on the Raspberry Pi and the Arduino code, Patrick completed the CAD (computer-aided-design) models. We had to create 3D solid modeling of two parts: the induction charging hub to hold the induction transmitter coil and the pod car door to hold the induction receiver coil. Over the weeks, the CAD models underwent several revisions. The induction hub saw two revisions, with the third design being the final version. Because the 3D printer available to us in the shop, the Prusa Mark3 i2, had a bed length of 10 inches, we had to restrict the length of the charging hub to a safe 9.5 inches. Version 1 simply entailed us placing the hub on the side of the bracket and then screwing it into place on the bracket’s side via the two holes at the top: For version 2, in addition to placing the hub on the side of the bracket and then screwing it into place on the bracket’s side via the two holes at the top, the bracket would wrap around the two bracket...

Week 30 (May 8, 2019): Prototype Evaluation Day, Final Circuit, Incorporating 3D printed parts, Final Presentation, Posters, & Maker Faire

Today, we held Prototype Evaluation Day. Like the rest of the senior project classes, the advisor walks around the classroom, evaluating the senior project apparatuses, asking the student teams to demonstrate their devices, and explain their design, though processes, and results. Dr. Furman and Ron examined and inspected the Full-Scale model, then the Half-Scale model, and lastly, us, the Small-Scale Team. We had completed our circuit to power one pod car and one of the two induction charging stations prior to Evaluation Day, so we were able to successfully demonstrate the pod car driving around the track as well as the induction charging. While we were still troubleshooting issues with the tablet’s Raspberry Pi communicating with the Arduino, the Arduino is still capable of operating on its own, so we could at least demonstrate the motor driving the pod car around the track and through the offline stations. Depicted below is our final circuit that powers the pod car: Dep...

Week 26 (Apr. 10, 2019): Programming – Python and Arduino Communication

The Python code and the Arduino code are able to run successfully on their respective boards, i.e. the Raspberry Pi in the tablet and the Arduino in the pod car. However, the Raspberry Pi is having issues sending data to the Arduino via the XBee RF (radio-frequency) module, specifically the user-input data. Whenever the user inputs the pickup station, destination, and selects a pod car, the Serial Monitor on the Arduino IDE does not show any of the data. Investigating further, we plugged the XBee module into one of our laptops, then opened the XCTU software’s (the software which deals with RF modules) Serial port as well. Now, whenever the user inputs the stations, we can see on the XCTU Serial Monitor that the receiving XBee does get the pickup station, destination, and pod car number, but the three inputs are all found between jumbles of random characters. As displayed in the screenshot of the XCTU software below, if the user inputs pickup station 2, destination station 5, and sele...