mcmahoney Posted June 30, 2011 Report Share Posted June 30, 2011 I have a project that reads the 16 bit registers from a slave device and have a problem with reading the unsigned value. I have worked out a way to read the value. if the value is positive, then I read it directly. If the value is negative, I add the value to 65535 and store it in a long location. I was wondering if there was a cleaner way of doing this. Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.