Sign in

username:

password:



Not a member?

Search basicx



Search tips

Subscribe to basicx



basicx by Keywords

Accelerometer | ADC | ADXL | Adxl20 | AVR | BasicStamp | BX-35 | BX28 | BX35 | COM3 | Compiler | Downloader | EEPROM | Electromagnet | GetADC | GP2D1 | GPS | I2C | IDE | Keypad | LCD | LCD+ | MIDI | Motors | Multitasking | Netmedia | Networking | PCB | PID | PlaySound | PWM | Relays | RTC | Servo | ShiftOut | SitePlayer | SPI | Stack | Timer | USB

Ads

Discussion Groups

See Also

DSPFPGAElectronics

Discussion Groups | BasicX | problem with ADXL202


Advertise Here

Discussion forum for the BasicX family of microcontroller chips.

problem with ADXL202 - Jeff Daniels - Jun 8 2:05:00 2000

I'm having trouble getting DisplayAcceleration from the BasicX web
site to work. I connected ground to pin 4, +5v to 13 and 14, and pins
8 and 9 of the ADXL to pins 16 and 17 of the BasicX. The only change
I
made to the program is that it now says:

' BX-24 pins.
Private Const PinX As Byte = 17
Private Const PinY As Byte = 16

But when I run it, it continuously displays
X: -3779, Y: -4241
no matter what accelerations I put on the chip.

I've tried 2 different BasicX's and 2 different ADXL202's, with
identical results. Can someone please help? Thanks.





(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )


Re: problem with ADXL202 - Jon Hylands - Jun 8 7:49:00 2000

On Thu, 08 Jun 2000 07:05:35 -0000, "Jeff Daniels" <>
wrote:

> But when I run it, it continuously displays
> X: -3779, Y: -4241
> no matter what accelerations I put on the chip.

You need a resistor, and a couple capacitors. Do yourself a favor and buy
the evaluation board, its only $30, and get a 220 K resistor and a couple
of 0.1 uf capacitors. The eval board gives you a 5-pin header with 0.1
spacing, and its small enough to use in a real project. It also gives you
spots to solder the resistor and caps in the correct place. Or you can read
the data sheet, and figure out where they go, and put them on your circuit.

Later,
Jon

--------------------------------------------------------------
Jon Hylands http://www.huv.com/jon

Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com






