bindechexascii – The Command-Line Converter

📅 December 16, 2016
cover

Wha…what?

Need a quick and easy way to convert between binary, ASCII, decimal, and hexadecimal values?

Try bindechexascii!

 

Regardless of how this is pronounced, chances are that bindechexascii is not installed on your Linux distribution. It is available for free from the Ubuntu repository, so use Synaptic or the command line to install it.

sudo apt-get install bindechexascii

Once installed, open a terminal and enter bindechexascii followed by the type of conversion to perform (a double hyphen option) and a value.

a

Converting ASCII to binary. Each ASCII character is converted into its binary equivalent. Multiple arguments are allowed. Spaces separate arguments, so the space character is not included in the binary output.

There are a number of options that specify what kind of conversion to perform.

a

Straight from the man page. (man bindechexascii)

Any attempt to run bindechexascii without arguments or options will return an error and the same help.

a

bindechexascii requires arguments to convert.

a

What is the ASCII character for binary 01001000? This program provides a quick way to find out. It’s the upper-case H character.

a

To double-check, we can take the same ASCII character H and convert to hex to find its hexadecimal value, which is 0x48. We can do the same to get H’s decimal value, 72, and its binary value, 01001000. For some reason, bindechexascii says “ASCII to Decimal” for hexadecimal conversions.

Overall, bindechexascii is a handy program to have in your command-line toolbox.

,

  1. Leave a comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: