Posts Tagged ‘Stylophone

15
Sep
13

The StyloSound

front_IMG_1497

The idea for the StyloSound came to me when, at about the same time, I acquired two small sound effect devices.  One was a ‘Sound Machine’, a small hand-held unit with 16 push-buttons, the other was a Sound effect kit with PCB, also with 16 different sounds.  I thought it would be a good idea to combine the two things into one unit and use the Stylophone stylus to trigger the sounds; plus I was also working on devices to interact with the ‘Bigfoot’ trigger/sequencer, so I decided to add the capability for the sounds to be triggered by the Bigfoot’s 4-bit binary output.

*

There are several varieties of Sound Machine.  The one I got was the silver ‘SciFi’ version.  This has a number of interesting ‘spacey’ effects, some of which I recognised from Star Wars, Close Encounters and others; some I didn’t.

sound-machine-sci-fi-box2

These Sound Machines aren’t all exactly the same inside, apparently (this site gives a very good first-hand account of looking inside them: http://www.magicmess.co.uk/cb/sm.php)*, but I guess the sounds are all initiated the same way – a +V pulse into the appropriate input of the dedicated chip which stores the samples.

*[Edit: unfortunately, this site is no longer up; I saved some of it, which had this information in it: http-www-magicmess-co-ukcbsm-php.pdf].

Having opened the Sound Machine and taken the PCB out, it was easy to attach a wire to each of the 16 inputs.  These wires went to the middle 16 notes on a Stylophone keyboard, salvaged from a broken instrument – via 16 SPDT switches, as I wanted to be able to choose either the sound from the Sound Machine or the sound from the Sound effect kit individually in each of the 16 positions.  This picture shows how the switches were arranged on the front of the StyloSound:

StyloSound outside in prep IMG_1469

The Stylophone stylus was connected to +V, and the output from the Sound Machine PCB went to the Stylophone speaker, which was much better than the small speaker in the original.

The Sound Machine is powered by three small 1.5v button cells, so it was no problem to use the Stylophone’s own battery compartment, which takes three AA batteries.  With all the switches to the left, the Sound Machine PCB was selected, and it was possible to play all 16 sounds from the Stylophone keyboard.  It was clearer from this than using the original buttons that each sound has to play right through before a new one can be selected.

The next obvious step was to interfere with the playback speed of the sample.  This version of the Sound Machine has only four visible components, two resistors and two capacitors – all tiny SMD (surface-mount) type – with the main chip embedded in its plastic blob.  Using the wetted finger method, I found the resistor responsible for playback speed, which is marked ‘R2’.  I removed it and replaced it with a potentiometer, which slowed down and speeded up the playback.

In this photograph you can see the points at which wires are soldered to the Sound Machine PCB.  In the magnified area you can just about make out the resistor on the left marked ‘R1’, the removed resistor, ‘R2’ (detached but still lying beside the place it was removed from), the wires going to the potentiometer and the two SMD capacitors behind the wires:

SMachine PCB IMG_1473

Unusually in my experience, the chip reacted badly to both too low a resistance and too high, and a 1M potentiometer, my usual first choice, was too big for it, causing it to crash.  In the end, I settled on a 470K potentiometer with 100k trimmers either side.  When the trimmers had been adjusted, this seemed to keep the resistance within acceptable levels.

(Later, I read the website referenced above, and the writer had a different solution to this problem, but I didn’t have time to check it out).

*

The above is all you would need to do to bend a Sound Machine, but the next thing in my case was to unpack the Sound Effect kit, which contained the following components:

Kit unpacked IMG_1471

The two logic chips are a 4066 (quad analog SPST switch), and 4011, (quad 2-input NAND gate); the sound effect chip was on a separate board, inserted, strangely, at right angles to the main board in the slot on the right.  The 4 SPDT switches enable the sound to be selected manually – the input is 4 bit binary – as an alternative to the 4 inputs on the left-hand side of the board.  Output is  through what looked like a small piezo element (the round black component in the bottom left of the picture).

The small board which the sound effect chip itself sits on is one of a range in the 9561 series.  This one has the prefix ‘LX’, but there are others, such  as ‘CK’, ‘CL’, ‘CW’, ‘KD” and others: all have the same general purpose, finding use in alarms, doorbells, and simple toys, making noises such as police sirens, machine guns and so on.  Simple circuits such as this one can be found on the internet utilising very few external components to produce the required sound (generally only one or two in each application):

LX9561

In fact, the kit I bought in an eBay auction only cost about the same as the module itself, and took full advantage of the range of sounds available by using the two switching terminals (F1 and F2) and a more complex array of resistors in place of the single 200k resistor shown in the circuit above.  The full list of sounds available is as follows:

0000: Machine gun voice
0001: Fire truck voice
0010: Ambulance voice
0011: The police car voice
0100: Crickets sound
0101: Alarm
0110: Electronic signal sound
0111: Koh
1000: Insect song
1001: Whistle
1010: Telegraph sound
1011: Bird song
1100: ChongJi gunfire
1101: Car sirens
1110: Bass instruments sound
1111: Racing sound

Some of these interpretations are rather fanciful, but that was no problem as I was more interested in making noise than repeating recognisable sounds.

This chart – for a similar chip in the series – gives some idea of the variations in binary inputs, combinations of selection inputs and resistances that produce different sounds.  If you read Chinese, which I don’t, it probably tells you in the right-hand column what sounds these combinations make.

KD9561 selection chart2

The PCB was robustly constructed and I put it together omitting the four slide switches, as I intended to control it externally, and didn’t attach the piezo sounder, which wasn’t going to be used.

Several of the resistors, when tested, had an effect on the pitch and speed of the sounds – the main job of the 4066 and 4011 is to select different combinations of resistors to affect the sound produced, much as indicated in the chart above – so I picked the likeliest one and replaced it with a 1M potentiometer.  This seemed to do the trick – perhaps taking things slightly too far in the upper direction, so I added a preset in series to keep it from going to its maximum – although it had happily done this without any danger of crashing the chip.

I only had a log potentiometer available, and in the end this was quite fortunate.  I found that connecting it the opposite way round from what would be expected – i.e. turning it clockwise decreased the pitch and speed, rather than increasing it – exploited the logarithmic scale well, making a much slower and smoother transition through the higher pitches and speeds.  I could have bought an ‘anti-log’ pot, but additional time and expense didn’t seem worth it.

This was a timely reminder that a useful part of experimentation would be to compare lin and log pots in particular situations, and reversing the log ones to see what difference this produced. (Reversing the linear ones would, of course, do no good, as they progress evenly through the scale from top to bottom, whichever way round they are).

This part of the circuit (the kit PCB) now looked like this:

Sound Effect Kit circuit 3

The original circuit diagram was provided by the supplier, Chip_Partner_Store, a Chinese company with an eBay shop at http://stores.ebay.com/Chip-Partner-Store.  Places like this – and there are many of them on eBay – are great for browsing through: you can find great deals on bulk buys of common components, as well as somewhat more unusual ones at very reasonable prices, and odd chips and modules like this one, which could always come in handy.

I’ve indicated in the diagram where I added the 1M potentiometer and preset, plus four LEDs, connected, via 470Ω resistors, to the A B C D inputs, the other ends connected to ground.  These were not there for any reason, particularly, except as an indicator of the code being received – and on the principle established with Bigfoot that flashing lights are always good.  I was sceptical as to whether the circuit supplying the four inputs would be able to power these as well as operate the Sound effect module correctly, but it all seemed OK.

The greyed-out section at the output wasn’t used in the final circuit.

Actually, this unit begins sounding repeatedly as soon as power is connected to it, since the default input 0 0 0 0 has an associated output – ‘Machine gun voice’ – and I couldn’t find a way of stopping it, so I also added a power on/off switch to this board, which isn’t shown, in case this feature became annoying.

*

SInce the circuit has four binary inputs, and I wanted to control the unit with the Bigfoot, which has a 4-bit binary output, it would seem logical to connect the Bigfoot output directly to the A B C D inputs.

Unfortunately, this wouldn’t allow the Sound effect module to be operated by the Stylophone keyboard, or the Bigfoot to control the Sound Machine, so additional circuitry was needed to convert the binary input into 16 individual outputs, and then convert that back into binary . . .

. . . Fortunately, the first of those would be a duplicate of part of the Bigfoot circuitry, which I was familiar with, using a 4067 chip.  This part of the circuit looked like this:

StyloSound - 4050_4067_3

The input from the 5-pin DIN socket goes first to a 4050 hex buffer.  Four of the six buffers are used.  The reason for doing this is to exploit an unusual and very useful feature which the 4050 shares with its more common sibling, the 4049.

Both perform a similar function, but the 4049 inverts the input (high level voltage in = low level voltage out, low level voltage in = high level voltage out), and the 4050 doesn’t.

What both of them are able to do is accept an input voltage level higher than the supply voltage, a vital consideration here as the output from Bigfoot is at 9v, whereas the circuitry of the StyloSound is at only 4.5v.  The 4050 is able to acccept the 9v input from Bigfoot and safely reduce it to 4.5v for the other circuits.  9v isn’t a problem for CMOS chips, but the Sound Machine and the Sound effects module are both rated at 4.5 – maybe 5 or 6 maximum – volts.

The four outputs of the 4050 go into the A B C D inputs of the 4067.  Each of the 16 outputs of the 4067 goes to the pole of one of the SPDT switches described earlier.  According to the binary coding on the inputs, one of the 16 outputs of the 4067 is connected to +V, and this signal is sent in the direction either of the Sound Machine when the switch is to the left, or the Sound effect module when it’s to the right.

*

The Sound Machine has 16 separate inputs, so no further circuitry was required: each switch was connected to one of the 16 places on the Sound Machine PCB where there used to be buttons.

For this signal to operate the Sound effect module, however, it needed to be changed back into binary.

Fortunately, this change is not difficult to implement, using a pair of 4532 chips and a 4071.  The 4532 is essentially the opposite of the 4067: it takes individual inputs and converts them to binary.  Each one has only 8 individual inputs and outputs in 3-bit binary, but the datasheet showed this 16-input, 4-bit binary output circuit, which is the one I used:

16 input encoder w pin Nos

The 16 inputs marked ‘From Stylophone Keyboard’ were all connected to ground with 100k resistors so that each one would be at 0v if not receiving a +V signal from the keyboard or the 4067.  The outputs of the 4071 were connected to the Sound effects module where marked A B C D in the earlier diagram.

Here’s how the physical connections are made, and what the chips look like on the board:

StyloSound 4532_4071_3

inside_IMG_1472_2

I’m not entirely sure that the correct order of those 16 inputs is as implied in the datasheet circuit.  Since I had LEDs on the inputs of the Sound effects module – i.e. effectively at the outputs of the 4071, I was able to check the sequence, and I found myself swapping some of them around.  If you’re using this method of converting single outputs to binary, it would be advisable to check this as you go along.  In my case, the wiring to and from the SPST switches was such a bird’s nest, that it became too difficult to work this out.  If it becomes clearer when I use this system in future projects, I’ll make sure to record the correct sequence.

However, when tested with ‘Bigfoot’, the module was triggered accurately, and the LEDs on the input lit up with the correct numbers when the notes were tested with the stylus and keyboard.

*

So now I had two separate sound effect circuits which differed in several ways: the Sound Machine uses samples, which are played back in their entirety, and are particularly effective when slowed down; the Sound effects module produces electronic sounds from oscillators, which can be cut off and replaced at any time by another sound, and lend themselves to being sped up.

Both sections had separate pitch/speed controls; both could be controlled automatically by Bigfoot, or manually via the Stylophone keyboard.

*

I could have stopped there, but I had another idea which I thought could be included.  I believe this is known in the trade as ‘feature creep’ – just adding that one extra implementation, which then turns into two, then three . . . and eventually makes a simple circuit over-complicated.

But I had  just acquired a number of unwanted ‘Voice Recorder’ key rings – 100, in fact! – at a few pence each.  At this price, they weren’t guaranteed to work, but when I tested some, quite a few seemed OK, and they were powered by 3 little coin cells – i.e. 4.5v, the same as the rest of the circuits in the StyloSound, so I thought I could employ a couple of them here.

Here’s what they look like:

outside_inside

There’s a very small microphone, a Record/Play switch, a button to operate whichever of the two functions it’s switched to, and an LED to indicate that it’s recording, as opposed to playing back.  I thought it would be good to be able to record a small (up to 8.2 seconds, it said) burst of sound while the samples or effects were being manipulated, then be able to play it back precisely the same again, a primitive – but undeniably inexpensive – repeat/looping device.

So I added a couple of these, connected to the outputs of the Sound Machine and the Sound effect module.  Small tactile switches glued to the front of the instrument replaced the ‘Record/Play’ switch and button, and I also moved the small LED’s to the front panel as well.

*

Only one thing remained, as far as the circuit was concerned, which was the output stage.  This turned out to be . . . strange.

First of all, I needed to mix together the four outputs: the Sound Machine, the Sound Effects module and the two recording devices, as well as send the Sound Machine and Sound Effects module outputs to the inputs of the recorders.  I planned to do this  with a passive mixer – i.e. just join the outputs together with resistors.

The Sound Machine worked perfectly with the internal speaker, but the Sound Effects module would only work with the other speaker terminal connected to +V rather than 0v: otherwise, it was extremely quiet.  I got round this by taking the output directly from the output of the LX9561 board, as indicated in the circuit diagram above, and bypassing the output transistor.

The outputs of the recorders were much too quiet, too, and the only way I could make them loud enough was to give them a path to +V by means of a very low value resistor (22Ω).  The sound quality of these didn’t quite match that of the Sound Machine and Effects module – partly, no doubt, because of reduced bandwidth in the recorders – but they definitely added a useful function.

In fact, I had intended to add tone and volume controls at this point, but the device refused point-blank to make any sound if anything other than a very low value resistor was put in the output path, I don’t know why.

In the end, I used 22Ω resistors to join the 4 outputs (two in series for the Sound Machine, which was a little louder than the others) and ran this straight to the speaker and output socket.  So, the final stage looked like this:

StyloSound - Output_3

The resistors are all 22Ω, as opposed to some other equally low value, simply because I had a pile of them which were going spare.

So: strange, but when I plugged it into my mixer, it  sounded fine, and the volume could be adjusted there.

*

The only thing left to do was to finish the case.  There was so much internal wiring and circuitry that the case had to be made 2.5″ deeper.  I constructed sides from an offcut piece of white plastic and superglued them in place – not especially neatly, it has to be said – with a little internal bracing.

top_IMG_1498
rside2_IMG_1494
back_IMG_1493*
This is what the StyloSound sounds like, controlled by ‘Bigfoot’:
Advertisements
12
Oct
12

Bigfoot – automatic/remote stylophone control, Part 2

As described in Bigfoot, Part 1, I was  constructing a device to play a modified stylophone remotely and automatically.  Using a 16 way analogue switch, the 24-pin 4067 chip, I designed a device where any one of 15 intervals on a 2-octave tonic sol-fa scale would be triggered by changing the chip’s 4-bit binary input.

First of all, I had used a physical control, a 16 position binary or hexadecimal rotary controller; what  I needed next to find was chips that could be made to output sequences of 4-bit binary numbers.

There are several of these, and I went for the 4516, which is a pre-settable binary counter.  It can, if left alone, repeatedly count upwards from 0 – 15, outputting numbers in binary form (‘0 0 0 0’ to ‘1 1 1 1’) on the pins marked ‘Q1’ to ‘Q4’ in the diagram below at the speed of a pulse connected to its clock input (Pin 15); or downwards from 15 – 0.  But by pre-setting a certain number, in binary form, on 4 extra binary inputs, marked ‘P1’ – ‘P4’ in the diagram, it can also be made to count upwards from this number to 15; or downwards from this number to 0.

This is how the 4516 is usually represented in circuits:

Q1 – Q4, as mentioned above, are the outputs, and P1 – P4 are the inputs for the number the count starts from, both in the form of a binary number.  The ‘Preset Enable’, pin 1, is usually held low (0v): when it’s taken high (+v) the number on the inputs P1 – P4 is loaded in and the next count starts from that number.  ‘Preset Enable’ is sometimes referred to as ‘Load’ for this reason.  The ‘Carry Out’ is normally high, but goes low when the count ends.

The ability to count downwards from a set number would be useful for an arpeggiator, which could be set to repeat a sequence with a length of 2 – 16 notes, using the rotary encoder, described in Part 1, connected to the 4 binary inputs to preset the sequence length.

The circuit for this device was extremely simple, requiring only the rotary encoder, a momentary switch to tell the 4516 to load the sequence length number, an on/off switch and two inverters from a 40106 (which has 6 in it altogether) .  One of the inverters was connected as an oscillator, which was connected to the 4516’s Clock input: this determines the speed at which notes sound; the other inverter was connected between the ‘Carry Out’ and ‘Preset Enable’ pins: the ‘Carry Out’ is normally high, so the inverter keeps the ‘Preset Enable’ low; when the count ends the ‘Carry Out’ goes low and the inverter sends a ‘high’ pulse to the Preset Enable, reloading the start number.

Encoder_4516

Pin 10 is connected to 0v in this circuit, which tells the 4516 to count down, not up: this was the easiest way to make sure it counted the right number of notes in the sequence.

In fact, counting up or down would result  only in a scale or part of a scale being played, so I made the output a bit more interesting by reversing the 4 outputs.  Instead of connecting the A output of the 4516 to the A input of the 4067, the B output to the B input, etc., I connected it so that A B C D were connected D C B A.  In essence this meant that consecutive notes in the sequence would not be consecutive notes in the scale, which I thought would be more interesting.

This produced method 2 of controlling the Stylophone: automatic arpeggiation.

*

The third method of controlling the Stylophone automatically used 3 more of the inverters in the 40106 which had been used for the 4516 clock and ‘Carry Out’ inverter.  The inverters were wired as oscillators.

This was the idea that came from the ‘Slacker Melody Generator’, described at http://electro-music.com/forum/viewtopic.php?t=27239&postorder=asc&start=50.  Each of the 4 oscillators is connected to one of the 4 inputs of the 4067; each runs at a different speed, changing the value on that input from low to high, or 0 to 1.  The different successive combinations of 0s and 1s produces a random melody, which can be changed by adjusting the speed of the oscillators, increasing or decreasing the rate at which each particular input changes from ‘1’ to ‘0’.

40106

The reason the four oscillators have two capacitors each is simply because the original circuit I used suggested values of 220n; I soldered these in place, but the oscillators seemed to run too fast for my liking, and it was easier to add new ones in parallel than take the old ones out and replace them.  The result of putting capacitors in parallel is the opposite of putting resistors in parallel – instead of the overall value decreasing, it increases; the capacitance is larger and the oscillators run slower.

Having put the 4067 and the five DPDT switches in place, I then had to connect the relevant input/outputs to 24 different resistors, in a chain (or ladder) like the original one inside the stylophone.  I suppose it would have been possible to calculate the exact resistances, but I had some time ago obtained a hundred 10k presets for about 7p each, for exactly this kind of situation, so decided to use those and tune it by ear.

This took some time, but at the end of it I had a substitute resistor chain for the SoftPot Stylophone and some methods of controlling it automatically.

*

It then occurred to me that with this arrangement, all this extravagance could only control one stylophone at a time, so I had a think about how to connect more instruments (and possibly instruments other than stylophones!).

The way to do it, it seemed to me, was to use the binary inputs to the 4067 as an output: any device could then be controlled, just by installing the 4067 and the five ‘major/minor’ switches in it – or perhaps some other suitable arrangement.

So I added two 5-pin DIN sockets as outputs, the five terminals being A, B, C, D and 0v.  Each of the four A, B, C, D outputs was buffered, using four of the six buffers in a 4050.  The 4050 is similar to its sister chip, the more well-known 4049; but whereas the 4049 inverts its outputs, the 4050 doesn’t.  This chip has even cleverer properties, which I will be using in a later project, but here I used it to ensure the binary outputs were of sufficient strength to make their way through a connecting cable and satisfactorily operate external circuitry.

I also added at this stage Clock In and Clock Out sockets, which would enable Bigfoot to set the tempo of a piece involving different instruments, or follow the tempo set elsewhere.  These two input/outputs passed through the remaining two buffers on the 4050.

The final thing was to add two more 5-pin DIN sockets, this time as inputs.  This would enable external circuitry to control the 4067s.  I had several more ideas of suitable external devices which could be used to do this, and I hope to be able to get around to making these quite soon.

The only other unusual component needed to get all this to work was a suitable master switch, to select the various external and internal inputs to the 4067s.  This had to have 4 poles – the A, B, C, D binary inputs – and 5 positions.  4 pole, 3 way rotary switches are easy to come by, but 4 pole, 4 or 5 way are not.  Fortunately, I was able to source a 4 pole, 5 way switch on eBay from a supplier in Hong Kong for just a couple of quid, so everything was in place.

With a circuit like this – just a handful of chips and a few external components – you either get a neatly laid out PCB or a rats’ nest of wiring.  I ended up with a rats’ nest of wiring . . . however, it worked, even when crammed into the case, with the addition of an extra section underneath the ‘big foot’ I had selected.

This picture shows the two binary input sockets on the left.  The 5 way switch is the knob on the front of the Bigfoot, just the right of centre in this picture.

Bigfoot Left DSCF0002

Due to a certain amount of experimentation along the way, some changes of mind about the functions, and some difficulties in getting all the switches and sockets to fit, there were some extraneous holes which I had drilled in the case.  The plastic frogs are there to hide the holes.  I also added a square of velcro on the back where I could attach a battery holder, as I had done with a number of previous projects.

DSCF0004*

This is what Bigfoot sounds like, controlling the SoftPot Stylophone and the StyloSound at the same time:

 [Edit: there is now a link to a short video of the Bigfoot in action at the bottom of this page].

12
Oct
12

Bigfoot – automatic/remote stylophone control, Part 1

I’d made enough instruments for the time being, and it was time to construct some automatic controllers – sequencers, arpeggiators and the like – as an alternative to playing them by hand.

When I made the SoftPot Stylophone, I had added a socket which allowed external circuitry to replace the chain of resistors which govern the pitch of the instrument.  This project was to make a device which would be able to use this feature to operate the SoftPot Stylophone remotely, and this rather blurry photograph shows the result – Bigfoot:

DSCF0005

I got the inspiration from several places: the arpeggiator and sequencer from Fun with Sea-Mosshttp://milkcrate.com.au/_other/sea-moss/; the melodygenerator by Slacker described on the electro-music.com forum: http://electro-music.com/forum/viewtopic.php?t=27239&postorder=asc&start=50; and the Intro to Lunetta Synths at https://docs.google.com/document/edit?id=1V9qerry_PsXTZqt_UDx7C-wcuMe_6_gyy6M_MyAgQoA&pli=1,  All these sites are full of great ideas and practical examples.

The main chip used in the circuits described above is a 4051, which is basically a single-pole 8-way switch.  It’s usually depicted in circuits like this:

The way it works is like this: it’s an analogue switch, not a digital switch, meaning you can connect anything you like to the pole (pin 3, marked Z in the diagram) and the 8 switch input/outputs (on the right-hand side, marked Y0 – Y7).  It doesn’t have to be logic high or logic low (i.e. +v or 0v) , it can be any voltage, an audio signal, anything – just like a physical switch.  Any one of the 8 input/outputs can be connected – one at a time – to the pole, not by turning a physical switch, but by the logic high or logic low status of the 3 ‘Select’ inputs (pins 9, 10 and 11, marked S1 – S3).

You can have every combination of logic high and logic low on the three Select inputs, ranging from 0v on all of them, 0v on one of the three and +v on two of them, +v on two of them and 0v on one, or +v on all of them.   There are eight possible variations, starting with 0v on all of them, which you could represent as ‘0 0 0’ or the binary equivalent of the number zero, to +v on all them, which could be represented as ‘1 1 1’ or the binary equivalent of the number 7.

If you feed 0v to all three of the Select inputs, or ‘0 0 0’, this is lowest possible binary number, so the lowest or first input/output is connected to the pole (Y0, pin 13); if you connect, say the one on pin 9 (S3) to +v and the other two to 0v, this would be the binary number ‘1 0 0’, the equivalent of the number 4.  Because the sequence starts with ‘0 0 0’ , or zero, feeding in ‘1 0 0’  connects the 5th rather than 4th input/output to the pole (Y4, pin 1).  By connecting all the Select inputs to +v, or ‘1 1 1’ (the number 7), the 8th input/output is connected to the pole (Y7, pin 4).

In the circuits I looked at, a common type of connection would be to have the pole connected to the part of an oscillator circuit that determines the pitch, and 8 input/outputs connected to different value resistors.  This would mean that a different resistance would be connected to the oscillator and a different pitch would be sounded when each of the 8 input/outputs was connected to the pole.

You could determine whether each of the Select inputs was a ‘1’ or a ‘0’  with  three 2 way switches, +v one way, 0v the other way, and change the notes by moving different switches up and down.  But this would be rather tedious.  By adding a circuit that automatically changed the ‘1’s and ‘0’s, you have a melody generator, arpeggiator or sequencer.

This was the kind of circuit I was after.

However, 8 notes was bit restricted.  Not restricted because there are 12 notes in one octave, though: I reasoned that you could make life easier for yourself by only allowing notes in a single scale – the ‘do’, ‘re’, ‘mi’ approach so succinctly captured in the Rodgers and Hammerstein song from The Sound of Music (‘Do a deer, a female deer/Re, a drop of golden sun’, etc.).  There are only 8 notes in a  ‘do’, ‘re’, ‘mi’ scale, including the next ‘do’ up from the one you started from.  If you just use those, you’ll never get an ‘out of tune’ note in your arpeggio or sequence.

The proper name for the ‘do’, ‘re’, ‘mi’ system, by the way, is ‘tonic sol-fa’, and was invented here in East Anglia by Sarah Ann Glover of Norwich, who lived from 1785 to 1867.  This 1868 woodcut shows Sarah Ann teaching ‘do’, ‘re’, ‘mi’ to the musical children of Norfolk:

(Why this public domain picture  is held by Music Department of the Bibliothèque National de France is not adequately explained by the Wikipedia, where I found it.  I suppose the fame of ‘do’, ‘re’, ‘mi’ is international).

No, it was restricted instead because the SoftPot Stylophone has 12 ‘do’, ‘re’, ‘mi’ steps from the bottom of the keyboard to the top – and in any case could be made to produce notes outside the range of the built-in keyboard.

So I decided I needed 16 steps (2 octaves, including ‘do’ two octaves up from the start), and found a chip, the 4067, to do the job.  The 4067 is a single-pole switch like the 4051, but with 16 switches instead of 8.  The only way it differs in operation from the 4051 is that it requires 4 Select inputs in order to go all the way from ‘0 0 0 0’ (zero, meaning the first input/output is connected) to ‘1 1 1 1’ (15, meaning the 16th input/output is connected).

The 4067 usually appears in circuits like this:

It’s very similar to the 4051: there’s a Pole (pin 1, marked Z); 16, instead of 8, input/outputs (right-hand side, marked Y0 – Y15); and 4, instead of 3, Select inputs (pins 10. 11, 13 and 14, marked S0 – S3).

I also decided to make things slightly more complicated by considering alternative scales.  If you follow the ‘do’, ‘re’, ‘mi’ scale of the Rogers and Hammerstein song, this is a major scale.  If, on the other hand, you wanted to play, for example, a minor scale, you would find that ‘mi’, sometimes ‘la’ and sometimes ‘ti’ have to be changed to be a semitone lower.  And occasionally you might feel like making ‘re’ and ‘so’ lower as well.  (‘Do’ and ‘fa’ can be left alone!).

I’ll explain in a minute exactly what scales I had in mind when doing this, and where I got the idea from, but adding the ability to sharpen or flatten certain notes of  the scale meant that I needed 25 notes instead of 15, so the 4067 was wired up like this:

4067 1 Edit

The notes depicted are the notes that would be used in the key of A.  Since the SoftPot Stylophone has a tuning control (in fact two tuning controls!) on it, it can be made to play in any key, not just A; the circuit here doesn’t need to be changed, only the tuning on the SoftPot Stylophone itself.

Each of the 16 outputs of the 4067 is connected to a resistor in a chain.  The top of the chain is connected to the tip of a 3 way (‘stereo’) 3.5mm socket; the bottom of the chain is connected to the ring, and the sleeve is connected to pin 1 of the 4067 – the pole of the 16-way switch.  When plugged in, it takes the place of the Stylophone’s own resistor chain.

Note that switches allow you to choose between 1) major and minor 2nd (‘re’); 2) major and minor 3rd (‘mi’); 3) major and minor 5th (‘so’); 4) major and minor 6th (‘la’); and 5) major and minor 7th (‘ti’), as you see fit.  C1/C#1 and C2/C#2, D#1/E1 and D#2/E2 etc. use the same switch, so there are 5 of these switches, not 10.

