Winter Logger

One of the (many) weird quirks of studying in the University of Cambridge is that our terms only last 8 weeks. Yes, the number of days we are officially “studying” is less than the number of days we are ostensibly on “holiday”. Of course, it never works that way, and Cambridge is probably one of the only places where going to uni feels exactly like going to secondary school. Over these long break, we are told that our rooms are going to be used for conference purposes, and that we would have to move all our stuff out to a tiny, cramped storage container....

January 30, 2023 · 20 min · Infinus

STM32 MIDI Controller Part 7: The software

Finally, we are at the end of this series, where I am going to give an overview of the software behind all the menu system and of course, all the handling of user inputs and sending of MIDI messages. We’ve spent so much time configuring the various peripherals and writing driver code to abstract away the nitty-gritty implementation stuff, this is where it all comes together! For the project files, do check out the Github repo....

July 6, 2021 · 24 min · Infinus

How to Use I2C EEPROM with Arduino

First off, there are already a whole bunch of tutorials on how to use this particular I2C EEPROM with an Arduino. If you want to understand how such an EEPROM works, this post is not for you. I just wanted to share this bit of code with anyone who doesn’t feel like writing their own. It basically allows you to select an EEPROM address and specify a payload to be written to that particular address....

November 5, 2020 · 2 min · Infinus

Using Hardware Serial with the HC-05 Bluetooth Module

I recently ran into an interesting issue developing my dawn simulator lamp (full project details coming soon): the HC-05 module I was going to use really didn’t play nice with the hardware UART peripheral on the Arduino Nano. Why not use software serial like the countless other tutorials on the HC-05 on the Internet suggest, you may ask. Well, its because this project uses WS2812B LEDs, which are a real pain when you have to do multiple things that require precise timing (both RS232 and the WS2812B’s communication protocol are asynchronous) on something like an Arduino Nano, which isn’t particularly fast, has limited peripherals, doesn’t have a DMA… you get the idea....

September 30, 2020 · 3 min · Infinus

How to Serial.read() Multiple Bytes on Arduino

Have you ever tried to Serial.read() multiple bytes successively with an Arduino, only to have it spit out a bunch of 0xFF or similar nonsense? I sure have. Check out this section of code from my mood light project: uint8_t cmd = Serial.read(); 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 //other stuff here else if (cmd == 0xcc) { //set color currR = Serial....

September 30, 2020 · 2 min · Infinus