DIYbanter

DIYbanter (https://www.diybanter.com/)
-   Electronics (https://www.diybanter.com/electronics/)
-   -   FPGA or shift registers? (https://www.diybanter.com/electronics/201748-fpga-shift-registers.html)

[email protected] May 24th 07 10:52 AM

FPGA or shift registers?
 
hi,

I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:

a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.

The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.

Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?

thanks,
Jon.


John Fields May 24th 07 01:50 PM

FPGA or shift registers?
 
On 24 May 2007 02:52:34 -0700, wrote:

hi,

I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:

a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.

The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.

Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?


---
If this is a one-off I recommend the shift register method, and
there's no reason for the skipping error to occur if the thing is
designed properly.

Would you like a schematic?


--
JF

[email protected] May 24th 07 02:48 PM

FPGA or shift registers?
 
On May 24, 3:50 pm, John Fields wrote:
On 24 May 2007 02:52:34 -0700, wrote:



hi,


I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:


a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.


The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.


Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?


---
If this is a one-off I recommend the shift register method, and
there's no reason for the skipping error to occur if the thing is
designed properly.

Would you like a schematic?

--
JF



It's a proof of concept, but for now I'd just like to go with
whatever's simplest. If you can give me a schematic I'd be very
grateful.

Thanks,
Jon.



John Fields May 24th 07 03:10 PM

FPGA or shift registers?
 
On 24 May 2007 06:48:26 -0700, wrote:

On May 24, 3:50 pm, John Fields wrote:
On 24 May 2007 02:52:34 -0700, wrote:



hi,


I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:


a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.


The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.


Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?


---
If this is a one-off I recommend the shift register method, and
there's no reason for the skipping error to occur if the thing is
designed properly.

Would you like a schematic?

--
JF



It's a proof of concept, but for now I'd just like to go with
whatever's simplest. If you can give me a schematic I'd be very
grateful.


---
OK.

I'll post it to alt.binaries.schematics.electronic sometime tomorrow
and I'll also email you a copy since you can't access binary
newsgroups through Google.


--
JF

[email protected] May 26th 07 05:13 PM

FPGA or shift registers?
 
On May 24, 5:10 pm, John Fields wrote:
On 24 May 2007 06:48:26 -0700, wrote:



On May 24, 3:50 pm, John Fields wrote:
On 24 May 2007 02:52:34 -0700, wrote:


hi,


I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:


a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.


The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.


Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?


---
If this is a one-off I recommend the shift register method, and
there's no reason for the skipping error to occur if the thing is
designed properly.


Would you like a schematic?


--
JF


It's a proof of concept, but for now I'd just like to go with
whatever's simplest. If you can give me a schematic I'd be very
grateful.


---
OK.

I'll post it to alt.binaries.schematics.electronic sometime tomorrow
and I'll also email you a copy since you can't access binary
newsgroups through Google.

--
JF



Got it. Thank a lot! I really appreciate it.

Jon.



John Fields May 26th 07 10:28 PM

FPGA or shift registers?
 
On 26 May 2007 09:13:26 -0700, wrote:

On May 24, 5:10 pm, John Fields wrote:
On 24 May 2007 06:48:26 -0700, wrote:



On May 24, 3:50 pm, John Fields wrote:
On 24 May 2007 02:52:34 -0700, wrote:


hi,


I have a device with 34 digital (5V or 0V) inputs. Only one of the 34
can be 5V at any one time. I'd like to know the number of input which
is at 5V. I can think of two ways of doing this:


a) 5 eight-bit shift registers. Each input is connected to a shift
register and the shift registers are read and outputted one bit at a
time periodically (left shifting the bits one bit at a time).
b) programming a FPGA. It'll have 34 inputs and report the number of
input that was tripped as output.


The disadvantage of method (a) is that it has more parts and also I
was told that during the reading of the shift registers there might be
an error where one bit is skipped, which will result in getting the
wrong number for the tripped input.
The disadvantage of method (b) is that I have no idea how to program a
FPGA.


Can anyone recommend either of these methods (or a simpler one if it
exists)? Is it likely that the skipping error in reading the shift
registers will occur?


---
If this is a one-off I recommend the shift register method, and
there's no reason for the skipping error to occur if the thing is
designed properly.


Would you like a schematic?


--
JF


It's a proof of concept, but for now I'd just like to go with
whatever's simplest. If you can give me a schematic I'd be very
grateful.


---
OK.

I'll post it to alt.binaries.schematics.electronic sometime tomorrow
and I'll also email you a copy since you can't access binary
newsgroups through Google.

--
JF



Got it. Thank a lot! I really appreciate it.

Jon.


---
My pleasure. :-)


--
JF


All times are GMT +1. The time now is 11:03 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004 - 2014 DIYbanter