You are on page 1of 16

LITERATUR KONSEP DIGITAL

PROGRAM STUDI TEKNIK TELEKOMUNIKASI

JURUSAN TEKNIK ELEKTRO


POLITEKNIK NEGERI JAKARTA
 CAPAIAN PEMBELAJARAN
Mahasiswa dapat menjelaskan Konsep Dasar rangkaian digital dan Sistem Bilangan.

 DIGITAL TECHNOLOGY
Digital Electronics represents information with only two discrete values.
Ideally
“no voltage” (e.g., 0v) represents a 0 and
“full source voltage” (e.g., 5v) represents a 1

Realistically
“low voltage” (e.g., <1v) represents a 0 and
“high voltage” (e.g., >4v) represents a 1

We achieve these discrete values by using switches.


We use transistor switches, which operates at high speed, electronically, a small in size.
 ANALOG VS DIGITAL

Analog systems process time-varying signals that can take on any value across a continuous
range of voltages.

Digital systems process time-varying signals that can take on only one of two discrete values
of voltages (in electrical/electronics systems). Discrete values are called 1 and 0 (ON and
OFF, HIGH and LOW, TRUE and FALSE, etc.)
 PENYAJIAN INFORMASI SECARA ELEKTRONIK
Sebuah Lampu harus menyajikan 4 informasi yang berbeda :
1. Lampu padam informasinya tidak ada mahasiswa di dalam kelas.
2. Lampu 1/3 cerah informasinya ada 1 mahasiswa di dalam kelas.
3. Lampu 2/3 cerah informasinya ada 2 mahasiswa di dalam kelas.
4. Lampu dengan kecerahan penuh informasinya ada 3 mahasiswa di dalam kelas.

 PERMASALAHAN

o A light bulb has to represent 10 different information:


Is it possible to differentiate the ten different light intensity?

o A light bulb has to represent 2 different information:


Bulb off - no student inside
Bulb Full lit - 1 student inside

o A light bulb has to represent 4 different information:


How? With one bulb?
Use two bulbs

o A light bulb has to represent 10 different information:


Use four bulbs

“Analog electronics” deals with non-discrete values


“Digital electronics” deals with discrete values

 Benefits of Digital over Analog


o Reproducibility
o Not effected by noise means quality
o Ease of design
o Data protection
o Programmable
o Speed
o Economy

 SISTEM BILANGAN
PENDAHULUAN
SISTEM BILANGAN BINER
SISTEM BILANGAN DESIMAL
SISTEM BILANGAN HEXADECIMAL
SISTEM BILANGAN OKTAL
PENGKODEAN BILANGAN BINER

 PENDAHULUAN
Coding:
A single binary input can only have two values: True or False (Yes or No) (1 or 0)
 Kombinasi Biner

More bits = more combinations

 Contoh

Example 1:
o How many combinations are possible with 10 binary inputs?
Example 2:
o What is the minimum number of bits needed to represent the digits ‘0’ to ‘9’
as a binary code?”

 Decimal systems
Number Representation
o Difficult to represent Decimal numbers directly in a digital system
o Easier to convert them to binary
o There is a weighting system:
eg
403 = 4 x 100 + 0 x 10 + 3 x 1
or in, powers of 10:
40310= 4x102 + 0x101 + 3x100 = 400 + 0 + 3

 Positional Weighting System

Both Decimal and Binary numbers use a positional weighting system, eg:

10102 = 1x23+0x22+1x21+0x20 = 1x8 + 0x4 + 1x2 + 0x1 = 1010

 Konversi Biner ke decimal

 Konversi Desimal ke Biner


An alternative way is to use the “placement” method

128 goes into 155 once leaving 27 to be placed

So 64 and 32 are too big (make them zero)


16 goes in once leaving 11

and so on…
 BCD
Decimal BCD
 6 of the possible 16 values unused
0 0000
 example 45310 = 0100 0101 0011BCD 1 0001
