Discussion forum for the BasicX family of microcontroller chips.
receiver and a basicX on the same servo??? - naimead - Jun 2 18:51:00 2005
Hi guys,
What i am trying to do is to connect on the same servo a basicX and a
receiver.The main problem though is that when i have the ground of
the battery of the receiver connected to the ground of the basicX
then the basicX can control the servo but i can't use at all the
receiver.The opposite goes when i do not have the ground of the battery
connected to the basicX.Is there any way i can solve this?I can't even
use an interrupt!
thanks

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - Neil Jepsen - Jun 2 21:10:00 2005
You MUST have the grounds connected together at all times. Failure to do
this may damage the bx24.
naimead wrote:
> Hi guys,
>
> What i am trying to do is to connect on the same servo a basicX and a
> receiver.The main problem though is that when i have the ground of
> the battery of the receiver connected to the ground of the basicX
> then the basicX can control the servo but i can't use at all the
> receiver.The opposite goes when i do not have the ground of the battery
> connected to the basicX.Is there any way i can solve this?I can't even
> use an interrupt!
>
> thanks
>
>
> ------------------------------------------------------------------------
> *>.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 2 21:30:00 2005
Get it Neil!But how else should i make the receiver take control of the
servo?

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: Re: receiver and a basicX on the same servo??? - Neil Jepsen - Jun 3 1:36:00 2005
Without knowing what your setup is exactly Nainead, I can't comment.
All I can say is that if you have different power supplies on different
peices of equipment, driven by the bx24, (or any processor for that
matter), you must have the grounds connected together. The only time you
don't ned to follow this rule is if you have opto coupling.
neil
naimead wrote:
> Get it Neil!But how else should i make the receiver take control of the
> servo?
>
> ------------------------------------------------------------------------
> *>.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: Re: receiver and a basicX on the same servo??? - Neil Jepsen - Jun 3 1:36:00 2005
Describe to me exactly what you have connected to what.
naimead wrote:
> Get it Neil!But how else should i make the receiver take control of the
> servo?
>
> ------------------------------------------------------------------------
> *>.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 3 7:05:00 2005
The connection is fairly simple:
The servo connected to basicX on pin 6 and the servo connected to the
receiver on channel one from where it draws power(the battery of the
receiver moves the servo too).So i was expecting to be able to move the
servo both from the basicX and from the receiver too(or at least when
the program of the basicX is executed and finished to be able to take
over by the receiver). Neil it is the most important part of my project
so please if i don't explain it right
ask me again.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - Douglas R Franklin - Jun 3 9:46:00 2005
Naimead,
I did something like this for a project wherein my BX-24 "took control" of a
throttle servo on an electric-powered RC plane depending on certain inputs.
The simplest way (in terms of hardware) is to feed the RC receiver output to
an input pin of the BX, and then depending on the state of your software,
either pass it through to an output pin w/o changing the pulse width (the
receiver is "in control"), or output a different pulse width (the BX is
"in
control").
So the BX is always in the loop, but it either passes the signal through
untouched, or tweaks it as need be. It's plenty fast enough to do this.
You could also use external circuitry -- a gate or two -- to do the same
thing, with the BX asserting another line to force its signal to win. (Ie
one output carries the signal from the BX, and another output asserts a
"listen to me!" signal.) But I'd have to haul out a logic book and think
about that for a bit.
Doug Franklin

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - arhodes19044 - Jun 3 13:32:00 2005
Well, the most simplistic method uses one inverter and two AND gates.
One AND gate gets the "listen" signal plus the CPU's PWM signal.
The other AND gate gets the "not-listen" signal plus the raw PWM
signal.
This way one or the other gate will be talking to the servo, but not
both.
I am positive this can be solved in other more fancy ways, but
probably there is no way to use JUST ONE IC for the job. So,
probably you would need 2 IC's so this method might be the most
straightforward.
I like the alternative of having the BX-24 buffer the signal, and
either modify it or not as the needs dictate. No other IC's needed
at all.
-Tony
--- In basicx@basi..., Douglas R Franklin <DRFranklin@g...>
wrote:
> Naimead,
>
> I did something like this for a project wherein my BX-24 "took
control" of a
> throttle servo on an electric-powered RC plane depending on
certain inputs.
> The simplest way (in terms of hardware) is to feed the RC receiver
output to
> an input pin of the BX, and then depending on the state of your
software,
> either pass it through to an output pin w/o changing the pulse
width (the
> receiver is "in control"), or output a different pulse width (the
BX is "in
> control").
>
> So the BX is always in the loop, but it either passes the signal
through
> untouched, or tweaks it as need be. It's plenty fast enough to do
this.
>
> You could also use external circuitry -- a gate or two -- to do
the same
> thing, with the BX asserting another line to force its signal to
win. (Ie
> one output carries the signal from the BX, and another output
asserts a
> "listen to me!" signal.) But I'd have to haul out a logic book and
think
> about that for a bit.
>
> Doug Franklin

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - Thad Larson - Jun 3 14:06:00 2005
The 74HC244 might be a good canidate.
One BX pin on the output, the other for the enable.
Just have to make 100% sure that your BX pin is an input while the
servo is activated OR the servo is deactivated while the BX pin is
output. If a Schmitt trigger version is available, even better.
Thad
> You could also use external circuitry -- a gate or two -- to do the
same
> thing, with the BX asserting another line to force its signal to
win. (Ie
> one output carries the signal from the BX, and another output
asserts a
> "listen to me!" signal.) But I'd have to haul out a logic book and
think
> about that for a bit.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - Ingvar Esk - Jun 3 14:56:00 2005
--- In basicx@basi..., "arhodes19044" <spamiam@c...> wrote:
> Well, the most simplistic method uses one inverter and two AND
gates.
>
> One AND gate gets the "listen" signal plus the CPU's PWM signal.
>
> The other AND gate gets the "not-listen" signal plus the raw PWM
> signal.
>
> This way one or the other gate will be talking to the servo, but
not
> both.
>
> I am positive this can be solved in other more fancy ways, but
> probably there is no way to use JUST ONE IC for the job. So,
> probably you would need 2 IC's so this method might be the most
> straightforward.
One 74x00 will do:
A = Receiver
B = CPU PWM
C = Select
C' inverted C created by one gate
D=A*C (one gate)
E=B*C' (one gate)
Out=D*E (one gate)
By using the 74x00 the input signal gets inverted twice, i.e. not
changed.
> I like the alternative of having the BX-24 buffer the signal, and
> either modify it or not as the needs dictate. No other IC's
needed
> at all.
>
> -Tony
>
> --- In basicx@basi..., Douglas R Franklin
<DRFranklin@g...>
> wrote:
> > Naimead,
> >
> > I did something like this for a project wherein my BX-24 "took
> control" of a
> > throttle servo on an electric-powered RC plane depending on
> certain inputs.
> > The simplest way (in terms of hardware) is to feed the RC
receiver
> output to
> > an input pin of the BX, and then depending on the state of your
> software,
> > either pass it through to an output pin w/o changing the pulse
> width (the
> > receiver is "in control"), or output a different pulse width
(the
> BX is "in
> > control").
> >
> > So the BX is always in the loop, but it either passes the signal
> through
> > untouched, or tweaks it as need be. It's plenty fast enough to
do
> this.
> >
> > You could also use external circuitry -- a gate or two -- to do
> the same
> > thing, with the BX asserting another line to force its signal to
> win. (Ie
> > one output carries the signal from the BX, and another output
> asserts a
> > "listen to me!" signal.) But I'd have to haul out a logic book
and
> think
> > about that for a bit.
> >
> > Doug Franklin

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - arhodes19044 - Jun 3 15:33:00 2005
Perfect!!!! A very elegant solution. I love it.
-Tony
--- In basicx@basi..., "Ingvar Esk" <ingvar.esk@s...> wrote:
> --- In basicx@basi..., "arhodes19044" <spamiam@c...> wrote:
> > Well, the most simplistic method uses one inverter and two AND
> gates.
> >
> > One AND gate gets the "listen" signal plus the CPU's PWM signal.
> >
> > The other AND gate gets the "not-listen" signal plus the raw
PWM
> > signal.
> >
> > This way one or the other gate will be talking to the servo, but
> not
> > both.
> >
> > I am positive this can be solved in other more fancy ways, but
> > probably there is no way to use JUST ONE IC for the job. So,
> > probably you would need 2 IC's so this method might be the most
> > straightforward.
>
> One 74x00 will do:
>
> A = Receiver
> B = CPU PWM
> C = Select
>
> C' inverted C created by one gate
>
> D=A*C (one gate)
> E=B*C' (one gate)
> Out=D*E (one gate)
>
> By using the 74x00 the input signal gets inverted twice, i.e. not
> changed.
>
> >
> > I like the alternative of having the BX-24 buffer the signal,
and
> > either modify it or not as the needs dictate. No other IC's
> needed
> > at all.
> >
> > -Tony
> >
> > --- In basicx@basi..., Douglas R Franklin
> <DRFranklin@g...>
> > wrote:
> > > Naimead,
> > >
> > > I did something like this for a project wherein my BX-24 "took
> > control" of a
> > > throttle servo on an electric-powered RC plane depending on
> > certain inputs.
> > > The simplest way (in terms of hardware) is to feed the RC
> receiver
> > output to
> > > an input pin of the BX, and then depending on the state of
your
> > software,
> > > either pass it through to an output pin w/o changing the pulse
> > width (the
> > > receiver is "in control"), or output a different pulse width
> (the
> > BX is "in
> > > control").
> > >
> > > So the BX is always in the loop, but it either passes the
signal
> > through
> > > untouched, or tweaks it as need be. It's plenty fast enough
to
> do
> > this.
> > >
> > > You could also use external circuitry -- a gate or two -- to
do
> > the same
> > > thing, with the BX asserting another line to force its signal
to
> > win. (Ie
> > > one output carries the signal from the BX, and another output
> > asserts a
> > > "listen to me!" signal.) But I'd have to haul out a logic book
> and
> > think
> > > about that for a bit.
> > >
> > > Doug Franklin

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - Don Kinzer - Jun 3 15:52:00 2005
--- In basicx@basi..., "Ingvar Esk" <ingvar.esk@s...> wrote:
> --- In basicx@basi..., "arhodes19044" <spamiam@c...> wrote:
> One 74x00 will do
Or, for a simpler-to-connect 1-IC solution just use a 74x157. This is
a quad 2-1 multiplexor. With a single "select" signal you switch 4
different signals from two sources.
Don

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 3 19:52:00 2005
Somehow I have the feeling that you have then solution to my problem!
The main problem that comparing to you I am completely in early stages
in electronics!What connections should i make?how should i program this?
It is very important to understand this and my two years old project is
coming to an end!

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - tombhandley - Jun 4 2:26:00 2005
naimead, I like Ingvar Esk's 74x00 approach assuming you don't want
to use the BX-24 for this. On one side, you have to add an external
chip, on the other, you have to add more software. That's your call.
If you go with an external chip, I would recommend the 74HC00 since
it has a wider supply voltage and a threshold of 1/2 VCC which
provides better noise immunity in this case. Also it comes in a 14-
pin package. You can find a data sheet here:
http://www.datasheetcatalog.com/datasheets_pdf/7/4/H/C/74HC00.shtml
- Tom
--- In basicx@basi..., "naimead" <naimead@y...> wrote:
> The connection is fairly simple:
> The servo connected to basicX on pin 6 and the servo connected to
the
> receiver on channel one from where it draws power(the battery of
the
> receiver moves the servo too).So i was expecting to be able to move
the
> servo both from the basicX and from the receiver too(or at least
when
> the program of the basicX is executed and finished to be able to
take
> over by the receiver). Neil it is the most important part of my
project
> so please if i don't explain it right
> ask me again.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 4 7:06:00 2005
How about if we assume that i have to use basicX for it?
What code should i add?Is there any similar project?

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - tombhandley - Jun 4 11:28:00 2005
naimead, I hope this does not offend you as this is not my intent...
Is this for a school project? You are asking us to write code for you
and many of us, though glad to share ideas, have a 'full plate'. You
really have to read the documentation, do web searches, and study
basic electronics as well as the BasicX programming language. While
Parallax's Basic Stamp has a wealth of support for classrooms and
novices, NetMedia's BX-24 does not. It's much more advanced than the
Stamp family and they assume that folks that use it have a lot more
experience...
- Tom
--- In basicx@basi..., "naimead" <naimead@y...> wrote:
> How about if we assume that i have to use basicX for it?
> What code should i add?Is there any similar project?

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 4 12:01:00 2005
No offence taken Tom.I am a mechanical engineer so i don't have to know
electronics as a electrical and electronic one.And of course i am not
asking you to write code for me but tell me what to look for and how to
implement it(It is of course obvious for example that i can not use
interrupts).

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - tombhandley - Jun 5 1:48:00 2005
naimead, you are a mechanical engineer? I thought you were a student.
My mistake ;-) Heck, it's you that can teach me many things in
that 'world'. I will try to provide help in your efforts.
- Tom
--- In basicx@basi..., "naimead" <naimead@y...> wrote:
> No offence taken Tom.I am a mechanical engineer so i don't have to
know
> electronics as a electrical and electronic one.And of course i am
not
> asking you to write code for me but tell me what to look for and
how
to
> implement it(It is of course obvious for example that i can not use
> interrupts).

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - William Hubbard - Jun 5 16:06:00 2005
naimead,
I will attempt to at least steer you on the right track. I have not
seen a reply to your problem that explains why your configuration
won't work - this may help you to understand what you need to do.
By connecting the servo to both the BX-24 and to the receiver, you
have created a situation where two outputs are competing to drive the
servo. If the receiver is a straight FM receiver, it will send pulses
to the servo that it receives from the transmitter while the
transmitter is operating. If you are using a PCM radio, the receiver
will continue to send pulses to the servo even after the transmitter
stops transmitting.
If you then wanted to start sending pulses from the BX-24, the pulses
would not be in sync with the receiver, and would fight with the
receiver as to what voltage level to drive the signal line to. The
servo, therefore, would receive a garbage signal and would not behave
as desired.
The two signals need to be separated - the output from the receiver
and the output from the BX-24. That is what the other hardware
solutions (provided by other members) served to do, using logic gates
to select which output gets connected to the servo input.
The alternative is a software solution, which would involve simply
connecting the receiver output to an input pin on the BX-24. You
would use software to sample the pulse width of the signal from the
receiver (which sends pulses approx. once every 20ms - pulses that are
1ms to 2ms wide). Look up the PulseIn command. You would then write
your code (which is what you'll need to determine and research) to
either send that pulse (via PulseOut) to the servo, or to send a
computed pulse to the servo. Essentially, you are implementing the
logic in software rather than in hardware.
The hardware solution may be simpler, but requires an additional chip
in your circuit. The software solution may be more economical, but
brings with it other issues that may affect your BX-24 operation,
since I *believe* the PulseIn function waits for a signal before it
returns (I haven't used it in a while).
I hope this info is useful.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: Re: receiver and a basicX on the same servo??? - Mike Perks - Jun 5 17:18:00 2005
William Hubbard wrote:
> naimead,
>
> I will attempt to at least steer you on the right track.
I think you have provided a good summary of both the problem and the 2
possible approaches, both of which have been discussed in this group.
> By connecting the servo to both the BX-24 and to the receiver, you
> have created a situation where two outputs are competing to drive the
> servo....<snip>
> .....The two signals need to be separated - the output from the receiver
> and the output from the BX-24. That is what the other hardware
> solutions (provided by other members) served to do, using logic gates
> to select which output gets connected to the servo input.
>
> The alternative is a software solution, which would involve simply
Tom, myself and others have already discussed before this control
problem. The BX-24 has to be the master and should be the ultimate
decision maker on what to do.
> connecting the receiver output to an input pin on the BX-24. You
> would use software to sample the pulse width of the signal from the
> receiver (which sends pulses approx. once every 20ms - pulses that are
> 1ms to 2ms wide). Look up the PulseIn command. You would then write
> your code (which is what you'll need to determine and research) to
> either send that pulse (via PulseOut) to the servo, or to send a
> computed pulse to the servo. Essentially, you are implementing the
> logic in software rather than in hardware.
>
> The hardware solution may be simpler, but requires an additional chip
> in your circuit. The software solution may be more economical, but
> brings with it other issues that may affect your BX-24 operation,
> since I *believe* the PulseIn function waits for a signal before it
> returns (I haven't used it in a while).
InputCapture can be forced to timeout and return by turning off all
Timer1 interrupts - see the application note for how to do this. I
haven't tried this but I'm sure that PulseIn can be forced to behave in
the same way. If not then InputCapture with a pulse width array of size
1 can be used to simulate Pulse In at a good enough resolution for RC
pulses.
Mike

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 6 4:53:00 2005
How about if we didn't use basicX at the same time with the
receiver?I mean basicX will execute the code that was programmed
to and then the whole motion of the servo will be given to the
receiver.So no conflict between these two.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
recommend a piezo speaker to use? - Carol - Jun 6 23:29:00 2005
hello,
i am wishing to hook a piezo speaker to a basicx pin and get a beep out
of the thing with an instruction from the program to activate an I/O
pin..... something like
call PutPin(, bxOutputHigh)
delay (0.5)
call PutPin(16, bxOutputLow)
to get a half second beep.....
could someone recommend a part to use in such a manner? can you get
enough current out of a single pin to do such a thing?
thanks...

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - Neil Jepsen - Jun 6 23:46:00 2005
You'd be well advised to use an interposing transistor such as a BC547,
2n2222 etc. Nothing special. You can buy piezos with an internal
oscillator that only require switching to +5 or +12
neil
Carol wrote:
> hello,
>
> i am wishing to hook a piezo speaker to a basicx pin and get a beep out
> of the thing with an instruction from the program to activate an I/O
> pin..... something like
>
> call PutPin(, bxOutputHigh)
> delay (0.5)
> call PutPin(16, bxOutputLow)
>
> to get a half second beep.....
>
> could someone recommend a part to use in such a manner? can you get
> enough current out of a single pin to do such a thing?
>
> thanks...
>
> ------------------------------------------------------------------------
> *>.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - Carol - Jun 7 0:35:00 2005
can't i hook a ttl capable piezo buzzer (5ma) directly to a pin of the
bx24? am i risking some sort of damage by doing so?
Neil Jepsen wrote:
> You'd be well advised to use an interposing transistor such as a BC547,
> 2n2222 etc. Nothing special. You can buy piezos with an internal
> oscillator that only require switching to +5 or +12
> neil
>
> Carol wrote:
>
> > hello,
> >
> > i am wishing to hook a piezo speaker to a basicx pin and get a beep out
> > of the thing with an instruction from the program to activate an I/O
> > pin..... something like
> >
> > call PutPin(, bxOutputHigh)
> > delay (0.5)
> > call PutPin(16, bxOutputLow)
> >
> > to get a half second beep.....
> >
> > could someone recommend a part to use in such a manner? can you get
> > enough current out of a single pin to do such a thing?
> >
> > thanks...
> >
> > ------------------------------------------------------------------------
> > *>.
> >
>
> *>.
>------------------------------------------------------------------------
>
>No virus found in this incoming message.
>Checked by AVG Anti-Virus.
>Version: 7.0.323 / Virus Database: 267.6.4 - Release Date: 6/6/2005

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - Don Kinzer - Jun 7 1:14:00 2005
--- In basicx@basi..., Carol <carolkysela@y...> wrote:
> hello,
>
> i am wishing to hook a piezo speaker to a basicx pin and get a beep
out
> of the thing with an instruction from the program to activate an I/O
> pin..... something like
>
> call PutPin(, bxOutputHigh)
> delay (0.5)
> call PutPin(16, bxOutputLow)
>
> to get a half second beep.....
>
> could someone recommend a part to use in such a manner?
In my application I ended up using a 555 timer to generate the pulse
to enable the piezo buzzer rather than doing the timing in software.
In my particular case I couldn't spare the RAM to setup a separate
task to do the timing and didn't want have the main application tied
up for the duration either. If you use an external timer you may
still need a transistor too depending on the current requirements of
the piezo buzzer.
I actually used a 556 dual timer. The other half was wired in astable
mode and was used to drive a flashing LED. The timer was gated by a
signal from the BX-24 so that the LED could be held off or allowed to
flash.
Don

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: Re: recommend a piezo speaker to use? - Carol - Jun 7 6:05:00 2005
Don Kinzer wrote:
> --- In basicx@basi..., Carol <carolkysela@y...> wrote:
> > hello,
> >
> > i am wishing to hook a piezo speaker to a basicx pin and get a beep
> out
> > of the thing with an instruction from the program to activate an I/O
> > pin..... something like
> >
> > call PutPin(, bxOutputHigh)
> > delay (0.5)
> > call PutPin(16, bxOutputLow)
> >
> > to get a half second beep.....
> >
> > could someone recommend a part to use in such a manner?
>
> In my application I ended up using a 555 timer to generate the pulse
> to enable the piezo buzzer rather than doing the timing in software.
> In my particular case I couldn't spare the RAM to setup a separate
> task to do the timing and didn't want have the main application tied
> up for the duration either. If you use an external timer you may
> still need a transistor too depending on the current requirements of
> the piezo buzzer.
>
> I actually used a 556 dual timer. The other half was wired in astable
> mode and was used to drive a flashing LED. The timer was gated by a
> signal from the BX-24 so that the LED could be held off or allowed to
> flash.
>
> Don
> *>.
>------------------------------------------------------------------------
>
>No virus found in this incoming message.
>Checked by AVG Anti-Virus.
>Version: 7.0.323 / Virus Database: 267.6.4 - Release Date: 6/6/2005
some piezo buzzers are stated to be TTL capable with current draws of
5ma, would one of these connected to a pin simply buzz when the pin was
activated?

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - naimead - Jun 7 7:57:00 2005
Guys i managed to obtain the hardware:a 74HC00 and a 74x00.
Now what should i do?I have never created a circuit with AND gates
again!

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - arhodes19044 - Jun 7 8:23:00 2005
I bought a piezo buzzer at radioshack. It claims a few mA draw and
uses a wide range of voltage. I tested the draw and it seemed ok on
my dmm. But weird averaging may have occurred. (I really need to
get an oscilloscope!)
I hooked it up and it buzzes fine. I even tested it on the freqout,
which I did NOT expect to work at all, but it sort of had a
different tone. Now I just use it as a simple buzzer. NO
transistors or anythng. A transistor probably would not hurt,
though.
-Tony
--- In basicx@basi..., Carol <carolkysela@y...> wrote:
> Don Kinzer wrote:
> some piezo buzzers are stated to be TTL capable with current draws
of
> 5ma, would one of these connected to a pin simply buzz when the
pin was
> activated?

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: receiver and a basicX on the same servo??? - tombhandley - Jun 7 8:45:00 2005
naimead, assuming you are giving priority to the pre-programmed
control, that sounds good. How you monitor receiver input is another
story. There are several ways to do that.
- Tom
--- In basicx@basi..., "naimead" <naimead@y...> wrote:
> How about if we didn't use basicX at the same time with the
> receiver?I mean basicX will execute the code that was programmed
> to and then the whole motion of the servo will be given to the
> receiver.So no conflict between these two.

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - tombhandley - Jun 7 9:04:00 2005
Carol, I've used the basic Radio Shack transducer for years with
mainly PICs and driving them with a simple MOSFET like the 2N7000.
All you have to do in software is turn it on or off. Note, if you
want different frequencies you have to resort to other transducers
and implement it in software. I you just want a 'beep' the Radio
Shack or similar transducers are the easiest to deal with.
- Tom
--- In basicx@basi..., Carol <carolkysela@y...> wrote:
> hello,
>
> i am wishing to hook a piezo speaker to a basicx pin and get a beep
out
> of the thing with an instruction from the program to activate an
I/O
> pin..... something like
>
> call PutPin(, bxOutputHigh)
> delay (0.5)
> call PutPin(16, bxOutputLow)
>
> to get a half second beep.....
>
> could someone recommend a part to use in such a manner? can you
get
> enough current out of a single pin to do such a thing?
>
> thanks...

(You need to be a member of basicx -- send a blank email to basicx-subscribe@yahoogroups.com )
Re: recommend a piezo speaker to use? - Chris - Jun 8 2:42:00 2005
--- In basicx@basi..., Carol <carolkysela@y...> wrote:
> i am wishing to hook a piezo speaker to a basicx pin and get a beep
out
> of the thing with an instruction from the program to activate an
I/O
> pin.....
Carol,
I have found two excellent off-the shelf audio devides for use with
the BX-24. The easiest to use is a PIEZO BUZZER (for example, model
number CEP-2242, about $2.64) Radio Shack sells the same thing for
$1 more. This has its own driving circuitry, so all you need to do
is drive it with a DC voltage between 3 and 16V to get a continuous
ear-piercing sound at 4.1kHz (or the musical note C8). This is
easily done with code like this: Call PutPin(16, 1). This piezo
draws 7mA at 12VDC.
The other method is to use an AUDIO TRANSDUCER (for example, model
number CEM-1606, about $1.29). This does not have its own driving
circuitry, so you must do so with code. This element requires a
current of 50mA at half-duty, and is not as loud as the buzzer unless
you operate it at the resonance frequency of 2048Hz (a musical note
between B7 and C6). However, it does allow you to alter the pitch in
interesting ways. For example,
Dim i as Integer
' Buzz
For i = 1 to 20
Call PutPin(16,1)
Call Delay(0.01)
Call PutPin(16,0)
Call Delay(0.01)
Next
Call Delay(1.0)
' Buzz
For i = 1 to 20
Call PulseOut(16, 0.01, 1)
Call PulseOut(16, 0.01, 0)
Next
Call Delay(1.0)
' Resonance
Call FreqOut(16, 2048, 0, 2.0)
Call Delay(1.0)
' Frequency Sweep
For i = 100 to 300
Call FreqOut(16, i*10, 0, 0.1)
Next
Call Delay(1.0)
' Beat Frequencies
For i = 1 to 5
Call FreqOut(16, 4100, 4100 + i*2, 2.0)
Call Delay(0.25)
Next
This code will also work with the piezo buzzer (CEP-2242), too, but
you'll always hear the 4.1kHz signal in the background. Both of
these devices have PCB pin terminals, so they connect easily to a
breadboard or female jumper wires.
Hope this helps.
chris

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