12/9/29 Gakken Updates


Surprisingly, Gakken is continuing to add updates to their Facebook page.

First up: A belated announcement of the release of the first issue in the new Science Life series: Evolution of Stars, Galaxies and the Universe. The mook came out on Sept. 18, with a cover price of 2,100 yen ($25 USD), but Gakken didn’t officially announce it on Facebook until the 26th. 144 pages. I’ve seen it at the bookstore in Maruya Gardens, in the science magazines section, and it does look good, with tons of glossy photos and various professors from Tokyo University talking about theory and what’s been measured so far. I’ll buy a copy when the amount of work I have right now tapers off and I can take the time to really savor it.

Second: The last page of the Evolution of Stars mook contains a “Coming Next” ad, (it’s also at the bottom of the vol. 1 Science Life webpage) which indicates that volume 2 will be about the birth of matter and the universe, with a tentative release date in the first part of December. Also 2,100 yen.

Third: Gakken shared a link to the Open Reel Ensemble/Braun Tube Band Facebook page, to state that they are currently on tour in Europe.

 

Advertisements

Sept. 26 updates


Just a quick status update. The Otona no Kagaku Facebook page has two new comments added. The first is just an announcement stating that Kit #36, the Edison Wax Recorder is now on sale.

The second is the embedded video ad for the magazine, with the text “sound recorded on a candle looks good, try it!”

 

50 Famous People – Souichirou Honda


The 50 Famous People series doesn’t dwell much on Japan’s scientific community. 10 of the 50 are Japanese, and of those, 3 are writers or artists, 2 are warlords or statesmen, 3 are inventor/scientist businessmen, 1 is a solo explorer and the last is the director of the Godzilla movies.  Because I started this blog initially as a review site for the Gakken science kits (and I have an interest in various business practices), I wish that the Famous People series would spend more time on their scientific “local heroes”. We can see a little of them in the textbook sections of these mooks, but not enough to really learn anything about their accomplishments.  And somehow, I’m not expecting a whole lot of scientific theory in the book on Andou Momofuku, inventor of cup ramen.

(All rights belong to their owners. Images used here for review purposes only.)

Souichirou Honda is the founder of Honda Motors, makers of motorcycles, cars, jets and robots. Born in 1906 in Shizuoka (about 100 miles southwest from Tokyo), Soichiro grew up helping his blacksmith father. After finishing school, he went to Tokyo and got an apprenticeship at a garage repairing cars. After a few years, he returned to Shizuoka and opened his own branch of the repair chain, establishing a reputation for being able to repair anything and getting the name “the Edison of Shizuoka”.  He continued working during WW II, but an earthquake destroyed one parts plant and a second was bombed. After the war, the American GHQ had a proscription against Japanese companies making cars, and Honda refused to do work that anyone else could do just as well. After a year, he started making gas engines for powering bicycles. After saturating the market, he and his group, now with 50 people, created Japan’s first real motorcycle. Unfortunately, Honda had no head for business and the company was losing money.  He was introduced to Takeo Fujisawa, who then went on to handle the financial side of Honda Technical Research Institute. Eventually, Honda got to the “big fish in a small pond” stage and wanted to be known as the maker of the world’s fastest bikes. He set his sights on the Isle of Man TT, taking first place in its weightclass after a few years. Afterward, he moved into the automobile and airplane industries (he and his wife both owned pilot’s licenses). He died in 1991 at age 84 from liver disease.

The intro manga starts with Yoichiro, Mami and Merrino visiting Yutako’s family’s go cart track. Daichi is preparing for a race at the track, but he’s so nervous he throws up. Yoichi attempts to enter the race as well, but his bicycle doesn’t qualify as a go cart. Merrino breaks out his giant ladybug, but it’s disqualified for not having tires. Suddenly Yoichi and Daichi get inspired and start welding parts together. In the wrap-up, the ladybug now has a steering bar and a tire on the bottom. The race begins and Yochi is off to a flying start. Literally. Later, when the ladybug lands, Yoichi returns home to discover that Mami and Merrino are watching TV and eating snacks without him.

The main manga is unusual in that there are no flashbacks this time. Drawn by Kusa Shirotsume (Tears to Tiara), the artwork is simple yet detailed. Again, though, the faces have been westernized, with thinner noses, larger eyes and square chins.  It’s not as bad as the Galileo mook, but Honda doesn’t look much like the photos at the time.  The story picks up with Soichiro at age 40, talking to a friend just after WW II. He hasn’t decided what to do next, since his factories were destroyed and the U.S. Army won’t let the Japanese make their own cars again. He flat-out refuses to get back into machine repair because anyone can do that. He spies a piece of metal on the floor of the guy’s house – it’s a heat sink from an American wireless radio and looks like part of a motorcycle engine. This inspires him to start making engines for powering bicycles. A few months later, he’s founded Honda Technical Research and hired a few extra hands. When one of the men states that there aren’t any new customers and suggests making a new product copying the designs of the current one, Honda yells at him. Instead, he draws the design for a new engine on the floor and they go to work on making their first real motorcycle. Soon after, though, yet another customer goes belly up and is unable to pay for their order. Soichiro is in danger of going out of business as well, but a friend introduces him to Fujisawa and the two hit it off immediately. Honda decides that he’s going to put a bike in the Isle of Man TT, but once he’s actually at the race he gets cold feet because of the level of the competition.  This does inspires him, though, and the team spends a few years testing designs on the track. After they do win, Soichiro tries to do the same thing for Formula 1, except that the Japanese government is about to pass a law protecting its existing car manufacturers by preventing any new entrants to the market. Honda goes into a rage and the company works to get a car on the streets before the law takes effect. The manga ends with Honda triumphant with a series of successful products behind him.

The textbook section focuses mainly on Soichiro’s upbringing, work experience, and his teaming up with Fujisawa to make Honda Motors one of the most profitable car companies in the world. There are pictures of old bikes and stills from various races, a photo of Ayrton Senna after winning a race, and shots of Honda at different ages.  Sidebars describe the scars on Soichiro’s hand (from smashing it with a hammer or gouging it with a chisel), his friendship with Fujisawa, and some of Honda Motor’s other products such as a private jet and the Asimo robot. The last 2 pages highlight some of Japan’s other technological achievements, including a new process for making carbon tubes, the first realistic-looking female robot (HRP-4C), an anti-earthquake design where the house rides on an air cushion, the world’s smallest single-person helicopter and Hayabusa.

The TCG cards this time are for: Edmund Cartwright, Thomas Jefferson, Yemelyan Pugachev, Jeremy Bentham, Francisco Goya, Antoine Lavoisier, Charles Maurice de Talleyrand-Perigord, Johann Wolfgang von Goethe and Edward Jenner.

Summary: This mook for Souichirou Honda is a fairly well-drawn, simple overview of his life and the beginnings of Honda Motors. It doesn’t get into any of the details of his engine designs, and definitely ignores his personal and family life. The main impression I get is that he gets angry easily, yelling at people that don’t immediately see things from his point of view. The mook does repeat a couple of his more famous mottos, but there’s no description of his business philosophy (which may be for the best, since he was a better engineer than a businessman). If you’re not familiar with the person, this is as good a way as any to learn a little about him.

There’ll be a break until the next mook I want comes out in October.  There are 18 issues left in the series, but I only care about 6 of them. In the meantime, I hope to get more information to write about regarding the Gakken kits (the Edison wax recorder comes out on the 25th, and I may get it in my hands by the 28th).

Gakken Newsletter #152


Gakken’s Newsletter #152 just arrived in my mailbox. It starts out with the announcement of the 10th Otona no Kagaku Anniversary kit – the Edison Cylinder Recorder – going on sale on the 25th. There’s mentions of stuff that gets described in more detail later in the newsletter, and the ongoing anniversary events that were first announced back in July, including the big one at Culture Culture on Oct. 20th.

Item 1) The next kit, the Edison Wax Cylinder Recorder, is being packaged as the Special 10th Anniversary kit. Along with the recorder, which is similar to the earlier plastic cup premium kit, there are several articles in the mook that tie into the anniversary theme, like a photo essay on mods readers have made to past kits, and interviews with various famous contributors to Gakken’s suggested mods sections.

Youtube video ad

Item 2) Earlier this month, Gakken released a new line, called Science Life. The first mook is The Evolution of the Stars, Galaxy and Universe. 144 pages, 2,800 yen. The premise is to present cutting edge science and foundational knowledge pictorially in a way that will appeal to everyone. Mook one was developed with the assistance of the entire Tokyo University science department.

Item 3) Girl’s craft kits series. This section is just describes the 2 existing kits:
Making fluffy dogs and cats from felt (32 pages, plus supplies and tools, 1680 yen)

Yarn weaving kit (32 pages, plus supplies and tools, 1,575 yen)

Item 4) Crafts even beginners can do. This section describes another new line. The first mook is:
Simple Tissue Projects (950 yen, 104 pages)

Otona no Kagaku Update, 9-21


Gakken just updated their Otona no Kagaku page with two new products. First is a stand-alone mook that I haven’t seen announcements for before, entitled, 「星と銀河と宇宙の進化」 (Hoshi to Ginga to Uchuu no Shinka – Evolution of Stars, the Galaxy and the Universe). 144 pages, 2,100 yen ($26 USD), released on Sept. 18, 2012. This is part of a new series called “Science Life”. The sample pages have lots of nice color pictures.

Second is the Edison Wax Cylinder Recorder, which now has an official release date of Sept. 25th, and a price of 3,675 yen. The kit consists of roughly 20 parts, not including springs and screws, and a suggested assembly time of 60 minutes. Just looking at the instructions, it appears that there’s a cutter stylus that’s pressed against the cylinder when you speak into the cone. Not sure just yet what the difference is for playback. The cylinder rotates at a fixed speed due to the 3V DC motor supplied (I’m guessing it uses 2 AA batteries). A collection sheet is used to catch the shavings as they fall off the cylinder. You can recycle a cylinder by simply smoothing it out with the supplied rubbing tool. The kit comes with 5 cylinders (actually, candles without the wicks). Articles in the mook include a retrospective for Otono no Kagaku’s 10th anniversary, a look at every kit issued as part of the series, a look at Edison, and the next in Asari’s Manga Science series.

There’s also an entry for the next kit – a third Theo Jansen mini-Beest, the Animaris Imperio. It appears to be a wind-driven 2-footed walker. No suggested price, expected out in December.

 

K-Gater 3.2 – adding a second arp


No entry for the 50 Famous People this week.  Next one will be next week.

———————————————————————

I like synthesizers.I like the ability to manipulate and warp sound into strange, new shapes. Unfortunately, I don’t have the money or space to buy anything new, and adding a sequencer functionality to K-Gater isn’t quite the same thing (that and I’m still thinking about the best approach to take). I am still thinking about writing a simple ADSR synth in Java, but it’s not high on my priority list yet.  Recently, though, I started wondering what would happen if I added a second arpeggiator function to K-Gater.

If you arpeggiate a piano sound fast enough, it stops sounding like a piano. With a simple arp pattern where you’re just turning one note on and off (0 0 0 0) you get a kind of drum machine stutter effect.  So, adding a second arp would modulate the first one. Technically, this might be like having a really long pattern that emulates a modulated pattern  (0 0 0 0 0 0 0 0 2 2 2 2 2 2 2 2 0 0 0 0 0 0 0 0 2 2 2 2 2 2 2 2, etc.), but you wouldn’t be able to vary the modulation in real time this way.  It’s a simple enough effect to add, although it requires the addition of 3 to 4 more control knobs, and the duplication of the rate, ratio, pattern select and step size components on the laptop screen.  Instead, I decided to double up the use of the existing Java screen components and just flag whether they’re displaying/modifying the settings of Arps 1 or 2. Fortunately, I still have 5 free dials on the A-300 Pro, and after some further thought, I realized I only needed 3 of them.

The real difference between arp 1 and 2 is that arp 2 doesn’t need “ratio”. The purpose of arp 1 is to turn the note on and off. But if arp 2 is modulating arp 1, then there’s no actual turning off of the first pattern. That is, arp 2 has a permanent 100% ratio.

I was also wondering how to approach the modulating waveform, if I should settle for just a square or a triangle wave, or use one of the free controls for selecting from a sawtooth and a sinewave as well. But then the realization that I was going to use modulation with a 100% ratio meant that a square wave would just be a really slow 0 1 pattern, and I could change the height of the squarewave by adjusting the arp 2 step size (which was already in the plans, anyway). So a sawtooth would just be a 0 1 2 3 pattern and a reverse sawtooth would be 3 2 1 0.  In other words, I could greatly simplify the controls, but it would still mean rewriting the Java code for the arp 1 rate, pattern select and step size components to cope with MIDI messages coming in from the two sets of A-300 dials and sliders.  In fact, the rewrite itself was fairly trivial, and just needed additions to parseMidi() and timer(), along with the instantiation of a second gateArp object.

The overall effect of having a modulating arpeggiator isn’t quite as awesome as I’d imagined, and there’s no justification to taking the next step and adding a third arp.  But, it does completely destroy the original piano sound and rearrange it as something new, which was the entire point.  Having two arps doesn’t work well with all of the default software synthesizer voices – the best effects seem to be with piano, square wave, and tympani.  And, if I add the Gakken SK-150 Mark II for filtering, the final output is kind of amusing.

And I was just about to leave K-Gater at this point when a thought surfaced from the back of my mind – “What if the arps were free running?” I’d copied the rate timing from the Kaossilator Pro, which is fixed at 4 seconds, 2 seconds, 1 second, 3/4 sec., 1/2 sec., 1/4 sec., etc. This is useful if you’re making music based on normal timing, but it is limiting and doesn’t allow for generating a range of beat frequencies.  So, I repurposed drum pad A5 on the A-300 to turn it into a toggle switch between fixed and free rates.  The next step required a complete gutting of the arp code because the rate slider was hardcoded to only select between the 11 fixed rate values, and now I wanted to run from 0 to 127. When I hit A5, I program the rate slider to either go from 0 to 10, or 0 to 127, and either pull the fixed rate from the timing array (which I moved out from the jSlider2 action listener) or calculate it as 1024 divided by the jSlider2 select value (giving a rate value of 1 second down to 8ms). I eventually realized that I needed a map() method, also.

When I was playing with the Japanino microcontroller (AKA: the Arduino), one of my favorite C++ functions was map(), which easily converts values between ranges. That is, if a jSlider selects from 0 to 127, and I want to use this to switch between my 8 Kaossilator voice preset buttons, I can do something like:

button = map(jSlider1.getSelectedValue(), 0, 127, 0, 7);

where “0, 127” is the range of the slider and “0, 7” is the new range I want to convert to. If the slider is at 40, then I’ll be activating preset button2.  So, once I had map(), I then went back through the entire Java app and replaced the old code where possible.

I like the effect of having dual free-running arps.  Very noisy.

Youtube demo video

Full formatted Java code.

 

K-Gater Ver. 3.1


I know that I said I was going to put bug fixing on hold, but I really wanted to make a video of everything running together and I wanted to make sure that the program wouldn’t crash during recording.  Along the way, I remembered the mention somewhere of something called “aftertouch”.  Then, while trolling youtube for videos about the A-300 Pro, I saw someone actually using it and decided that I’d like to try implementing aftertouch into K-Gater with the software synth (the K-Pro doesn’t support it).  So, I got into debug mode while seeing about adding the new function.

The first thing I discovered (although it took too long to catch on) is that not all MIDI messages are 3 bytes long.  Most of them are, but Channel Pressure is only 2 bytes, and my MIDI message print function was throwing an index out of bounds exception until I figured that out.  There’s a nice document on the net that describes both Channel Pressure and Aftertouch. Problem is, the description of Channel Pressure says that there’s just the status byte and one data byte.  For the A-300 Pro for Channel Pressure, it’s the status byte (0xD0 to 0xDF) to indicate channel number, and two message bytes. Byte[0] relates to the channel number, and byte[1] is the pressure value (0-127).

Aftertouch is per note and Channel Pressure is averaged across all pressed keys for the channel.  While holding the key down, varying pressure on the key causes the software synthesizer to create a vibrato effect (other external hardware can implement it differently).  According to the above-mentioned description, most synthesizers only offer one or the other options, with cheaper keyboards using Channel Pressure.  However, some keyboards do have both.  The A-300 Pro only has Channel Pressure.  If you look at the Roland product description, they say it has “channel aftertouch”. This is misleading, because it really means “channel pressure” and NOT per-key aftertouch.

Anyway, to implement the function in Java, the code in parseMidi() looks like:

if(pNo == 0) {  // A-300 Port 1
if(midiStatus >= 208 && midiStatus <= 223) {  // Channel Pressure
if(channelNo != midiPorts.kProChannelNo) {  // Only for software synth, not K-Pro
channels[channelNo].setChannelPressure(midiByte[1]);
}
}
}

Pretty simple.

But I was still in debug mode. And the specific bug I was trying to track down is the “stuck key” problem. If I hit too many keys randomly for a certain amount of time, one of the keys gets stuck in the “key pressed” ArrayList and continues to play after I release it. I mentioned in the last entry that it’s because two incoming MIDI messages can interfere with each other, and the parser fails to see one of them arriving.  I’m pretty sure the same thing holds for two MIDI_OFF messages arriving, but that’s harder to check. I hadn’t encountered this problem before adding the “add note” and “delete note” ArrayList buffers, so I’m pretty sure the A-300 was sending the messages correctly and that the software synth was seeing matching NOTE_ON/NOTE_OFF pairs regardless of how I banged on the keyboard.  Meaning that the midiParser() method was also working right. But somehow, I’m losing that one occasional NOTE_OFF message. The work around is to turn the note off anyway during the flush “remove note” buffer step. It probably won’t affect how the music sounds and that’s the important part.

I uploaded the video of the entire rig to youtube.

Full formatted Java listing.

 

50 Famous People – Darwin


(All rights belong to their owners. Images used here for review purposes only.)

Arguably, no one scientist has been quite as divisive, in terms of the results of their research, as Charles Darwin. Just about everyone at least knows of his work, while not necessarily understanding it, much less agreeing with his conclusions. Regardless, he did contribute to our understanding of the wildlife in South America, and the Galapagos Archipelago with the drawings and observations he made while on his 5 year journey with the Beagle.

The intro manga starts out with Merrino bringing home one of his game machines from the Sheep planet. With this machine, you can insert two things, at least one of which has to be organic, and it will create a battle monster out of the combination. His banana-fly loses to Mami’s squash-doll.  Yoichi crams an armful of stuff, including his Darwin textbook, into the machine and the resulting 20′-tall beansprout creature threatens to destroy them all.  In the wrap-up, the creature disappears and Merrino states that the game only has a 3-minute lifespan, while Yoichi and Mami claim credit for defeating the thing. Soon after, their mother comes into the house carrying some cute little bean creatures she bought while out shopping.

In the main manga, by Naoto Satta (Miko to Kagaku no Uso Happyakuman), an elderly Darwin attempts to tell his contemporaries about his ideas regarding evolution and is met with derision by those Christians that believe all life was created as-is by god.  He comments to a student that the idea is easy to believe if you see enough life from around the world. This takes him into a reverie about when he first boarded the Beagle 20+ years earlier. The story then shifts to the point of view of a young sailor named “Conbinton” who resents being assigned as Darwin’s assistant by the ship’s captain, FitzRoy. Conbinton doesn’t understand why someone so ill-suited to sea life would be on their ship, while the narrator tells us that ships were getting one scientist each for assisting in the travels while also providing someone the captain can talk to. Darwin appears to be a complete clutz, falling off cliffs and throwing up over the railings, but he takes a massive amount of notes. At one point, the captain also asks what the point is of all this work, and Darwin simply replies that if life wasn’t created by god as-is, he wants to know how it started and where it’s headed. After 5 years, the trip ends and Darwin starts teaching at Cambridge. But it takes him 20 years to get up the nerve to publish “On the Origin of Species”. Naturally, the Church rejects the idea of evolution and fights to have him removed from his post.  However, getting the support of Thomas Huxley helped him keep his job. The narrator ends by saying that the children of today have inherited Darwin’s mantle.

The majority of the first 4 pages of the the textbook section are spent describing Darwin’s birth and upbringing in England and the events leading up to his being assigned to the Beagle for documenting the discoveries made while charting the seas around South America. His father was a famous surgeon, and his mother was from the Wedgewood pottery company (her father founded Wedgewood). Darwin was expected to follow his father’s footsteps as a doctor, but in college discovered an interest in life studies. There are sidebars on botany professor John Stevens Henslow, Captain Robert FitzRoy (a devote Christian, FitzRoy disagreed with Darwin’s conclusions), Alfred Wallace, and a quick peek at how the pressures for survival drive the selection of species. Photos and paintings include illustrations of Wedgewood’s pottery, Darwin’s childhood insect collection, the Beagle, a sample of an animal fossil and the map of the Beagle’s 5-year route. The last 2 pages discuss the concepts of human evolution, how we’re not directly descended from apes, and models demonstrating examples of Lucy, Neanderthal man, and homo sapiens. (What I find interesting in this section is that the Neanderthal is a hairy, barbaric-looking European, while homo sapiens is a clean-shaved, well-groomed modern-day Japanese.)

The TCG cards this time are for: Bach, Robert Walpole, Peter the Great, Voltaire, Montesquieu, Baldassare Castiglione, Ben Franklin, John Kay and Anne Bonny.

Overall, the manga for this issue isn’t too bad. Darwin looks somewhat like his photos, although his later appearance is greatly simplified. FitzRoy doesn’t look anything like his portrait and I expect that “Conbinton” was created solely for narrative purposes. The main focus of the story is just on some of the animals that he studied and his unsuitedness for being at sea.  The real discussion of his ideas and their implications takes place in the textbook section.  If you’re interested in learning more about Darwin, you’re better off getting one of his English biographies.

Sept. 8 updates


We’re getting a little more activity on the Gakken Facebook page.

First, there’s a new picture featuring an animal you can make from the “Fluffy Dogs and Cats You Can Make From Felt” book. This one is by an artist named Nosoko, and is “sheep style fur”.

Second, the Adult Science team has branched out and written up a new book titled “Making Haiku for Beginners”. Gakken acknowledges that this isn’t a part of their regular line up, but it’s related because of the team that worked on it.

K-Gater Ver. 3


I’m now up to K-Gater version 3. Version 1 was when I just started out and didn’t really understand the way the Kaossilator Pro behaves compared to the software synthesizer, and I didn ‘t have the Roland A-300 Pro midi controller keyboard. The code worked, but it wasn’t very efficient and it only sent data in one direction – out to one of the two players. With version two, I added the A-300, and moved some of the K-Pro receiver handling code out of the Change Instrument and Play Note methods. I also broke the initInstrument code in two, making the process of obtaining MidiDevice objects more modular. The next step was to figure out how to open transmitters to the A-300, set up the sequencer-sequence-track combinations, and then read incoming MIDI messages prior to interpreting them and passing the results to either the K-Pro or the software synth There were a few minor tweaks as well, such as making the metronome button flash red on the beat counts.

Version 3 was mostly intended to just add polyphony to the arpeggiator. It also ended up being a shake-out stage, where I had to do a lot of unexpected bug fixing. And I moved a few of the variables around to put them into a new class for recording NOTE_ON/NOTE_OFF events.

Originally, I just wanted to take MIDI NOTE_ON and NOTE_OFF messages from some keyboard device and convert them to CONTROL_CHANGE messages to send to the K-Pro. While I was at it, I figured I might as well add the arpeggiator ability. And that’s where a certain limitation crept in. I was only tracking one key at a time for ‘pegging, which sacrificed the polyphony (ability to play two or more notes at a time) supported by the A-300 and the software synth. Under most conditions, I expect that musicians won’t ‘peg chords, but it did make it difficult to smoothly transition from one note to another with the arp turned on. I had to release one key and wait a fraction of a second before pressing the next, and that produced a noticeable break in the ‘pegging.

The obvious solution was to convert the single variable to an ArrayList of key-NOTE_ON messages. To play the chords while ‘pegging or when changing preset voices, I just run through the array and send NOTE_ON for each key still being pressed. If a key is released, I remove that key from the ArrayList, and send a NOTE_OFF message to the instrument. This is fine in concept, but there’s a problem of losing notes when ‘pegging while changing instrument voices, so I turn all the notes off before changing the voice and then send new NOTE_ON messages afterward. Which brings me to the structure of the NOTE_ON message. We not only need to pass the number (0-127) of the note itself, but also the velocity (0-127). Velocity can either translate to “volume”, or it’s a measure of how hard the user hit the key on velocity-sensitive keyboards. If I’m sending NOTE_ON when ‘pegging or changing instrument voices, then I need to record the velocity with the note number. If I’m sending note off, I only need the note number, but now the velocity is associated with the note number within the keyPressed ArrayList and I need to mask it out when searching for the note number to be removed from that ArrayList. It’s not all that difficult to deal with, just kind of petty.

But, I found something else I didn’t quite like. When pressing a second or third key while ‘pegging, the notes get turned on or off in the middle of the arp note ON period and the result sounds sloppy. My solution was to buffer the NOTE_ON and NOTE_OFF events, storing them to their own ArrayLists, and then using removeBuffer() and addBuffer() methods to actually add and remove notes from the keyPressed ArrayList at the end of each arpeggiator time period. This results in a much smoother transition when ‘pegging from one key to another, but a new bug slipped in. Now, if you play a chord and both keys hit at the same time, one of the notes may get “stuck” in the buffer and the program will keep ‘pegging after you release all of the keys. The problem revolves around two NOTE_ON messages arriving at the PC at the exact same time and confusing the MIDI parsing process. So, I either don’t buffer and allow chord changes in the middle of an arp note on event; I buffer and try to avoid pressing 2 keys at the exact same time while ‘pegging; or I flush the keyPressed ArrayList when I turn the gate arp off (this is the work-around I settled on until I can fix the larger problem).

I haven’t decided what I’m going to do next. However, I’m spending more time on program debug than I am actually playing the keyboard. So I’m going to post the code now and come back to it again later when I have more time.

As I was going through the code, I realized also that the idea of a “base key” (jTextField2) for the arpeggiator was messing up my ability to change the keyboard bottom key and key spacing of the A-300 when driving the K-Pro. So I simplified the code and removed jTextField2. This gave me a little more room on the screen and I shortened the west, middle and east panels, and made the south panel taller. This gives me more room for displaying debug messages. Otherwise, the user interface is largely unchanged.

Formatted textfile.