2 0010
 Note that BCD code is longer than a direct representation in natural binary code: 3 0011
 453 = 111000101 4 0100
5 0101
6 0110
7 0111
8 1000
9 1001
Hexadecimal and Octal
 Octal (base 8) and Hexadecimal (base 16) notations can be used to reduce a long string
of binary digits.

 Octal as shorthand for Binary


binary octal
 Each octal digit corresponds to 3 binary bits

512 1 000 0
Octal 64 (82) 8 (81)
(83) (80)
001 1
512 + 128
1 2 0 7 +7
010 2

011 3
256 16 1
hexadecimal 100 4
(162) (161) (160)
101 256 +5160
1 A F + 15
110 6

To convert a binary string: 10011101010011 111 7


Split into groups of 3:
010 011 101 010 011
2 3 5 2 3
Thus 100111010100112 = 235238

 Similarly with Hexadecimal


To convert a binary string: 10011101010011
Split into groups of 4: 0010 0111 0101 0011
Thus 100111010100112 = ……………16 ?

Binary hex

1000 8

1001 9

1010 A

1011 B
binary Hex
1100 C

0000 0
1101 D

0001 1
1110 E

0010 2
1111 F

0011 3

0100 4

0101 5

0110 6

0111 7

 Colour codes
 You often see hex used in graphic design programs for the red, blue and green
components of a colour, its also known as RGB (Red, Green, Blue)
 Hexadecimal ini sebenarnya bukan sebuah jenis warna. Tapi adalah salah satu cara
penulisan kode warna diantara jenis kode warna lainnya, khususnya untuk halaman web
atau blog . Karena itulah konsep penulisan warna ini disebut dengan istilah Hexa Color
Code, atau disingkat dengan Hexa Code atau Hexa Color saja. Penulisannya
menggunakan angka (dari 0 sampai 9) dan huruf (dari A sampai F). Jumlah kodenya
adalah 6 karakter. Bisa terdiri hanya dari angka saja, huruf saja, atau gabungan dari
keduanya. Lalu sebagai penanda, menggunakan tanda pagar diawalnya. Contoh
penulisannya adalah seperti ini:

#000000 (hanya angka)


#FFFFFF (hanya huruf)
#FF0000 (gabungan angka dan huruf)
 Yang pertama dari contoh diatas, merupakan hexa code dari warna hitam, yang kedua
warna putih dan yang ketiga warna merah. Begitulah seterusnya cara penulisan warna
pada halaman web dengan menggunakan hexa code, dengan jumlah warna hingga
belasan juta.

Lalu apa arti dari struktur kode warna tesebut?


 Tanda pagar adalah penanda atau aturan cara penulisan untuk kode warna hexa. Sedang
keenam karakter yang mengikutinya, merupakan konversi dari sistem RGB menjadi
bilangan decimal (baca Apa Itu Warna RGB). 2 Karakter pertama, adalah kode untuk
varian warna RED, sedang 2 karakter kedua, kode warna untuk varian GREEN dan 2
karakter terakhir untuk varian warna BLUE.

 Jadi keenam kode warna diatas, sebenarnya kata lain dari percampuran warna. Dalam hal
ini pencampuran warna merah dengan hijau dan biru (RGB), dengan menggunakan
komposisi atau takaran tertentu. Hasil akhirnya, akan berbeda tergantung berapa
komposisi dari masing-masing warna yang digunakan. Hanya saja disini yang dicampur
bukan cat atau zat warna. Tapi hanya dalam bentuk bit dan pixels, yang ditulis dalam
bentuk kode-kode. Ibaratnya, anda sedang mencampur warna secara digital, yang
kanvasnya adalah layar atau screen monitor. Karena itu anda bisa gonta ganti keenam
warna tersebut dengan kode apa saja, lalu lihat hasilnya menjadi warna apa. Yang penting
tidak keluar dari aturan dasar kode yang boleh digunakan, yaitu dengan angka 0-9 dan
huruf A-F. Lalu diawalnya tambahkan tanda pagar
 Berikut adalah daftar lengkap table warna Colour Codes:
