DEBUG array? of some sort of multi if then statements?
AndrewParsons
Posts: 13
Hello Forum,
Okay so let me explain what I am trying to do. I need to display an * to show a visual from the data from an accelerometer (x and y).
So lets say I was dead center on both x and y i would like a debug like this.
500________________1000_______________2000
| |
| |
| |
| |
| |
| * |1000
| |
| |
| |
| |
| |500
=================================
using the same diagram this would represent full tilt front left.
500________________1000_______________2000
|* |
| |
| |
| |
| |
| |1000
| |
| |
| |
| |
| |500
=================================
To simulate the accelerometer output i will be using 2 10k pot sliders scaled to 500 to 2000. As i adjust the sliders it is my hope to move the * as if falls into the different if then statements.
Please see attached for they layout and a better understanding of what i am trying to do.
Any advice to simplify this would be much appreciated.
Thanks in advance
Andrew
Okay so let me explain what I am trying to do. I need to display an * to show a visual from the data from an accelerometer (x and y).
So lets say I was dead center on both x and y i would like a debug like this.
500________________1000_______________2000
| |
| |
| |
| |
| |
| * |1000
| |
| |
| |
| |
| |500
=================================
using the same diagram this would represent full tilt front left.
500________________1000_______________2000
|* |
| |
| |
| |
| |
| |1000
| |
| |
| |
| |
| |500
=================================
To simulate the accelerometer output i will be using 2 10k pot sliders scaled to 500 to 2000. As i adjust the sliders it is my hope to move the * as if falls into the different if then statements.
Please see attached for they layout and a better understanding of what i am trying to do.
Any advice to simplify this would be much appreciated.
Thanks in advance
Andrew
bsx
1K
Comments
http://www.youtube.com/watch?v=t2tzBEOAtjg&feature=player_detailpage#t=322s video
http://forums.parallax.com/showthread.php?86110-Ping)))Dar-a-Radar-Style-Display thread