2017 was our 20th year online!

Welcome to the Piano World Piano Forums
Over 3 million posts about pianos, digital pianos, and all types of keyboard instruments
Join the World's Largest Community of Piano Lovers (it's free)
It's Fun to Play the Piano ... Please Pass It On!

Shop our online store for music lovers
SEARCH
Piano Forums & Piano World
(ad)
Wessell Nickel & Gross
PianoForAll
(ad)
Best of Piano Buyer
 Best of Piano Buyer
(ad)
Faust Harrison Pianos
Faust Harrison 100+ Steinway pianos
Who's Online Now
56 members (andredatele, 36251, Carey, chopinetto, ChrisGoesPiano, brendon, anotherscott, 16 invisible), 609 guests, and 450 robots.
Key: Admin, Global Mod, Mod
(ad)
Estonia Pianos
Estonia Pianos
Previous Thread
Next Thread
Print Thread
Hop To
Page 5 of 6 1 2 3 4 5 6
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039005 10/24/20 04:18 PM
Joined: Aug 2017
Posts: 983
E
500 Post Club Member
Offline
500 Post Club Member
E
Joined: Aug 2017
Posts: 983
My own approach would be getting some multi-ADC (there are some from TI with 8, 12, 16 even more ADCs), controled by one processor, probably an STM32F4 or F7. That would allow for a simpler yet flexible architecture. Add an EEPROM where you can store configuration and calibration data and you are good to go. Ofc this is speculative only, just to add some ideas to this brain storm. I am not saying this is THE best or THE only approach, that would be mine. Also it would allow some adaptability to drifts of the optical sensors due to aging (e.g. recalibrate now and then).


Kawai ES8, Roland RD2000, Yamaha AG06 mixer, Presonus Eris E5 monitors, Sennheiser HD598SR phones.
(ad)
Sweetwater Gifts That Rock
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039008 10/24/20 04:27 PM
Joined: Apr 2007
Posts: 6,274
6000 Post Club Member
OP Online Content
6000 Post Club Member
Joined: Apr 2007
Posts: 6,274
Well, speaking of fine tuning in the software, I've actually thought of a solution with no trimpots but just well chosen resistors and some way to tilt the small sensor boards towards or away from the hammers through a screw. The combination of both will make it the same as turning trimpots.

One particular problem with per-note corrections in software would be the need for more RAM. Here's why. Currently I measure the the duration between two activations. To produce a MIDI value from this duration I need to first calculate velocity:

velocity = distance / duration.

And then to translate this into MIDI velocity (0-127) I use a logarithmic function:

MIDI velocity = factor * log10(velocity) + offset

(the factor will determine the MIDI dynamic range, and the offset will position that window of values absolutely within the range)

Performing these calculations is kind of expensive especially since the speed of scanning is of highest priority. Which is why I create e pre-calculated lookup map in RAM on startup:

duration -> MIDI velocity

For instance (and speaking from memory), a high velocity strike will have a duration of around 200 microseconds, whereas a low velocity strike would be 9000 microseconds. (for a 1.5mm distance).

This means that I have an array of 9000 8-bit values. If we use a separate lookup table for all the 88 keys, that means 773kB.

However Teensy 3.6 (my initial board) has only 256kB memory. But since I calibrate through trimpots, I don't need separate lookup tables for the keys. I actually thought that I would use only one lookup table for the entire keyboard but it turned out that if I use only one of them, the higher keys will become louder because their hammers are lighter and can more easily be accelerated to higher velocities. On a real piano that the higher relative velocity will be negated by the lighter mass, however with Garritan CFX (and I suppose other software pianos) the velocities are uniform across all the keys, so I had to create one lookup table for each of the note groups (17 in my case for the 85 keys) and introduce a gradual compensation for the higher keys and I tuned the gradation by ear with Garritan CFX. With another software it may require different spread.
----------
Anyway, Teensy 4.0 has 1024 kilobytes of RAM and it would allow for 88 separate lookup tables which means we can use hardwired resistors instead of trimpots, corresponding to a predefined voltage difference that would be produced for a 1.5mm of distance between the trigger points for that particular hammer material and reflectivity. I actually thought of putting white paper stickers on the hammer shank base to make the reflectivity uniform and high but ultimately that wasn't necessary. Even the normal wood surface of the hammers would be good enough, but then I have trimpots. With hardwired resistors, some better uniformity might be required. And if the small sensors boards can be tilted through a screw, that would solve the problem of positioning the virtual trigger points in space. Or to summarize:

