How to listen in on digital communication with AVR (8b uC)

M

Michael

Jan 1, 1970
0
Hi - I'd like to interface an AVR (an 8 bit microcontroller) with a
computer so that it can "listen in" on various communication going on
within the computer for debugging purposes. How would I attach it to a
digital line so that it didn't affect communication at all? I mean like for
example I've heard that you can't have more than one device attached to a
PCI clock for some reason (I forget why) - so how would one be able to
listen in on that clock? Hopefully someone understands what I'm trying to
say! :) Thanks!

Michael
 
I

Ian Stirling

Jan 1, 1970
0
Michael said:
Hi - I'd like to interface an AVR (an 8 bit microcontroller) with a
computer so that it can "listen in" on various communication going on
within the computer for debugging purposes. How would I attach it to a
digital line so that it didn't affect communication at all? I mean like for
example I've heard that you can't have more than one device attached to a
PCI clock for some reason (I forget why) - so how would one be able to
listen in on that clock? Hopefully someone understands what I'm trying to
say! :) Thanks!

What do you expect this to do?
 
B

Ben Bradley

Jan 1, 1970
0
Hi - I'd like to interface an AVR (an 8 bit microcontroller) with a
computer so that it can "listen in" on various communication going on
within the computer for debugging purposes. How would I attach it to a
digital line so that it didn't affect communication at all? I mean like for
example I've heard that you can't have more than one device attached to a
PCI clock for some reason (I forget why)

This must mean something like "you can't have more than one
standard TTL load connected."
I'm not that familiar with the PCI interface, but I know it runs
at least as fast as an AVR microcontroller. It would be unsuitable for
this task. You would need programmable logic to sample the computer
bus at fixed times and transfer the data to RAM for later analysis.
You are essentially making a logic analyzer.
- so how would one be able to
listen in on that clock?

There are special chips used in logic analyzers that give an
insignificant load to the lines they are connected to.
 
M

Michael

Jan 1, 1970
0
What do you expect this to do?

Well currently I'm working on an AVR that will sort of act as a "Y" adapter
on a single board computer, allowing two keyboards and two mice to be
attached to the same computer at the same time. For now - I'd simply like
to be able to make sure the AVR is doing what I believe it's doing
(essentially capture all the packets it's sending and recieving - and
allowing me to view them on a computer) It would be nice if it could handle
other digital lines as well, though I know the AVR's max speed will present
itself as a problem (being that the fastest AVR available runs at 16Mhz)

-Michael
 
M

Michael

Jan 1, 1970
0
This must mean something like "you can't have more than one
standard TTL load connected."
I'm not that familiar with the PCI interface, but I know it runs
at least as fast as an AVR microcontroller. It would be unsuitable for
this task. You would need programmable logic to sample the computer
bus at fixed times and transfer the data to RAM for later analysis.
You are essentially making a logic analyzer.


Yes - I'm aware of the speed limitation - as I believe PCI runs at 66mhz
(or maybe 33 - I forget) and the fastest AVR is 16Mhz. But PCI was just an
example. Currently I'm hoping to use this to listen in on PS/2 traffic,
which ranges in speed from 10 to 16.7 kHz - which I think an AVR should
have no trouble whatsoever with. I guess yeah I am trying to build a sort
of logic analyzer - as I simply don't have the budget to buy my own! :)
(poor college student)

There are special chips used in logic analyzers that give an
insignificant load to the lines they are connected to.


You wouldn't happen to know what these chips are called, or who makes them,
or anything like that would you?



Thanks again,

Michael
 
I

Ian Stirling

Jan 1, 1970
0
Michael said:
Well currently I'm working on an AVR that will sort of act as a "Y" adapter
on a single board computer, allowing two keyboards and two mice to be
attached to the same computer at the same time. For now - I'd simply like
to be able to make sure the AVR is doing what I believe it's doing
(essentially capture all the packets it's sending and recieving - and
allowing me to view them on a computer) It would be nice if it could handle
other digital lines as well, though I know the AVR's max speed will present
itself as a problem (being that the fastest AVR available runs at 16Mhz)

Well, for the PS/2 port, all you need to do is to build a cable to connect.
It's all TTL levels.
PCI, well, no.
You might be able to electrically connect it, but the bus is so fast that
you can't do anything usefull.
 
A

Activ8

Jan 1, 1970
0
Yes - I'm aware of the speed limitation - as I believe PCI runs at 66mhz
(or maybe 33 - I forget) and the fastest AVR is 16Mhz. But PCI was just an
example. Currently I'm hoping to use this to listen in on PS/2 traffic,
which ranges in speed from 10 to 16.7 kHz - which I think an AVR should
have no trouble whatsoever with. I guess yeah I am trying to build a sort
of logic analyzer - as I simply don't have the budget to buy my own! :)
(poor college student)

Yeah, well, a logic analyzer would be overkill for this anyway and
even then, all you can do is listen.
You wouldn't happen to know what these chips are called, or who makes them,
or anything like that would you?

If you really need to listen to the PCI clock at 66 MHz, you could
probably use an opamp voltage follower. THe high impedance won't
load you down. The cost is cheap enough that a failure won't totally
ruin your day. Forget FSB for now. At 433 MHz (?) you're looking for
trouble.

For the PS/2 interface, IIRC, Y adapters have been used. As another
poster said, it's TTL levels, so the TTL level inputs on the AVR
(just like a PIC?) shouldn't load it down too much. I know you can
google for PIC logic analyzer threads/projects so you shouldn't have
a prob finding something for AVR or just doing the same thing. You
only need to read the PS/2 input(s) and pass them to the output(s).
You can even write code to scribble all over your screen with the
pointer.have fun. AVR freaks and PICList will most likely be your best
resource.
 
R

Rene Tschaggelar

Jan 1, 1970
0
Michael said:
Hi - I'd like to interface an AVR (an 8 bit microcontroller) with a
computer so that it can "listen in" on various communication going on
within the computer for debugging purposes. How would I attach it to a
digital line so that it didn't affect communication at all? I mean like for
example I've heard that you can't have more than one device attached to a
PCI clock for some reason (I forget why) - so how would one be able to
listen in on that clock? Hopefully someone understands what I'm trying to
say! :) Thanks!

Don't worry about PCI, this is out of reach anyway.
You can attach an AVR and/or some support circuits, speaking
CPLD to a bus. However You should have a scope to verify that
the signals come right.

Rene
 
M

Michael

Jan 1, 1970
0
Well, for the PS/2 port, all you need to do is to build a cable to
connect. It's all TTL levels.
PCI, well, no.
You might be able to electrically connect it, but the bus is so fast
that you can't do anything usefull.

Right now - I'm just worried about the connection part. Additional
circuitry for higher speed circuits is something that I plan on worrying
more about in the future.

So I would just set the pins on the AVRs as inputs. Would I enable the
internal pull up resistors? Would I need internal/external pull up
resistors? Thanks!

Michael
 
I

Ian Stirling

Jan 1, 1970
0
Michael said:
Right now - I'm just worried about the connection part. Additional
circuitry for higher speed circuits is something that I plan on worrying
more about in the future.

So I would just set the pins on the AVRs as inputs. Would I enable the
internal pull up resistors? Would I need internal/external pull up
resistors? Thanks!

Yes, just set them as inpouts without any pullups.
I think you can get a keyboard merger as a product, I'm sure I've seen them.
 
M

Michael

Jan 1, 1970
0
Yes, just set them as inpouts without any pullups.
I think you can get a keyboard merger as a product, I'm sure I've seen
them.

Allright but can I do this for any sort of lower speed communication? If
not - what do I need to do? And for higher speed stuff (such as PCI -
though at this time I don't expect to ever work on PCI) what would I need
to do? Besides making sure the data is at TTL levels (like how I'd have to
bring down RS-232 from IIRC -12/+12 to 5/0.)

Thanks again!

Michael
 
I

Ian Stirling

Jan 1, 1970
0
Michael said:
Allright but can I do this for any sort of lower speed communication? If
not - what do I need to do? And for higher speed stuff (such as PCI -
though at this time I don't expect to ever work on PCI) what would I need

You need some sort of programmable logic that can latch at the speeds
you need under defined conditions, and either store the information,
or commit it to internal memory that you can read later slowly.
to do? Besides making sure the data is at TTL levels (like how I'd have to
bring down RS-232 from IIRC -12/+12 to 5/0.)

The simple way to convert RS232 levels is to use one of the many chips,
for example, the ones available from http://www.maxim-ic.com/
 
Top