Yes, I do this with scanners and printers in my Axure prototypes, as well as all sorts of input and output devices. ...But it ain't easy.
Here is a nice way to offer printing from your prototype:
If this is too daunting or you can't get it to work out, consider using the old "man behind the curtain" method for your usability testing. You can attach a wireless or Bluetooth keyboard to your computer, phone or tablet (anything other than an iOS device which prevents Bluetooth keyboards from controlling web pages.) Then, in your OnPageKeyUp event, put in some secret keypresses so a test moderator or assistant can surreptitiously control your prototype to pretend it is interacting with or controlling devices. For instance, to simulate voice control, whenever the user says "Please turn on my webcam" the assistant would press the 'w' key, triggering a simulated or real webcam image to appear. Or, if user presses the "Scan" button, the assistant would press the 's' button to simulate a page being scanned (e.g., show a dynamic panel with image of page) --things like that.