(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: problem with ADXL202 - Jon Hylands - Jun 8 10:08:00 2000

On Thu, 08 Jun 2000 07:49:48 -0500, Jon Hylands <> wrote:

> and get a 220 K resistor...

Actually, I made a mistake here... You want a 120 K resistor, which
will give you an (approximately) 1 ms period. My ADXL202 ended up with
a measured period of 972 us, which is close enough. Whatever you end
up with, you need to measure it at the beginning (calibration) and use
that period when calculating acceleration.

Note that a 220 K resistor will still work, but the period would be
increased to something like 1.9 ms or so.

According to the doc, here are some sample resistor values you can
use, and the corresponding periods for each:

1 mS 124 k
2 mS 248 k
5 mS 620 k
10 mS 1.24 M

Note that if you change the period from the value I am using, you may
need to use different capacitors, but I'm not really sure. See the
data sheet for details. I do know that 0.1 uf caps with the 120 K
resistor work well together...

Later,
Jon

--------------------------------------------------------------
Jon Hylands http://www.huv.com/jon

Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com






(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: problem with ADXL202 - Jeff Daniels - Jun 8 22:32:00 2000

Well, I didn't have a resistor, which is a mistake (now that I read
the data sheet more carefully). So I added a 120K between pin 5 and
ground.

But I'm using DisplayAcceleration.bxp from the BasicX web site's App
Notes page. This program is an example of using the Xout and Yout
lines (pins 10 and 9) to get at the duty cycle. The data sheet
doesn't show any capacitors on those lines; do they need capacitors?
(Without caps, I'm still getting unchanging negative values from both
pins.)

And if I use the XFilt and YFilt lines, I'm getting voltages, right?
Which is not what I want, since that makes the BasicX code more
complex than I want it to be.

--- In , Jon Hylands <jon@h...> wrote:
> On Thu, 08 Jun 2000 07:49:48 -0500, Jon Hylands <jon@h...> wrote:
>
> > and get a 220 K resistor...
>
> Actually, I made a mistake here... You want a 120 K resistor, which
> will give you an (approximately) 1 ms period. My ADXL202 ended up
with
> a measured period of 972 us, which is close enough. Whatever you end
> up with, you need to measure it at the beginning (calibration) and
use
> that period when calculating acceleration.
>
> Note that a 220 K resistor will still work, but the period would be
> increased to something like 1.9 ms or so.
>
> According to the doc, here are some sample resistor values you can
> use, and the corresponding periods for each:
>
> 1 mS 124 k
> 2 mS 248 k
> 5 mS 620 k
> 10 mS 1.24 M
>
> Note that if you change the period from the value I am using, you
may
> need to use different capacitors, but I'm not really sure. See the
> data sheet for details. I do know that 0.1 uf caps with the 120 K
> resistor work well together...
>
> Later,
> Jon
>
> --------------------------------------------------------------
> Jon Hylands Jon@h... http://www.huv.com/jon
>
> Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
> http://www.huv.com





(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Re: problem with ADXL202 - Jon Hylands - Jun 8 22:38:00 2000

On Fri, 09 Jun 2000 03:32:31 -0000, "Jeff Daniels" <>
wrote:

> But I'm using DisplayAcceleration.bxp from the BasicX web site's App
> Notes page. This program is an example of using the Xout and Yout
> lines (pins 10 and 9) to get at the duty cycle. The data sheet
> doesn't show any capacitors on those lines; do they need capacitors?
> (Without caps, I'm still getting unchanging negative values from both
> pins.)

According to the data sheet, you need the two capacitors, one between the
XFilt pin and ground, and one between the YFilt pin and ground.

I wouldn't bother trying to connect to it using the analog outputs. But you
definitely need the caps, because otherwise you get too much noise in the
signal.

The other thing to do is strip down the DisplayAcceleration routine, so
you're getting fairly raw numbers (like pulse lengths in u-secs) displayed.
That way you can see exactly what is happening.

Later,
Jon

--------------------------------------------------------------
Jon Hylands http://www.huv.com/jon

Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com




______________________________
Stellaris® MCU Family: New Parts, New Package, New Price.


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: problem with ADXL202 - Jeff Daniels - Jun 8 23:01:00 2000

OK, I'll try that. I would have already, except I'm having trouble
figuring out how to add even more wires to the tiny leads on this
chip. Is there a socket of some sort that a "cerpak" can be plugged
in
to, to allow easier access to the leads?

Thanks for all your help!

--- In , Jon Hylands <jon@h...> wrote:
> On Fri, 09 Jun 2000 03:32:31 -0000, "Jeff Daniels"
<jeffdaniels@e...>
> wrote:
>
> > But I'm using DisplayAcceleration.bxp from the BasicX web site's
App
> > Notes page. This program is an example of using the Xout and Yout
> > lines (pins 10 and 9) to get at the duty cycle. The data sheet
> > doesn't show any capacitors on those lines; do they need
capacitors?
> > (Without caps, I'm still getting unchanging negative values from
both
> > pins.)
>
> According to the data sheet, you need the two capacitors, one
between the
> XFilt pin and ground, and one between the YFilt pin and ground.
>
> I wouldn't bother trying to connect to it using the analog outputs.
But you
> definitely need the caps, because otherwise you get too much noise
in the
> signal.
>
> The other thing to do is strip down the DisplayAcceleration
routine,
so
> you're getting fairly raw numbers (like pulse lengths in u-secs)
displayed.
> That way you can see exactly what is happening.
>
> Later,
> Jon
>
> --------------------------------------------------------------
> Jon Hylands Jon@h... http://www.huv.com/jon
>
> Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
> http://www.huv.com





(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

NO problem with ADXL202! - Jeff Daniels - Jun 9 2:25:00 2000

It works! After two hours of going blind soldering, the X-axis works.
The Y is still flaky, probably because of a microscopic solder
bridge, but I only need one for my application (rocket liftoff
sensing).

Thank you very much, Jon!

--- In , "Jeff Daniels" <jeffdaniels@e...> wrote:
> OK, I'll try that. I would have already, except I'm having trouble
> figuring out how to add even more wires to the tiny leads on this
> chip. Is there a socket of some sort that a "cerpak" can be plugged
> in
> to, to allow easier access to the leads?
>
> Thanks for all your help!
>
> --- In , Jon Hylands <jon@h...> wrote:
> > On Fri, 09 Jun 2000 03:32:31 -0000, "Jeff Daniels"
> <jeffdaniels@e...>
> > wrote:
> >
> > > But I'm using DisplayAcceleration.bxp from the BasicX web
site's
> App
> > > Notes page. This program is an example of using the Xout and
Yout
> > > lines (pins 10 and 9) to get at the duty cycle. The data sheet
> > > doesn't show any capacitors on those lines; do they need
> capacitors?
> > > (Without caps, I'm still getting unchanging negative values
from
> both
> > > pins.)
> >
> > According to the data sheet, you need the two capacitors, one
> between the
> > XFilt pin and ground, and one between the YFilt pin and ground.
> >
> > I wouldn't bother trying to connect to it using the analog
outputs.
> But you
> > definitely need the caps, because otherwise you get too much
noise
> in the
> > signal.
> >
> > The other thing to do is strip down the DisplayAcceleration
> routine,
> so
> > you're getting fairly raw numbers (like pulse lengths in u-secs)
> displayed.
> > That way you can see exactly what is happening.
> >
> > Later,
> > Jon
> >
> > --------------------------------------------------------------
> > Jon Hylands Jon@h... http://www.huv.com/jon
> >
> > Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
> > http://www.huv.com



______________________________
Stellaris® MCU Family: New Parts, New Package, New Price.


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Re: problem with ADXL202 - Jon Hylands - Jun 9 8:52:00 2000

On Fri, 09 Jun 2000 04:01:29 -0000, "Jeff Daniels" <>
wrote:

> OK, I'll try that. I would have already, except I'm having trouble
> figuring out how to add even more wires to the tiny leads on this
> chip. Is there a socket of some sort that a "cerpak" can be plugged
> in
> to, to allow easier access to the leads?

For $30, you can get the eval board, which is 7/8" x 3/4", with a standard
5-pin header spaced 0.1" apart. The 5-pin header has X, Y, ground, and +5,
as well as self-test. The ADXL202 is already soldered on the board.

It also has space (through-holes) for the resistor and the two capacitors
to be soldered in.

You can order it directly from Analog Devices on their web site.

Later,
Jon

--------------------------------------------------------------
Jon Hylands http://www.huv.com/jon

Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com




______________________________
Stellaris® MCU Family: New Parts, New Package, New Price.


(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: NO problem with ADXL202! - Jon Hylands - Jun 9 8:55:00 2000

On Fri, 09 Jun 2000 07:25:21 -0000, "Jeff Daniels" <>
wrote:

> It works! After two hours of going blind soldering, the X-axis works.
> The Y is still flaky, probably because of a microscopic solder
> bridge, but I only need one for my application (rocket liftoff
> sensing).

Cool :-)

> Thank you very much, Jon!

Glad to be of service.

Later,
Jon

--------------------------------------------------------------
Jon Hylands http://www.huv.com/jon

Project: Micro Seeker (Micro Autonomous Underwater Vehicle)
http://www.huv.com





(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )

Re: Re: problem with ADXL202 - Author Unknown - Jun 9 10:08:00 2000

At 08:52 AM 6/9/00 -0500, Jon wrote:

>For $30, you can get the eval board, which is 7/8" x 3/4", with a standard
>5-pin header spaced 0.1" apart. The 5-pin header has X, Y, ground, and +5,
>as well as self-test. The ADXL202 is already soldered on the board.

Digikey has 'surfboards' by Capital that will allow you to plug these
cerpaks into a breadboard. Although the chip has 14 pins, the only one that
fits properly is the 20 pin - model 9210.

HTH, Duncan





(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )