Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

How to read data stream on a specific hardware pin?

Need help with peripherals or devices?
Post Reply
Message
Author
ninene
Posts: 6
Joined: 2019-12-23 04:16

How to read data stream on a specific hardware pin?

#1 Post by ninene »

Hi,

I am junior, especially in Linux, but I got great replies in my first post, so I am asking another question.

How to read the data that's coming/going over any given pin (of the USB/Serial/HDMI/DVI port) of a hardware device? Say, I want to record the bits going over TX pin (only) of a USB port, how can we do that?

Search engines returned tangential answers, touching but not treating the topic (such as this, this & this).
Searching "pin data" turned up this post on our forum, but I don't think that's relevant.

I recently learned everything is a file & the whole /dev/cdrom0 concept really excites me, but I am curious at the same time: can we go one level deeper in abstraction and inspect data coming/going through individual pins? Its obvious the data is there (the WireShark can monitor USB traffic like it was recording Wi-Fi packets :o its genius), but does the latest Linux-kernel allow one to separately read individual pin data?

Cheers :D

chadrick
Posts: 83
Joined: 2016-01-06 00:32

Re: How to read data stream on a specific hardware pin?

#2 Post by chadrick »

That sounds like something that might be done with a Raspberry Pi since you can connect i/o pins. You might be able to have a pin directed to the Pi, read on the Pi, and then output from the Pi on a different pin connected to the final destination. I am not sure if that will mess up timings though.

chadrick

ninene
Posts: 6
Joined: 2019-12-23 04:16

Re: How to read data stream on a specific hardware pin?

#3 Post by ninene »

chadrick wrote:That sounds like something that might be done with a Raspberry Pi since you can connect i/o pins. You might be able to have a pin directed to the Pi, read on the Pi, and then output from the Pi on a different pin connected to the final destination. I am not sure if that will mess up timings though.
Exactly.

I had a similar thought & am trying to understand RPi.GPIO (python package)'s source code because it's the official RPi way to read/write at GPIOs. The source code has too many files, IDK where to look.

Thanks.

ninene
Posts: 6
Joined: 2019-12-23 04:16

Re: How to read data stream on a specific hardware pin?

#4 Post by ninene »

Can fellow developers who write/port hardware drivers, please shed some light on this topic? Is this even possible?

Post Reply