Re: bike computer to PC interface



On 7 Mar 2007 09:06:32 -0800, pete_tomson@xxxxxxxxxxx wrote:

Hi All - I found this newsgroup and was wondering if anyone could help
me.
I'd like to connect a magnetic sensor (bicycle computer) directly to
my computer through one of the ports without a power supply.

Basically the reed switch will have a current induced in it so I'm
thinking I'd ideally like the circuit to be passive with minimal
external circuitry.

I have a pic of a basic circuit I found but don't know how it works
and I don't know how to post it. Basically it has a connection to pin
4 through a 4.7kohm resistor a direct connection to pin 6 and a ground
through pin 20.
If you tell me how to post a pic I can show the diagram.


Can anyone make suggestions about circuit design - can I feed the
wires directly into my parallel/serial port?

I'm also trying to write a program in VB6 to read the input, but not
having much luck.

I'd really appreciate any help anyone could give me.
Thanks
Pete


I assume you are wanting to make a simple revolution counter for
a stationary bike. I made a simple setup by connecting pin 7
(rts) to a resistor (4.7k sounds good) thru a wheel contact setup
to pin 2 (rx). When the com port is opened, pin 7 goes high
supplying ~+10v. When the wheel contact was made, jibberish is
put in the serial port input buffer. I made a simple program
using Just Basic (free) that checks the input buffer for input
every 150 ms. If there is input to the buffer the wheel has made
a revolution.The wheel contact was an index card stuck into the
spokes such that I bowed out a little bit. l taped some aluminum
foil on the card surface so that it would brush two bare wire
ends from the circuit when it went by to make the circuit. This
put the jibberish in the buffer. Below is a simple program I made
to test it to see if it would work. It assumes that one wheel
revolution is ~.00138762 miles.

open "Com1:9600,n,8,1,ds0,cs0,rs" for random as #comm

x = 0
y = 0

[repeat]
timer 150, [delay]
wait

[delay]

dataRead$ = input$(#comm, lof(#comm))

if dataRead$ = "" goto [repeat]

y = y+.00138762
print y

'print x
x=x+1

if x=1000 goto [quit]

goto [repeat]

[quit]
Close #comm

End






.



Relevant Pages

  • Re: magnetic sensor to PC interface
    ... It will not have enough power to run a micro. ... I have a pic of a basic circuit I found but don't know how it works ... Basically it has a connection to pin ... 4.7K to VCC and 100s ohms between op amp ouput and port. ...
    (sci.electronics.design)
  • Re: [patch -mm 20/20 RFC] chardev: GPIO for SCx200 & PC-8736x: add sysfs-GPIO interf
    ... We need a standard rep for GPIO in sysfs, ... GPIO hardware design appears to have 2 top-level factors; ... change will also exhibit in the port attr too. ... if a pin is output only, it shouldnt have an _output_enabled attr. ...
    (Linux-Kernel)
  • Re: OT: DOS programming EPP
    ... There seems to be *no* specifications or equivalent circuits for the parallel port as implemented on the ASICs used in modern PCs. ... it is completely unknown as to the maximum safe sink current to a logic low pin or the maximum source current from a logic high pin. ... The EPP page assumes you did. ... CONTROL bit 5 defaults low. ...
    (sci.electronics.design)
  • Re: WTB: Power supply for Heathkit "home" version of Fireball (Bally?)
    ... pin work in this Fireball home version pin. ... I also had to build a pass through circuit ... that carried fuses and returned back to the board for the 22v (coils ... board and then go directly off board again through fuses. ...
    (rec.games.pinball)
  • Re: decoupling caps placement
    ... I've got a circuit that uses 3 4049 inverters. ... pin 8 and the ground is on pin 1. ... sufficient to connect 1 end of the cap to V+ and the other to a nearby ... If building on veroboard or solderless breadboard, make sure you have reliable power and ground rails. ...
    (sci.electronics.basics)