2023-03-10 (F) Weekly Summary

I integrated an Arduino library that measures clock jitter to generate random numbers. The process could be faster, but it does a masterful job of seeding the controller's rand() function. I ran the program and took a screenshot to show that the program starts with unique numbers each time, but before the library, they were identical.
Entropy library ensuring different starting points

mode2() played multiple instruments simultaneously by utilizing fifteen MIDI channels. I moved the pitch controllers from encoders at the bottom to potentiometers at the top. I created an array to hold the relevant data, like channel, note, velocity, probability, and offset. I also figured out a tidy method to sustain channel notes until the next one played, even if other channels were active, significantly improving the cohesion between different instruments.
Three instruments playing in mode2

I powered up the equalizer with an external battery todampen the signal enough that an iPhone could record a clip. I also tested the power running from the battery to the Arduino, which checked out. I extracted the audio and uploaded it to GitHub to embed it into this page.
Sixty-second clip

I planned and programmed mode2(), but I should have paid more attention to a few things in the first round. Some of my notes hung, and every channel played a Grand Piano (MIDI instrument #0). I fixed the problems and recorded a video demonstrating all the current modes.
(1:07) mode2() with four instruments

I repaired some minor problems with the then moved onto mode3(), which will be percussion. I spent significant time planning it on paper and implementing it in code. The machine played some notes but it was not the loop I expected. I printed the table, which looked correct, but it bears investigating.
Percussion table

I forgot to use a counter that would step through the tracks, so I implemented one, and the notes played well. I cleaned up other issues with the code, but mostly ways to stop sounds from hanging. I wrote a list of percussion instruments I want to avoid appearing in prandomly generated arrangements and wrote a check to play drums instead.
Code and serial data

The rest of the summary posts have been arranged by date.
First time here?

Completed projects from year 1
Completed projects from year 2
Completed projects from year 3
Completed projects from year 4
Completed projects from year 5
Completed projects from year 6
Completed projects from year 7
Completed projects from year 8

Disclaimer for http://24hourengineer.blogspot.com and 24HourEngineer.com

This disclaimer must be intact and whole. This disclaimer must be included if a project is distributed.

All information on this blog, or linked by this blog, is not to be taken as advice or solicitation. Anyone attempting to replicate, in whole or in part, is responsible for the outcome and procedure. Any loss of functionality, money, property, or similar, is the responsibility of those involved in the replication.

All digital communication regarding the email address 24hourengineer@gmail.com becomes the intellectual property of Brian McEvoy. Any information contained within these messages may be distributed or retained at the discretion of Brian McEvoy. Any email sent to this address, or any email account owned by Brian McEvoy, cannot be used to claim property or assets.

Comments to the blog may be utilized or erased at the discretion of the owner. No one posting may claim property or assets based on their post.

This blog, including pictures and text, is copyright to Brian McEvoy.