Closed TCIII closed 2 years ago
@chrisl8,
Observations:
When I run "~/catkin_ws/src/ArloBot/scripts/PropellerSerialTest.sh" the amber LEDs on the DHB-10 never stop flashing which I believe means that the PAB is not communicating with the DHB-10. Though the Parallax SimpleIDE tests worked as described in the tutorial.
The blue LED on the PAV flashes in sync with the "Updating settings" window indicating that there is communication between the SBC and the PAB when running "~/catkin_ws/src/ArloBot/scripts/PropellerSerialTest.sh".
Regards, TCIII
@chrisl8,
I found out why I did not have a Telemetry/Hardware Status/Settings Header between the Main Menu and the "Updating settings" Window:
I missed that I needed to define the "FIRST_PING_SENSOR_PIN" as seen below where I changed the default pin number from "5" to "14" which allowed the Telemetry/Hardware Status/Settings Header to appear when I run "~/catkin_ws/src/ArloBot/scripts/PropellerSerialTest.sh"
// Settings for PING and IR (Infrared) sensors connected DIRECTLY to the // Activity Board: SETTING: Which pin on the Activity Board is the first PING // sensor connected to? Also used by the 2nd Quickstart board in my code.
However, this leads to a conundrum: Since I am using a PAB with four PING sensors attached and followed the Parallax tutorial for connecting the PING sensors to the PAB, the PING connections by location are: P14 to Front, P15 to back, P16 to left, and P17 to right. Since the Arlobot PING numbering/location goes from the left (0), to the front (1), then around to the right (2) and finally the back (3), should the left PING sensor be on P14 (the first connector), then the front PING sensor on P15, the right PING sensor on P16, and finally the back (3) PING sensor on P17?
Regards, TCIII
@chrisl8,
I rewired the PING sensor order as described above and I am getting good ranges from the PINGs when I run PropellerSerialTest.sh. Also, the motors respond to directional input with the keyboard and to maneuvering commands. The wheels turn just about the right distance with the one meter forward/backwards command.
Since I provided my own solution to my issue, I am closing out this issue. It has been a really learning experience.
Regards, TCIII
@chrisl8,
SBC: LattePanda 4GB/64GB OS: Ubuntu 20.04.3 ROS: Noetic Motor Controller: DHB-10 Sensors: 4 PING sensors (3 Front/1 Rear) Wheel encoders: Connected to DHB-10 Motor Controller
1) Prior to installing the Propeller code to the PAB I used my laptop and SimpleIDE to test the PING and DHB-10 Motor Controller per the Parallax "Arlo with an Activity Board Brain" tutorial. The PBA/DHB-10 configuration passed all of the tutorial tests so I am confident that there are no hardware issues.
2) I then configured both "per_robot_settings_for_propeller_c_code.h" and "personalDataForBehavior.json" to reflect my Arlobot configuration and successfully downloaded the hardware configuration to the PAB using "install_Propeller_code.sh".
Here is my Sensor Configuration in "per_robot_settings_for_propeller_c_code.h":
// PROXIMITY SENSORS: // IMPORTANT! This section is very important! // SETTINGS: Proximity (PING & IR) Sensor count and location:
define NUMBER_OF_PING_SENSORS 4
define NUMBER_OF_IR_SENSORS 0
// QUESTION: Do you have PING sensors on the front of your robot?
define hasFrontPingSensors
define FIRST_FRONT_PING_SENSOR_NUMBER 0 // Count from 0
// Your sensors need to poll consecutively for each section!
define HOW_MANY_FRONT_PING_SENSORS 3
// QUESTION: Do you have PING sensors on the back of your robot?
define hasRearPingSensors
define FIRST_REAR_PING_SENSOR_NUMBER 3 // Count from 0
define HOW_MANY_REAR_PING_SENSORS 1
// QUESTION: Sensor Identities: // Put the sensor number by each label // Comment out any sensor you do not have
define FRONT_CENTER_SENSOR 1
// NOTE: IF you comment out the FRONT_CENTER_SENSOR, then ALL Front sensors are // ignored for escaping! "Left" refers to the ROBOT's left, assuming he faces // the way he drives "forward" //#define FRONT_NEAR_LEFT_SENSOR 1
define FRONT_FAR_LEFT_SENSOR 0
//#define FRONT_NEAR_RIGHT_SENSOR 3
define FRONT_FAR_RIGHT_SENSOR 2
//#define REAR_FAR_RIGHT_SENSOR 5 //#define REAR_NEAR_RIGHT_SENSOR 6
define REAR_CENTER_SENSOR 3
Here is the output of "PropellerSerialTest.sh":
thomas@thomas-Default-string:~$ ~/catkin_ws/src/ArloBot/scripts/PropellerSerialTest.sh Checking all configured devices to make sure they are available, attempt 1 Checking Activity Board . . . Hardware Check SUCCESS! All devices found.
ArloBot Propeller Serial Interface Test Program Errors: 0 | Write Delay: ? | Update Delay: ? | Test Sent:?/Rcvd: ? Main Menu: t - send Test data | r - Run speed test | i - Interrupt speed test | m - send Move commands | s - Settings | a - mAneuvers | p - Position override | l - Led | q/Esc - Quit lqUp/Down PgUp/PgDn Home/End(follow)qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqk xo: (0.40299999713897705, 0.003379999892786145, 1.0, 0, 0, 0, 0, 1) x xUpdating settings. x xo: (0.40299999713897705, 0.003379999892786145, 1.0, 0, 0, 0, 0, 1) x xUpdating settings.
I receive the above display whether I use the CLI or run from the terminal in the Ubuntu Desktop Display. As can be seen there is no Telemetry/Hardware Status/Settings Header between the Main Menu and the "Updating settings" Window.
Any suggestions as to how to correct this issue will be greatly appreciated.
Regards, TCIII per_robot_settings_for_propeller_c_code_TC.zip personalDataForBehavior_TC.zip