KEEP WITH YOU

Cheat sheets

The formula, the memory cue and the trap—together on one sheet. Choose a reference, then print or save it as a PDF.

Open calculator

TRYPLC FIELD REFERENCE / 01

Number & Bit Converter

Convert binary, decimal, hexadecimal and octal. Flip bits, inspect nibbles and compare signed integers through 64 bits.

  • 4 bits = 1 nibble
  • 8 bits = 1 byte
  • 1 hex digit = 4 bits
  • Unsigned range: 0 to 2ⁿ − 1
  • Signed range: −2ⁿ⁻¹ to 2ⁿ⁻¹ − 1
MOST SIGNIFICANTLEAST SIGNIFICANT
Nibble 1A
Nibble 0C

How to use this on a job

A drive manual says bit 7 is set. Your watch table says −84. The packet capture says AC. These can all describe the same byte. Start with the stored bits, then decide how the software should interpret them.

  1. 01

    Choose the input format and register width. Enter digits without a radix prefix; spaces or underscores may separate binary, octal or hexadecimal groups.

  2. 02

    Use unsigned for masks and status words. Use signed when the source explicitly declares a signed integer. Decimal input must fit that interpretation; other bases describe the stored pattern.

  3. 03

    Flip a bit below. Its position tells you its weight: bit 0 is worth 1, bit 1 is worth 2, and bit 7 is worth 128. Group four bits at a time to read hexadecimal.

Work through one example

172 = 10 × 16 + 12

1010 1100 has two nibbles: 1010 = A and 1100 = C. Its unsigned value is 128 + 32 + 8 + 4 = 172. With 8-bit two’s-complement interpretation, subtract 256 to obtain −84. Change to signed without changing the bits to see that distinction.

Before you trust the answer

Changing the width can change the meaning. FF is −1 as a signed 8-bit pattern but +255 in a signed 16-bit register. This converter rejects overflow; it does not silently drop high bits. Decimal signed values and unsigned hexadecimal patterns are deliberately different input conventions.

https://tryplc.com/tools/number-converter