Cousteau CORE0858Abdoul BahJiayeChen
Published

Embedded Systems Clock

This project features a real time clock using 7-segment displays. The clock is initialized using Bluetooth and driven using UART.

IntermediateShowcase (no instructions)Over 1 day45
Embedded Systems Clock

Things used in this project

Hardware components

MSP-EXP432P401R SimpleLink MSP432 LaunchPad
Texas Instruments MSP-EXP432P401R SimpleLink MSP432 LaunchPad
×1
HM-10 BLE
×1
Custom PCB
×1
SparkFun 7-Segment Serial Display - Red
SparkFun 7-Segment Serial Display - Red
×1

Software apps and online services

LightBlue Explorer
Punch Through LightBlue Explorer
Autodesk Eagle

Hand tools and fabrication machines

Laser cutter (generic)
Laser cutter (generic)

Story

Read more

Custom parts and enclosures

Custom laser cut box schematic

We used the website Makerbox to easily create a dxf file which we were able to send to a laser cutter to create a wood box to house the clock.

Schematics

PCB Layout

We created our PCB in Eagle and had it manufactured by Advanced Circuits

Circuit Diagram

7-segment display UART driver diagram

HM-10 Bluetooth board UART driver

Logic analyzer debugging of UART communication

This picture is of a waveform captured by the logic analyzer while using an arduino for testing purposes. Here, we modified some example code from the internet and made the sparkfun board display the kind of value (“1202”) that we will need to display for our clock. At first we were confused about why the wave forms do not seem to match the binary representations of each number, however, we realized that the waveform is the binary representation of the ASCII value of each character or number. In our actual project, the MSP432 sends hex values.

Using the MSP432 debugger

One of the most useful methods of debugging our project was using the built in debugger on the MSP432. Each time we ran our code, we were able to check the registers on the MSP432 to make sure that they actually got configured correctly. There were definitely a few times when we checked the registers through the debugger and found that they were not configured correctly. For example, when we wanted in enable interrupts for each of our UART communication peripherals, we saw that the IE (interrupt enable) register had not changed after running the code ( featured in the pictured below). This surprised us because we had written the line of code correctly, however, we found that it was necessary to move this line of code outside of the block where the SWRST register is set. Looking back at the technical reference manual, this change made sense because it specified that one should enable interrupts after resetting SWRST. Another example of the debugger revealing a simple problem was when we checked the registers corresponding to the UART communication with the HM-10. The Bluetooth connection had not been working and when we checked the registers associated with this communication, we found that none of them had been configured. We quickly realized that we had not called the function that configures these registers in our main function, and as soon as we called it, the Bluetooth connection worked. The ability to easily check how the registers on the MSP432 are configured made it easy to debug our project.

Code

Github

Credits

Cousteau CORE0858

Cousteau CORE0858

1 project • 0 followers
Abdoul Bah

Abdoul Bah

1 project • 0 followers
JiayeChen

JiayeChen

1 project • 0 followers

Comments

Add projectSign up / Login