I am writing a program for which I will create a script to generate test data in a specific format.
- How can I create a
/dev/myprogramdevice that would work similar to
/dev/random(preferably in the subdirectory of
- Can I attach any script to such device or do I have to make a C program using some (which?) low level APIs?
- Do I have to return one byte at a time or can I setup the device to always return specified amount of bytes, greater than 1?
I am using Ubuntu 14.04, though I am looking for a generic answer that would work on any *nix system.