Electrical Energy Calculator
Calculate electricity use from power and duration, or constant DC voltage and current. Compare energy use over different operating times in watt-hours, kilowatt-hours and joules.
Open toolCalculation needs JavaScript. If it does not load, the explanation, parameter table and examples below remain available.
Calculate or verify CRC-8, CRC-16 and CRC-32 values and simple 8-bit checksums for text or hex bytes, using catalogued CRC parameters.
Choose the algorithm your protocol or file format uses. The parameter card shows its width, polynomial, initial value, reflection and final XOR, so you can match it to a datasheet.
Choose whether you are entering text or hex bytes, then enter the data. The checksum updates as you type; changing the format keeps the same bytes.
To verify received data, paste the received checksum into Expected checksum. The tool reports Match or Mismatch.
Check the byte order your protocol transmits: the result is shown as big-endian and little-endian bytes.
If your implementation disagrees, compare its value after each byte with the running checksum table. For an unlisted CRC, choose Custom CRC and enter its parameters.
A cyclic redundancy check treats the message bits as the coefficients of a polynomial and divides it by a fixed generator polynomial using arithmetic without carries, where addition and subtraction are both XOR. The remainder is the CRC. The receiver repeats the division; a different remainder means the data changed.
Many standards share a polynomial but differ in the register's initial value, whether each byte is processed least significant bit first (reflected), whether the result is reflected, and a final XOR. The Rocksoft model names these six parameters, and Greg Cook's catalogue lists them for over a hundred standards with a check value: the CRC of the ASCII text 123456789.
A CRC of width W detects every error burst no longer than W bits, and the common polynomials detect all errors of a few bits in short messages. A simple sum or XOR checksum misses errors that cancel. Two's-complement sums are still common in formats such as Intel HEX, where adding all bytes, including the checksum, gives zero.
The byte order of the transmitted CRC is set by the protocol, not by the algorithm. Modbus RTU sends the CRC-16/MODBUS low byte first, while many CRC-32 file formats store it big-endian.
Limitations: results are exact for the listed algorithms and for any custom CRC of width 8, 16 or 32. The tool does not cover other widths, Fletcher or Adler checksums, or cryptographic hashes, and it cannot detect deliberate tampering: a CRC is not a security check.
Text is encoded as UTF-8, so characters outside ASCII use two to four bytes, and a single-line field cannot hold line breaks. The same text in another encoding, or with different line endings, gives a different checksum. Use hex input, such as 0D 0A for CR LF, to control the exact bytes.
CRC: Remainder of (message ร x^W, preset by init) รท (x^W + G), with optional reflection and a final XOR
Register step: r = (r << 1) XOR G if the top bit is 1, else r << 1, kept to W bits
Sum-8: s = (d1 + d2 + โฆ + dn) mod 256
Two's-complement Sum-8: t = (โ(d1 + โฆ + dn)) mod 256
Check value: CRC of the ASCII bytes 31 32 33 34 35 36 37 38 39
CRC-8/SMBUS: width 8, poly 0x07, init 0x00, refin false, refout false, xorout 0x00, check 0xF4
CRC-8/MAXIM-DOW: width 8, poly 0x31, init 0x00, refin true, refout true, xorout 0x00, check 0xA1
CRC-16/IBM-3740: width 16, poly 0x1021, init 0xFFFF, refin false, refout false, xorout 0x0000, check 0x29B1
CRC-16/KERMIT: width 16, poly 0x1021, init 0x0000, refin true, refout true, xorout 0x0000, check 0x2189
CRC-16/MODBUS: width 16, poly 0x8005, init 0xFFFF, refin true, refout true, xorout 0x0000, check 0x4B37
CRC-16/XMODEM: width 16, poly 0x1021, init 0x0000, refin false, refout false, xorout 0x0000, check 0x31C3
CRC-32/ISO-HDLC: width 32, poly 0x04C11DB7, init 0xFFFFFFFF, refin true, refout true, xorout 0xFFFFFFFF, check 0xCBF43926
CRC-32/ISCSI: width 32, poly 0x1EDC6F41, init 0xFFFFFFFF, refin true, refout true, xorout 0xFFFFFFFF, check 0xE3069283
CRC-32/ISO-HDLC, text 123456789: 0xCBF43926. This matches the catalogue check value and zlib's crc32, the CRC used by ZIP, PNG and Ethernet.
CRC-16/MODBUS, hex 01 03 00 00 00 01: 0x0A84; sent as 84 0A. A Modbus RTU read request. The low byte is transmitted first, so the frame ends 84 0A.
CRC-16/IBM-3740 versus CRC-16/KERMIT, text 123456789: 0x29B1 versus 0x2189. Common mistake: both are often called CRC-CCITT. The same polynomial 0x1021 gives different results because the initial value and reflection differ.
Two's-complement Sum-8, hex 03 00 30 00 02 33 7A: 0x1E. The Intel HEX record :0300300002337A1E. The bytes plus 1E sum to 0 modulo 256.
Greg Cook: Catalogue of parametrised CRC algorithms
Ross Williams: A Painless Guide to CRC Error Detection Algorithms (archived)
Koopman and Chakravarty: CRC polynomial selection for embedded networks
Available now
Calculate electricity use from power and duration, or constant DC voltage and current. Compare energy use over different operating times in watt-hours, kilowatt-hours and joules.
Open tool โAvailable now
Add up to 20 resistors in series using ฮฉ, kฮฉ or Mฮฉ for circuit analysis and electricity calculations, with a diagram and running total.
Open tool โAvailable now
Convert absolute temperatures between Celsius, Fahrenheit and kelvin.
Open tool โNice audio board working as expected.
Given the fact that this was my first purchase and I made it thinking I was buying genuine Yihua products, this has been a setback. I received a lesser known OEM brand called MYTO and while both the products seem to be similar from appearance, my real contention is the quality and quantity of the brass wool. On top of that not informing the customer about the unavailability of the Yihua product and instead sending a product from a different brand is also antagonising. Henceforth, I might just have to think twice before ordering from ThinkRobotics.
TOF MINIF Range Sensor - UART TOF Time-of-Flight Laser Range Sensor
We are disappointed with our recent order experience. We clearly communicated our requirement for 433 MHz antennas on WhatsApp, but the issue remains unresolved. We have been following up for more than 10 days and are still waiting for a proper refund resolution.
As a regular B2B customer, we expected better support. This experience has affected our trust in ThinkRobotics, and we may have to consider other suppliers for future purchases. We request a fair and prompt refund.
Anodised Aluminium Cup Head Washers (Pack of 10)