Skip to content
Snippets Groups Projects
register_bit.md 5.88 KiB

Registers

!!! Attention resistor[ruh_zi_str] : electrical component that implements electrical resistance
register[reh_juh_str] : a memory location within the actual processor that work at very fast speeds

n-ary numbers

  • 1 byte = 8 bits = 2^8 = 256 = [7:0]

  • 1 B = 8 b

    JP EN usable 15 255 255
    2進数 Binary 0,1 0b1111 0b11111111 B11111111
    10進数 Decimal 0,1,2,3,4,5,6,7,8,9 0d15    0d255 255
    16進数 Hexadecimal 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F 0xf 0xff $f
  • Ref. 2進数、8進数、10進数、16進数相互変換ツール

!!! Note 1kB = 1 [kilo] byte = 1000 B
1KB = 1 [ke̞ː] byte = 1024 B = 2^10 B = 1KiB = 1 [kibi] byte

1 bps = 1 [bits per second]  

pinout

Datasheet

ATtiny1614

5. I/O Multiplexing and Considerations
5.1 Multiplexed Signals

![](../images/register/PORT_Function _Multiplexing .png)

Pin names are of type Pxn, with x being the PORT instance (A, B) and n the pin number. T``

16 . PORT - I/O Pin Configuration
16.1 Features
General Purpose Input and Output Pins with Individual Configuration:
– Pull-up

16.2 Overview

The I/O pins of the device are controlled by instances of the PORT peripheral registers. Each PORT instance has up to eight I/O pins. The PORTs are named PORTA, PORTB, PORTC, etc.

Each PORT pin has a corresponding bit in the Data Direction (PORTx.DIR) and Data Output Value (PORTx.OUT) registers to enable that pin as an output and to define the output state. For example, pin PA3 is controlled by DIR[3] and OUT[3] of the PORTA instance.

16.4 Register Summary - PORTx

16.5.1 Data Direction

Name: DIR
This bit field controls the output driver for each PORTx pin.

Value Description
0 Pxn is configured as an input-only pin, and the output driver is disabled
1 Pxn is configured as an output pin, and the output driver is enabled