User Tools

Site Tools


drc_hubo_creating_new_al_dw

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
drc_hubo_creating_new_al_dw [2016/11/19 14:27] dwallacedrc_hubo_creating_new_al_dw [2017/04/27 21:50] (current) dwallace
Line 22: Line 22:
 Once all of the projects are setup, right click the ALPrograms project, and select "New Subproject" Once all of the projects are setup, right click the ALPrograms project, and select "New Subproject"
  
-{{dylanw:huboal1.jpg}}\\ +{{dylanw:huboal1.jpg?800}}\\ 
  
 Now, for the template, select "Application" in the "Projects" area, and then "Qt Console Application" in the template area. Now, for the template, select "Application" in the "Projects" area, and then "Qt Console Application" in the template area.
  
-{{dylanw:huboal2.jpg}}\\ +{{dylanw:huboal2.jpg?600}}\\ 
  
 Finally, name your project. Finally, name your project.
Line 38: Line 38:
 First, copy the text from the ALTutorial.pro file to the .pro file for your new AL. First, copy the text from the ALTutorial.pro file to the .pro file for your new AL.
  
-{{dylanw:huboal3.jpg}}\\ +{{dylanw:huboal3.jpg?800}}\\ 
  
 Next, right-click the new AL project and select "Add Existing Files...". Next, right-click the new AL project and select "Add Existing Files...".
  
-{{dylanw:huboal4.jpg}}\\ +{{dylanw:huboal4.jpg?400}}\\ 
  
 Navigate to ~/Desktop/PODO_AL_CLASS/podo_nrl/src/ALPrograms/ALTutorial and select the folder "BasicFiles". Navigate to ~/Desktop/PODO_AL_CLASS/podo_nrl/src/ALPrograms/ALTutorial and select the folder "BasicFiles".
  
-{{dylanw:huboal5.jpg}}\\ +{{dylanw:huboal5.jpg?600}}\\ 
  
 Finally, copy from the ALTutorial main.cpp to your new AL's main.cpp Finally, copy from the ALTutorial main.cpp to your new AL's main.cpp
  
-{{dylanw:huboal6.jpg}}\\ +{{dylanw:huboal6.jpg?800}}\\ 
  
 ==== Changing Commands ==== ==== Changing Commands ====
Line 56: Line 56:
 Once you have correctly setup and added files to your AL, you will need to make modifications in the code to give your commands unique names. See the photos below as a guideline. Once you have correctly setup and added files to your AL, you will need to make modifications in the code to give your commands unique names. See the photos below as a guideline.
  
-{{dylanw:huboal7a.jpg}}{{dylanw:huboal7b.jpg}}\\ +{{dylanw:huboal7a.jpg?300}}{{dylanw:huboal7b.jpg?300}}\\ 
  
 Some guidelines that must be followed when naming and creating commands: Some guidelines that must be followed when naming and creating commands:
Line 70: Line 70:
 First, right-click the PODOGUI project and select "Add New...". In the pop-up, select Qt int the "Files and Classes" section, and then select "Qt Designer From Class" in the template section. Name the class as you choose, but use the word dialog in the name. First, right-click the PODOGUI project and select "Add New...". In the pop-up, select Qt int the "Files and Classes" section, and then select "Qt Designer From Class" in the template section. Name the class as you choose, but use the word dialog in the name.
  
-{{dylanw:huboal8.jpg}}\\ +{{dylanw:huboal8.jpg?600}}\\ 
  
 In the new .h file, include "CommonHeader.h", and in the private section declare a new integer value (name it ALNum_<your desired name>. In the new .h file, include "CommonHeader.h", and in the private section declare a new integer value (name it ALNum_<your desired name>.
  
-{{dylanw:huboal9.jpg}}\\ +{{dylanw:huboal9.jpg?600}}\\ 
  
 In the new .cpp file, include "BasicFiles/PODOALDialog.h". Next, add the enum from you AL command. Finally, initialize the ALNum integer as PODOALDialog::GetALNumFromFileName(“<your AL filename>”). In the new .cpp file, include "BasicFiles/PODOALDialog.h". Next, add the enum from you AL command. Finally, initialize the ALNum integer as PODOALDialog::GetALNumFromFileName(“<your AL filename>”).
  
-{{dylanw:huboal10.jpg}}\\ +{{dylanw:huboal10.jpg?600}}\\ 
  
 ==== Adding a GUI Button ==== ==== Adding a GUI Button ====
Line 86: Line 86:
 First, go to the Design tab and edit the .ul file for your new dialog. Drag out a button and rename it. Next, right-click the button and select "Go to slot...". First, go to the Design tab and edit the .ul file for your new dialog. Drag out a button and rename it. Next, right-click the button and select "Go to slot...".
  
-{{dylanw:huboal11.jpg}}\\ +{{dylanw:huboal11.jpg?400}}\\ 
  
 Now, add the following to the code, and save the file: Now, add the following to the code, and save the file:
Line 106: Line 106:
  
 Now you are ready to test your AL. Make sure that it does not break the other ALs that PODO uses. Also make sure that it performs as you have desired. Now you are ready to use you AL!  Now you are ready to test your AL. Make sure that it does not break the other ALs that PODO uses. Also make sure that it performs as you have desired. Now you are ready to use you AL! 
 +
 +==== Final Words ====
 +
 +This tutorial's objective was to teach the concepts behind creating a new AL for DRC-HUBO. Complete setup instructions for a base AL were provided. Once the concepts were conveyed the reader could successfully create and test their own AL for DRC-HUBO.
 +\\
 +\\
 +For questions, clarifications, etc, Email: <wallad3@unlv.nevada.edu>
  
drc_hubo_creating_new_al_dw.1479594460.txt.gz · Last modified: by dwallace