electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Articles  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links  |  Store
Forum with support of Syndicator RSS
 FAQFAQ   CalendarCalendar   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   LinksLinks
 RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in  Chat RoomChat Room 
Live streaming at radio.electro-music.com

  host / artist show at your time
<on air> Faux Pas Quartet and friends Music From Last Thursday
Please visit the chat
 Forum index » DIY Hardware and Software » Lunettas - circuits inspired by Stanley Lunetta
Simple 2 Chip Drum Machine
Post new topic   Reply to topic Moderators: mosc
Page 1 of 1 [24 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Mon Aug 08, 2011 7:42 pm    Post subject: Simple 2 Chip Drum Machine Reply with quote  Mark this post and the followings unread

I was testing out a circuit that uses a 4066 to switch signal on and off, so I needed a bunch of audio signals to test with. I set up a schmidt trigger oscillator on a 40106 and sent that to a 4040 so I had my 4 audio signals to test with. I mixed the 4 outputs from the 4066 so I could hear if the switch was working correctly. I turned the pot on the oscillator and when it dipped below audio level I noticed a familiar rhythm. When I thought about what the 4040 was doing, it all made sense. I explain it all in the video below.



The 4066 isn't needed - just the 40106 and 4040. Then highpass filters for the hihat and snare and low pass filter for the kick.
Back to top
View user's profile Send private message
MusicMan11712



Joined: Aug 08, 2009
Posts: 712
Location: Upstate New York USA
Audio files: 148

PostPosted: Mon Aug 08, 2011 7:56 pm    Post subject: Reply with quote  Mark this post and the followings unread

Nicely done video! Congrats on the accidental drum machine.
Steve
Back to top
View user's profile Send private message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 5978
Location: San Antonio, Tx, USA
Audio files: 258

PostPosted: Mon Aug 08, 2011 10:30 pm    Post subject: Reply with quote  Mark this post and the followings unread

Yes, well done! I can understand the circuit from your description, however can you post a schematic?

As we discussed in chat, I'm looking forward to featuring this circuit on The Les Hall Show this Fruday. Should be fun, I'll play that video.

Les

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Tue Aug 09, 2011 7:08 am    Post subject: Reply with quote  Mark this post and the followings unread

Here is a better audio example recorded with the line-in on my computer:

http://www.jacobwatters.com/music/drumsample.mp3

Again, it is passively mixed so it doesn't sound too great when all mixed together. If I solder this up I will actively mix it and use pots to control the volume of each part. Also, I am using very basic filters. I'm certain that there are other filters that can be used that would make each part sound better, so I included both the basic schematic that any filters can be added and the schematic for the filters that I used.


2chipdrum.gif
 Description:
 Filesize:  27.04 KB
 Viewed:  825 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

2chipdrum.gif


Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sun Dec 18, 2011 6:57 pm    Post subject: Reply with quote  Mark this post and the followings unread

I wired this up again to test it out with the clock output of my C-MOnSter synth. I spent a bit of time working on the filters for snare and hi-hat and actively mixed the sounds. Also, the beats were on the off beat - maybe the 4040 inverts the output or the 4029 and 4514 in the sequencer. So I had to invert the clock before using it.

It is now up to 5 chips, and still a one trick pony, but it is sounding good Very Happy


drumsample.mp3
 Description:
Sound sample of simple drum machine clocked from the sequencer in my C-MOnSter synth.

Download
 Filename:  drumsample.mp3
 Filesize:  1.83 MB
 Downloaded:  329 Time(s)

Back to top
View user's profile Send private message
tjookum



Joined: May 25, 2010
Posts: 353
Location: Netherlands
Audio files: 26

PostPosted: Mon Dec 19, 2011 3:38 am    Post subject: Reply with quote  Mark this post and the followings unread

seriously cool, good design and even better explanation. Im glad to see your working on a drum machine to compliment that awesome synth you made.
_________________
There he goes. One of God's own prototypes. A high-powered mutant of some kind never even considered for mass production. Too weird to live, and too rare to die.
Hunter S. Thompson
movies
noise
Back to top
View user's profile Send private message
MadScientist



Joined: Nov 28, 2011
Posts: 63
Location: Denmark

PostPosted: Mon Dec 19, 2011 5:25 am    Post subject: Reply with quote  Mark this post and the followings unread

Looks like a fun circuit. Smile

I'd suggest adding something like a 470-560 ohm resistor, or a bit larger perhaps, in series with all the 50K potentiometers. Doing this will limit the output current from the inverters to sane values, when you turn the pots all the way down to zero resistance. Without them the inverters would be standing with one leg in the grave, when the pots are at zero. 470-560 ohm should be OK for up to 0-15V supply voltage, use a bit larger resistance if you are the belt-and-suspenders type. Wink

Frank.

Edit: Must admit I am not sure that I understand how this is wired together. Suspect there may be parts of the schematic we don't see perhaps?
Edit, part II: Ah, there are two 40106s. Very Happy
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Mon Dec 19, 2011 7:03 am    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
Must admit I am not sure that I understand how this is wired together.

It has changed a bit since the early schematic. The functioning part is pretty much the same, but the filtering and mixing has more stuff. I have to do a schematic for it before I solder, so I will post the latest version when the schematic is complete. I plan on using a pot for each sound at the mixing stage.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Mon Dec 19, 2011 2:21 pm    Post subject: Reply with quote  Mark this post and the followings unread

Here is the latest version with better filtering.

The only thin i'm not too happy with is the kick. I am going to play with that a bit. I may need to add and active filter.


SimpleDrumV1-1.gif
 Description:
 Filesize:  32.17 KB
 Viewed:  548 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

SimpleDrumV1-1.gif


Back to top
View user's profile Send private message
MadScientist



Joined: Nov 28, 2011
Posts: 63
Location: Denmark

PostPosted: Mon Dec 19, 2011 2:53 pm    Post subject: Reply with quote  Mark this post and the followings unread

Some random suggestions:

*) Replace U4, the TL071, with a TLC271 or a similar, single supply op-amp. Feed U4 pin 3 from a voltage divider, made from 100K connected to +5V, and 56K connected to ground. This should put about 1.8V on pin 3, given your 5V supply. Decouple U4 pin 3 to ground with something like a 1uF capacitor. This will make for a *much* improved mixer. The TL071 is not a good choice for your setup (unless you like the sound, of course. Smile ).