The reason I chose to do it this way is because of an extremely interesting article – series of articles, actually – which I read on The Tonal Centre website, written by Andrew Milne.  I’m not in the slightest bit concerned that the theory described there is ‘unconventional and some of the concepts . . . quite novel’, as it seems to me to make perfect sense, and presents a coherent view of scales and chords which I’ve found quite easy to understand, and useful to use.  Furthermore, Milne’s motives for writing the articles are ones with which I would hope none of my readers could disagree: ‘not for theory to be an intellectual straight-jacket which smothers spontaneity, but as a springboard for creativity and, even more importantly, as a foundation for exploration’.

Essentially, the articles do precisely as the author says in his introduction: ‘convince you that there is a lot more for the tonal composer to experiment with . . . than just the major and the minor scale.’

I can’t explain everything in the articles because a) there is too much, and b) I don’t understand it all; but essentially, the points I want to draw attention to are these:

1. What constitutes a useful and versatile scale?

A scale should constitute ‘a unified collection of notes – a selection which is in some sense complete and to which any addition is heard to be extraneous’.

2.  What makes a scale useful as a melodic resource?

A scale should be ‘reasonably smooth and even, without sudden gaps which sound as if a note has been omitted, or sudden concentrations of notes which sound as if an extraneous note has been added’.

