(33 intermediate revisions by the same user not shown) | |||
Line 543: | Line 543: | ||
<b>November 25, 2011 (30 minutes):</b> | <b>November 25, 2011 (30 minutes):</b> | ||
<br> | <br> | ||
+ | Created a server on my netbook while on campus...no public IP from PAL, which I figured would be the case. For this semester, any demo for HK will have to be done using a different wireless connection. | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | |||
+ | <table border="1" bgcolor=#D2B48C> | ||
+ | <tr> | ||
+ | <td width=800><b>WEEK SUMMARY:</b><br> | ||
+ | <u>Accomplishments</u>: Web server successfully setup with a functioning index | ||
+ | <br> | ||
+ | <u>Weekly Work Total</u>: 11 hours | ||
+ | <br> | ||
+ | <u>Project Work Total</u>: 67.9 hours | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | <br> | ||
+ | ---- | ||
+ | |||
+ | |||
+ | <table border="0"> | ||
+ | <tr> | ||
+ | <td width=800><center><h2>Week of Nov. 28</h2></center></td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | <table border="1" bgcolor=#FFFFBB> | ||
+ | <tr> | ||
+ | <td width=800> | ||
+ | <b>November 28, 2011 (8 hours):</b> | ||
+ | <br> | ||
+ | Spent a good deal of time debugging my index.php and making it work with the php_serial.class.php. I had to make some changes so that the php errors and warning would show up. In the php.ini file, I changed display_errors = Off and error_reporting = E_ALL. Errors/warning still did not show up so, in the httpd.conf for apache2, I added "php_flag display_errors on" and | ||
+ | "php_value error_reporting 2039" which resulted in a load of error files echoed on index.php upon a refresh. Essentially, any access by the script was getting an "Access denied". All of the commands use stty. The command by the script, which took "/dev/ttyO2" as an argument, was essentially running the command "stty -F /dev/ttyO2" and getting the access denied reply. I tried this command in a terminal on the board and had no trouble running it.<br><br> | ||
+ | Obviously the permissions were not right, so I ran "sudo chmod 777 /dev/ttyO2" and reloaded the page - no more errors. I hooked up the scope to the transfer line of the serial port on the pandaboard and pressed the buttons on the site from my netbook and saw blips on the scope - finally things were working right.<br><br> | ||
+ | Scott hooked up the pandaboard to his laptop and ran putty. It works!<br><br> | ||
+ | [[Image:Pandaboard_serial.avi]] <br><br> | ||
+ | Scott, Kin Chin, Michael, Matt, and Chris worked on figuring out the initializations and main code for the microcontroller. Once they had what they thought would work, we hooked the two boards up - nothing. We tried the micro with putty - and it worked! So, we currently have the Pandaboard<-->laptop and micro<-->laptop connections working. However, at this point we cannot get the two to communicate with each other. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>November 29, 2011 (30 minutes):</b> | ||
+ | <br> | ||
+ | Did more research on serial connections to figure out why the Pandaboard was not communicating with the micro. I found an article I came across previously stating "When PCs are connected back-to-back each end is acting as a DTE (there is no DCE in this case) and consequently certain signals may have to be looped in the connection to satisfy any input signal requirement." This is, right now, the only possible reason I can think of as to why the two are not communicating.<br> | ||
+ | http://www.zytrax.com/images/rs232_db9.gif <br> | ||
+ | <br> | ||
+ | Pin----Signal--In/Out---Description<br> | ||
+ | 1-------DCD-----In------Data Carrier Detect<br> | ||
+ | 2-------RxD-----In------Receive Data<br> | ||
+ | 3-------TxD-----Out-----Transmit Data<br> | ||
+ | 4-------DTR-----Out-----Data Terminal Ready<br> | ||
+ | 5-------GND-------------Ground<br> | ||
+ | 6-------DSR-----In------Data Set Ready<br> | ||
+ | 7-------RTS-----Out-----Request To Send<br> | ||
+ | 8-------CTS-----In------Clear To Send<br> | ||
+ | 9-------RI------In------Ring Indicator<br> | ||
+ | <br> | ||
+ | This is the male DB9 pin out. We probably need to add a jumper between pins 7 and 8 and get rid of the wires. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>November 29, 2011 (3.5 hours):</b> | ||
+ | <br> | ||
+ | Worked with Kin Chin to get the serial communication to work. After further research, we realized the male to male wiring of the store bought cable was not at all what we needed. Logically, the correct pinout was what we found being referenced on one site: | ||
+ | <br> | ||
+ | [[Image:Cable_connection.gif]] | ||
+ | <br> | ||
+ | I soldered a cable per that pinout and - it worked! Kin Chin and I worked on a simple protocol for the dual H-bridge setup and added that to the micro program. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>November 30, 2011 (8 hours):</b> | ||
+ | <br> | ||
+ | Got some cables from Dr. Swabey and crimped ends on for connecting the micro to the motor driver circuit. Bought the following for building an H-bridge:<br> | ||
+ | 4 x IRF9630<br> | ||
+ | 4 x IRF630<br> | ||
+ | 4 x 4N28<br><br> | ||
+ | Spent a while testing an H-bridge configuration. I kept having problems that didn't seem to make any sense - at one point forward would work and backward wouldn't when the port pins were definitely switching the opto-isolators. The reverse voltage was actually .1V. Kin Chin came and we probed more around the circuit and started switching components out. We narrowed the problem down to the 4N28 which, after further inspection of the data sheet, I realized that I was probably frying them with too much current from the battery. We switched the configuration to use TIP120's instead of the 4N28's and the circuit finally worked for forward and backward. We updated the code on the micro to reflect changes in the control.<br><br> | ||
+ | I added a startup script to the Pandaboard that runs 'sudo chmod 777 /dev/ttyO2' when the board boots. I will soon add the command 'sudo webcam /etc/webcam.conf &' so that the webcam is initialized on startup. If I have time and can figure it out, I will add commands so the board emails me its IP address when it boots - however I am unsure of how this would work. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>Dec 1, 2011 (5.5 hours):</b> | ||
+ | <br> | ||
+ | Attended video conference with Hong Kong. Most of the discussion revolved around how the system diagram has changed from the intial proposal and what we can do to allow for more integration between the teams. The goal by next thursday is to update the Rhea discussions page with our ideas for a system diagram including specifics and also continue developing the protocol.<br> | ||
+ | Went to lab after the video conference to continue working on the project. Since I had gotten the H bridge circuit working, I condensed the layout and put two on one breadboard to allow it to fit in the tank. We worked on fitting the pandaboard, micro, dual H-bridge setup, and all wiring into the tank. It took a while and most of the mounting is rigged up, but it is all fairly secure and no metal on metal contact can occur. For this semester, the tank will be plugged into the wall as we do not have time to worry about battery power for all components at this point. We tested it out and only one tread was moving. After further inspection, I found a wire in the wrong place on one of the H-bridge circuits. After moving it, both treads worked. The tank can move forward and backward as well as turn right and left.<br><br> | ||
+ | Here is a picture of the tank internals:<br> | ||
+ | [[Image:tank_internals.JPG|400px|thumb|left]] | ||
+ | <br> | ||
+ | On the left you can see the Pandaboard. Underneath that is the micro - both are mounted with cardboard and masking tape. The transformer is for the Pandaboard. The micro gets power from the Pandaboard through a USB port. On the breadboard you can see both H-bridge circuits which the micro port pins and motors are connected to. The battery for the motors is in its compartment underneath. The green wiring coming out of the Pandaboard comprises a custom wired serial cable that we made according to the previous serial cable diagram.<br><br> | ||
+ | Cannot seem to get the webcam working consistently. Added it to the startup script; however, when you unplug the monitor it stops working completely. I won't worry about the webcam right now. If need be (in the near future), a webcam can be attached to a computer near the tank. We need to acquire one like Dr. J's as it works much better than the ones we are working with. | ||
+ | <br><br> | ||
+ | Update: Figured out how to get the camera working at least for demo purposes: SSH into the server after figuring out the IP address and kill the camera process and restart it. Commands:<br> | ||
+ | >ps aux | less | grep webcam <br> | ||
+ | >kill "proc#"<br> | ||
+ | >sudo chmod 777 /dev/video0<br> | ||
+ | >sudo webcam /etc/webcam.conf & | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>Dec 2, 2011 (2 hours):</b> | ||
+ | <br> | ||
+ | Setup the tank in preparation for the demo. Demoed the tank for Dr. J, Dr. Swabey, and Dr. Krogmeier.<br><br> | ||
+ | Here is the tank in action:<br> | ||
+ | [https://www.projectrhea.org/rhea/images/b/b8/Demo_tank.avi Tank Demo] | ||
+ | <br><br> | ||
+ | |||
+ | Here are some obvious problems that will need to be addressed:<br> | ||
+ | 1. Gearbox is shot, or some other problem with tank drive.<br> | ||
+ | 2. Barrel connector on the Pandaboard is not the right size causing disconnection when bumped.<br> | ||
+ | 3. We need a more stable connection to the pandaboard wirelessly<br> | ||
+ | 4. Need to figure out power requirements for our hardware to find a battery. | ||
</td> | </td> | ||
Line 552: | Line 669: | ||
<tr> | <tr> | ||
<td width=800><b>WEEK SUMMARY:</b><br> | <td width=800><b>WEEK SUMMARY:</b><br> | ||
− | <u>Accomplishments</u>: | + | <u>Accomplishments</u>: Tank control successfully demonstrated! |
<br> | <br> | ||
− | <u>Weekly Work Total</u>: hours | + | <u>Weekly Work Total</u>: 29.5 hours |
<br> | <br> | ||
− | <u>Project Work Total</u>: hours | + | <u>Project Work Total</u>: 97.4 hours |
</td> | </td> | ||
</tr> | </tr> | ||
Line 562: | Line 679: | ||
<br> | <br> | ||
---- | ---- | ||
+ | |||
+ | <table border="0"> | ||
+ | <tr> | ||
+ | <td width=800><center><h2>Week of Dec. 5</h2></center></td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | <table border="1" bgcolor=#FFFFBB> | ||
+ | <tr> | ||
+ | <td width=800> | ||
+ | <b>December 6, 2011 (1.5 hours):</b> | ||
+ | <br> | ||
+ | Met with group to discuss protocol and system architecture as well as outline for the final report. We decided that there isn't much we can do to change the overall architecture without changing the current vehicle setup. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>December 7, 2011 (45 minutes):</b> | ||
+ | <br> | ||
+ | Met with Dr. J to discuss the final report - decided it needs to be a combination of VIP final report and 477 proposal in layout.<br><br> | ||
+ | 1. Title<br><br> | ||
+ | |||
+ | 2. Executive Summary<br><br> | ||
+ | |||
+ | 3. Outcomes<br> | ||
+ | *Prototyping (Scott, Kin Chin, Chris)<br> | ||
+ | **Proof of concept<br> | ||
+ | **Practice technologies<br> | ||
+ | **Demo ARM MCU control<br> | ||
+ | **Demo remote control of ARM<br> | ||
+ | *Proposal for ECE 477 (Jason, Matt)<br> | ||
+ | **Requirements<br> | ||
+ | **Components<br> | ||
+ | **Architecture<br> | ||
+ | **Protocol<br> | ||
+ | **Vehicle Platform<br> | ||
+ | *Collaboration with HKUST (Michael)<br><br> | ||
+ | |||
+ | 4. Research and prototyping (Scott, Kin Chin, Chris)<br> | ||
+ | *Requirements<br> | ||
+ | *Components<br> | ||
+ | *Architecture<br> | ||
+ | *Vehicle Platform<br> | ||
+ | *Prototyping Results<br><br> | ||
+ | |||
+ | 5. Proposed ECE 477 Project (Jason, Matt)<br> | ||
+ | *Requirements<br> | ||
+ | **Features<br> | ||
+ | ***Physical<br> | ||
+ | ***Environment<br> | ||
+ | **Expectations regarding integration<br> | ||
+ | *Components<br> | ||
+ | *Architecture<br> | ||
+ | *Protocol<br> | ||
+ | *Vehicle Platform<br><br> | ||
+ | |||
+ | 6. Conclusions (Michael)<br> | ||
+ | *Summary of accomplishments<br> | ||
+ | *Collaboration Summary<br> | ||
+ | **Communication methods<br> | ||
+ | **Joint decisions<br><br> | ||
+ | |||
+ | 7. Appendix<br> | ||
+ | *Code<br> | ||
+ | *Data<br> | ||
+ | *Pictures<br> | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>December 8, 2011 (1.5 hours):</b> | ||
+ | <br> | ||
+ | Attended video conference. However, no HKUST members showed up. Instead, we discussed the overall system architecture and came up with a new plan to allow for more integration. Also delegated parts of final report. | ||
+ | </td> | ||
+ | </tr> | ||
+ | <tr> | ||
+ | <td> | ||
+ | <b>December 9, 2011 (2 hours):</b> | ||
+ | <br> | ||
+ | Looked into H-brides. The L298 looks like a great chip and is widely used, but it is designed to work on the 5v logic level. We will either need to step up the voltage or figure out if the micro can work on the 5v level - currently at 3.3v. Stepping up the voltage would not be difficult.<br><br> | ||
+ | Attended weekly meeting where we went over Hong Kong's idea for a system architecture - similar to what I had proposed at a previous meeting with a central server that directs vehicle control to the appropriate vehicle. It will add some latency but will make the project make a lot more sense and easily extensible. | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | |||
+ | |||
+ | <table border="1" bgcolor=#D2B48C> | ||
+ | <tr> | ||
+ | <td width=800><b>WEEK SUMMARY:</b><br> | ||
+ | <u>Accomplishments</u>: Getting very close to an agreement on system architecture that is logical | ||
+ | <br> | ||
+ | <u>Weekly Work Total</u>: 5.7 hours | ||
+ | <br> | ||
+ | <u>Project Work Total</u>: 103.1 hours | ||
+ | </td> | ||
+ | </tr> | ||
+ | </table> | ||
+ | <br> | ||
+ | ---- | ||
+ | |||
[[ Design Notebooks|Back to Design Notebooks]] | [[ Design Notebooks|Back to Design Notebooks]] |
Latest revision as of 11:55, 10 December 2011
Contents
Jason Holmes - Design Notebook
Week of Sept. 19 |
September 21, 2011 (1.5 hours):
|
September 22, 2011 (20 minutes):
|
September 23, 2011 (1 hour):
|
WEEK SUMMARY: Accomplishments: Obtained usernames for HKUST members
|
Week of Sept. 26 |
September 27, 2011 (45 minutes):
|
September 27, 2011 (30 minutes):
|
September 28, 2011 (1 hour):
|
September 29, 2011 (45 minutes):
|
September 30, 2011 (1.5 hour):
|
WEEK SUMMARY: Accomplishments: Completed preliminary block diagram layout of system. Decided on potential processor family.
|
Week of Oct. 3 |
October 6, 2011 (2 hours):
|
October 7, 2011 (1 hour):
|
October 7, 2011 (1.5 hours):
|
WEEK SUMMARY: Accomplishments: Finished poster for VIP poster session
|
Week of Oct. 10 |
October 11, 2011 (30 minutes):
|
October 13, 2011 (1 hour):
|
October 14, 2011 (1.5 hours):
|
WEEK SUMMARY: Accomplishments: Decided on a development board to begin prototyping.
|
Week of Oct. 17 |
October 17, 2011 (30 minutes):
|
October 17, 2011 (1 hour):
|
October 18, 2011 (3 hours):
IP Camera:TRENDnet TV-IP110WN Wireless N Internet Camera
|
October 19, 2011 (2 hours):
|
October 20, 2011 (1 hour):
|
WEEK SUMMARY: Accomplishments:
|
Week of Oct. 24 |
October 25, 2011 (3.2 hours):
(640 x 480 pixels) X (2 bytes per pixel) = 614,400 bytes per frame All of the CMOS cameras output in a RGB format or similar - raw image data. For most cameras, this is 16 bits per pixel. Without doing our own compression, this image data would be impossible to send wirelessly. There is a library for C to convert RGB data to JPEG format, which then possibly be converted to MJPEG on the controller side. This could possibly be used on-board, but the speed would have to be tested.
|
October 28, 2011 (1.5 hours):
|
WEEK SUMMARY: Accomplishments:
|
Week of Oct. 31 |
November 1, 2011 (4.5 hours):
|
November 3, 2011 (7 hours):
|
November 3, 2011 (1.5 hours):
|
WEEK SUMMARY: Accomplishments: Received tanks
|
Week of Nov. 7 |
November 8, 2011 (3 hours):
|
November 9, 2011 (3 hours):
|
November 10, 2011 (2 hours):
|
November 11, 2011 (2 hours):
|
WEEK SUMMARY: Accomplishments: Completed design review
|
Week of Nov. 14 |
WEEK SUMMARY: Accomplishments: Got a webcam feed - though not a great feed
|
Week of Nov. 21 |
November 23, 2011 (3 hours):
|
November 24, 2011 (6 hours):
|
November 25, 2011 (1.5 hours):
$serial = new phpSerial; $serial->deviceSet("/dev/tty0"); $serial->confBaudRate(2400); $serial->deviceOpen(); switch ($_POST['D']) { case "Forward": echo "Forward Pressed"; $serial->sendMessage("F"); break; case "Left": echo "Left Pressed"; $serial->sendMessage("L"); break; case "Right": echo "Right Pressed"; $serial->sendMessage("R"); break; case "Backward": echo "Backward Pressed"; $serial->sendMessage("B"); break; case "Stop": echo "Stop Pressed"; $serial->sendMessage("S"); break; default: echo "Initial page load"; } ?> |
November 25, 2011 (30 minutes):
|
WEEK SUMMARY: Accomplishments: Web server successfully setup with a functioning index
|
Week of Nov. 28 |
November 28, 2011 (8 hours):
|
November 29, 2011 (30 minutes):
|
November 29, 2011 (3.5 hours):
|
November 30, 2011 (8 hours):
|
Dec 1, 2011 (5.5 hours):
|
Dec 2, 2011 (2 hours):
Here are some obvious problems that will need to be addressed: |
WEEK SUMMARY: Accomplishments: Tank control successfully demonstrated!
|
Week of Dec. 5 |
December 6, 2011 (1.5 hours):
|
December 7, 2011 (45 minutes):
2. Executive Summary 3. Outcomes
4. Research and prototyping (Scott, Kin Chin, Chris)
5. Proposed ECE 477 Project (Jason, Matt)
6. Conclusions (Michael)
7. Appendix
|
December 8, 2011 (1.5 hours):
|
December 9, 2011 (2 hours):
|
WEEK SUMMARY: Accomplishments: Getting very close to an agreement on system architecture that is logical
|