o FF0000 represents red, for example.
o How many bits are used to represent each colour?
o How many different colours can be represented?

 Characters
– Three main coding schemes used: ASCII (widespread use), EBCDIC (not used
often) and UNICODE (new)
– ASCII table (in hex) :
00 01 02 03 04 05 06 07 08 09 0a 0b 0c 0d 0e 0f
nul soh sot etx eot enq ack bel bs ht nl vt np cr so si
10 11 12 13 14 15 16 17 18 19 1a 1b 1c 1d 1e 1f
dle dc1 dc2 dc3 dc4 nak syn etb can em sub esc fs gs rs us
20 21 22 23 24 25 26 27 28 29 2a 2b 2c 2d 2e 2f
sp ! " # $ % & ' ( ) * + , - . /
30 31 32 33 34 35 36 37 38 39 3a 3b 3c 3d 3e 3f
0 1 2 3 4 5 6 7 8 9 : ; < = > ?
40 41 42 43 44 45 46 47 48 49 4a 4b 4c 4d 4e 4f
@ A B C D E F G H I J K L M N O
50 51 52 53 54 55 56 57 58 59 5a 5b 5c 5d 5e 5f
P Q R S T U V W X Y Z [ \ ] ^ _
60 61 62 63 64 65 66 67 68 69 6a 6b 6c 6d 6e 6f
` a b c d e f g h i j k l m n o
70 71 72 73 74 75 76 77 78 79 7a 7b 7c 7d 7e 7f
p q r s t u v w x y z { } ~ del
 Gray Codes

 Gambaran umum Gray Code?

Gray code merupakan cerminan dari binary code (kode biner), yang artinya angka terkhir pada string dapat sama
dengan angka awal.tetap dalam urutan terbalik,sehingga dapat memungkinkan untuk membangun dan
meningkatkan kegunaan dari kode biner standar atau natural. FRANK GRAY ,peneliti Bell labs,dimana nama
belakangnya digunakan (Grey Code) ,mengembangkan sistem bilangan biner ini untuk membantu mengontrol
electromechanical switch. Saat ini, Grey code digunakan untuk berbagai macam Environment, terutama pada
komunikasi digital dimana sinyal analog perlu diubah menjadi media digital.

 Apa itu Gray Code?

Gray code merupakan bentuk biner yang menggunakan metode yang berbeda dari incrementing dari nomor satu
ke berikutnya. Dengan gray code, hanya terdapat satu perubahan keadaan dari satu posisi ke posisi lainnya. Fitur
ini memungkinkan perancang sistem untuk melakukan beberapa pengecekan error (yaitu jika lebih dari satu bit
perubahan, data harus salah). Berikut adalah tabel perbedaan antara biner asli dengan gray code:

 Mengapa perlu digunakan Gray Code?

Kode Gray merupakan encoder mutlak yang paling popular outputan jenisnya, karena penggunaannya
mencegah data tertentu mengalami kesalahan yang dapat terjadi dengan biner asli selama perubahan
keadaan sirkuit (atau respon sistem lesu), sebuah biner asli keadaan perubahan 0011-0100 dapat menyebabkan
konter / PLC untuk melihat 0111. Kesalahan semacam ini kesalahan adalah tidak mungkin dengan apabila
menggunakan Kode Gray, sehingga data tersebut dapat lebih dapat diandalkan.

Dalam table 2 di bawah ini, perhatikan bahwa dari posisi 7-8, gray code hanya berubah dengan sedikit keadaan
.

 cara mengkonversikan decimal ke biner :

example 1 :
Bilangan desimal
1. 260 ( jadikan ke biner )
o cari bilangan terdekat dengan 260
o lalu sisa juga.

1 0 0 0 0 0 1 0 1

512 256 128 64 32 16 8 4 2 1

jadi : 101000001
 cara mengkonversikan Binary Code ke Gray Code?
example :
Bilangan Biner
101000001 ( jadikan ke gray )
o caranya tambahkan angka sebelah kiri dengan seterusnya.
biner gray keterangan
101000001 MSB

(1+0)1000001 1 1+0=1
1(0+1)000001 10 0+1=1
10(1+0}00001 101 1+0=1
101(0+0)0001 1010 0+0=0
1010(0+0)001 10100 0+0=0
10100(0+0)01 101001 0+0=1
101000(0+0)1 1010011 0+0=0
1010000(0+1) 10100111 0+1=1

jadi desimal > biner > gray :

10100111
examples 2:
84, 84375 ( jadikan desimal > biner )
o caranya 84 dahulu di kerjakan baru 0,84375
o setelah itu hasilnya di gabungkan.
kerjakan dahulu 84, setelah itu dibagi dengan 2
= 42 = 0
maka hasil (84) desimal > biner adalah 1010100

= 21 = 0

= 10 = 1

= 5 =0

= 2 =1

= 1 =0
= 0,5= 1
kemudian 0,84375 dikali dengan 2
0,84375
2 = 1,6875 maka hasil (0,84375) desimal > biner adalah 11011

0,6875 2 = 1,375
0,375 2 = 0,75 Maka hasil (84,84375) adalah 1010100,11011
0,75 2 = 1,5
0,5 2=1
Dari hasil biner (1010100,11011) jadikan ke gray.
Tab I
biner gray keterangan
1010100 MSB

(1+0)10100 0 1+0=1
1(0+1)0100 01 0+1=1
10(1+0}100 011 1+0=1
101(0+1)00 0111 0+1=1
1010(1+0)0 01111 1+0=1
10101(0+0) 011111 0+0=0
Tab II
biner gray keterangan
11011 MSB

(1+1)011 1 1+1=0
1(1+0)11 1 1+0=1
11(0+1}100 111 0+1=1
1010(1+0)0 1010 1+0=1
10101(0+0) 10100 0+0=0

Maka hasil biner (1010100,11011) adalah 011111,0110


• Other codes exist for specific purposes
• Gray codes provide a sequence where only one bit changes for each increment
• Allows increments without ambiguity due to bits changing at different times.
– E.g. changing from 3 to 4, normal binary has all three bits changing 011 ->
100. Depending on the order in which the bits change any intermediate value
may be created.

Dec Gray

0 000

1 001

2 011

3 010

4 110

5 111

6 101

7 100

 Konversi Biner ke kode Grey :


Caranya adalah dengan menambahkan angka paling depan ke belakang.

contoh 1 : konversikan 0010(2) =............(Grey code)


catatan :
0 0
0 exor 0 = 0
0 exor 1 = 1
1 Exor 0 = 1 angka ke-empat

hasil konversi 0010(2) = 0011(Grey code)


contoh 2 : konversikan 1111(2) =.1000 (Grey code)

 Konversi Grey code ke Biner :

Caranya dengan menambahkan angka paling depan ke belakang, setelah mendapat hasilnya
ditambahkan ke belakang lagi.
contoh 1 : konversikan 1000(Grey code) =............(2)
1 exor 0 = 1
1 exor 0 = 1
1 exor 0 = 1
1 exor 0 = 1

hasil konversi 1000(Grey code) = 1111(2)

contoh 2 : konversikan 0011(Grey code) =.0010.............(2)


hasil konversi 0011(Gray code) = 0010(2)

 Exercises
• You should practice conversions between binary, octal, decimal and hexadecimal.
• You should be able to code decimal to BCD (and BCD to decimal) and between
binary to gray.
• You should be able to explain and give examples of digital and analogue data.
Sumber:
http://msoffice-blog.blogspot.co.id/2012/07/cara-mengubah-jarak-enter-di-microsoft.html
http://anjees.blogspot.co.id/2010/06/daftar-kode-warna-lengkap.html

You might also like