1. Mechanical shift of the sensor boards will position the two measurement points.
2. Hardwired resistors will determine the distance between the two measurement points
3. Software correction will account for non-linearity of the sensors (because even if 1 and 2 are the same, a non-linear response of the sensors may contribute to two sensors giving differing measurements)


My YouTube, My Soundcloud
Currently: Yamaha N1X, DIY hybrid controller -> Garritan CFX
Previously: NU1X, ES7, MP6, CA63, RD-700SX, CDP-100, FP-5, P90, SP-200
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039018 10/24/20 04:59 PM
Joined: Apr 2007
Posts: 6,274
6000 Post Club Member
OP Online Content
6000 Post Club Member
Joined: Apr 2007
Posts: 6,274
And something that CRIES for a fix in my current solution is power supply.

In my current solution I have daisy chain of powering where my main power supply (an iPad USB charger) gives power to the first note board and then it transfers it to the second, the second to third, and so on until the 17th (18 in case of 88 keys). The voltage drop is considerable at the last board.

Even changing the USB power cable will necessitate an entire trimpot recalibration because all voltage will change! Sh*t!!! 🤬

Also, the voltage ripple is the worst enemy of my design. I didn’t account for that which is why I only use this iPad charger. All other power supplies introduce too high ripple (one more reason why I think Apple are a serious company. AFAIK they went to great lengths ensuring noiseless power supplies for their devices because they are also audio devices)

Furthermore, I have no separate power lines however the bulk of the consumption goes to the LED-s in the sensors (20mA each). I think separate power lines would be much better.

Also, maybe a regulator at each note module group would be the proper way of ensuring low ripple. It turns out creating a high wattage low ripple supply is almost an unsolvable task...


My YouTube, My Soundcloud
Currently: Yamaha N1X, DIY hybrid controller -> Garritan CFX
Previously: NU1X, ES7, MP6, CA63, RD-700SX, CDP-100, FP-5, P90, SP-200
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039029 10/24/20 05:36 PM
Joined: May 2020
Posts: 233
D
Full Member
Offline
Full Member
D
Joined: May 2020
Posts: 233
Originally Posted by CyberGene
And something that CRIES for a fix in my current solution is power supply.
Also, the voltage ripple is the worst enemy of my design. I didn’t account for that which is why I only use this iPad charger. All other power supplies introduce too high ripple (one more reason why I think Apple are a serious company. AFAIK they went to great lengths ensuring noiseless power supplies for their devices because they are also audio devices)

That may be the best that is relatively inexpensive and readily available, but it is far from perfect. I have a 1y old Macbook Pro and when I tried using that for VST I definitely can tell if it's running on the battery or on the power supply. The second introduce audible noise.

Originally Posted by CyberGene
Also, maybe a regulator at each note module group would be the proper way of ensuring low ripple. It turns out creating a high wattage low ripple supply is almost an unsolvable task...

Getting clean power supply is extremely complicated and expensive. As I mentioned in my kickstarter thread, in my opinion the best and easier route is to assess how much power draw you have (I assume is minimal) then powering the system from the largest battery that would give a large or at least reasonable playing time, say, 8 hours (if possible, otherwise the longest possible). If you want to be "fancy", as I supposed on the kickstarted thread, have the battery attached to a switch for power on: when playing ("on position") the battery is connected to the electronics and the power supply is not connected to anything; when not playing ("off position") the battery is connected to the power supply for charging and the electronics is disconnected.

EDIT: so you edited your post adding more info and changing the text I quoted above. Not bothering about the latter, but regarding the former, if my understanding is correct we are talking about a 20mA*88key + margin for other things = 2A total power draw at 5V or 10W. It's very easy to find USB power banks of 100+ Wh, which will give 10+ hours of playing (nominally) for around $25 -- ripple problem solved.

Last edited by Del Vento; 10/24/20 05:44 PM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039050 10/24/20 07:28 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
CG: now I get why you needed calibrated voltages through the trimpots. You couldn't fit individual tables inside the ram! I always thought you were using a per-key factor over the general lookup table. Ingenious... And this serves as an example why this solution is wonderful in its deceptive simplicity. ADCs and continuous speed calculation are in an entirelt different league of complexity (and pitfalls).

