scottbez1 / smartknob

Haptic input knob with software-defined endstops and virtual detents

Home Page:https://www.youtube.com/watch?v=ip641WmY4pA

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Issues using a MT6701 and ESP32 devkit

kiranscott opened this issue · comments

Hey everyone seeing that the SParkfun brushless motors are back in stock, I've started building a breadboard smartknob without the custom PCB.
IMG_3616
I have a ESP-WROOM-32 devkit, and a MT6701 on a break out board acting as the hall effect sensor
image
https://www.aliexpress.com/item/1005004216058243.html
When running the callibration I get the following:
LOG: Electrical angle / mechanical angle (i.e. pole pairs) = inf LOG: Pole pairs set to 2147483647
I'm assuming this has to do with the sensor being read incorrectly / not at all. I've changed the CLK / DATA pins to correspond with 14,12 as they're the default HSPI_CLK and HSPI_MISO pins on my devkit.
Anyone encountered a similar issue / got a similar setup

I should add that the board seems to default to Z, B, A or has a pad to short to set to i2c , so it might not be in SPI mode at all, and I can't seem to find schematics for it online to cross reference with the smartknob pcb schematic. This might be a super simple fix, I'm very much out of my comfort zone with this project haha

i think spi or ssi mode needs the mode pin on the encoder to be pulled up , if mode pin is pulled down you get abz or pwm modes,
so i think you need to short the 12c pin and that will be fine.
in the data sheet you can see the pin out ,and then use use a multimeter to find the circuit http://img.ekeic.com/ekeic/5001592712907.pdf.

Managed to get the screen and sensor working - but the motor is unstable / noisy. I've tried tuning the PID values but can't seem to get it behaving properly. Any idea what might be causing this?

IMG_3710.MOV