It appears to me that Baofeng/Vero is using offsets (bytes) 04 and 09 in each 16-byte frequency (or channel structure) word to designate the CTCSS tone or DCS code. From what I see, there are 50 CTCSS tone codes and 104 DCS codes. Do I double that last number to account for the 2 polarities? If so, that means I'm trying to store 258 distinct bit codes in a max 16-bit hex byte (00-FF)..
The tone fields are two bytes wide. I would point you at the code if you're interested in the details, and also point you to the chirp_devel list if you want to talk bits and bytes. That's beyond the scope of what most people subscribed here want to see.
http://d-rats.com/hg/hgwebdir.cgi/chirp.hg/file/43efd847a8fe/chirp/wouxun.py...
Is what you classify as DTCS "R" polarity what the Baofeng folks designate as "I"?
Yes. Icom calls it "reverse" and many commercial rigs call it "inverted". I expect the UV3-R refers to it as "inverted," since Baofeng stole (allegedly, of course) from a commercial rig.