Hello ppatierno,
Please let me confirm, are you uploading and testing one specific example or your own code?
If you are loading an example, can you let me know where to get it, I could test this on my Galileo to see how it behaves.
Also sounds like the code is compiling without problems, but it does not return the value that you are expecting, is this the situation?
LDiego.