> Gathering data...by hand right now at least....a data > packet from the PIC, representing the 10bit AD values. > Would be nice for something to dump right into > excel... I'm sure some VB wizard has that done somewhere; for myself, I just use a program called "COM Port Toolkit", which does simple hex logging. I capture the hex values, which comes out in a line 16 bytes wide, then open that .txt file in Word where I have a simple macro that removes the spaces and puts each word on its own line. Then I import the result into Excel. Not elegant, but very easy to make and use. > So ive got it left justified, high byte being the > upper 8 bits and low byte upper two bits being the > lowest two bits...that made sense right? Right justified makes more sense. Then you don't need to strip off the lower six bits, you just ignore the upper six. > Say we have the value 0x79C0, I want to have excel > strip off the lower 6 bits and convert to decimal. > And so I get the final result of 487. Is there a > simple way in excel to do this? As above, Word removes the spaces CPTK introduces, then I have a file of 4 char hex values, one per line. Easy to import into Excel. In your case, to "strip off" the lower six bits, you can divide by 64, then use Hex2Dec on the result. CAUTION!!! Using Hex2Dec is made more difficult by the fact that Excel DESPERATELY doesn't want to interpret hexadecimal content as a number. It can be tricky to get it to do so- especially in cases where the first byte is 0E. In those cases, even if you tell Excel that the field should be a number, it will attempt to make the contents into scientific notation, that is, 0 x 10^(lower byte). You have been warned- it's not too tough to work around, but harder than it ought to be. Mike H. -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist