Intro to Computer Engineering

Week 4 Prep

Java - Arduino Communication

The focus of this module is communication between the Arduino and Java, which will require that we think carefully about how the data are represented. We will send data from the PC to the Arduino. With this functionality, we’ll be able to control our circuits from the PC side - a very useful tool.

We will be using the Java Simple Serial Connector (jSSC) library for serial communications. A local copy of the JavaDoc for the library can be found here.

========

Text

Read Chapter 12 in the course text.

Note, this chapter is only in draft form, meaning there is lots of information that is helpful to you in completing this week’s activities, but don’t consider it complete by any means.

========

Some Review

Video Description
Text Representation You saw this video earlier in the semester, but we’ll be using more text in this module, so it would be a good idea to review these concepts.
NOTE: This video indicates that ‘A’ is represented as 0x40 and ‘a’ is represented as 0x60 in ASCII. They are actually 0x41 and 0x61, respectively.
Hexadecimal We first introduced you to hexadecimal in week 1, but we’ll be relying on it more and more in the next few modules, so be sure you understand this concept.

========

Input Streams

The following videos are very helpful in understanding how to read user input from the console in Java.

Video Description
Java Input Streams In this video we’ll discuss how to use input streams to grab information from the user.
Validating Input The data you receive from your users may not be what you were expecting. This video will give some tips about what to do when that happens.

Guide to SerialComm

This guide gives some help on how to use the serial communication libraries in Java.

Generated at 2022-07-20 19:49:20 +0000.
Page written by Doug Shook.