logo64 Posted July 4, 2005 Report Share Posted July 4, 2005 GreetingsI am trying to get my AIN to work with my MidiboxSID. I checked, and it's getting 5V - and it seems to be connected properly to the CORE. I grounded A0-A7 on J2, J3, and J4, and left IC2, IC3, and IC4 in place.I set the LFO1 wav. to AIN, and had this LFO modulate oscillator pitch. I put a 0 - 3.5V staircase LFO input into the A0 input of J1, and it doesn't seem to modulate the pitch at all. In fact, it drops the pitch really low, so you cannot hear it. Switching back to SIN modulates the oscillator fine - AIN kills it.Can I use MIOSStudio to check to see what's wrong? I tried querying MIOS_AIN_LastPinsGet and then putting the input oscillator into A0-A5, hoping to see it change as I switched inputs. It just changed from 04 05 to 05 04 (can't remember exactly what these params were). Do I need AIN.INC? Seems like MidiboxSID v1.7 is set up for the AIN module (ENABLE_AIN_LFO_WAVEFORM 1).Anyway, here is a picture of my FracSid. It is obviously a work in progress. I didn't label anything, because it is easy to guess what's what. Top row AIN, with two extra jacks TBD. Bottom row is reserved for AOUT whenever I get one together. Bottom right is for SID-IN and SID-Out.thanks for listening to me ramble,-gerald Quote Link to comment Share on other sites More sharing options...
logo64 Posted July 8, 2005 Author Report Share Posted July 8, 2005 Good news, I got my AIN module working with my MidiBox SID. Weird thing is... A0-A5 are reversed??? I'm using the SmashTV board, and in order to figure out what the heck was going wrong, I uploaded the ain_example2_v1_3 program. This one checks POT 0 for activity. It sat there, doing nothing until I ran an LFO into A5. What the Heck? I re-installed MboxSID V1.7 and tried running an LFO into A0, and when I set LFO6's waveform to AIN, sure enough, it worked??? It isn't modulating much, even though the LFO is puting out 0-3.5V. What does the AIN module expect on the input?What are A6 and A7 for on the board? I have these connected to the front-panel, and they're normally grounded. I ran a square-wave from the LFO into A6, and the modulation amount jumps every time the square wave is high. Are these trigger inputs? Should I connect them to 5V when they're not in use?Any ideas on what is going on would be much appreciated.-gerald Quote Link to comment Share on other sites More sharing options...
logo64 Posted July 9, 2005 Author Report Share Posted July 9, 2005 In keeping with tradition, I will reply to my own post again.There are three AIN example files posted, ain_example1_v1_3.zip, ain_example2_v1_3.zip, and ain_example3_v1_3.zip.ain_example1_v1_3.zip Purpose:;  -> Sends a MIDI event (CC #7) when first pot (#0) is moved;  -> Prints the value on LCDThis example turns off multiplexing. If you have AIN inputs A0-A5 wired as shown in the AIN PDF, and you run thisprogram hoping to check your AIN board, you will find that it only responds when you apply a signal to pin 13 onthe 4051 chip. This is input A6, NOT A0. I thought I had a wiring problem, but if you look at the datasheet for theCD4051B, pin thirteen is channel 0. In fact, the channel assignments are all mucked up relative to their designationin MBHP_AINX4_V2a.pdf.Now, I thought I had to rewire everything... unless the _software_ untangled this mess for me. So I modifiedain_example1_v1_3.zip in the following way so that it would be relevant to the midibox SID.USER_Init movlw 0x06 ; enable the first 6 analog inputs call MIOS_AIN_NumberSet ;; use the AIN 4051 multiplexers movlw 0x03 ; 8 bit resolution call MIOS_AIN_MuxedI ran the program, and put an LFO into each input A0-A5 as identified in the AIN PDF, and what do you know- it works beautifully! I can watch the input value oscillate slowly, exactly as it should, and it gets the inputchannel number right. So - multiplexed, the A0-A5 inputs are labeled properly. Unmuxed, they're quite different.I modified the Midibox SID v1.7 input from #if ENABLE_AIN_LFO_WAVEFORM movlw 0x06 ; enable the first 6 analog inputs call MIOS_AIN_NumberSet call MIOS_AIN_UnMuxed ; not multiplexed movlw 0x03 ; 8 bit resolution#endifto#if ENABLE_AIN_LFO_WAVEFORM movlw 0x06 ; enable the first 6 analog inputs call MIOS_AIN_NumberSet movlw 0x03 ; 8 bit resolution call MIOS_AIN_Muxed ; multiplexed#endifMinor changes, but... why would you enable 6 inputs, and then have it unmuxed? And, shouldn't themovlw come before the call statement?Now my SID is capable of being modulated, and the inputs are numbered correctly.I wish that everything were running perfectly, but... it sounds like the modulation is hoppingvalues from 0 to the AIN input value and back. For example - if I run a ramp into AIN0, withvalues 0,5,10,15,20,25,30,35,40,45 etc.It seems to be modulating the pitch like this:0,5,0,10,0,15,0,20,0,25, etc.Really rough sounding. The modified ain_example1_v1_3.zip shows that the CORE is getting theinput right, so I would guess that somehow, it just isn't sending exactly these values to the pitchof the oscillator. I can hear the pitch rise and fall, with the un-shifted note underlying it. Kind oflike wavetable arpeggios on a SID, oscillating between pitches really fast.Since my posts on this subject have been met with silence - I'm beginning to wonder if anyoneuses the AIN inputs as LFO's on their SID?-gerald Quote Link to comment Share on other sites More sharing options...
logo64 Posted July 9, 2005 Author Report Share Posted July 9, 2005 My last comment may have been right on the money... nobody uses AIN for the analog LFO waveform inputs, do they?  They just put the CORE in unmuxed mode, and put the inputs directly onto RA0 - RA5? That would explain why the v1.7 main.asm codehad it unmuxed, and it would explain why nobody is chiming in with answers to my AIN problems - because they don't use AIN boardswith SID's?Ok - Just yanked the AIN board altogether, and connected A0-A5 to Core J5... and it works beautifully, absolutely beautifully! I'm tempted to delete this thread... -gerald Quote Link to comment Share on other sites More sharing options...
illogik Posted July 10, 2005 Report Share Posted July 10, 2005 My last comment may have been right on the money... nobody uses AIN for the analog LFO waveform inputs, do they?  ...., and it would explain why nobody is chiming in with answers to my AIN problems - because they don't use AIN boardswith SID's?yup i guess :-\ tempted to delete this thread... no don't it's good/interesting to read about those things/results, i like your modular approach to the sid, especially the possibillity to modulate the sid with other control generators then the "usual" lfo's and envelopes. (different is good ;D)keep it up! marcel Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.