-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[miio] improve viewer with coordinates #8168
Conversation
Print coordinates to allow finding the room clean details Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Travis tests have failedHey @marcelrv, |
for (int i = 0; i < area.length; i++) { | ||
pw.printf("\t%.1f", area[i]); | ||
} | ||
pw.print("\r\n"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you should not directly write new lines, Just as done above use:
pw.print("\r\n"); | |
pw.println(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, agree. done
@@ -299,6 +300,16 @@ public String toString() { | |||
return sw.toString(); | |||
} | |||
|
|||
private void printAreaDetails(ArrayList<float[]> areas, PrintWriter pw) { | |||
areas.forEach(area -> { | |||
pw.printf("\tArea details:"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If there are more areas does it make sense to include some information about what area these details are about. With your change you would get several generic "Area details" printed next to each other.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Improved the text slightly to make it area coordinates to give hint on what the numbers are.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
btw, in each case, just before this is called, it prints out the area type.
No Go zones: 2
Area coordinates: 356.0 218.0 340.0 218.0 340.0 207.0 356.0 207.0
Area coordinates: 329.0 222.0 321.0 222.0 321.0 205.0 329.0 205.0
Walls: 1
Area coordinates: 274.0 363.0 273.0 291.0
Zones: 0
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Travis tests have failedHey @marcelrv, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@Hilbrand can this be merged? |
Further calculation of the goto coordinates to be used for zone cleaning Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Travis tests were successfulHey @marcelrv, |
* Parser prints real coordinates (robot,goto, zones etc) * Offline viewer provides zone clean command * Offline viewer provides goto command * Offline viewer provides coordinates on mouseover Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Travis tests were successfulHey @marcelrv, |
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Travis tests were successfulHey @marcelrv, |
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com> Signed-off-by: Clayton Tabone <taboneclayton@gmail.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com> Signed-off-by: Daan Meijer <daan@studioseptember.nl>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Signed-off-by: Marcel Verpaalen <marcel@verpaalen.com>
Print coordinates to allow finding the room clean details
Signed-off-by: Marcel Verpaalen marcel@verpaalen.com