If I need to post this elsewhere let me know.
We have some old software thats being re-written, that uses a printerdriver to a propriatery printer.
I need to rewrite the software bypassing the print driver and go directly to the printer. I do have the specs for the printer communication, thats fine, but what Id like to do is monitor the communications to the printer to view its contents (from the existing software that Im re-writing) and compare it to the specs, and what I will be sending it for validation.
I have to make sure Im not missing anything.
Any ideas on how I might be able to accomplish this?
Thanks
To capture the traffic you have to basic options.
1. Use software
If you are using ethernet, you can use a program like WireShark or USBTrace to capture the packets that are being sent out. There are similar programs for USB.
2. Use hardware
Another option would be to use an external logic analyzer. It's basically a box that sits in-between the computer and the printer that captures all the data, then uses software to decode it. There are some inexpensive options available (USBEE, Bus Pirate, and Total Phase Beagle.
I own a USBEE and I've used it to debug a simple USB device. It works well enough for that. The software is a little clunky though.
Related
I'm implementing software to casino auto-play. I'm using .NET technology and C# language.
The main problem is how to capture data from casino game (here is the link to the game http://www.bet-at-home.com/redirNetentCasino.aspx?game=lrblackjack2-3h&pff=True ). I have never been dealing with Flash so I don't know a lot about this technology.
Well, I know that In the game we have server and client. Server is sending data to client and client is responding. For example server is sending information about dealt cards. My question is it's possible to capture data sent by server to client, I quess it is?? I need to now what kind of card I'm receiving. This data is sent in readable format or is ciphered?? Could you give me some hints?
The second option is to use a screen capture.. but this is very slow method. What are you thinking??
Thank you for help.
Regards,
Pablo
There are a couple of things you can do to interpret data from the game. First, you can use CheatEngine which is mostly the choice of Flash game hackers. The following links will help you get started:
How to hack flash games with cheat engine 5.5How to Cheat and Hack Flash based Games
The above method will not work for server based games like the ones hosted on Facebook. So, your second choice is capturing the network traffic and see what you can gather to attain the required information. For capturing the network from C#, you can use Pcap.NET. But before you try to do it programmatically, you should try it doing using Fiddler, which gathers plethora of information for you whenever you surf a website or when a plugin like Flash makes use of web.Get Fiddler and GL !
We should monitor and log ~1000 devices (1..4 sensor per device). SMS and email alert and the common functions are required if anything going wrong.
I think we instead of developing the whole ecosystem in .NET/C# it would be nice to use an existing one - for example Zabbix. But is it possible without any bigger hack?
I think that the main problem is that the devices are old-school and using RS232 for communication.
Any idea or any other flexible monitoring software?
Zabbix is a good monitoring tool, and it's easy to configure sms and email alerts. You'll need to script the serial port check, as there is no built in support for that. This may help: http://ramblings.narrabilis.com/node/310
I was wondering if anyone knows how (or even if it is possible) to monitor and trigger an action when a computer running windows (7-8) starts reciving a file transfer from over the network onto one of its drives.
Bonus points if I can find out how big the file is that the other guy is placing on my machine and how much is done etc...
I want to know if there is any API in windows, or snippit of code, or some other API that provides any of this functionality.
I still want to be able to recive files, I just want to manage them better. I am on a network with over 90 computers and this software that I wish to write would be running on most of them.
Of course you can (after all it's what an Antivirus program does) but it's NOT easy and probably you'll see it's more comfortable to do in C than in C#. I'm sure there's a .NET porting of WinPCap anyway you can always P/Invoke.
Start reading about Network Monitor SDK on MSDN. It's not an easy task, you have to capture a specific set of frames, you may use a Network Packet Monitor to inspect the content and the type of the packets you have to capture and parse.
I'm not sure but you may take a look to QoS API (start reading this article), it should provide something you can use.
In my scenario to print something, I don't want the printer has to be connected with a computer. Rather I am trying to connect that with a Modem(GSM or any other). when a sms arrives to the modem, the print command will fire and the sms will be printed.My question is, is it possible to implement the diagram with our existing technology? If not, i will be delighted if you provide some alternatives.
Unless you can customize the firmware of the GSM modem or the printer, it is likely you will need a small computer in between. If both can talk over serial ports, this can be really tiny - PIC, AVR (including packaged version such as Arduino), etc. If at least one needs USB you may be better off with a bare-metal Arm board. This is going to range from $2 at the low end to maybe $70 at the high. (There are also a few Arm boards that run an embedded .NET framework if that is your background... how well they run it I'm not sure)
If you need to do formatting, or the printer depends on the computer to do a lot of the work, or your engineers aren't familiar with the mindset of tiny embedded systems, you probably want something capable of running an operating system - ie, a faster Arm chip with hundreds of megabytes of memory - think Beagleboard, plugputer, Chumby Hacker Board, etc or one of those micro-servers that are basically x86 netbooks refactored for better cooling. Depending on how careful you are, this puts you anywhere from $50-$250.
You could also use an android phone (pick one with known USB host capability) and fold in the GSM capability, but may spend a lot of time tripping over the android components when all you really want is an embedded linux with a full libc. A more "linux-y" linux smartphone might be preferable if you can find one you expect will continue to be available.
I'm messing with the idea of writing a small program to mirror output of a video capture device. If you buy a video capture device you can only use it with one program at a time because the device gets locked. Instead of buying a second capture card id like to write a program to accept input from my capture device and expose the output to other applications.
Capture Device----->Program---->Flash Media Encoder
I've never done this type of thing before. Is it device driver related? Can I make my program look like a capture device to other programs without digging in device driver dev?
If someone could point me in the right direction that would be great.
Can I make my program look like a capture device to other programs without digging in device driver dev?
-No, I'm afraid not. You'd need to do exactly that, write a driver or capture source of your own. You could make some interface to serve up image to multiple apps (what a great idea!) but then it would need to be standardised, and you'd need other companies or developers to use that interface. Again a great idea but you'd need to agree on the feature set - and each developer would likely want something new or different.
(If you are talking about particular/specific other programs, they might have a particular interface you can work with already..)
(I was also assuming you were talking about realtime video capture: if you're talking about photo capture etc, you could write an image file to disk, and then import into the other apps ... not as joined up or integrated as ideal though)
Hope that helps - not an ideal situation though!
I will not say it is impossible, but I will say it is impossible in C# because this will require you to write a device driver software which can emulate virtual capture devices which your other program can use and your program can capture actual capture device and mirror or split the data to virtual capture devices that your device driver will create.
Very much same to Virtual CD Rom Drives that we can create with some software, you will need windows device driver kit for that.
You can write combination of application, one device driver and you can have some sort of C# api or program to control the operation.