Microswitch programming
Archiver
Posts: 46,084
Hi, I have a disk that is being spun by a motor. On the disk, it as
an X on it and I want to know if someone knows how to program the
Stamp board so the X on the disk will always be at the top when the
disk spins at in certain time interval. I hope this is a clear
enough explanation. I would appreiciate any help with this. Thanks
an X on it and I want to know if someone knows how to program the
Stamp board so the X on the disk will always be at the top when the
disk spins at in certain time interval. I hope this is a clear
enough explanation. I would appreiciate any help with this. Thanks
Comments
pointing light at the disk. Depending upon the frequency of the strobe light,
as you vary the motor speed (Fast, slow, just right) you should be able to
make the X rotate both directions and also make it stop. Without some kind of
rpm
feedback from the motor that is involved in controlling the speed of the
motor, it will be very difficult to keep the X at one spot.
Ken
Hi, I have a disk that is being spun by a motor. On the disk, it as
an X on it and I want to know if someone knows how to program the
Stamp board so the X on the disk will always be at the top when the
disk spins at in certain time interval. I hope this is a clear
enough explanation. I would appreiciate any help with this. Thanks
[noparse][[/noparse]Non-text portions of this message have been removed]
there is a clip attached to the outer edge of it. What I want to do
is have that clip hit the microswitch and have a program on the
board so that when the microswitch is tripped a certain amount of
times, the X on the disk will always stop at the top when the motor
stops.
--- In basicstamps@yahoogroups.com, smartdim@a... wrote:
> If I understand what you are trying to do, you will need have a
strobe light
> pointing light at the disk. Depending upon the frequency of the
strobe light,
> as you vary the motor speed (Fast, slow, just right) you should be
able to
> make the X rotate both directions and also make it stop. Without
some kind of rpm
> feedback from the motor that is involved in controlling the speed
of the
> motor, it will be very difficult to keep the X at one spot.
>
> Ken
>
> Hi, I have a disk that is being spun by a motor. On the disk, it
as
> an X on it and I want to know if someone knows how to program the
> Stamp board so the X on the disk will always be at the top when
the
> disk spins at in certain time interval. I hope this is a clear
> enough explanation. I would appreiciate any help with this. Thanks
>
>
> [noparse][[/noparse]Non-text portions of this message have been removed]
jonny_yang2k@y... writes:
I already have a microswitch attached behind the disk. On the disk
there is a clip attached to the outer edge of it. What I want to do
is have that clip hit the microswitch and have a program on the
board so that when the microswitch is tripped a certain amount of
times, the X on the disk will always stop at the top when the motor
stops.
OK. The basic stamp has a PULSIN command that can be used to sense the switch
close, open then close again, which in turn will allow you to count the
number of times your microswitch is tripped.
The microswitch MUST be debounced, because when the switch opens and closes,
it will actually close several times before remaining closed, and the same can
be said for opening. I am almost sure the Parallax web sight has example code
on how to debounce a switch.
Also, we must know how fast the disk will rotate and at what radius the
microswitch is positioned. This information is needed to know how much time will
elapse between microswitch closures....The stamp can do the PULSIN command, but
only so fast.
You will also likely want to position the switch so that it is tripped before
the X is at the top (advanced position). Some time is needed to stop the
motor/disc once the switch closure is detected and debounced.
ken
[noparse][[/noparse]Non-text portions of this message have been removed]
now.
Jon