	.file	"23576639.c"
	.intel_syntax noprefix
	.text
	.section	.rodata
.LC0:
	.string	"/dev/ttyACM0"
.LC1:
	.string	"Error opening the port!!!"
.LC2:
	.string	"port opened succesfully"
.LC3:
	.string	"ERROR ! in Setting attributes"
.LC4:
	.string	"Stop bits: %b"
.LC5:
	.string	"Bytes received: %d\n"
	.align 8
.LC6:
	.string	"\n-------------------------------------------------------------------------"
	.text
	.globl	main
	.type	main, @function
main:
.LFB0:
	.cfi_startproc
	endbr64
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rsp
	.cfi_def_cfa_register 6
	sub	rsp, 144
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR -8[rbp], rax
	xor	eax, eax
	lea	rax, .LC0[rip]
	mov	QWORD PTR -128[rbp], rax
	mov	rax, QWORD PTR -128[rbp]
	mov	esi, 258
	mov	rdi, rax
	mov	eax, 0
	call	open@PLT
	mov	DWORD PTR -136[rbp], eax
	cmp	DWORD PTR -136[rbp], 0
	jns	.L2
	lea	rax, .LC1[rip]
	jmp	.L3
.L2:
	lea	rax, .LC2[rip]
.L3:
	mov	QWORD PTR -120[rbp], rax
	mov	rax, QWORD PTR -120[rbp]
	mov	rdi, rax
	call	puts@PLT
	lea	rdx, -112[rbp]
	mov	eax, DWORD PTR -136[rbp]
	mov	rsi, rdx
	mov	edi, eax
	call	tcgetattr@PLT
	lea	rax, -112[rbp]
	mov	esi, 13
	mov	rdi, rax
	call	cfsetispeed@PLT
	lea	rax, -112[rbp]
	mov	esi, 13
	mov	rdi, rax
	call	cfsetospeed@PLT
	mov	eax, DWORD PTR -104[rbp]
	and	ah, -2
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -104[rbp]
	and	eax, -65
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -104[rbp]
	and	eax, -49
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -104[rbp]
	or	eax, 48
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -104[rbp]
	and	eax, 2147483647
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -104[rbp]
	or	eax, 2176
	mov	DWORD PTR -104[rbp], eax
	mov	eax, DWORD PTR -112[rbp]
	and	ah, -29
	mov	DWORD PTR -112[rbp], eax
	mov	eax, DWORD PTR -112[rbp]
	and	eax, -28
	mov	DWORD PTR -112[rbp], eax
	mov	eax, DWORD PTR -108[rbp]
	and	eax, -2
	mov	DWORD PTR -108[rbp], eax
	mov	BYTE PTR -89[rbp], 10
	mov	BYTE PTR -90[rbp], 0
	lea	rdx, -112[rbp]
	mov	eax, DWORD PTR -136[rbp]
	mov	esi, 0
	mov	edi, eax
	call	tcsetattr@PLT
	test	eax, eax
	je	.L4
	lea	rdi, .LC3[rip]
	mov	eax, 0
	call	printf@PLT
	jmp	.L5
.L4:
	mov	esi, -65
	lea	rdi, .LC4[rip]
	mov	eax, 0
	call	printf@PLT
.L5:
	mov	eax, DWORD PTR -136[rbp]
	mov	esi, 0
	mov	edi, eax
	call	tcflush@PLT
	lea	rcx, -48[rbp]
	mov	eax, DWORD PTR -136[rbp]
	mov	edx, 32
	mov	rsi, rcx
	mov	edi, eax
	call	read@PLT
	mov	DWORD PTR -132[rbp], eax
	mov	eax, DWORD PTR -132[rbp]
	mov	esi, eax
	lea	rdi, .LC5[rip]
	mov	eax, 0
	call	printf@PLT
	mov	DWORD PTR -140[rbp], 0
	jmp	.L6
.L7:
	mov	eax, DWORD PTR -140[rbp]
	movzx	eax, BYTE PTR -48[rbp+rax]
	movsx	eax, al
	mov	edi, eax
	call	putchar@PLT
	add	DWORD PTR -140[rbp], 1
.L6:
	mov	eax, DWORD PTR -140[rbp]
	cmp	eax, DWORD PTR -132[rbp]
	jb	.L7
	lea	rdi, .LC6[rip]
	call	puts@PLT
	mov	eax, DWORD PTR -136[rbp]
	mov	edi, eax
	call	close@PLT
	mov	eax, 0
	mov	rcx, QWORD PTR -8[rbp]
	sub	rcx, QWORD PTR fs:40
	je	.L9
	call	__stack_chk_fail@PLT
.L9:
	leave
	.cfi_def_cfa 7, 8
	ret
	.cfi_endproc
.LFE0:
	.size	main, .-main
	.ident	"GCC: (Ubuntu 10.5.0-1ubuntu1~20.04) 10.5.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 6
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"23576639.c"
	.text
	.section	.rodata
	.align	2
