如何在Windows中使用c / c ++从设备读取字节 [英] How to read bytes from a device using c/c++ in windows

查看:184
本文介绍了如何在Windows中使用c / c ++从设备读取字节的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以这里的背景:

我有这个SCSI设备与媒体,其上有原始数据(为简单起见,我们说它包含abc123)。此设备位于Windows计算机上。我想使用C / C ++初始化设备,打开它,发送SCSI读命令到设备,并最终读取字节。

I've got this SCSI device with media that has raw data on it (for simplicity let's say it contains abc123). This device is on a Windows machine. I'd like to use C/C++ to initalize the device, open it, send the SCSI read command to the device, and ultimately "read" the bytes.

I我搜索了类似的主题,但我不断得到Linux / Unix指南或Visual C ++(我没有访问)。

I've searched for similar topics, but I keep getting Linux/Unix guides, or Visual C++ (which I do not have access to).

有人知道一个好方法开始这个?可能有一些示例代码,或者有人放置了教程; - )

Does anyone know a good way to start this? Maybe some sample code or maybe someone has a tutorial laying around ;-)

提前感谢!

EDIT:我使用的是Cygwin。

I am using Cygwin.

推荐答案

更新:有一些时间,有些恳求和乞讨,我设法让我的上司允许我得到Visual Studio 2003安装!

UPDATE: After banging my head into a wall for quite some time, and some pleading and begging, I managed to get my superviser to allow me to get Visual Studio 2003 installed!

对于寻找有关此主题的更多信息的任何人,我非​​常同意上面提供的意见 - 几乎不可能在Windows机器上完成此操作,而不使用Visual C ++。

To anyone looking for more information on this topic, I highly agree with the comments provided above-it's near impossible to accomplish this on a Windows machine and not use Visual C++.

我唯一的其他建议是让奇妙的切换到* nix世界(如果可以)!

My only other suggestion is to make the wonderful switch to *nix world (if you can)!

这篇关于如何在Windows中使用c / c ++从设备读取字节的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