Jump to content

din (not only on midio ) question


superdavies
 Share

Recommended Posts

HI!  :)

This is my question and it is regarding the configuration of the buttons on midio or in mb64, so we are talking about the DIN module.

As most of you already know, I'm midifying an old hammond organ for use it to control VST as B4...I'm probably at the end of my project: the keyboards works, the drawbars and the other pots works...so maybe this is my last problem :-\

I have the mb64 core using for the pots and for some other buttons ( the hammond classic controls ) such as the VIBRATO ON-OF, PERCUSSION ON-OFF VOLUME NORM-SOFT and so on.

My problem is that all these controls are two way selectors or three way (deviator ) in a on-off mode not as push button; so for instance, if I take the percussion on-off selector when I turn ON it can send midi on signal but how to made it do the midi OFF signal if the another position is from on to off (from close to open)? If it were a push button just first push and it send On signal, another push and it send off signal, but it isn't...and i really want to maintain the original layout of the hammond organ console.

Is there a possibility for doing this working on the firmware? My mb64 is working with the ain64_din128_dout128_v1_3 apps ( the asm one)

Another question: Is there the possibility that ( as we can do with the pots ) for example I have percussion ON activated and when I turn off and on the midibox it recognise the last value before the rebooting?

Thank you very very much!!!

Andrea

Link to comment
Share on other sites

buttons don't toggle like you described...

if you hold a button in, or in your case you have a switch closed the value of the pin will read as closed...

so you just need to write the firmware to do what it needs to do

it would be easy to write a onload function to do what you described, if I'm right in thinking you are talking about switches rather than momentary buttons...

Link to comment
Share on other sites

If these switches are wired so their positions send to different DIN pins, the modification to the code would be kept to a minimum. I'm not a coder yet (cause I'm yet to connect my LCDs-core-INs-OUTs together, and plough every waking moment from then on  ;D ). My impression of how the control surfaces interpret things is as follows:

1) You close a switch.

2) The core sends a MIDI message or string dependant on the function related to that switch.

3) The core goes back to looking for a change in the control surface, or a MIDI message to interpret.

...so, if you give each switch position its own DIN, then:

1) You change a switch position, thus changing the state of the control surface.

2) The core sends a MIDI message or string dependant on the function related to that switch.

3) The core goes back to looking for a change in the control surface, or a MIDI message to interpret.

The key word here is change. If you leave the switch in a given position, the core would still send the message only once. So all you need to do is choose a MIDI command to be sent by the switch. In terms of power down/restore, I'm not sure but I think the core sends the current state on powerup, so by using big 'ol clunky switches, you might reduce coding even more!

As I say, I'm a bit of a n00bie, but this is my grasp of things thusfar. Anyway, there's nothing to be lost in playing around!

Link to comment
Share on other sites

Yes

This is my opinion too! It is digital so it's not important if the circuitry is open or close, the only thing that matter is the changing of the state; but my real problem is after the start-up!

What I have to do?

Think about the hammond organ and think about the NI b4...think about the percussion on-off button: in the hammond you have a switch (like the one for turn up the light in your home) maybe a 2 way switch so you have the circuit open or close...it's analog

In the NI b4 as for other "Midi" apps for doing this function you have a push button: first push=perc on, second push=perc off it doesn't matter the circuit-state open or close, just the function sending.

Now I really want to use the hammond consolle I have here at home so I don't have push buttons, I have only switches: I think I have two possibilities...

I can make a little modification to the firmware so it would recognize that it must send control change message when switch turns from open to close and the same control change when it turns from close to open, I think it's possible, this possibility use only one pin of the din but have the problem that ,for instance ,if I turn off the midibox with the percussion switch in position ON and I move the switch to OFF while the midibox still off, when I power the midibox on (assuming that the midibox can recognize the last value ofter poweron ) I have the percussion switch to OFF but the percussion on NIb4 in on.

Second possibility: using 2 din and a 2 way switch: if the circuit is close in the first din= control change message for percussion, if the circuit is close in the secong din= the same control change message for percussion, thinking it has the advantage that maybe can recognize the value at startup.

Is it possible? What's the "yes and no" of this configuration?

Please, please help!

Andrea

Link to comment
Share on other sites

I would say that the 2pin- 2way switch is the better configuration. It just seems a little more, I guess, fail-safe. I'm sure that the PIC is stable and more than capable of remembering what state it was in at power-down, though. It really is up to you. If you need to save DIN pins, or to have the software application show you its configuration on the controller, then go with the pin saving toggle switch option. If you dont need to (which it seems you don't), then go for the wire-per-setting configuration. Since this is planned as a very specific controller, then the choice is absolutely up to you.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...