NDSpiritLevel After seeing a spirit level application on the HTC Diamond phone I was very impressed.
Having had an NDS for a while and a DSMotion card, I thought, hmmm, maybe I could replicate
that on the NDS.........and here we are today with release one of my NDSpiritLevel.
I have tested this on the NDS with a DSMotion card and am happy with the results. I have also
added the code in for the DSerial card also, but I have not been able to test that card obviously
but with a friends help (thanx Bram) I believe that the DSerial card should also work.
Should you not own an DSMotion or DSerial card you will be able to move the bubbles with the DPAD.
Not a lot of use really but at least it will show you what you are potentially missing out on.
The limits of the DMotion and DSerial card is that the values returned are in a range of +/-128
depending on how far tilted in a relevant direction the card senses. The DSMotion zero level returns
a 0 with a range of -128 and +128. The DSerial card is different - the zero level is 128 and ranges
down to 0 or upto 255, but still the range for each direction is 128. To this end I have maxed the
Calibration limit of each axis to a difference of 64 so that you can not place the calibration range
to the fullest as that would mean there would be no available movement in a particular direction if
calibrated to the max.
This is my first NDS application so am still learning about what functions PALib provides. I am sure
there are better ways to do the sprite creation routines in my code, and maybe lots of other speed
improvements could be made in the code, but this isn't a particularly intensive app so I therfor I am
not concerned about that!
This is probably the final release unless somebody points out a big bug or advises that DSerial doesn't
Like it? Share with your friends!
If you got an error while installing Themes, Software or Games, please, read FAQ.