; Hauptinitroutine oled_init: ; Folge von Kommandos senden (Beispielwerte für SSD1306) ldi r16, 0xAE ; DISPLAY_OFF rcall oled_send_command ldi r16, 0xD5 ; SET_DISPLAY_CLOCK_DIV rcall oled_send_command ldi r16, 0x80 ; CLOCK_DIV_VALUE rcall oled_send_command ldi r16, 0xA8 ; SET_MULTIPLEX rcall oled_send_command ldi r16, 0x3F ; MUX_RATIO 64 rcall oled_send_command ldi r16, 0xD3 ; SET_DISPLAY_OFFSET rcall oled_send_command ldi r16, 0x00 ; OFFSET 0 rcall oled_send_command ldi r16, 0x40 ; SET_START_LINE rcall oled_send_command ldi r16, 0x8D ; CHARGE_PUMP rcall oled_send_command ldi r16, 0x14 ; Enable Charge Pump rcall oled_send_command ldi r16, 0x20 ; MEMORY_MODE rcall oled_send_command ldi r16, 0x00 ; Horizontal Addressing rcall oled_send_command ldi r16, 0xA1 ; SEG_REMAP rcall oled_send_command ldi r16, 0xC8 ; COM_SCAN_DEC rcall oled_send_command ldi r16, 0xDA ; SET_COM_PINS rcall oled_send_command ldi r16, 0x12 ; COM_PINS_HW_CFG rcall oled_send_command ldi r16, 0x81 ; SET_CONTRAST rcall oled_send_command ldi r16, 0xCF ; CONTRAST_VALUE rcall oled_send_command ldi r16, 0xD9 ; SET_PRECHARGE rcall oled_send_command ldi r16, 0xF1 ; PRECHARGE_VALUE rcall oled_send_command ldi r16, 0xDB ; SET_VCOM_DETECT rcall oled_send_command ldi r16, 0x40 ; VCOM_DETECT_VALUE rcall oled_send_command ldi r16, 0xA4 ; DISPLAY_ALL_ON_RESUME rcall oled_send_command ldi r16, 0xA6 ; NORMAL_DISPLAY rcall oled_send_command ldi r16, 0xAF ; DISPLAY_ON rcall oled_send_command ret ________________________________________