Let's Design and Build a (mostly) Digital Theremin!

Posted: 10/27/2024 7:45:14 PM
sarob

Joined: 10/27/2024

@Dewster, thanks for your thoughtful reply.

"For the group of 3 pins: the middle pin should be ground, the outer two should be +3.3V.  Turning the encoder should cause the outer pins to go to ground and then return high."

The outer two pins go from around 1.9 V to 3.3 V when I rotate the encoder. I guess I am not seeing them going down to 0V, due to limitations of my cheap multimeter, rather than the encoder being bad.

"For the group of 2 pins: one should be ground and the other +3.3V.  Pressing the encoder should cause the high pin to go to ground, releasing should make it go back high."

Behaves exactly as you describe.

At this point my best guess is:
1) The encoders are not healthy. I'll try to get my hands on an oscilloscope, and perhaps one of the Alps Engineering EC11 encoder to compare. Or,
2) Somehow in the FPGA re-compiling process etc., the signal read pins got disabled (or something along these lines).

Any of these theories make sense to you? I agree wiring (instead of these more exotic theories) is the most likely issue, although when I double check I think I am matching the PCB layout / schematic etc. I also tried a single encoder on a breadboard in isolation (including flipping some of the pins), but still could not get the display to react.


"And I'm always up for a video call!"

That is very kind of you and much appreciated. I may very well take you up on the offer in a few weeks (once I am back from a work trip, if my debugging is not successful).

Posted: 10/28/2024 10:34:52 AM
André

From: 30 km south of Paris (France)

Joined: 12/23/2022

Hi Dewster,

I just received my LC meter !
I tested the coils. The values are as follows :
For the 1 mH -> 0,970 mH. 3 % deviation.
For the 2 mH -> 1,925 mH. 3,75 % deviation.
To keep in mind for the next series. I'll put a few more turns !

Posted: 10/28/2024 11:04:57 AM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"So, I'm not expecting to have a wrong inductance value?"  - André

"For the tension, I simply used my finger on the coil and added a little more tension by holding the wire between my palm abd the other fingers."

You are doing everything correctly!

"What do you call dope ?"

In this case: nail polish.  Just wondered if you were doing anything different here.

[EDIT] Oops, just missed your post above, everything seems good!

Posted: 10/28/2024 11:23:47 AM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"Where can I start to track down the "ER!"?" - gerbold

The unusual out of range values for Mon, Out, Vcal, and Pcal are an indication that something is wrong with the system profile values stored in the EEPROM.  The "ER!" indicates the software has gone off the rails, which can happen when the software is presented with out of range values.  Have you used the librarian to pump up the EEPROM?

"Today I connected everything, including some "stub" inductances of 1mH and 2mH, just to have something similar in place. Actually I wound them using a ferrite ring plus some 25 respective 50 windings."

Hmm.  Have you checked their actual values and Q?  It's not causing your "ER!" problem above, but the electrical qualities of the inductors are rather critical for proper operation once everything is up and running.

Posted: 10/28/2024 11:28:23 AM
André

From: 30 km south of Paris (France)

Joined: 12/23/2022


You are doing everything correctly!

Not quite !

When I put the shrink tube, which is not that larger than the coil (44 mm for 40 + wire) I had difficulties with one of the coils.
When sliding the tube, a turn went over the next one.
I finally could save the coil but I definitely need to put more tension.

Also I overheated some of the shrink tubes and got holes right at terminal connections !

Nail polish is not ideal. The one I use does not stick to PVC. It does stick the wire turns together but not to the tube.
Generally the solvent of nail polish is ethyl acetate.
May be an acetone solvent would be better.
PVC dissolved in acetone, may be ?

Posted: 10/28/2024 11:53:59 AM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"The outer two pins go from around 1.9 V to 3.3 V when I rotate the encoder. I guess I am not seeing them going down to 0V, due to limitations of my cheap multimeter, rather than the encoder being bad."  - sarob

In the detent position you should see 3.3V.  Rotating it from one detent to the other very slowly this should go to 0V and then go high again.  I think you should be able to see this even with a cheap DMM.

You might take a spare unmounted encoder and check continuity between the group of three outer pins and the center pin, it should be infinite ohms.  Slow rotation from one detent to another should show very low ohms in there somewhere, and return to infinite at the detents.  A diode test function would also work here if your DMM has one.