3.  What makes a scale useful as a harmonic resource?

Because three-note major and minor chords are the basis of our kind of western music (like C-E-G and C-Eb-G), a scale shouldn’t have any notes which aren’t part of a three-note major or minor chord.

Of all possible scales there are only five prime scales which satisfy Milne’s criteria, as above. (These are the main criteria, but see the full article for a couple of others).

All of these scales contain, as it happens, seven notes, and these are clearly the most useful and versatile scales to use.  This was good news for me, as the Bigfoot would inevitably use 7-note scales.

There are 8 different scales altogether in Milne’s system, not just 5, because of  differences between major and minor, and so on, and these 8 variations of the 5 ‘prime scales’ (in the key of C) are:

1.  The diatonic scale, major and ‘aeolian’:

C-D-E-F-G-A-B

C-D-Eb-F-G-Ab-Bb

2.  The harmonic minor scale:

C-D-Eb-F-G-Ab-B

3. The harmonic major scale:

C-D-E-F-G-Ab-B

4.  The melodic scale, major and minor:

C-D-E-F-G-Ab-Bb

C-D-Eb-F-G-A-B

5.  The double harmonic scale, major and minor:

C-Db-E-F-G-Ab-B

C-D-Eb-F#-G-Ab-B

So, there are 8 different scales you can use, which all allow you to make interesting melodies and chords.  Each one has its own ‘character’, and some are much more commonly used than others.

