According to Josh Koffman on Thu, 03/19/15 at 13:21: >=20 > I have no Arduino experience, but from what I've been reading, it > appears that in their ecosystem you can define multiple instances of a > class. So in my case if I made one routine that dealt with a single > encoder, I could create 2 instances to deal with 2 encoders, etc. As > far as I understand it, I can't do that in straight C. In the good ole' days (prior to object oriented languages) folks would have used a "transfer vector" to handle things like this. It sounds like the Arduino ecosystem is object oriented -- I dunno. But the C language definitely is not. C++ is -- but don't go there... :-) Perhaps write a bevy of functions in C, each of which is slightly different, to handle the different hardware types you are dealing with. Each function would have the same argument or parameter list (the same calling convention, or "signature"). Then index into your "transfer vector" (which is a list of function entry points) based on some feature of your different hardware needs, and voila! YMMV... :-) Regards, web... --=20 /"\ ASCII RIBBON / William Bulley \ / CAMPAIGN AGAINST /=20 X HTML E-MAIL AND / E-MAIL: web@umich.edu / \ LISTSERV POSTINGS / 72 characters width template ----------------------------------------->| --=20 http://www.piclist.com/techref/piclist PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist .