?
Solved

Sending data from a saved file Through USB port with Delphi

Posted on 2006-05-18
5
Medium Priority
?
914 Views
Last Modified: 2008-01-09
I'm looking for a way to record data from an Xbox controller (USB compatible) into a created file extension, then to be able to send it back from the pc onto the USB port to the Xbox so the computer can replay the Xbox controller sequences by itself. I'm using the XBCD 1.07 driver which can be found on www.redcl0ud.com, but I can't seem to figure everything out(I'm trying to modify the Main.pas of the XBCDSU folder of the source code). Is it possible to use "TFileStream" to record data into a file? Also, how can I send data from a saved file through the USB port with a 20 millisecond interval between each byte, since the software also reads the signal at the same interval? Thank you.
0
Comment
Question by:JeffParadis
  • 2
3 Comments
 
LVL 11

Expert Comment

by:robert_marquardt
ID: 16715062
This is hogwash. USB does not work that way.
This cannot be done without hardware because USB is a serial master-slave bus and not a serial line.
The bus is under hardware control on both sides.
Two masters are not allowed on the bus so you cannot connect your PC to the Xbox. This would kill both USB host controllers.
0
 

Author Comment

by:JeffParadis
ID: 16719099
On the Xbox, the gamepad is responsible for sending the data to the Xbox (Atmel At43USB353-M microcontroller). Knowing that, could it work if I switch between the pc and the controller for signal transmission to the Xbox? The way I see it is that in both cases the Xbox console would be the slave (because it's always on the receiving end).....or am I simply missing a few concepts in USB knowledge?

If you suggest this activity to be done with hardware, how would you proceed? Thanks?
0
 
LVL 11

Accepted Solution

by:
robert_marquardt earned 2000 total points
ID: 16720057
Host controller and slave device communicate in hardware. The bus protocol is complicated and not deterministic enough for playback.
The easiest way would be to attack the Xbox controller on the other side. The microcontroller reads its sensors which is simple digital electronic.
If you grab the signals and play them back the Xbox controller will faithfully report them to the Xbox.

You should search and read this board.
http://www.usb.org/phpbb/viewforum.php?f=1
The USB IF forum is the place where all the USB developers meet.

Also read http://www.lvr.com the website of Jan Axelson.
Her (!) book is reference material.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
In a question here at Experts Exchange (https://www.experts-exchange.com/questions/29062564/Adobe-acrobat-reader-DC.html), a member asked how to create a signature in Adobe Acrobat Reader DC (the free Reader product, not the paid, full Acrobat produ…
Screencast - Getting to Know the Pipeline
Suggested Courses

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question