This series of articles seemed to me when I came across it to be an extremely good guide to useful scales, and could be a help to anyone: you could use the description above to work out what scale or scales you commonly use, and then try writing a composition or improvising a solo using a completely different one.  There’s bound to be at least one you’ve never thought of using before!

Bigfoot allows the 2nd, 3rd, 5th, 6th and 7th (D, E, G, A, B in the above examples) to be individually adjusted, so arpeggios and sequences in all – well, almost all! – of these scales are possible.  The double harmonic minor isn’t possible because Bigfoot can’t produce F# and G at the same time; but 7 out of 8 isn’t bad!

So, 16 individual intervals are available  from the Bigfoot, spread over two octaves; the tonic is repeated 3 times, at 3 octaves; the 4th is repeated twice, at two different octaves; the other 10 notes are switchable between a ‘normal’ or ‘flattened’ version, which is semitone lower.

Hang on, that’s only 15 intervals . . . Well, since all 16 Select input combinations from ‘0 0 0 0’ to ‘1 1 1 1’ could be used to produce notes, there might in some circumstances be no way of stopping the Stylophone from sounding; so what I did was to start with ‘0 0 0 1’ (the second output) and make that the lowest note, reserving ‘0 0 0 0’ (the first output) for a rest where no note would sound.  I added a switch so that the first and second inputs could be connected together for those situations when this would be better.

I also added a START/STOP switch, which is what pin 15 of the 4067 does: if connected to +v it stops, and all the switches are disconnected, regardless of the state of the Select inputs; if pin 15 is connected to 0v the switches start to work.  (The 4051 also has this feature).

In practice, I actually installed a second 4067, with the two 4067’s being connected only at the 4 Select inputs (pins 10, 11, 13 and 14).  I wanted to have an LED indication of which switch was connected, and had to separate this function from the resistor chain that produced the notes.

So the pole pin of the second 4067 was connected to +9v via two 1k resistors [not one, as shown in the diagram], and each of the 16 outputs was connected to a green LED (matching the green case the circuit was built into).

4067 2

In order to test the LEDs – and later to test the notes which were being produced – I needed some way of connecting exactly the right input/output to the pole of the switch, so I would know I was adjusting the right preset.  This meant feeding exactly the right combination of  +v (‘1’s) and 0v (‘0’s) to the Select inputs, to get exactly the right output.

I considered four 2-way switches, +v one way, 0v the other way, and changing the notes by moving different switches up and down, as I described before – but it turns out there is a device which does this job very simply, just like turning a rotary switch: a 4 bit binary (sometimes called hex) rotary encoder.  I wouldn’t say these are extremely easy to come by, but this is the one I got:  http://uk.mouser.com/ProductDetail/Alpha-Taiwan/RE2001F-40E2-20F-4B/?qs=yA6kp8fx8Y4fjZ7sDt2l6A%3d%3d.

rotary encoder2

(The above picture shows a typical rotary encoder made by Alpha Electronics.  RS online sell a couple, but looking at the product details, I don’t think the connections of the ‘Code 033’ version they sell is right.  There are lots of 2 bit encoders, and lots of encoders which are not binary or hex.  They won’t work – it has to be 4 bit binary with 16 positions, starting with ‘0 0 0 0’ at position 1 and stepping through the binary numbers 1 – 15, ending up at ‘1 1 1 1’ at position 16. These are referred to as ‘hex’ because the hexadecimal system has 16 numbers in it [usually written as ‘0 1 2 3 4 5 6 7 8 9 A B C D E F’ – a more user-friendly way of depicting ‘0 0 0 0’ to ‘1 1 1 1’]).

I needed to use the encoder for another part of the circuit, which I’ll come to later, but for the time being its 4 outputs were connected directly to the 4 Select inputs, ‘A B C D’, of the 4067s.  Its other connection, ‘Common’, was connected to + volts.  To test it, I used  4 LEDs, and could see that turning it from position 1 to position 16, it automatically output the binary numbers in order from ‘0 0 0 0’ to ‘1 1 1 1’.

It’s worth mentioning an important point, to avoid later confusion, which is that ‘D’ is actually the bit on the left in a binary number such as ‘1 1 0 0’, and ‘A’ is the bit on the right.  You might sometimes see ‘D’ referred to as the ‘Most Significant Bit’ (or ‘MSB’) and ‘A’ as the ‘Least Significant Bit’ (‘LSB’).  That means the number sequence goes like this:

D  C  B  A

0  0  0  0

0  0  0  1

0  0  1  0

0  0  1  1

0  1  0  0

etc.

The other thing about rotary encoders is that they don’t usually have a stop, they just go round and round.  This is fairly useless if you need to know where ‘1’ is, or where ’16’ is, and this is the main reason why I decided to incorporate the LEDs as a visual indication.  The other reason is that sequencers and so forth really ought to have flashing lights on them.

The rotary encoder is the knob on the right-hand side of the Bigfoot, just to the right of centre in this picture:

DSCF0003

I glued the LEDs in place on the top and connected up the rotary switch.  Sure enough, with each turn the LEDs lit up one by one, one at a time, and now it was possible to tell which was position 1, which was position 2, etc.

Not only that, with the lack of a stop at 1 and 16 – which you would expect with a normal rotary switch – if nothing else I had Method 1 of controlling the Stylophone remotely: a manual method of arpeggiation by spinning the encoder backwards and forwards! . . .

. . . Entertaining, but not the automatic method I was looking for, however, so I moved on to Part 2 of the construction.

23
Aug
12

BigBoy BeatBox

You’ve got a Stylophone, you’ve got a Stylophone Beatbox – but don’t you sometimes wish the two could be combined into one instrument? . . .

Well, now that wish has become reality, with the ‘BigBoy BeatBox’: two great Stylophone products in one!

New Front IMG_1128

As the picture suggests, the BigBoy BeatBox is, in fact, two great Stylophone products literally glued and bolted together, with some of their internal circuitry combined.  The way it was created was like this:

1.  The Stylophone

The Stylophone half of the instrument is, in fact, a recreation of the original ‘Big Boy’ – a regular Stylophone S1 inside a Beatbox case.  As mentioned in an edit to the original post here, I managed to inflict terminal damage on the ‘Big Boy’ by reckless experimentation.  I normally do this before finishing an instrument, this time I contrived to do it afterwards . . . so the first thing I had to do was remove and replace the electronics with a new donor Stylophone I had lying around.

The actual process closely followed the construction of the original, but was made easier because of the sockets and wiring still remaining in the Beatbox case.  First of all, the end had to be sawn off the Stylophone circuit board, which is too long to fit in a Beatbox case; then the lowest 12 notes of the keyboard were connected to the 12 outside pads of the round Beatbox keyboard.  Fortunately, the wires attached to the Beatbox keyboard remained in the case, and just needed connecting to the appropriate Stylophone keys.  The Beatbox’s amp circuit board was taken out, but the Stylophone’s was kept and connected to the Beatbox’s speaker.  A power socket was connected to the Beatbox’s on/off switch, and the Stylophone’s on/off and vibrato switch circuit board disconnected.

I decided to replace the ‘Big Boy’s troublesome original 3-way octave switch with a simple  pitch potentiometer.  I used a 100k for  coarse tuning, in series with a 10k for fine tuning and a 100k variable preset to fix the highest pitch available.  Previous experimentation with Stylophones had taught me they have no objection to going down to very low pitches, but they cease to function – usually temporarily – if the pitch is taken up too high: on resetting, when this happens – by switching the power off and on – sometimes they will begin to work again, sometimes they won’t.

That’s what I did to the original ‘Big Boy’, and there’s no cure apart from throwing the circuit board away and starting again.  The likelihood of this happening is increased because I don’t just replace the tuning potentiometer pin-for-pin – the range of voltages available between the two pins the Stylophone uses isn’t wide enough for very large pitch variations, so I use only one of the pins that the original tuning potentiometer was connected to – the left-hand one – but connect the other one to +v.

The two new pitch controls were fixed to the front (the rounded end) of the Beatbox case, as was a replacement 10k log volume control.  The problem with the Stylophone’s original volume control was not that it wouldn’t work perfectly well, but that it would have had to be on the side of the case which I was intending to fix permanently to  the other Beatbox.

The original ‘Big Boy’ had no vibrato, but I decided the recreation should have a variable control, as fitted to the ‘Alien’, my first Stylophone modification project.  All this involved was connecting a 1M potentiometer instead of an on/of switch between the two vibrato connections next to the power connection on the main Stylophone circuit board.

Apart from an output socket and a switch to cut out the internal speaker, that half of the BigBoy BeatBox was done.

Stylophone half IMG_1132

2.  The Beatbox

The other half of the instrument was a plain Beatbox, with very little in the way of modifications.

(I don’t seem to have written specifically about the Beatbox in the blog, by the way.  Read the user guide here!)

The first thing I did to it was to replace the tuning potentiometer with a larger one of 100k (a direct pin-for-pin replacement this time), allowing for considerable slowing down and lowering of the pitch of the drums and other sounds.

I also followed an excellent example in this YouTube video: http://www.youtube.com/watch?v=xXdelnxXF7A to add buttons in parallel with the ‘Record’ and ‘Play’ pads normally operated by the stylus.  The trouble with the stylus-operated method is the delay in time between activating ‘Record’ with the stylus, and then using the same stylus to stop recording and begin playing the pattern you want to  be looped, as the loop begins the moment ‘Rec’ is selected.  With a small normally-open tactile switch as an alternative method of beginning and ending the recording period, you can be much more accurate as regards timing.

It’s worth mentioning at this point that, like the original Stylophone itself, the Beatbox comes in more than one variety, as far as circuitry is concerned.  I noticed two significant variations between the Beatbox I used in my ‘test to destruction’ phase, and the one that eventually found its way into the finished instrument: in one case, there was a tap from the battery compartment at 3v, which fed into the circuit (via the 3-way tone control) as well as the full 4.5v; and the layout of the circuit board was different.  As it happens, spots on the board marked ‘Rec’ and ‘Play’ were easily accessed in one case – the test unit – but not in the other – the one I was eventually to use.

In my experience, the Beatbox is a very delicate circuit, and it doesn’t take much to do something to it that will cause Record or Play to malfunction, or the output quality of the sound samples to degrade; so, proceed with caution, I’d say.

A third new button I added to this unit was ‘Reset’.  The Beatbox’s method of erasing an old loop and re-recording a new one is to switch the power off and on again.  The original power switch had to be removed as it was on the side of the case which was going to be fixed to the other Beatbox case – and there would, anyway, be a single power switch for both units: so the third button is a direct replacement for the Beatbox power switch, but now a normally-on, push-to-break, supplying power to the Beatbox side only.  To reset and re-record just takes a quick press and release of this button.

Finally, a new 10k log output volume pot was fixed to the front of the unit.

Beatbox controls IMG_1131

Beatbox halfIMG_1131

3  Joining the two halves

Superglue and two bolts was all that was required to physically join the two Beatbox cases, plus a couple of holes through which wires could pass from one side to the other.

The easiest way to connect the power seemed to be to detach the +v and 0v wires from the battery compartment on the Beatbox side and attach these to the original ‘Big Boy’ Stylophone side, which had a power input socket.

In the end I decided that whereas the battery compartment of the Big Boy Stylophone had to be removed – there was no room for batteries as well as the Stylophone circuitry – the one in the Beatbox could be used.  So I wired in a power cable which ran out of the back and was just long enough to reach the power socket in the other half.  In this way the instrument could be powered from an external source, or from internal batteries, and there was no need for a switch to change from one to the other.

The two 10k volume controls were taken to two individual tone controls.  I just wanted something fairly rudimentary, so I used a circuit from http://www.muzique.com/lab/swtc.htm called the ‘Stupidly Wonderful Tone Control’.  The component values I used were quite different – and I have no idea why – but the format of the circuit was more or less the same, and gave a little bit of variation to the tone.

After the tone controls, the two outputs were joined with 10k resistors to the original Beatbox volume control, and then the ‘Big Boy’ Stylophone amp circuit board.  This meant that the sound from both units was going to the ‘Big Boy’ half , and the volume and tone of each unit could be independently varied.  The input to the Beatbox amplifier was disconnected, and the speaker removed.