.LC0:
	.ascii	"/dev/ttyACM0\000"
	.align	2
.LC1:
	.ascii	"Error opening the port!!!\000"
	.align	2
.LC2:
	.ascii	"port opened succesfully\000"
	.align	2
.LC3:
	.ascii	"ERROR ! in Setting attributes\000"
	.align	2
.LC4:
	.ascii	"Stop bits: %b\000"
	.align	2
.LC5:
	.ascii	"Bytes received: %d\012\000"
	.align	2
.LC6:
	.ascii	"\012-----------------------------------------------"
	.ascii	"--------------------------\000"
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	main
	.syntax unified
	.arm
	.fpu softvfp
	.type	main, %function
main:
	@ args = 0, pretend = 0, frame = 120
	@ frame_needed = 1, uses_anonymous_args = 0
	push	{fp, lr}
	add	fp, sp, #4
	sub	sp, sp, #120
	ldr	r3, .L10
	ldr	r3, [r3]
	str	r3, [fp, #-8]
	mov	r3,#0
	ldr	r3, .L10+4
	str	r3, [fp, #-116]
	ldr	r1, .L10+8
	ldr	r0, [fp, #-116]
	bl	open
	str	r0, [fp, #-112]
	ldr	r3, [fp, #-112]
	cmp	r3, #0
	bge	.L2
	ldr	r3, .L10+12
	b	.L3
.L2:
	ldr	r3, .L10+16
.L3:
	str	r3, [fp, #-108]
	ldr	r0, [fp, #-108]
	bl	puts
	sub	r3, fp, #100
	mov	r1, r3
	ldr	r0, [fp, #-112]
	bl	tcgetattr
	sub	r3, fp, #100
	mov	r1, #13
	mov	r0, r3
	bl	cfsetispeed
	sub	r3, fp, #100
	mov	r1, #13
	mov	r0, r3
	bl	cfsetospeed
	ldr	r3, [fp, #-92]
	bic	r3, r3, #256
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-92]
	bic	r3, r3, #64
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-92]
	bic	r3, r3, #48
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-92]
	orr	r3, r3, #48
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-92]
	bic	r3, r3, #-2147483648
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-92]
	orr	r3, r3, #2176
	str	r3, [fp, #-92]
	ldr	r3, [fp, #-100]
	bic	r3, r3, #7168
	str	r3, [fp, #-100]
	ldr	r3, [fp, #-100]
	bic	r3, r3, #27
	str	r3, [fp, #-100]
	ldr	r3, [fp, #-96]
	bic	r3, r3, #1
	str	r3, [fp, #-96]
	mov	r3, #10
	strb	r3, [fp, #-77]
	mov	r3, #0
	strb	r3, [fp, #-78]
	sub	r3, fp, #100
	mov	r2, r3
	mov	r1, #0
	ldr	r0, [fp, #-112]
	bl	tcsetattr
	mov	r3, r0
	cmp	r3, #0
	beq	.L4
	ldr	r0, .L10+20
	bl	printf
	b	.L5
.L4:
	mvn	r1, #64
	ldr	r0, .L10+24
	bl	printf
.L5:
	mov	r1, #0
	ldr	r0, [fp, #-112]
	bl	tcflush
	sub	r3, fp, #40
	mov	r2, #32
	mov	r1, r3
	ldr	r0, [fp, #-112]
	bl	read
	mov	r3, r0
	str	r3, [fp, #-104]
	ldr	r1, [fp, #-104]
	ldr	r0, .L10+28
	bl	printf
	mov	r3, #0
	str	r3, [fp, #-120]
	b	.L6
.L7:
	sub	r2, fp, #40
	ldr	r3, [fp, #-120]
	add	r3, r2, r3
	ldrb	r3, [r3]	@ zero_extendqisi2
	mov	r0, r3
	bl	putchar
	ldr	r3, [fp, #-120]
	add	r3, r3, #1
	str	r3, [fp, #-120]
.L6:
	ldr	r2, [fp, #-120]
	ldr	r3, [fp, #-104]
	cmp	r2, r3
	bcc	.L7
	ldr	r0, .L10+32
	bl	puts
	ldr	r0, [fp, #-112]
	bl	close
	mov	r3, #0
	ldr	r2, .L10
	ldr	r1, [r2]
	ldr	r2, [fp, #-8]
	eors	r1, r2, r1
	mov	r2, #0
	beq	.L9
	bl	__stack_chk_fail
.L9:
	mov	r0, r3
	sub	sp, fp, #4
	@ sp needed
	pop	{fp, pc}
.L11:
	.align	2
.L10:
	.word	.LC7
	.word	.LC0
	.word	258
	.word	.LC1
	.word	.LC2
	.word	.LC3
	.word	.LC4
	.word	.LC5
	.word	.LC6
	.size	main, .-main
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
