Save this video free

CE351 lec21 IR transmitting and receiving a message

Yiyan Li · 29:00 · Watch on YouTube

Part of Fort Lewis College CE351. See all 21 lectures and search them

These notes were made with YouTube Collector. Paste any YouTube link and get the same: a summary, chapters and a searchable transcript.

Overview

Yiyan Li explains how an IR message is framed, transmitted, and received using UART, with an additive checksum and a null byte to mark the message end. The message contains placeholder source and destination bytes, typed characters, a null terminator, and a checksum; a receive interrupt copies each incoming byte from UART1's UDR1 register into a memory buffer because UART provides no acknowledgment or flow control.

Key takeaways

Chapters

0:00 Adding an ASCII Checksum to Detect IR Message Errors
4:00 Building a Message with Addresses, Typed Characters, and a Null Byte
12:00 Using Null Termination and UART Receive Interrupts for Message Boundaries
16:00 Separating Message Construction, UART Transmission, and Display
22:00 How the UART1 Receive ISR Copies Bytes into the Buffer

Keep these chapters and the full searchable transcript in your own library.

Transcript excerpt

0:00 and one each time. So the better strategy to do that is having a receiver interrupt. So what's happening is um the receiver is being controlled. Um so whenever one bite is being received it, uh it stored it into something else. You can do it like receiver um or re say receive the message. You have an index over there, right? So every time the interrupt happens, you store whatever in the buffer into this guy and then you do I plus+ okay you probably plus one plus one to it or you can do this. So add a one to I or index. Uh so in that case the next time it interrupts uh there will be a new bite uh in the

0:51 buffer for sure because it only interrupts whenever a bite is received. So everything can be controlled. You're not hopefully you're are not missing anything. Um but there are still cases that you probably will lose a message due to a lot of reasons. For example, the IR is not transmitting reliably for some reason. Um so so in that case uh what we can do is we when you send uh for example multiple characters multiple characters I'm sending a b c d here right. So before I send it, I construct another bite here as a trike bite. Okay. So that number here will be the addition of all the ASI code for example.

1:39 Okay. And and that number will be another another bite to be sent. So you can use that bite as a error checking message. For example, A B CD. We just do a A plus B plus C plus D because characters are being added together. They're actually adding their S code together. You get a summation of A plus B plus C plus D. It's a pretty

This is the start of the transcript. Save this video free for the whole transcript, searchable and time-coded.

In this course

Related notes

Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, Yiyan Li.

Want the full transcript?

Save this video in YouTube Collector to get its complete searchable transcript, your own AI summaries, and a library that keeps every video you collect in one place.