// File: /workspace/github_c_makefile_star2_O0/dcat[P]mdphat/mdphat.c
// Function: main
int
main(int argc, char **argv) {
	int i;
	int rflag = 0;
	int hflag = 0;
	int iflag = 0;
	char *argv0;
	char line[8];

	d = open(I2C_DEV, O_RDWR);
	if (d < 0)
		err(1, "open '%s'", I2C_DEV);

	reset();
	i2c_set_all(CMD_MODE, DEFAULT_MODE);

	ARGBEGIN {
	case 'r':
		rflag = 1;
		break;
	case 'h':
		hflag = 1;
		break;
	case 'i':
		iflag = 1;
		break;
	case 'b':
		brightness(atoi(ARGF()));
		break;
	} ARGEND

	if (!iflag) {
		while (*argv)
			printstring(*argv++);
	} else {
		while (fgets(line, 8, stdin)) {
			clear();
			printstring(line);
			update();
		}
	}

	update();

	if (hflag) {
		getchar();
		rflag = 1;
	}

	if (rflag)
		reset();

	close(d);
	return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl $0x0, -0x18(%rbp)
movl $0x0, -0x1c(%rbp)
movl $0x0, -0x20(%rbp)
leaq 0x97506(%rip), %rdi     # 0x499048
movl $0x2, %esi
movb $0x0, %al
callq 0x448f50
movl %eax, 0x1394fc(%rip)    # 0x53b050
cmpl $0x0, 0x1394f5(%rip)    # 0x53b050
jge 0x401b77
movl $0x1, %edi
leaq 0x974ea(%rip), %rsi     # 0x499053
leaq 0x974d8(%rip), %rdx     # 0x499048
movb $0x0, %al
callq 0x44b4e0
callq 0x401a80
xorl %edi, %edi
movl $0x18, %esi
callq 0x401a10
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
movl -0x8(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x8(%rbp)
movq -0x10(%rbp), %rcx
xorl %eax, %eax
cmpq $0x0, (%rcx)
movb %al, -0x45(%rbp)
je 0x401bdf
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl 0x1(%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x45(%rbp)
je 0x401bdf
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl (%rax), %eax
cmpl $0x2d, %eax
sete %al
movb %al, -0x45(%rbp)
movb -0x45(%rbp), %al
testb $0x1, %al
jne 0x401beb
jmp 0x401d8b
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl 0x1(%rax), %eax
cmpl $0x2d, %eax
jne 0x401c25
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl 0x2(%rax), %eax
cmpl $0x0, %eax
jne 0x401c25
movq -0x10(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
movl -0x8(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x401d8b
movl $0x0, -0x44(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
movq -0x10(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl (%rax), %ecx
xorl %eax, %eax
cmpl $0x0, %ecx
movb %al, -0x46(%rbp)
je 0x401c62
cmpl $0x0, -0x44(%rbp)
setne %al
xorb $-0x1, %al
movb %al, -0x46(%rbp)
movb -0x46(%rbp), %al
testb $0x1, %al
jne 0x401c6e
jmp 0x401d6f
movq -0x40(%rbp), %rax
cmpq -0x10(%rbp), %rax
je 0x401c7d
jmp 0x401d6f
movq -0x10(%rbp), %rax
movq (%rax), %rax
movb (%rax), %al
movb %al, -0x31(%rbp)
movsbl -0x31(%rbp), %eax
addl $-0x62, %eax
movl %eax, %ecx
movq %rcx, -0x50(%rbp)
subl $0x10, %eax
ja 0x401d5a
movq -0x50(%rbp), %rax
leaq 0x9735a(%rip), %rcx     # 0x499004
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movl $0x1, -0x18(%rbp)
jmp 0x401d5a
movl $0x1, -0x1c(%rbp)
jmp 0x401d5a
movl $0x1, -0x20(%rbp)
jmp 0x401d5a
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl 0x1(%rax), %eax
cmpl $0x0, %eax
jne 0x401cfa
movq -0x10(%rbp), %rax
cmpq $0x0, 0x8(%rax)
jne 0x401cfa
xorl %eax, %eax
movq %rax, -0x58(%rbp)
jmp 0x401d4a
movl $0x1, -0x44(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movsbl 0x1(%rax), %eax
cmpl $0x0, %eax
je 0x401d22
movq -0x10(%rbp), %rax
movq (%rax), %rax
addq $0x1, %rax
movq %rax, -0x60(%rbp)
jmp 0x401d42
movl -0x8(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x8(%rbp)
movq -0x10(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rax
movq (%rax), %rax
movq %rax, -0x60(%rbp)
movq -0x60(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rdi
callq 0x40a600
movl %eax, %edi
callq 0x401ae0
jmp 0x401d5c
movq -0x10(%rbp), %rax
movq (%rax), %rcx
addq $0x1, %rcx
movq %rcx, (%rax)
jmp 0x401c42
jmp 0x401d71
movl -0x8(%rbp), %eax
addl $-0x1, %eax
movl %eax, -0x8(%rbp)
movq -0x10(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x10(%rbp)
jmp 0x401ba8
cmpl $0x0, -0x20(%rbp)
jne 0x401db8
jmp 0x401d93
movq -0x10(%rbp), %rax
cmpq $0x0, (%rax)
je 0x401db6
movq -0x10(%rbp), %rax
movq %rax, %rcx
addq $0x8, %rcx
movq %rcx, -0x10(%rbp)
movq (%rax), %rdi
callq 0x4019b0
jmp 0x401d93
jmp 0x401def
jmp 0x401dba
leaq -0x30(%rbp), %rdi
movq $0x539458, %rax         # imm = 0x539458
movq (%rax), %rdx
movl $0x8, %esi
callq 0x40cb50
cmpq $0x0, %rax
je 0x401ded
callq 0x401aa0
leaq -0x30(%rbp), %rdi
callq 0x4019b0
callq 0x401a60
jmp 0x401dba
jmp 0x401def
callq 0x401a60
cmpl $0x0, -0x1c(%rbp)
je 0x401e06
callq 0x40f010
movl $0x1, -0x18(%rbp)
cmpl $0x0, -0x18(%rbp)
je 0x401e11
callq 0x401a80
movl 0x139239(%rip), %edi    # 0x53b050
callq 0x4491f0
xorl %eax, %eax
addq $0x60, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
nop