"Behaves exactly as you describe."

If you see this is OK, what happens to the corresponding LCD value?  An unsigned value should cycle between 0 and max with each press.  A signed value should cycle through max, min, and 0, stepping with each press.  For the lower right page encoder it should cycle between the "D-LEV" page and the "SYSTEM" page.

"2) Somehow in the FPGA re-compiling process etc., the signal read pins got disabled (or something along these lines)."

Unless something has changed between Quartus versions, I don't believe a recompile should be necessary if you haven't relocated any of the FPGA pins.  The "output_file.jic" in the ZIP archive can be loaded into the programmer and used directly.

Posted: 10/28/2024 12:14:06 PM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

"When I put the shrink tube, which is not that larger than the coil (44 mm for 40 + wire) I had difficulties with one of the coils.  When sliding the tube, a turn went over the next one.  I finally could save the coil but I definitely need to put more tension."  - André

Yes, that's probably a tension problem, and any heating causes the wire and plastic to expand at different rates.  I now run a line of nail polish down the length of the windings to help fix them through the heat shrink stage.  A winding slip probably won't hurt things very much, but it can be distressing!  And loose winding might aggravate drift (only anecdotal evidence here).

"Also I overheated some of the shrink tubes and got holes right at terminal connections !"

I've seen this too, particularly when the solder leaves a sharp point.  You're using thicker lead wiring than me and the higher thermal mass might be aggravating the situation.  Nothing wrong with thicker wire - it's probably for the best since mechanical wire vibrations will then be better damped (in the past I've seen these vibrations on the tuner).

"Nail polish is not ideal. The one I use does not stick to PVC. It does stick the wire turns together but not to the tube."

True, but that's probably good enough for this use.

"Generally the solvent of nail polish is ethyl acetate.  May be an acetone solvent would be better.  PVC dissolved in acetone, may be ?"

I've seen videos of Styrofoam dissolved in acetone and it produces a gummy, stringy precipitate that looks like it would be problematic for coil use - not sure if PVC would behave better?  Ethyl Acetate seems like the solvent we're looking for here because it produces a spreadable liquid with Styrofoam.  Things might stick a bit better with a light sanding of the coil former?

Posted: 10/29/2024 11:48:53 AM
dewster

From: Northern NJ, USA

Joined: 2/17/2012

Doping

A good article on dissolving plastics: https://www.instructables.com/Recycling-Styrofoam-EPS-Into-Castable-Styrene-Plas/

It has many interesting notes and links at the end, this one predicts solubility given a mix of two solvents: https://www.hansen-solubility.com/HSP-science/solvent-blends.php

I wonder if one could wind a coil on something like PVC, and at the end apply just a solvent, so that the wires end up somewhat embedded in the coil form?  Might help with thermal drift.

Posted: 10/30/2024 1:29:39 PM
André

From: 30 km south of Paris (France)

Joined: 12/23/2022

Interesting articles.
Amazing what people do in their kitchen !
They can't be married !

About thermal drift, I made an experiment.
I heated the coils with a hair dryer for several minutes. I only noticed a drift of one or two digits.
From 0.970 mH to 0.971 mH and from 1.925 mH to 1,927 mH.

Posted: 10/30/2024 3:23:31 PM
gerbold

Joined: 9/26/2024

The "ER!" indicates the software has gone off the rails, which can happen when the software is presented with out of range values.  Have you used the librarian to pump up the EEPROM? - dewster

Yes and no. I used the librarian with the option "6. Upload All Presets". This was not enough. After using option "7. Factory Reset", the out-of-bounds values were gone and also the "ER!" message. Once it was working I used Quartus to program the FPGA configuration that I compiled and it still was working as with the original FPGA configuration.

"Have you checked their actual values and Q?  ... the electrical qualities of the inductors are rather critical for proper operation once everything is up and running" - dewster

No.  I just measured the inductance. When monitoring the pitch drive output of the AFE, I can see that the frequency raises up to 1.6 MHz, then breaks down to zero and rises again. I assume this is the effect of my poor inductance with the ferrite ring core. The volume does look pretty much the same.

I'm waiting for a set of the solenoids wound by André. With these I expect a stable oscillation.

You must be logged in to post a reply. Please log in or register for a new account.