1.1.2 Hexadecimal
What are the uses of hexadecimal in web addresses?
- Each character on a keyboard has a corresponding ASCII code, which can be represented using hexadecimal - You can use hexadecimal values instead of ASCII for a URL - Sometimes hexadecimal addresses are used as a security feature
What are the uses of hexadecimal in HTML?
- HTML is used for writing and developing web pages - The code can be used to represent colours seen on the screen - The intensity of the three primary colours is determined by its hexadecimal value
Why use hexadecimal?
- It is much easier to work with in comparison to binary e.g B5A41AFC rather than 1011 | 1001 | 1010 | 0100 | 0001 | 1010 | 1111 | 1100
How do you convert binary to hexadecimal?
- Starting from the right and working left, split the binary number into groups of 4 bits. If the last group has less than 4 bits, simply fill in with 0s from the left. - Convert these groups into the equivalent hexadecimal digit
How do you convert denary to hexadecimal?
- You can also use trial and error
What are the uses of hexadecimal in Media Access Control (MAC)?
- A Media Access Control Address refers to a number which uniquely identifies a device on the internet - The address is rarely changed, so a device can always be identified - MAC addresses are usually made up of 48 bits which are shown as 6 groups of hexadecimal digits - The first half is the identity number of the manufacturer and the second half is the serial number of the device
How do you convert hexadecimal to binary?
- As 16 = 2⁴ (₂), each hexadecimal digit is equivalent to four binary digits
What is hexadecimal?
- Base 16 - Numbers 0 to 9 and letters A to F are used (A = 10, B = 11, C = 12, D = 13, E = 14, F = 15) - Counts in powers of 16
What are the uses of hexadecimal when debugging?
- Can be used to trace errors in programs - When memory contents are outputted to a monitor or printer, it is called a memory dump - From this, a developer can find the error - Using hexadecimal is far more manageable than using binary
What are the uses of hexadecimal in assembly languages and machine code?
- Computer memory can be referred to directly using machine code or an assembly language - It is easier, faster and less prone to error than binary - They are low-level languages used by software developers in games - Easier to locate errors