Now I had an instrument in a single conjoined case, with a single power supply and output through a single speaker or output socket.  There were two styluses and two keyboards, and – as I had hoped, but not expected with any confidence – both styluses work on both keyboards!  This means that both units can be played with a stylus in each hand, and quicker and more rhythmic patterns can be played.  I extended the wires to the styluses slightly to make sure they could reach right across both keyboards.

When using two styluses on the ‘Stylophone’ side of the unit, the ‘Beatbox’ side needs to be set to ‘Play’, otherwise that stylus will only work for a very short period and then not sound any more.  I haven’t timed the ‘very short period’, which might give a clue, but this is probably to do with the circuitry which regulates the maximum of 8 seconds (at ‘normal’ tempo) for which the Beatbox can record.

The complete circuit looks something like this:

BigBoy Beatbox circuit 2 Corrected sm

The following pictures show the inside of the instrument shortly before it was finished:

Inside Stylophone half with numbers 6 in IMG_1127

This is the ‘Big Boy’ stylophone half.

1 = speaker cutout switch

2 = socket for external 4.5v power source

3 = 3.5mm sound output socket

4 = Stylophone S1 circuit board with permanently soldered connections to first 12 keys

5 = socket for extra stylus, remaining from original ‘Big Boy’ design – not really needed now

6 = fine tune pitch control

7 = variable preset to prevent the Stylophone’s highest note from being too high and causing the circuit to malfunction

8 = coarse pitch control

9 = Stylophone volume control

Beatbox half with numbers 7 in IMG_1126

This the Beatbox half.

1 = the original Beatbox output and ‘mp3’ input sockets, no longer used

2 = Stylophone tone control

3 = Beatbox tone control

4 = Original Beatbox volume control, now master volume

5 = ‘Reset’, push to break switch

6 = wires going to ‘Play’ and ‘Record’ push to make switches mounted on top surface of Beatbox

7 = original Beatbox tempo switch, still in-circuit, but no longer used

8 = Beatbox pitch control

9 = Beatbox volume control

The features visible on the outside were these:

Front DSCF0003 3

Before finishing I gave the speaker grilles a coat of blackboard paint.  The reason I used blackboard paint was a) it was the only black paint I found in my garage not in a spray can, and 2) it gives a pleasing matt finish, but is more durable than water-based matt emulsion.

The rear of the instrument was sprayed black and the holes masked with painted material.

New Back IMG_1130Front & Rear View IMG_1129_30

22
Aug
12

Stylophones 3 – The Stylophone 350S, Part 1

A series on the Stylophone can only reach a climax with the mighty 350S!

The question of why the original Stylophone sold in its millions and became a world-wide success story, and the 350S didn’t, has long been debated.

According to http://stylophonica.com (‘The official home of the Stylophone’), it was ‘too costly, and lost the key uniqueness of the Stylophone itself, which was its small size and mass-market appeal’ – but it certainly wasn’t through of a lack of features.

You may be familiar with the Stylophone, but not the 350S: if so, then to start with, a run-down of its capabilities is required:

First of all, it’s certainly true to say that it’s much larger than the regular Stylophone – which is, after all, about the size of an inch-and-a-half thick postcard.  Here’s my 350S together with the regular-sized ‘New Sound’ Stylophone with which it shares many of its design cues:

350s + New Sound IMG_1050

The 350S is a souped-up Stylophone in every way: instead of the Stylophone’s 20 notes – an octave and a half – the 350S has 44.  That’s three and a half octaves, and you can see in the picture the difference in length between the two keyboards.

Not only that, the 350S has eight voices, as opposed to one (or even the S1’s three), and some of these are themselves in different octaves.

The voices are designated ‘woodwind’, ‘brass’ and ‘strings’.  In these days of sample-based synths, none of these sound terribly much like what they say they are, but they have the general qualities of these instruments – and, despite what you may read, one or two of them are quite like the distinctive tone of the regular Stylophone that we all know and love!

These voices are:

four ‘Woodwind’ voices pitched at four different octaves, and described (like organ stops) as 16′, 8′, 4′ and 2′;

two ‘Brass’ voices at 16′ and 8′; and

two ‘Strings’ voices at 4′ and 2′.

Because these voices are pitched at different octaves, from 2′ to 16′, in all no less than six and half octaves are available from the bottom of the keyboard to the top.  This is almost as large as a ‘professional’ 88-note synthesizer keyboard.  Up to two of the voices can be combined at any time, one each of the four octaves.

As well as this wide range of voices, the 350S has a variety of built-in effects.  Like the regular Stylophone, one of these is Vibrato – and two speeds are available, rather than one.

There is also a two-speed ‘Decay’ facility: as well as the usual Stylophone ability to hold a note as long as the stylus is in contact with the keyboard, when the Long or Short (actually, ‘short’ or ‘very short’) Decay button is pressed, the note will fade out while the stylus is still in contact.  According to the nicely-produced, LP-sized User’s Guide that comes with it, this enables the player to obtain ‘a percussive effect rather like  piano.’

350s rocker switches IMG_1053 sm

However, as can be seen from the above picture, this is only the beginning of the 350S’s abilities.

The fast or slow ‘Reiteration’ button (second from the left) can be used to imitate the sound of a banjo or mandolin, and the 350S even has a second stylus which is used to produce these effects.

Normally, whichever stylus is being used, the ‘regular’ or ‘reiteration’, it’s held in the right hand; but it’s possible to play two notes at once in reiteration mode by using the reiteration stylus with the right hand, and playing lower notes with the regular stylus in the left hand.  It doesn’t work the other way round, and it doesn’t work in ‘normal’ mode, i.e. without either the fast or slow reiteration switch pressed.

The white tuning control can also be seen in the above picture – handily placed on the front of the instrument, unlike its counterpart in the regular Stylophone, which is always hidden underneath.

The most unusual effect, though, has got to be this:

350s Photo control IMG_1052

Above the volume control is the 350S’s secret weapon – the ‘Photo Control’.  This device, operated with the player’s left hand while the stylus is wielded in the right, can be set to control the volume, amount of vibrato or low-pass filter cut-off point – acting as a ‘waa waa’.

On the side of the 350S, next to the Photo Control, are three 1/4″ mono jack sockets.:

350s sockets IMG_1051

While one of these is ‘sound in’ and another ‘sound out’, the middle one is a socket for a foot pedal that replaces the Photo Control – either because the player would prefer to control volume, vibrato or waa with their foot, or because the ambient light level is too low for the Photo Control to be effective.  A 50k – 100k potentiometer does the job, according to the User Guide.

My experience of light-dependent controls like this – and I’ve made a number of them – is that they are really only fully effective when quite a bright light is shining on them, which is not always the situation when you sit down to play.

Unsurprisingly, this magnificent machine requires a fair amount of juice, so it’s powered by not one, but two weighty PP9 batteries, connected in series to provide 18v of power to the 350S.  [Edit: but see notes below about powering the 350S].  The batteries are housed underneath the rear of the instrument:

350s back IMG_1056

The battery covers look as if they’re held in place by screws, but these aren’t really screws: they click into place when pushed, and just require a slight turn with a screwdriver or a thin object to loosen them.  (The User Guide suggests a coin, but in my experience modern coins are too thick to perform this function.  Maybe a 5p would do it).

This is the User Guide that came with the 350S:

p1

350sBooklet

Reliable information on when the 350S first came on the market, how many were sold, etc. seems hard to come by.  http://stylophonica.com says: ‘No more than a few thousand 350S’s were ever sold’; http://stylophone350s.com/ says ‘Dubreq, the manufacturer of the original Stylophone created and produced the Stylophone 350S beginning in 1971 . . . fewer than 3000 were ever produced’ and quotes a Ben Jarvis (son of Stylophone inventor Brian Jarvis and re-founder of Dübreq in 2003) estimate that only 200-300 working units are probably still available worldwide.

I’d be surprised if the numbers were quite this low, but they’re certainly not common, and those that appear on eBay in the UK frequently command in excess of £100, rarely less than £70. Stylophone350S.com in the States have access to a recently discovered cache of mint condition boxed examples, which are now on sale.  Their website tells the story of this amazing find.  [Edit: this site is now defunct, unfortunately.  I don’t know what happened to the mint condition 350S’s that were for sale there].

The back of the 350S is removed by undoing 4 large screws in the corners and two very small screws under the front, and reveals two printed circuit boards: a thin, narrow one at the front containing the keyboard and the resistor chain – not discrete resistors, but what I’ve previously called ‘resistor modules’, since I can’t remember what the proper name for them is – and a large, rectangular one with everything else on it, including potentiometers, sockets and switches:

Just opened IMG_1068

The circuit boards themselves come away quite easily: there are 4 screws, clearly visible in the above photograph, which hold the keyboard in place, and 6 similar ones for the larger board.  The volume control knob doesn’t need to be taken off – it fits through the hole surrounding it – but the plastic nuts on the three sockets need to be removed.

This is what the other sides of the boards look like:

Component side IMG_1070

Here we see the larger items across the middle of the board, from left to right: the three sockets, the volume control, the eight voice and effect switches, the pitch control and the on/off switch.  If I was an electronics expert, I could tell you what the rest of the components do; but I can’t.  I can only surmise that the round inductor next to the left-hand switch is to do with the waa circuit; the LDR (light-dependent resistor) to the left of that is the ‘Photo Control’.

LDR & Ind New IMG_1144

The black ‘hood’ that partly surrounds the LDR was slightly damaged when I came to look at it, and it’s quite possible that I did this myself when I opened the case.  It was easily repairable with a spot of superglue, but watch out for this if you’re looking inside yours.

The ferrite core inductor is a Mullard FX2236.  In this close-up you can see that mine looks a bit broken.  I don’t know enough about these things to know if this means it isn’t working properly, but, while by no means common, they can be found – perhaps more easily in the UK than elsewhere – so I shall certainly consider replacing it.

According to the experts at www.stylophone.com, under the heading ‘VITAL INFORMATION WHEN BUYING A 350S… PLEASE READ CAREFULLY!’, one of the components you can see here – which they describe as the ‘Amp-ic’ – is highly prone to failure.

The related website, the Stylophone Information Centre at www.stylophone.fsnet.co.uk says: ‘The circuit board carries an IC which controls sound output, and this component (long since obsolete) is the single- most likely cause of the 350S to break down. If this happens . . . the unit will only be heard if played through a separate amplifier, if at all.’

The symptoms to look out for are: ‘when the stylus is applied to the keyboard, only a very faint sound is heard (if even audible at all), which fades away rapidly . . . Even with the volume control turned up to max, the sound will still be very low – then quickly fall away. The user will then be left with a ‘dead’ 350S.’

The chip in question is this one – the black one with six legs in the middle of the picture:

MFC6070 New IMG_1145

It’s a Motorola MFC 6070, 1-watt power amplifier  – ‘designed primarily for low-cost audio amplifiers in phonograph, TV and radio applications’, according to the datasheet.

If you don’t know what a phonograph is, ask your grandad, he’ll remember them!  The use of this antiquated vocabulary confirms what is said above.  If you find the datasheet for this chip, it says ‘Device discontinued – consult factory’; if you try to buy one on the Net, you’ll mostly find specialist sites, dedicated to sourcing obsolete parts.

As a matter of fact, you can, at the time of writing, get one on eBay for about £20, but you aren’t going to want to do that: the problem doesn’t arise, apparently, just because 350S’s are now all old – it even used to happen to quite new ones.

Stylophone.com told me that ‘the original chips as fitted . . . were working very close to their breakdown point voltage-wise. Although theoretically all the chips supplied to them should have worked, Dübreq actually had to batch-test the chips to find those with an acceptable working voltage range, especially the maximum voltage’ (which is meant to be 20v). ‘We’ve seen some of these chips.’ they said, ‘ running extremely hot (basically too hot to touch) by simply switching the instrument on, before even playing a note.’

That’s not to say the MFC6070 was a particularly unusual part at the time – they were used all over the place, and even the venerable VCS3 synthesiser used one as a driver for its spring reverb circuit.  However, as the site offering VCS3 spares, http://www.synthi.com, says: ‘The Achilles heel of the VCS3/Synthi AKS are the now obsolete and ultra rare semiconductors that it uses’ . . .

This made me think twice about powering the 350S with a mains-powered adapter: the increased risk of overdoing the voltage and blowing the chip might not be worth it.  Dübreq themselves did apparently produce some 350S’s with an ‘adaptor socket factory-fitted’, but ‘this led to many of them blowing the chip.’

I’m not quite as worried as I was, however, as stylophone.com are now marketing a new module, the ‘Stylophone ACM’, which can be retro-fitted to an ailing 350S – or even to a working one, as a precautionary measure – to get round this problem altogether.

The circuitry inside this unit is not operating close to its limits, and makes it much safer to run the 350S from an 18v adapter.  (And if you buy a reconditioned 350S from stylophone.com, it will already have one of these in it).

[Edit: see comments from Christian Oliver Windler below relating to powering the 350S.  He concludes from his tests that the 350S could – and should – be powered at less than 18v, and preferably less than 15v.  Some of the above problems and their expensive solutions can thus be avoided.

As with the original Stylophone, by the way, there appear to have been various upgrades during the course of production, and it’s interesting to note that some of the components inside Christian’s 350S differ from those in mine].

As a matter of fact, this is not the only ‘obsolete’ component in the 350S.  Although the resistors, capacitors and transistors that fill the circuit board are not commonly used in new designs nowadays, they’re still readily obtainable; the round silver integrated circuit over on the right-hand side, just above the tuning control, isn’t.

AY15051 New IMG_1142

It’s a General Instruments AY-1-5051, and what it does is frequency division (presumably for the 350S’s different octaves) – the kind of thing modern CMOS 4000-series chips do with the greatest of ease.  There’s a description on this website: http://www.divdev.fsnet.co.uk/repair2a.htm of how one might make such a replacement (using the example of a 1960s Elka electronic organ).  All I can say it, it looks feasible in theory, but not something I’d want  to be faced with in practice – let’s hope this isn’t a part which is going to fail!

Returning to my 350s, it looked badly in need of a clean up.  There was a lot of dust inside it, and over the years the keyboard had got very dirty:

Corroded keyboard IMG_1072Dust and corrosion IMG_1076

The switches sounded OK – no crackling or intermittent operation, so I left those, and just cleaned the circuit board and keyboard.  The keyboard in particular needed attention from, in order, a soft brush, switch cleaner, WD40 and Brasso.   This seemed to do the trick, and it began to look shiny again.

I cleaned everything, including the switch rockers, the case and the tips of the styluses, and put it back together again.  It now looked much better, and sounded clearly and reliably on every note.

Outside after cleaning IMG_1091

In my next post, I’ll take a longer look under the bonnet of the 350S and see what there is to see.

16
May
12

The SoftPot Stylophone

Ever since I found out about the ‘SoftPot’, I wanted to use one to control a stylophone.

A SoftPot, if you’ve never come across one, is a type of slider potentiometer – but not a metal one with a knob, like a fader on a mixer: it’s a wafer-thin piece of flexible plastic, and you operate it by pressing on it with your finger, or an ‘actuator’ – something like a pen will do, but it’s better if it has a rounded end not a pointed one, as that won’t damage the thin plastic. It looks like this:

softpot1

(This is one which still has its backing sheet.  The SoftPot itself is transparent, and sticky on the back).

The normal SoftPot value is 10k. When I looked at stylophone circuits, I realised that in most cases 10k isn’t going to do much. The pitch pot I added to The Alien – a modern reissue stylophone – was 2.2M, and although that amount of variation in pitch wouldn’t really be necessary, 10k would only represent a few notes.

So I looked at one of the original 1970s stylophones, and saw more possibilities there, so I bought one from eBay with a slightly damaged keyboard.

The definitive guide to the sounds and circuitry of the original stylophone is at http://www.waitingforfriday.com/index.php/Reverse_Engineering_the_Stylophone, but the particular circuit variation of the one I had was not quite the same as the one they had. The circuit of mine was like this:

Original Stylophone circuit

The values of the resistors are a bit blurry in this scan, but you can see that 10k isn’t going to affect the pitch very much if connected to the resistor ladder on the left – along most of the scale, this would represent only about 2 or 3 semitones.

So I concentrated on the area where there is a tuning pot and a resistor to +v and resistor to ground. The tuning pot, which was 25k, allows the stylophone to be tuned, but doesn’t really cover more than about half an octave – still not enough to play tunes effectively.

At first, I tried varying the 470Ω resistor to +V and the 820Ω resistor to ground, but to little effect: adding a 1k variable resistor to the +V end, in series with the 470Ω, and turning it down a bit did seem to help, but in the end the effect I wanted to achieve – a variation between top and bottom of a couple of octaves – was achieved first of all by reducing the tuning pot value to 10k, the magic number, the same value as the SoftPot.

Secondly, the stylophone version I was working on had a resistor in parallel with the tuning pot – a very small one of about 270Ω. Replacing this with a resistance of 1k seemed to do the trick – and in fact I added a 1k potentiometer, as this would function as a narrow-to-wide control of the note range, in tandem with the 10k tuning pot.

A 3.5mm stereo switched socket on the side of the stylophone would allow the stylophone to function normally, when required, but anything plugged into the socket would replace the tuning potentiometer in the circuit. This is how the SoftPot would be attached.

That part of the circuit now looked like this:

SoftPot Stylophone 2

and the SoftPot Stylophone looked like this:

SoftPot Stylophone right high angle IMG_0906SoftPot stylophone back corner IMG_0907

The next thing was to make a unit for the SoftPot which could be plugged in when required. This was quite a minimalist design, and was put together like this:

