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 
 Forum index » DIY Hardware and Software » Microcontrollers and Programmable Logic
PIC12F675 based Sub-Oscillator
Post new topic   Reply to topic Moderators: State Machine
Page 1 of 1 [5 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
AT



Joined: Mar 18, 2013
Posts: 6
Location: North Carolina, USA
Audio files: 1

PostPosted: Mon May 06, 2013 10:33 pm    Post subject: PIC12F675 based Sub-Oscillator
Subject description: 1 in, 2 out
Reply with quote  Mark this post and the followings unread

Greetings.

Newbie here.

This is still under development so maybe is premature, but...I am building a PICSynth (Kevin Godwin variety, dual) and wanted a suboscillator. Using a flip flop was a usual option, but thought I would try cloning a wave off the main PIC's wave outs into a pin set up for a high/low edge interrupt on a PIC12F675, and then toggle it every so often...voila: Clone-wave sub-oscillator, which works the entire default PICSynth output range. I haven't installed the master waveshaper with octave divider yet but I tink one would want to run this sub from the master outs of the PICSynth chip, because otherwise the subs could end up too low once things divided. On the plus side you end up with easy octaves up the other way, with the main waves set lower.

Since the output of the PIC is a square, I then added portion of the wave shaper for the PICSynth (integrator) to get (sort of) a triangle, and then used Nicolas Woolaston's tri+square-> sawtooth shaper in combination to get something that's more than a square out.

I'm probably killing something the way I have it set up because I have not much idea what I am doing, am big-time op-amp newbie, but it works and sounds alright so far. The sample mp3 is very thin (not much bass) due to the RadioShack mini amp I used, and then that going into a digicam which would have thinned it out anyway.

It's only a single PIC12F675, a 20 MHz resonator, a 10k pot set up Electric Druid style, a couple capacitors and a resistor basically for the suboscillator itself. The wave shaper and that I have it set up for two waves there is what adds the complexity. You can see how small the basic subosc is in the small inset.

I have a pot to adjust options using the PIC's analog input,
The ranges are software delimited as so (currently):

0 is off
1 is both outs as input clones (over-drives the output)
2 is 1 as clone, 1 @ 1 octave down
3 is 1 @ 1 octave down, 1 @ 2 octaves down
4 is 1 @ 1 octave down, 1 @ 2, then a 5th back up
5 is both at 2 down, a 5th back up
6 is 1 at 2 down, the other at 2 down, 5th back up
7 is...1 at 2 down a fifth back up, then another that's same, but way on down...

If you toggle a pin every 1st, 2nd, 3rd, 4th, 6th wave in, that's what it does in various combinations.

The saw out is more a shark fin, but it sure sounds cool. With both saws going, it really sings (didn't have both hooked up, I think the sample was one square, and one saw)

I am currently applying the same notion with a larger and faster PIC to clone out a true add-on frequency tracking oscillator (including software PWM, no filter needed) with individual detuning and octave shifts up or down. Since you are tracking the main oscillators, it will also auto-add any main-oscillator's portamento yet still change with the regular keyboard.

Could work with any oscillator outputting a good clear high/low edge I'd think.

rc


sub.jpg
 Description:
Sub-oscillator board showing PIC, and dual wave shapers.
 Filesize:  228.92 KB
 Viewed:  73 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

sub.jpg



synth.jpg
 Description:
This is the PICSynth dual in progress.
 Filesize:  182.55 KB
 Viewed:  71 Time(s)
This image has been reduced to fit the page. Click on it to enlarge.

synth.jpg



Wave 2.mp3
 Description:
Audio sample of initial oscillators, with Sub-oscillator coming in, then the various options.

Download
 Filename:  Wave 2.mp3
 Filesize:  850.63 KB
 Downloaded:  126 Time(s)

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



Joined: Feb 08, 2010
Posts: 44
Location: UK

PostPosted: Wed May 08, 2013 1:55 pm    Post subject: Reply with quote  Mark this post and the followings unread

This is really interesting as I was planning to use the PICsynth as the basis for a simple string synth.
Do you plan to make the .hex file public or sell the programmed PICs ??
Back to top
View user's profile Send private message
AT



Joined: Mar 18, 2013
Posts: 6
Location: North Carolina, USA
Audio files: 1

PostPosted: Thu May 09, 2013 12:40 am    Post subject: Reply with quote  Mark this post and the followings unread

Quote:
Do you plan to make the .hex file public or sell the programmed PICs ??


Hi, I am not sure yet, but otherwise I need to make sure the last setting is correct. I might have a little glitch in the potentiometer code, perhaps the ADC timings are off, but generally it works perfectly.

I use PICSimulatorIDE from Oshon Software http://www.oshonsoft.com/pic.html. Works nice for such as this, and you can simulate things fairly well, saving a lot of false starts.

If you build a PICSynth, which I recommend as Kevin is very helpful, keep it simple, and you'll be done in no time.

I over-worked mine, so am still not done. (2 x PICSynth chips, 2 x Subosc, 2 x PWM boards, 2 x VCF/VCA, 2 x Steiner VCF, 2 x PT2399 delay (Synthrotek) 2 x Real RingMod (1 synthrotek, 1 home grown), and when i get the kinks worked out, a pair of VOX HUMANA filter boards (polymoog clones). Plus 3 band tone control perhaps.) So,that's how overboard you can go! Plus LFO's... Smile

Tayda Electronics has all the parts you need generally, good deals on the potentiometers and knobs. The hardest part will be working up a keyboard! I used Yamaha PSR's (1 thru 12 models are great for this, 49 keys, $10 to $20 usually)...but you'll need to extract the keyboard part (easy, it is a single unit) then take out the circuit board for the contacts, and reverse all the diodes (it uses a reverse logic), which is a time taker, and also, connect 6 groups of keys into 4 octaves total, plus relocate some of the C's to be part of the adjacent group. It's not difficult in principle, but is tedious. I will have a how-to posted some time. An organ keyboard might be better, easier, depends on model.

If you get going and there's no resolution of status here by then, contact me. rc

(Sorry to be overly wordy)

----
www.soundcloud.com/artly-there
Back to top
View user's profile Send private message
ejr27233



Joined: Feb 08, 2010
Posts: 44
Location: UK

PostPosted: Thu May 09, 2013 4:16 am    Post subject: Reply with quote  Mark this post and the followings unread

My plan is to keep it very simple at first, see what it sounds like and add a filter and saw animator if it needs it. The problem at the moment is searching for gold wire to make the key contacts ...no success so far
Back to top
View user's profile Send private message
Quintus



Joined: Feb 20, 2011
Posts: 13
Location: UK

PostPosted: Sat Jul 06, 2013 9:00 am    Post subject: Reply with quote  Mark this post and the followings unread

Kimber Allen (Swanley UK) organ suppliers have gold contact wire on page 50 of part 2 of the pdf catalogue:

Gold Clad Wire .015" dia code GS109/02

I bought some bus bars from them a couple of years ago certainly worth giving them a ring if you are still looking.

http://www.kimberallen.8m.net/contact.html

Quintus
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Moderators: State Machine
Page 1 of 1 [5 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 » Microcontrollers and Programmable Logic
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
e-m mkii

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