If you use a TLC271, then connect pin 8 to pin 3.

*) Once the mixer is working, increase R9, R11, R13 and R14 to equal and much higher values, at least 100k. Right now your mixer - if it was working - will have a 4.7k input resistance. I'm guessing this is probably not what you want? Among other problems this will severely distort your filter following U3.

*) Belt-and-suspender suggestions (unless you like to run 'em hard): Add 470 ohm resistor in series with R4. Add reverse voltage protection diodes to U2 and U3, for instance a pair of 1N4148. Connect cathodes to pin 14, anode to ground. This will largely protect the ICs from the negative supply voltage pulse, generated while their 'pulse' capacitors, C4 and C5, recharges. Right now they do so by drawing current through U2 and U3 - in reverse.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Tue Dec 20, 2011 8:05 pm    Post subject: Reply with quote  Mark this post and the followings unread

MadScientist - Thanks for all the suggestions. You were correct about the resistors. The distortion on the snare sounded great, but it was drowning out the kick too. I will try adding distortion another way.

I am using a virtual ground on the TL071. I know it's not the best method, but it is getting the job done for now.

Also, I added the diodes that have the black end at pin 14 and the other end to ground. Is that the way it should be? The other way stopped the sound from working.

I made a few other changes, but have been delayed making the schematic because my wife knocked the breadboard off the desk and I had to put a lot of it back together again (and I didn't remember most of what I had changed). The holidays are coming soon, so it might not be until next week when I get a chance to make the schematic.
Back to top
View user's profile Send private message
MadScientist



Joined: Nov 28, 2011
Posts: 63
Location: Denmark

PostPosted: Wed Dec 21, 2011 1:51 am    Post subject: Reply with quote  Mark this post and the followings unread

Cynosure wrote:
I am using a virtual ground on the TL071. I know it's not the best method, but it is getting the job done for now.

The virtual ground is fine, that isn't the issue. The problem is that a TL071 cannot really work on a supply voltage of 5V. The output is listed in the data sheet as being able to be driven to typically 1.5V below the positive supply rail, and 1.5V above the negative. At worst these limits are 3V below and 3V above. So, worst case, your op-amp will not be able to swing *any* voltage around the virtual ground, best case will leave you with 2V of somewhat undistorted output. Maybe. Confused

The result is that you are very/extremely likely to have a flat topping output from U4, regardless of level. This will add harmonics back into the signal, harmonics you may be trying to filter out. A TLC271 is a common part, which is guaranteed to be able to drive its output between 0 and 3.5V on a 5V supply, giving you more wiggle room. The virtual ground I suggest puts about 1.8V on pin 3, which of course is just about halfway between 0 and 3.5V.

If your load is always above 1Kohm, then the positive limit increases to 4.2V, in which case 2.1V may be a better choice for the virtual ground level. (Looking closer at the datasheet, then you should connect pin 8 on a TLC271 to ground in your case, not pin 3.)

Cynosure wrote:
Also, I added the diodes that have the black end at pin 14 and the other end to ground. Is that the way it should be? The other way stopped the sound from working.

Correct, and they shouldn't chance the sound in any way, they just make life easier for U2 and U3.

Cynosure wrote:
I made a few other changes, but have been delayed making the schematic because my wife knocked the breadboard off the desk and I had to put a lot of it back together again (and I didn't remember most of what I had changed). The holidays are coming soon, so it might not be until next week when I get a chance to make the schematic.

Suggest asking her to please be more careful in the future. Laughing

I won't be doing much tinkering until after the holidays either, and E-M also seems to be winding down a bit.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Thu Dec 22, 2011 6:32 pm    Post subject: Reply with quote  Mark this post and the followings unread

Thanks again for the advice. I ended up using a TL071 to distort the snare on purpose.

Here is what I have on hand. Would any of these work for the mixing?

LM324
LM386
MC1458
UA1458
NTE 778A
MC1741

Or should I go get a TL271?

New schematic to be posted before the new year.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sun Dec 25, 2011 3:17 pm    Post subject: Reply with quote  Mark this post and the followings unread

After some deliberation and testing, I decided to use a TL072 - one opamp to give extra distortion the the snare and one to mix. The distortion is actually sounding better on the drum sounds - especially the snare. It sounds too zappy without it.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sun Dec 25, 2011 8:04 pm    Post subject: Reply with quote  Mark this post and the followings unread

Here is the final schematic. Thanks again for all the input. I decided to go with the TL071's because I want the distortion. I even added a Wasp distortion filter to the kick (modified from the JH Wasp schematic).


SimpleDrumV1-2.gif
 Description:
 Filesize:  47.19 KB
 Viewed:  497 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

SimpleDrumV1-2.gif


Back to top
View user's profile Send private message
MadScientist



Joined: Nov 28, 2011
Posts: 63
Location: Denmark

PostPosted: Wed Dec 28, 2011 1:30 am    Post subject: Reply with quote  Mark this post and the followings unread

Looks great, love the unconventional thinking involved.

If some day you do decide you need a more suitable op-amp for a 5V design, then a LM324 should do nicely for most functions. Has about the same voltage limits as the TLC27x series I mentioned.
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sat Jan 28, 2012 7:24 am    Post subject: Reply with quote  Mark this post and the followings unread

Here is the final schematic and sound demo video. I made a few minor changes - the kick sounded a little different once soldered up so I adjusted the cap values.



And here is the post in the build thread with a pic of the panel: http://electro-music.com/forum/post-352701.html#352701


SimpleDrum1-3.gif
 Description:
 Filesize:  47.95 KB
 Viewed:  782 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

SimpleDrum1-3.gif


Back to top
View user's profile Send private message
JingleJoe



Joined: Nov 10, 2011
Posts: 876
Location: Lancashire, England
Audio files: 14

PostPosted: Sat Jan 28, 2012 9:32 am    Post subject: Reply with quote  Mark this post and the followings unread

I say, that kick drum is admirable Very Happy I hope you don't mind if I copy your design for it Wink
_________________
As a mad scientist I am ruled by the dictum of science: "I could be wrong about this but lets find out"


Green Dungeon Alchemist Laboratories
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sat Jan 28, 2012 10:22 am    Post subject: Reply with quote  Mark this post and the followings unread

JingleJoe wrote:
I hope you don't mind if I copy your design for it Wink

You are more than welcome to. That is why I posted the schematic.

You should be able to trigger it from any clock pulse, so it would work in a module too.

Just let me know when you do use it. I'd like to see how you implement it. Smile
Back to top
View user's profile Send private message
Sonic



Joined: Dec 02, 2010
Posts: 84
Location: Toronto

PostPosted: Sat Jan 28, 2012 12:15 pm    Post subject: Reply with quote  Mark this post and the followings unread

Lovely job Jacob!

I quite fancy building an UM-TSS. I think I'd want to be able to vary the rhythm a bit. Perhaps a logic chip alongside the 4040 and a patch bay à la Inventor? Or separate CV in jacks to control the individual sounds? Or both?
Back to top
View user's profile Send private message
JingleJoe



Joined: Nov 10, 2011
Posts: 876
Location: Lancashire, England
Audio files: 14

PostPosted: Sat Jan 28, 2012 12:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

I don't quite get your kick drum circuit but I think I just need to have a proper read-through of this thread, however I can't right now because my brain is too tired from working on my latest invention all day
Would you be so kind as to give me a run down of whats happening with the kick circuit? Or point me to which posts explain it?

_________________
As a mad scientist I am ruled by the dictum of science: "I could be wrong about this but lets find out"


Green Dungeon Alchemist Laboratories
Back to top
View user's profile Send private message
Cynosure



Joined: Dec 11, 2010
Posts: 623
Location: Toronto, Ontario - Canada
Audio files: 34

PostPosted: Sat Jan 28, 2012 6:05 pm    Post subject: Reply with quote  Mark this post and the followings unread

Sonic - I thought about doing that when I was working on it - a patch bay with various logic chips to control the triggers. I also thought about trying a shift register loop as a tap trigger. In the end, I decided to keep this build simple since it was more of a test of what I can do. I have plans for a very complex cmos based drum machine. It will take a lot of time and money to build, but I hope to get around to it some day.

JingleJoe - I will try my best to explain what I can, but I honestly do not know most of it. I build mostly by trying out a bunch of different stuff until it does something interesting, and then I adjust values to tweak the sound. Here is my best guess as to what is happening:

    The ON pulse goes through an inverter. Using the output of the 4040, the kick was triggering between beats compared to the hi-hats and snare. Inverting it solved that problem. You might not need to do this if you are triggering it another way.

    The ON pulse goes through a capacitor(C10) and into the power pin of a 40106. The cap gives a small reserve of power for the chip.

    Once powered, the 40106 starts to oscillate the oscillator that is wired up on pins 1 and 2. As the capacitor(C10) drains, the rate of the oscillator slows down, making the sound start high and finish low. This gives it a bit of a zap. Increasing the value of C10 will increase the duration of the kick sound because it will take longer to drain the power reserve in the capacitor.

    The oscillator sound passes through a diode. In the case of the kick, I just used this to prevent the 40106 oscillator from using the capacitors further on in the circuit for oscillation. The hi-hats and snare also use it for highpass filtering. The resistor to ground after the diode is needed to help pull the sound through the diode. I think it is called a pull-down resistor.

    The sound goes through an inductor. This acts as a lowpass filter, but doesn't lower the volume as much as a cap to ground.

    The sound goes into a Wasp distortion circuit. This is taken from the JH/Fonik schematic, but I modified some of the cap values. As far as I can tell, it uses an inverter to clip the sound, and has a cap to ground for lowpass filtering. Maybe they are linear cmos amplifiers?

    The sound is split. One division goes through a low value capacitor(C17), which acts as a highpass filter. The other split goes through a pot and joins up with the highpassed sound. When the pot restricts the sound, then more of the highpass sound comes through. When the pot is opened, then the unfiltered sound comes through and you don't hear the highpassed effect.

    R13, C18 and R14 are part of the mixing circuit for actively mixing the sound with the hi-hat and snare.
Back to top
View user's profile Send private message
JingleJoe



Joined: Nov 10, 2011
Posts: 876
Location: Lancashire, England
Audio files: 14

PostPosted: Sun Jan 29, 2012 2:54 am    Post subject: Reply with quote  Mark this post and the followings unread

Cynosure wrote:

    The ON pulse goes through a capacitor(C10) and into the power pin of a 40106. The cap gives a small reserve of power for the chip.

    Once powered, the 40106 starts to oscillate the oscillator that is wired up on pins 1 and 2. As the capacitor(C10) drains, the rate of the oscillator slows down, making the sound start high and finish low. This gives it a bit of a zap. Increasing the value of C10 will increase the duration of the kick sound because it will take longer to drain the power reserve in the capacitor.

OH thats whats I was missing! Thankyou Very Happy I got many parts of the circuit e.g. pull down resistors and mixing and oscillators, but I missed that, a very interesting idea, thankyou Smile
I have observed the output of a 40106 osc slowly powering down from a still charged psu cap; both the pitch and peak voltage of the wave change- first increasing in frequency because the hysteresis zone shrinks, then decreasing in pitch and volume decreases the whole time. So it;s like you get an envelope and pitch control all in one!
Fantastic, thankyou for putting me on the right track Smile

_________________
As a mad scientist I am ruled by the dictum of science: "I could be wrong about this but lets find out"


Green Dungeon Alchemist Laboratories
Back to top
View user's profile Send private message
tjookum



Joined: May 25, 2010
Posts: 353
Location: Netherlands
Audio files: 26

PostPosted: Mon Jan 30, 2012 3:52 am    Post subject: Reply with quote  Mark this post and the followings unread

another awesome machine cynosure. I like the way you added a clock sync and made everything work together.
_________________
There he goes. One of God's own prototypes. A high-powered mutant of some kind never even considered for mass production. Too weird to live, and too rare to die.
Hunter S. Thompson
movies
noise
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Moderators: mosc
Page 1 of 1 [24 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
 Forum index » DIY Hardware and Software » Lunettas - circuits inspired by Stanley Lunetta
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum
emSynth

Please support our site. If you click through and buy from
our affiliate partners, we earn a small commission.


Forum with support of Syndicator RSS
Powered by phpBB © 2001, 2005 phpBB Group
Copyright © 2003 through 2009 by electro-music.com - Conditions Of Use