Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: Adafruit-16-Ch-PWM-Servo-Driver HCSR04 PID PololuQik2 QEI Sharp mbed-rtos
Diff: ShapeDetect.cpp
- Revision:
- 11:8d2455e383ce
- Parent:
- 8:77a57909aa15
- Child:
- 12:284be46593ae
--- a/ShapeDetect.cpp Sat Mar 29 21:22:14 2014 +0000
+++ b/ShapeDetect.cpp Tue Apr 01 02:00:01 2014 +0000
@@ -208,8 +208,8 @@
void centerMass(int *xcoord, int *ycoord, int *s_area){
ImageToArray(BINARY);
- printImageToFile(BINARY);
- clearBounds();
+ //printImageToFile(BINARY);
+ //clearBounds();
int count = 0;
int sumi = 0;
int sumj = 0;
@@ -316,6 +316,20 @@
//CODE GOES HERE
- };
+ }
+int get_com_x(void)
+{
+ return xcoord_val;
+ }
+int get_com_y(void)
+{
+ return ycoord_val;
+ }
+
+int get_com_a(void)
+{
+ return s_area_val;
+}
+