On the other hand, and if I understand correctly, your proposal of fixed resistors and fine tuning of sensor distance only for the final portion of hammer travel, would still not be able to measure note-off speed. Am I understanding correctly? Even so, it may be a good trade of... It would be possible to have a separate software to read key presses and generate 88 tables for ram upload (cybrid firmwares 😊).

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039088 10/25/20 12:35 AM
Joined: Apr 2007
Posts: 6,274
6000 Post Club Member
OP Online Content
6000 Post Club Member
Joined: Apr 2007
Posts: 6,274
^ Yes, all you said is correct.

Although you can use 4 resistors instead of 3 to also start measuring release velocity.


My YouTube, My Soundcloud
Currently: Yamaha N1X, DIY hybrid controller -> Garritan CFX
Previously: NU1X, ES7, MP6, CA63, RD-700SX, CDP-100, FP-5, P90, SP-200
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039113 10/25/20 04:28 AM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
Yeah. I figured that out, but, again if I understand correctly, using a fixed resistor would lead to a variance in the distance threshold to the sensor, and that "error" would increase with distance. And what about a mixed model: fine positioning for minimal distance, trimpot for largest distance, fixed resistor for binarization along hammer travel?

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
vagfilm #3039151 10/25/20 07:48 AM
Joined: Jan 2020
Posts: 17
X
Junior Member
Online Content
Junior Member
X
Joined: Jan 2020
Posts: 17
A lot of analog effort is being expended here to obtain what are basically some digital position measurements.

It feels a bit like measuring the speed of a train by standing on the tracks watching it "get bigger" instead of standing off to one side with a stopwatch and timing it over some fixed physical distance.

It would be mechanically trickier, but electronically a lot simpler, to get some direct position measurements either optically:

Vishay TCUT1630X01 Triple Channel Transmissive Optical Sensor

Or magnetically:

Infineon TLE4966-2G Dual Hall Sensor

Both of these solutions would require physically attaching something to the hammer or shank (a shutter vane or a magnet respectively), and careful mechanical positioning of the sensor, but in return you'd be getting position signals over fixed, known distances.

Last edited by xooorx; 10/25/20 07:51 AM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
xooorx #3039156 10/25/20 07:58 AM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
Hi xooorx. I don't know how familiar you are with the cybrid prototype, but what you propose is exactly the strategy successfully used by Cybergene (optical, not magnetic). Other contributors are now discussing the merits of going ADC all the way... It would be an interesting proof of concept, although in my opinion it is a very complex approach when a simpler method has shown to be high efficiency. Maybe I am wrong...

Last edited by vagfilm; 10/25/20 07:59 AM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3039167 10/25/20 08:42 AM
Joined: Apr 2007
Posts: 6,274
6000 Post Club Member
OP Online Content
6000 Post Club Member
Joined: Apr 2007
Posts: 6,274
There are many approaches and I also thought of using simple interrupt sensors, however the biggest problem I have with these is they would rely on overly precise regulation of the action and installing metal notches on the hammers which may not be reversible. I was afraid of doing mechanical changes to the action that may turn out wrong and then not being able to revert. It’s an overly cautious and passive approach that I believe still makes it the best one I took considering my own abilities and especially the real action that often seems to wrap with the humidity and temperature, for instance hammers touching each other and requiring slight touch up here and there. And so my current solution is non-invasive, it measures velocity from a distance. Indeed, that’s a bit too complicated for solving a very simple task but it works and I can at any time remove my frame and even put back the action in the original piano smile


My YouTube, My Soundcloud
Currently: Yamaha N1X, DIY hybrid controller -> Garritan CFX
Previously: NU1X, ES7, MP6, CA63, RD-700SX, CDP-100, FP-5, P90, SP-200
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3040010 10/27/20 05:02 PM
Joined: Oct 2020
Posts: 20
J
Full Member
Offline
Full Member
J
Joined: Oct 2020
Posts: 20
I appreciate all of the comments of the past week, reading them and explaining myself helped clarify my thinking.

I spent some time with one of the CNY70s over the weekend, fiddling with it while watching the output on my oscilloscope. An FYI to anyone else considering this, the phototransistor in them is sensitive to the "white" LED light on my bench. I could quite clearly see a 120Hz signal from the light on the output of the phototransistor. (120Hz you ask? US 60Hz + full wave rectification in the light = 120Hz) When the sensor was aimed straight at the light, I was seeing ripple of 10% of the peak signal I got my placing my finger over the sensor. Not a problem, but worth noting in case anyone tries to work with the part without the benefit of a scope.

Originally Posted by CyberGene
^ Right, that’s a good enough strategy. Only the 5-bit resolution bothers me but if you can provide an absolute offset and width of the 5-bit window, then it can be good enough.
Your velocity resolution is coming from a combination of your ability to time events, as well as the distance/position resolution. If under that scheme you were able to switch to using interrupts, instead of scanning, you'd increase your time resolution. That might offset the loss of position resolution.

Feeding your 266 comparator outputs into 16:1 IO expanders would bring your signal count down to manageable number of interrupt lines. (I'm pretty sure there are IO expanders with outgoing interrupt pins.)

Originally Posted by EVC2017
My own approach would be getting some multi-ADC (there are some from TI with 8, 12, 16 even more ADCs), controled by one processor, probably an STM32F4 or F7. That would allow for a simpler yet flexible architecture.

My thinking has shifted in this direction after last week's comments, and doing some investigation over the weekend. There are STM32 parts with >22 ADCs on them that should be able to perform ADC conversions fast enough for the task.

Originally Posted by CyberGene
It turns out creating a high wattage low ripple supply is almost an unsolvable task...
Originally Posted by Del Vento
if my understanding is correct we are talking about a 20mA*88key + margin for other things = 2A total power draw at 5V or 10W. It's very easy to find USB power banks of 100+ Wh, which will give 10+ hours of playing (nominally) for around $25 -- ripple problem solved.

The power requirements of the LEDs should be smaller than that. The way to reason about it is that we've got 88 LEDs, times a forward voltage of maybe 1.5V, so 132V. They all want the same 20mA. That totals up to ~2.64W.

We can get close to that draw, and eliminate all ripple, by organizing the LEDs into long strings (possibly all of them in one string), and putting them in series with a linear constant current regulator. They'll all see exactly the same current, all the time. The power supply feeding that string would need to be able to exceed the combined forward voltage of all of the LEDs (~132V) with some room to spare, but it would only need to provide 20mA, and any noise would be cleaned up by the linear regulator. If the 132V supply is awkward to arrange, the string can be split into smaller ones until a manageable supply voltage is reached.

I think my plan to put an op amp on the sensor boards was moving in the wrong direction. They can instead be simplified. They don't even need a resistor on them. smile Instead, chain the LED power from one board to the next (per the above), and wire the two terminals of the phototransistor back to whatever board you want to use to process the signal. The two wires will form a current loop, which (ought to be?) more resistant to noise. You can put your resistor to turn the current into a voltage on the board immediately adjacent to the comparators, ADCs, or whatever will process the signal.

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3040036 10/27/20 06:24 PM
Joined: Apr 2007
Posts: 6,274
6000 Post Club Member
OP Online Content
6000 Post Club Member
Joined: Apr 2007
Posts: 6,274
^ Very interesting ideas 👍🏻🙂


My YouTube, My Soundcloud
Currently: Yamaha N1X, DIY hybrid controller -> Garritan CFX
Previously: NU1X, ES7, MP6, CA63, RD-700SX, CDP-100, FP-5, P90, SP-200
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3040060 10/27/20 07:46 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
I have already mentioned in this thread that adding note-off speed would be a great and perhaps important addition to Cybrid. However, I have been thinking about this and I am now convinced that I was completely wrong about the simplicity of adding note-off speed. I'm afraid I was naively assuming it to be simply a matter of adding another positional comparator to measure drop-off speed from the backcheck once the key is released.

By looking at time lapse videos of grand piano actions, I believe that in both fast and slow key releases, the inertia of the hammer make it move much later than the key and in both fast and slow key releases the hammer drop is gravity-based and rather constant (and thus useless for this purpose). Moreover, there is an important difference between the small actual key lift that is needed for disengagin the hammerhead from the backcheck allowing the hammer to drop fully, while that same small key upward travel causes a very gentle drop of the damper (or even causes the damper to barely touch the strings)... If I am analysing this correctly, then the only way to have correct note-off speed would be to measure key travel and not hammer travel. However, having only key sensors creates a myriad of problems for separating "leggiero" from silent strokes (even Yamaha after dozens of years and hundreds of engineers have not fully solved the famous "loud notes")...

Which brings me to the conclusion that the best implementation would be to have optical sensors to measure note-on by measuring the final portion of hammer travel, and once there is a note-on event, then switch to key sensing to detect timing and speed of note-off. And this is probably impossible to do, because there is non-linearity and almost complete independence between the movements of keys and hammers (for example, depending on the mass of bass vs treble hammers and the force exerted on the key, the hammer can reach the string before or after the key bottoms while in a strong staccato touch the key rebounds in the bottom and travels upward more rapidly than the damper travels downward...).

Cybergene: will this be the end of note-off detection? If I am correct, I don't think it will be worth the effort... Would love to have your comments since you are the expert on how grand action translates to string strikes.

Last edited by vagfilm; 10/27/20 07:50 PM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
vagfilm #3040078 10/27/20 08:29 PM
Joined: Oct 2020
Posts: 20
J
Full Member
Offline
Full Member
J
Joined: Oct 2020
Posts: 20
Originally Posted by vagfilm
If I am analysing this correctly, then the only way to have correct note-off speed would be to measure key travel and not hammer travel.

That is my assessment. Damper velocity is a function of key velocity.

Originally Posted by vagfilm
Which brings me to the conclusion that the best implementation would be to have optical sensors to measure note-on by measuring the final portion of hammer travel, and once there is a note-on event, then switch to key sensing to detect timing and speed of note-off.

Yes.

Originally Posted by vagfilm
And this is probably impossible to do, because there is non-linearity and almost complete independence between the movements of keys and hammers

I don't understand. Watching both the hammer and the key with separate sensors seems sufficient. The signal will need to be processed differently for each, but that's minor. Even if you wanted to stick with trimpots and comparators, enough of them ought to suffice.

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
JayKominek #3040084 10/27/20 08:46 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
Originally Posted by JayKominek
I don't understand. Watching both the hammer and the key with separate sensors seems sufficient. The signal will need to be processed differently for each, but that's minor. Even if you wanted to stick with trimpots and comparators, enough of them ought to suffice.

I am not entirely sure if in the right "perfect storm" conditions (leggiero touches in treble notes with lighter hammers) you could not end with note-off events (key returning to resting position) that precedes the note-on events (hammer reaching maximum travel). It may never happen, or it may be very common: only experimentation can tell. If it ends being common, then it may be impossible to calibrate and compensate for that while maintaining the overall sensitivity...

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
vagfilm #3040087 10/27/20 08:51 PM
Joined: May 2020
Posts: 233
D
Full Member
Offline
Full Member
D
Joined: May 2020
Posts: 233
Originally Posted by vagfilm
Originally Posted by JayKominek
I don't understand. Watching both the hammer and the key with separate sensors seems sufficient. The signal will need to be processed differently for each, but that's minor. Even if you wanted to stick with trimpots and comparators, enough of them ought to suffice.

I am not entirely sure if in the right "perfect storm" conditions (leggiero touches in treble notes with lighter hammers) you could not end with note-off events (key returning to resting position) that precedes the note-on events (hammer reaching maximum travel). It may never happen, or it may be very common: only experimentation can tell. If it ends being common, then it may be impossible to calibrate and compensate for that while maintaining the overall sensitivity...

You are overthinking the problem. Consider an acoustic piano, even just decently regulated. Note on is on the hammer, note off on the dampers which are basically solid with the keys (pedals aside). They are independent and measuring them independently electronically will be sufficient and will work as well as in a piano. Unless the action regulation is totally screwed up (e.g. dampers don't lift before the hammer hits or other weirdness like that) it will work just fine

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3040089 10/27/20 08:56 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
Cybergene: do you think it would be feasible to have two teensys sending 2 streams of MIDI signals along the same MIDI channel number (merged in a USB hub)? One of the teensys would scan the hammer optical sensor and only sends note-on events, while the other teensy scans the key movement and only sends note-off events... Even if possible, I believe it would be easy to run into cancellation problems between the two streams and very fast trills would end up with a lot of silent notes or a few strangely longer ones...

Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
Del Vento #3040094 10/27/20 09:06 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
Originally Posted by Del Vento
You are overthinking the problem. Consider an acoustic piano, even just decently regulated. Note on is on the hammer, note off on the dampers which are basically solid with the keys (pedals aside). They are independent and measuring them independently electronically will be sufficient and will work as well as in a piano. Unless the action regulation is totally screwed up (e.g. dampers don't lift before the hammer hits or other weirdness like that) it will work just fine

I would totally agree with you IF the note-off sensor would be placed on the damper; but that is not an option in a majority of cases, since the grand action mechanism is separate from the dampers and salvaged actions generally do not include the dampers that require a different structure set (Cybrid being an example of that, and all the avant-grands for that matter)... So, all you have left is the key and it will be very difficult to predict what would be the real position of hammer and damper, from the actual position and movement of the key. The movements of the key cause the movements of hammer and damper, and each one has it own inertia and momentum completely independent from the momentum of the key... Maybe I am overthinking, but only experiment can tell, and I would not be surprised to have some nasty surprises.

In a very fast same-key trill, the key rebounds and travels multiple times from top to bottom at high speed, while the damper may be continuously maintained elevated from the strings due to inertia... This is not a problem per-se (it would generate many note-on events without intercalated note-offs, which is not an issue for a VST) but serves to illustrate how separate the 2 things are...

Last edited by vagfilm; 10/27/20 09:12 PM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
CyberGene #3040100 10/27/20 09:26 PM
Joined: Jun 2020
Posts: 66
V
Full Member
Offline
Full Member
V
Joined: Jun 2020
Posts: 66
I went back to watch the slow motion videos and contrary to my fears, the damper inertia is very low and so the damper closely follows the movement of the key (much quicker than the hammer which is light and has high inertia)... Thus, using the key as note-off may not create problems. But, again, only experimentation can tell...

Last edited by vagfilm; 10/27/20 09:27 PM.
Re: Cybrid (CyberGene's hybrid MIDI controller) is open-source!
JayKominek #3040194 10/28/20 08:18 AM
Joined: Jan 2020
Posts: 17
X
Junior Member
Online Content
Junior Member
X
Joined: Jan 2020
Posts: 17
Originally Posted by JayKominek
Originally Posted by CyberGene
^ Right, that’s a good enough strategy. Only the 5-bit resolution bothers me but if you can provide an absolute offset and width of the 5-bit window, then it can be good enough.
Your velocity resolution is coming from a combination of your ability to time events, as well as the distance/position resolution. If under that scheme you were able to switch to using interrupts, instead of scanning, you'd increase your time resolution. That might offset the loss of position resolution.
Yes. Velocity is being measured here as time taken to cover a fixed distance. That 5 bits wouldn't be the resolution of the measurements: It's just something that lets you set up some start and finish posts so you can make some measurements. If they're in roughly the correct places, at roughly the correct distance apart, then the key will work and measurements can be taken. The accuracy of the timing measurement is the important thing.

For fine tuning, because yes, they're only *roughly* the correct distance apart, any error should be completely linear: If the actual distance is 1.1x the intended then the measurement will be 1.1x the expected, and this doesn't need look up tables to correct it just needs a single multiplication.

OTOH, for people thinking about going the full ADC route: Note that you would now be measuring distances over fixed times (the sampling period) instead of times over fixed distances. It might be better to work with these measurements directly rather than just using them to set up start/finish points and then making a new timing measurement.

Page 5 of 6 1 2 3 4 5 6

Moderated by  Piano World 

Link Copied to Clipboard
(ad)
Pianoteq
Steinway Spiro Layering
(ad)
PianoDisc

PianoDisc
(ad)
Piano Life Saver - Dampp Chaser
Dampp Chaser Piano Life Saver
(ad)
Mason & Hamlin Pianos
(ad) SWEETWATER Cyber Sale
New Topics - Multiple Forums
Beginner looking for purchase advice
by savagekeys - 12/05/20 11:21 AM
Fazioli soundboards
by Withindale - 12/05/20 10:08 AM
Practice and resting
by Ubu - 12/05/20 05:25 AM
Strange phenomena....
by piano_primo - 12/05/20 12:55 AM
Download Sheet Music
Virtual Sheet Music - Classical Sheet Music Downloads
Forum Statistics
Forums41
Topics203,279
Posts3,030,850
Members99,491
Most Online15,252
Mar 21st, 2010
Please Support Our Advertisers


Faust Harrison 100+ Steinways

Dampp Chaser Piano Life Saver

 Best of Piano Buyer

PianoTeq Bechstein
Visit our online store for gifts for music lovers

Virtual Sheet Music - Classical Sheet Music Downloads



 
Help keep the forums up and running with a donation, any amount is appreciated!
Or by becoming a Subscribing member! Thank-you.
Donate   Subscribe
 
Our Piano Related Classified Ads
| Dealers | Tuners | Lessons | Movers | Restorations | Pianos For Sale | Sell Your Piano |

Advertise on Piano World
| Subscribe | Piano World | PianoSupplies.com | Advertise on Piano World |
| |Contact | Privacy | Legal | About Us | Site Map | Free Newsletter |


copyright 1997 - 2020 Piano World ® all rights reserved
No part of this site may be reproduced without prior written permission
Powered by UBB.threads™ PHP Forum Software 7.7.4