I'm getting a write error when writing to a serial port (COM1) on a Windows machine. The returned error is a 112 (DISK_FULL). As this is a serial port I don't get what the error means.
Could it be that the buffer is full? I don't think so as I'm getting the error on the first request I send after opening the port.
I/O errors like that are generated by the device driver. Which these days is rarely the standard Windows serial port driver provided by Microsoft, it only works on real serial port hardware. Serial ports are very often emulated by device drivers that use custom hardware to implement communications. Bluetooth and USB for example. But anything goes.
It is convenient for the device manufacturer because they don't have to provide a custom DLL that lets you use the device in your own code. Emulating a serial port lets you simply use the standard winapi functions to talk to the device.
But that's as far as it goes, a core problem is that you are not actually using serial port hardware. And another is that these device manufacturers are not very good at writing custom drivers. Particularly USB driver are notorious for their poor quality. What doesn't help at all is that serial ports are not plug-and-play enabled, they are too primitive to support device discovery. So simple things like discovering which port number is connected to a device and dealing with disconnecting the device while it is in use are serious obstacles.
So sure, a "disk full" error code doesn't mean anything. The device driver writer grabbed the error code for some kind of error condition that's specific to the device. The only way to find out what the error really means is to ask the vendor.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With