Connect with us

1V/Oct Control for oscillator

Discussion in 'General Electronics Discussion' started by CiaranM, Aug 17, 2012.

  1. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    hello. I have schematics for a VCO, VCA, VCF etc, but I have nothing that tells me how to configure/make a keyboard. I need a keyboard that will provide a gate and pitch CV. The oscillator uses 1V/oct control. I think the keyboard has something to do with a potential divider but I'm not sure. Can you help me by explaining what circuit(s) I need to build? Thanks!

    Note: I'm going to make an analogue synth, so monophony is fine. I think I need to add another oscillator for another note. Can someone explain how this is done?
     
    Last edited: Aug 17, 2012
  2. GreenGiant

    GreenGiant

    830
    5
    Feb 9, 2012
    I would assume that a typical keyboard would have a small set (like 5-10) keys that work like voltage dividers and are based around one frequency each

    so for example you use a voltage controlled oscillator that works at say 440Hz, and have some of the lower keys change the voltage to a slightly lower (or higher) voltage that lowers the frequency to the next note

    This is the best I can do with the information that you have provided, we need as much detail as possible please
     
  3. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    huh? I didn't know that a VCO had a specified frequency. That would be because of octave, semi, and fine configurations right?
    Here is the schematic for the CV processing part of the circuit, if it helps. http://www.birthofasynth.com/Thomas_Henry/pdf/VCO-1/vco1_schem1.pdf

    You can see the '1V/OCT' input jack at the top. I am concerned with how to build a controller/circuit to act as the pitch input. I'm not sure how I would configure the keys to give differing voltages. Would each key have a different value of 'R1', or 'R2'? What about gate? is that just a separate circuit being made/broken by the pressing of keys? is there a way to prevent the pitch from going 'weird' if two keys are accidentally pressed?
    I'm not sure how I can be more specific, sorry.
     
  4. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    The best way is digitally. You can pick up MIDI keyboards fairly cheaply. You may be able to buy or find a design for a MIDI to control voltage converter that will produce a voltage that follows the 1V/octave convention, and a gate signal. If you want to get into microcontrollers, you can make this converter fairly easily. It would get more complicated if you need to support glissando, bender or vibrato, though.

    There are other ways of course. Old monophonic keyboards are based on resistor chains. The Minimoog is the only one I know in detail. It feeds a constant current into a resistor chain at a point chosen by the key that's being pressed. This produces a 1V/octave control signal directly. The gate signal is actually generated from a separate set of contacts on the Minimoog keyboard (Pratt and Read) but could easily be generated by the current source, which can provide a signal that indicates whether there is a load on it or not.

    So in case it's not obvious, the keyboard has a chain of resistors of the same value, and high accuracy (1% was the best you could get in those days; this is one reason for the always-out-of-tune sound of early analogue synths) and every key is a switch that connects the resistor chain at that point to a common contact. The keyboard is open circuit when nothing is pressed, but when a key is pressed, it presents a resistance that is related to the position of the key that's pressed.

    When two or more keys are pressed, one gets priority - either the highest one, or the lowest one, depending on which end of the chain is grounded. On the Minimoog, the lowest one gets priority.

    Another approach would be to use a voltage divider made of a chain of resistors, with each key connecting a different point in the chain to a common output connection, but this suffers from the "pitch going weird if two keys are accidentally pressed" problem that you mentioned.

    What hardware do you currently have? Do you have the physical keyboard with keytops etc? Are you planning on buying one?

    Do you have any microcontroller experience?
     
    Last edited: Aug 18, 2012
  5. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    hi Kris! is this what you mean by 'resistor chain'? I assumed that a higher current will generate a higher pitch, so I placed +V to the right of the circuit so that the rightmost keys get the most current. Is this wrong? Conventional flow would mean that its OK, but in real terms it should be on the left side, I think..

    Yes I do plan on buying a keyboard instrument from eBay; it'll probably be a cheap Casio or Yamaha. Unless I suddenly acquire my own plastics manufacturing plant, hah.

    I have very vague microcontroller experience. I can't say that my tutor helped me understand it..

    I have a question regarding power supplies; if I have several modules (VCO, VCF, etc) can they operate off the same power supply (15V in my case), or do they each need their own?
     

    Attached Files:

  6. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    Yes, that's a resistor chain. It's the type I described in the paragraph starting with "Another approach ...". If you press two keys simultaneously, you get an output voltage that doesn't correspond to either key; most of the time, it won't be an exact semitone voltage either.

    Yes, you can and should run multiple modules from the same power source. Make sure the power supply can supply enough current for all modules (added together).

    When you buy your keyboard and open it up, you'll probably find that the contacts that are closed by the keys are not metallic, and won't give you a clean connection. Most likely they'll be carbon-coated rubbery dome-type contacts as used in many computer keyboards. This very much limits your options, because you need a clean connection (no resistance) to use the current-driven resistor chain method.

    These carbon contact keyboards are scanned by a microcontroller or microprocessor to determine which keys are down. This information would be passed to the synthesiser section either internally (within a single IC or between ICs) or via MIDI, if the keyboard has a MIDI output and you're using an external synthesiser.

    This is why I suggested converting MIDI to a control voltage and a gate signal. Google "midi to control voltage converter", there are lots of hits.
     
  7. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    great, thanks. so if I'm using 5 octaves, then I'll need 60 resistors, is that correct? and the voltage should be 0.08333 higher/lower as successive resistors are added? one thing; if a key is pressed, then it forms a potential divider with 'R1' being the resistors going to +V and 'R2' being the resistors going to -V. When a different key is pressed, R1 and R2 will be different; will this complicate things? Or do all resistors/trimpots merely need to be the same value.

    OK, I'll look up midi to control voltage converters. I never considered them, since I thought MIDI was only for computer use...

    once again, thanks for your help!
     
  8. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    All the resistors need to be the same value. For five octaves you'll actually need only 59 resistors, because you only need a resistor BETWEEN semitones. The bottom and top keys are the ENDS of the string. But you've got the right idea.

    You haven't addressed the issue I raised about contact resistance and simultaneous keypresses. If the keyboard uses carbon-coated dome type contacts, you will have variable resistance across the contact, which won't work if you use the current source method. You could use the voltage divider string method (as in your diagram) because then the contact resistance becomes much less important (because no current flows through the contact, so no voltage is lost across the contact resistance), but you then have the problem that pressing two keys at once generates an ill-defined voltage. You will have to address this issue sometime.

    The definition "1V/octave" means that 83.333 mV represents a semitone, no matter where it appears on the scale. So, assuming you will use the voltage divider string method, you just need to ensure that each resistor has 83.333 mV across it. The whole string needs to have 83.333 mV * (number_of_stemitones - 1) across it. Each junction in the string will have a voltage that represents the correct control voltage for that key. When you press the key, that voltage will be fed to the synthesiser.

    You will also need to create a gate signal that is active when any key is held down, and inactive when no key is held down. This could be done by weakly biasing the common line at an invalid voltage (e.g. -1V) and having a comparator that detects that voltage; while no key is down, the common line will follow that invalid voltage and the comparator will detect it and drive the gate signal false; when any key is pressed, the voltage from the resistor string will override the weak bias voltage and the comparator will detect a valid voltage and drive the gate signal true.

    Unless you can get a keyboard that has metal (i.e. zero-resistance) contacts, so you can use the current drive method, I really think a MIDI-to-control-voltage converter is your best option.
     
  9. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    I see what you're saying about contact resistance. If I do make a resistor chain keyboard, I'll keep in mind not to press more than one note!
    Thanks for that bit of maths. I'm beginning to understand how it all comes together. I think I'll use a 5V regulator, or it'll be a hassle when adding power to the circuit.
    A comparator is a type of op amp configuration, right? If the gate is 'false', meaning that sound from the VCO/VCF etc can't be outputted, does this mean that the signals are wasted or not.
    What if I soldered onto the bottom of the contacts? Or would that merely make a bad smell.
     
  10. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    I think you'll find it very hard to avoid pressing two keys simultaneously!

    You'll need a pretty exact voltage for your resistor chain. A fixed regulator will only be accurate to a few percent. The current through the chain won't be high, so I would use a small variable regulator such as a TL431.

    Assuming your resistors are 10 ohms each, the total chain resistance will be 590 ohms, and at 5V that will draw about 8.5 mA. Add say 5 mA for the TL431 (it's a shunt regulator, so it connects in parallel with the chain, and is supplied from a higher voltage using a series resistor), and your total current is 13.5 mA. The series resistor drops from 15V (assuming you power it from +15V) to 5V so it has 10V across it, and it needs to supply 13.5 mA, so it will be around 741 ohms. You can use 680 ohms; it will just increase the current in the TL431 slightly. Then you need a voltage divider with a trimpot in the middle to divide 5V down to 2.5V for the reference pin.

    But I still think you need to address the issue of getting a reliable clean signal out of the keyboard - either using metal contacts, or using a converter from MIDI to control voltage. And no, you can't replace the carbon coating with metal. The whole design of these rubbery dome contacts doesn't give a firm clean contact anyway, and replacing the carbon with metal would just make for a clicky keyboard with lots of contact bounce and unclean switching.

    A comparator is like an op-amp, and you can use an op-amp as a comparator. If the gate is false, the synthesiser doesn't produce any sound, which is essential if you don't have a useful control voltage to tell it what pitch to produce. I don't know what you mean about signals being "wasted". Which signals?
     
    Last edited: Aug 19, 2012
  11. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    what does 'shunt' mean in terms of electronics? is that to do with random power surges? ..will the resistors have to have a high power rating?

    what I mean by 'wasting signals' is that the VCO, VCF is outputting/processing a signal, so when no gate is present does this mean that these signals are still being reduced despite not being heard (thus power is used for nothing)?

    hey, did you find that article you were telling me about previously?
     
  12. (*steve*)

    (*steve*) ¡sǝpodᴉʇuɐ ǝɥʇ ɹɐǝɥd Moderator

    25,174
    2,690
    Jan 21, 2010
    It generally means to apply an alternate current path.

    In this case it means that the regulator draws current in order to produce a stable voltage across itself. In order to do this, it requires a series resistor so that the voltage across it is reduced when the current is increased.

    If you're familiar with zener diodes, they are a form of shunt regulator.

    Google "shunt regulator" for more information.

    no

    Not likely. They need an appropriate power rating. Calculate the voltage across them and calculate the power dissipated. In a shunt regulator this will be constant for a given line voltage.

    Signals are generally low power, so I don't think you're wasting anything, but I'm not familiar enough with your project to comment further. I've just read the relevant parts of the previous post to answer the voltage regulator issues.
     
  13. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    Steve has answered this. No, 1/4 watt resistors will be fine.
    Yes, but don't worry about it, it's not exactly going to be a big contributor to greenhouse gases! The oscillator has to keep running after the key is released, so you can hear the "release" part of the ADSR (attack-decay-sustain-release) envelope.
    Which article do you mean? I can't see any article mentioned in any of my other posts.

    Have you googled MIDI to control voltage converters? You might also want to grab schematics of old analogue synths. The Minimoog stuff is available, at least.
     
    Last edited: Aug 21, 2012
  14. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    I Googled 'MIDI to CV converter', and got a schematic. https://obsoletetechnology.files.wordpress.com/2009/11/midi_cv_f628_add_driver.png
    Its a little bit difficult for me to read, but it'll do. I hope!

    "The oscillator has to keep running.." OK, that's good enough. I read that VCOs produce an output with a high amplitude, but it's fine as long as the electricity bill doesn't suddenly soar!

    Oh, I've got plenty of schematics for various modules. I'll give you links to two great sites if you want. The odd thing is that plenty of envelope generators, LFOs, VCO etc are shown, but info on keyboard control is hard to come by.

    Thanks for your help too, Steve!

    I'll quote you: "I start to suspect that they're just showing off and imagining themselves to be more perceptive than they really are (whether they know it or not).
    My father wrote an amusing article on this subject for a local magazine (NZ Listener, I think). It's a bit dated now, but still funny. I will try to dig it up and post it on this thread.
    "
     
    Last edited: Aug 21, 2012
  15. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    I think you may be able to find a better design for the MIDI to CV converter. I see a few problems with that one, including what looks like an error in the schematic and lots of design decisions that aren't good. The main problem is that the DAC only has 8 bits of resolution, which means the board can only generate 256 different control voltages. Assuming you cover a range of 80 semitones, that means the DAC can only resolve to about 1/3 of a semitone, which is not really exact enough to give a result that sounds exactly in tune. I would use at least a 10-bit converter; 12-bit converters with voltage output are readily available.

    Also, the capabilities of the firmware are very important, unless you don't care about glissando, vibrato etc.

    I was being sarcastic with the "greenhouse gases" comment. The signals within a synthesiser are very low power. They're like a drop in the ocean compared with real power users like heaters and other household appliances. You have absolutely nothing to worry about.

    Ah, _that_ article. I thought that was on a different thread. I'll have a look for it now.
     
  16. KrisBlueNZ

    KrisBlueNZ Sadly passed away in 2015

    8,393
    1,266
    Nov 28, 2011
    I haven't been able to find the article. I'll look again tomorrow.

    Have a look at http://www.midimplant.com/ for a compact MIDI-to-CV converter. There are several others available but they're big and expensive, and this one is probably all you need.
     
  17. CiaranM

    CiaranM

    74
    1
    May 19, 2012
    wow.. 55 euros.. part of the reason I decided to become involved with electronics is so that I could make my own stuff instead of paying for it.. plus I'm always low on funds, haha.
    thanks though. tell me when you've got that article!
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-