SoftPot Stylophone 4

The SoftPot, as previously mentioned, is sticky on the back, so was stuck to a piece of 2mm acrylic sheet cut to fit on top of the keyboard, just clear of the power and vibrato switches, and nestling inside the lip on the right hand side. Underneath this was stuck a smaller piece of 2mm acrylic which fitted inside the keyboard cut-out, and stopped the whole thing from moving as it was played.  These three layers were stuck together, but weren’t stuck down to the keyboard.

The soft pot terminals came attached to a 3 pin socket, the same size as the ones you get for PCB headers. I had some of these, so made up a lead with a 3.5mm stereo plug on one end, and a 3-pin PCB header plug on the other.

SoftPot attachment 2 IMG_0903

You may be able to see from the back of the attachment how it was put together to fit firmly into the keyboard recess:

SoftPot Stylophone w back of attachment IMG_0908

The SoftPot assembly fitted in place, and was ready to go. All it needed was an actuator – like a pen, but with a rounded end. And, of course, the stylophone has one of these already: the stylus which gives it its name! So the SoftPot Stylophone can still be played with the stylus in the traditional manner, but moving up and down the SoftPot, like a ribbon controller.

SoftPot Stylophone Complete high angle IMG_0909

There was just one more change to make to the circuit before this could happen. The Stylophone sounds when the +V in the stylus contacts a key, which is in turn connected somewhere within the resistor ladder. Now that the keys had been covered up, there would be no sound without a connection between the resistor ladder and +V – the stylus only pushes the SoftPot together, and the connection is made internally.

As with The Alien and The Hedgehog, I simply made an internal connection between +V and one of the resistors in the ladder – the highest note – operated by closing a switch. Try as I might, I couldn’t arrive at a situation where the SoftPot Stylophone was silent until the Softpot was activated, but still gave a good note range.  So I added a volume control – a feature which any stylophone would benefit from – and when you play, you can turn the volume down when not sounding a note with the SoftPot.

Before finishing up, I added a socket to allow the SoftPot Stylophone to be operated from an external power source, a switch to cut out the internal speaker (this is not done automatically when the lineout socket is used), and a switch to cut out the low-pass filter in the line-out circuit.

These original stylophones are famous for having a simple resistor-capacitor tone control on the line-out circuit which is not in the circuit to the internal speaker. This is the main reason why stylophones sound so different when the line-out socket is used. When you see pop musicians who use the stylophone at live gigs holding their instrument up to the vocal mic as they play, this is not mere theatricality: it is theatricality, of course, but it’s also the only way to get an unmodified stylophone to sound the same to a stadium or festival audience as it does to you when you play it ‘unplugged’ at home.

The other end of the circuit now looked like this:

SoftPot Stylophone 1

Finally, I made a small modification for the benefit of a future project which I haven’t yet started on. I added another 3.5mm stereo socket configured in a similar way to the SoftPot input socket. In normal or SoftPot operation the resistor ladder is connected into the circuit; but anything plugged into this socket replaces the resistor ladder.

IMG_0912

13
Jan
12

Jack and the StyloSim

My next programming project was designed as an experiment to see if Pure Data could deal with QWERTY keyboard input, USB input and audio input all at the same time.

I planned to make an audio effects device, using a Stylophone for the audio input, plugged into the laptop’s 3.5mm (1/8″) stereo mic/line in socket; the laptop keyboard; and a nice twin-joystick device I found on eBay.

The joystick device was called ‘USB Simulator’ (‘For Airplan Heli’) and had the model number FS-SM020.  The two joysticks were quite good to use – not the kind you grip in the hand, but bigger than the thumb-operated joysticks you get on a game controller, plus each of the 4 axes had separate adjusters which you could use to fix the centre of the joystick’s range of control.  There were a couple of buttons on the front, which you can see on the bottom right and left, but these proved to be cosmetic only once I opened the case and looked inside.

StyloSim6sm

I couldn’t find out much about this device on the internet, except that it was, as its name implied, normally used for flight simulation – presumably to simulate a radio-control transmitter – and, in fact, it came with a CD, probably containing the simulation program.

The case was quite large, and there would be ample room inside for further circuitry.  I may look at this possibility later, but for the moment I made no alterations to the device, intending just to use the two joysticks: a bandpass (‘wah wah’-type) filter and volume for the left one, and a binaural panning control for the right one.

The first problem to be overcome was to make sure the audio input from the Stylophone couldn’t be heard, only the output from Pure Data, which would hopefully be the audio input modulated by the joystick effects.  This was achieved by the simple-to-use and very handy audio-routing program Jack.

Jack works by running an app called JackPilot.  When opened this presents a small window like this:

Actually, the top button on the left reads ‘Start’ when opened, but I took this screenshot after clicking it and starting the Jack server.  The normal procedure is to open Jack, start all the programs involved in your routing scheme, then click ‘Start’, and then, when it’s ready, ‘Routing’.  (Just occasionally, you may have to start some audio running through a program before Jack recognises it, but mostly that isn’t necessary).

The Routing window looks like this:

jack2

All the inputs are in the left-hand column, all the outputs on the right; it always shows the System audio in and out.  In this instance I was just practising, so I only used Pure Data, but I would frequently have Logic running, too.  To set the route, click on all the inputs and outputs in turn (they are shown in red when being edited), and click on the item(s) you want them to be connected to before moving on to the next one.

At the beginning of the Pure Data program I put the ‘Print’ and ‘Open’ instructions, as I did for the Theresynth and Cybersynth (see previous posts):

This configuration enabled me, once I’d plugged in the Stylophone (audio input) and Simulator (USB input),to check the Device number of the Simulator and open the Device so the ‘hid’ object would receive and deal with the output from the two joysticks.  When I clicked the ‘Print’ message box at the top, the following was printed in the Pure Data window, telling me that the Device Number was ‘0’:

StyloSim4

(It also gave the Device’s name ‘FS-SM020’, which it hadn’t done with the particular game controller I used for the Theresynth and Cybersynth).

As the Device number was 0, I amended the ‘Open’ box to show this number, and clicked it.  Then I clicked the ‘Print’ message box at the top again, and it showed me the controls it could recognise:

StyloSim5

The 4 axes of the joysticks can be seen (‘abs_x’, ‘abs_y’, ‘abs_z’ and abs_rx’, I think, and I can’t remember if any input was recognised from ‘abs_ry) – and also 3 buttons, but the button function hadn’t been implemented in this device.

I clicked the on/off toggle switch, applied the stylus to the Stylophone keyboard, and sounds issued forth – a very good sign!

The Pure Data StyloSim program had three inputs:

StyloSim3

On the left is the [key] object, which receives input from the laptop keyboard.  In the end, I added only the box with [== 114] in it: 114 is the ASCII code for the ‘r’ key, so the program only responds to the letter r, turning a reverb effect on or off.

[Edit: I later changed this to 119, the letter ‘W’, to avoid conflict with another program that used ‘R’ for a different function]

In the middle is the audio input, [adc~] (analogue-to-digital converter), which leads to the output stage.

On the right is the [hid] (Human Interface Device) object, receiving input from the 4 axes of the joysticks.  The [route] objects separate the 4 inputs and send them in different directions for their various functions (bandpass filter, volume and binaural panning).

All the effects worked – although the panning was less binaural than left-to-right; I’ve heard better.  This is the complete patch, showing the objects I used, and the mathematical calculations required to get it right.

StyloSim2

The patch can be downloaded from here.  (Click ‘Save Link As’).

This proved that Pure Data could combine information from the keyboard (or an external USB QWERTY keyboard) and [hid] to work on an audio signal entering simultaneously.   As  can be seen from the following picture of the set-up in action, I used ‘The Alien‘, my first Stylophone modification, as the audio source.

StyloSim1sm

This instrument has a ‘drone’ function, so it’s possible to put the stylus down and operate both joysticks on the Simulator at the same time.  Both the joysticks, incidentally, are centre-sprung, meaning that all values return to the central ones, except the y-axis of the left one – the bandpass filter.  This means the centre-frequency of the filter can be set and left while other parameters are adjusted.

Here’s a sound file illustrating the StyloSim:

It’s more of an example than an actual piece, just to show what the StyloSim does.

It’s slightly edited, but only to make it a bit shorter, otherwise it’s exactly as it sounded when played. There’s no post production effects on it, I just hit the ‘r’ button to turn on the StyloSim’s reverb before I started.

There are three parts: the first part is the Stylophone played with the stylus in the conventional manner; the second part uses The Alien’s ‘drone’ feature and variable pitch and vibrato controls; the third part is played with the ‘feedback’ switch on.

[Edit: more modifications have been made to the StyloSim joystick (although not for this particular use).  See this post].




andymurkin

June 2018
M T W T F S S
« Apr    
 123
45678910
11121314151617
18192021222324
252627282930  

Enter your email address to follow this blog and receive notifications of new posts by email.

Advertisements