This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Data content of CC1 register

I am require to calculate the distance of the object that the range finder detects. The microcontroller I am using is C167CR-LM. I am using T1 to detect the time lag between transmitting and receive of the pulse.

When the the content of the timer is latch into the CC1 register, what is saved inside there? The timer's location? In what format(decimal, hexadecimal)? Without knowing, I couldn't continue my program.

Awaiting ur reply,
Frank

Parents
  • But anything wrong with using %g as the floating point specifier?

    If the number you're printing is a floating point one, no.

    It won't affect the result right?

    Wrong. If it didn't affect the result, why would it exist as a separate option?

    If I can't, what should i use?

    A C textbook. Seriously, you need to brush up your C knowledge before you go on foraging into the specifics of embedded programming in C.

Reply
  • But anything wrong with using %g as the floating point specifier?

    If the number you're printing is a floating point one, no.

    It won't affect the result right?

    Wrong. If it didn't affect the result, why would it exist as a separate option?

    If I can't, what should i use?

    A C textbook. Seriously, you need to brush up your C knowledge before you go on foraging into the specifics of embedded programming in C.

Children
No data