SHC not working


andrea tasselli
 

Hello everyone,

I am trying to see whether the SHC I have built works. It flashed correctly. So far so good. ST4_HAND_CONTROL is set to ON and ST4_INTERFACE is set to ON_PULLUP in Config.h.
When I connect the SHC to the ONStep box (BluePill) nothing shows on the screen and a red led is lit in the STM32. Nothing else. Is there a way to know what is going on and why it doesn't work?

Thanks for your help

Andrea


Dave Schwartz
 

You should get at least the OnStep logo on the display... that is done before anything else.

Check that your display's pin order matches the order in which the PCB is routing them. Some OLED modules have the order VCC GND SCK SDA and others have GND VCC SCK SDA (i.e. the order of VCC and GND are reversed). Some modules also have zero-ohm chip resistors on the back that allow you to switch the order from the default, which is silkscreened on the front, to the other order.

In order to accommodate this, I designed the ESP32 SHC PCB with jumpers to either side of the OLED header so that you could reverse the order without having to buy a different module or rework the chip resistors that you may or may not have. The Teensy PCB does not have such jumpers so your choices would be surgery or buy a different module (many eBay vendors offer both types explicitly now whereas before it was random as to what you got).

On 2021-01-10 8:58 a.m., andrea tasselli via groups.io wrote:
Hello everyone,

I am trying to see whether the SHC I have built works. It flashed correctly. So far so good. ST4_HAND_CONTROL is set to ON and ST4_INTERFACE is set to ON_PULLUP in Config.h.
When I connect the SHC to the ONStep box (BluePill) nothing shows on the screen and a red led is lit in the STM32. Nothing else. Is there a way to know what is going on and why it doesn't work?

Thanks for your help

Andrea


andrea tasselli
 

Thanks for getting back to me, Dave. The issue here isn't the display. When I connect the SHC to the PC via USB the OnStep Logo is splashed and the SHC tries to connect to OnStep.It is when is connected to the controller (BluePill) that it doesn't work. The led light goes up and that's it. JP3 is shunted and the resistor array orientation is correct. I checked the input voltage thru Pin 1 from the cable and it reads 4.2V.

Thanks for any help.

Andrea


Dave Schwartz
 

That may be your problem.

You haven't said whether this concerns an ESP32 or Teensy SHC so I'll talk only about the ESP32 and it may apply to the Teensy but I do not know that.

With ESP32 modules, the power LED is on the 5V input, before the 3.3V regulator that provides the juice to run the processor so almost any input will cause it to light up.

On the ESP32 Dev Kit module (the official one from Espressif, clones are probably similar) the regulator is an AMS1117-3.3 device. The datasheet doesn't give the specific minimum input voltage for each output value but it does say that the dropout voltage is typically between 1.3V (at 100mA) and 1.5V (at 1A). This would seem to imply that generally the minimum input voltage must be at least 1.3V above the output voltage (slightly more at higher current) or the device will drop out (i.e. no output).

So for 3.3V out of the regulator, the input must be at least 1.3V higher or 4.6V. You're getting that when using a USB cable directly but you're not getting that when connected via your cable to the controller.

Trace the voltage all the way from your controller's regulator to the SHC... you have a high-resistance connection somewhere that is knocking down the voltage your SHC gets to below the minimum for the SHC processor module's regulator.

On 2021-01-10 1:43 p.m., andrea tasselli via groups.io wrote:
I checked the input voltage thru Pin 1 from the cable and it reads 4.2V.


andrea tasselli
 

Thanks Dave. I came at the same conclusions. The SHC is an ESP32 one. The problem is that I checked the voltage at the source (voltage regulator on the controller) and read exactly 4.2V. When I remove everything it reads 5.09V (which is what I trimmed it to). So the drop is connected to something that is working as is, as OnStep is working. Could it be the two TMC5160s?

Thanks for your help

Andrea


Dave Schwartz
 

Sounds like your regulator is sagging under load. Maybe not its fault, probably because the power supply isn't up to the job. What are you using as a power supply?

On 2021-01-10 3:06 p.m., andrea tasselli via groups.io wrote:
Thanks Dave. I came at the same conclusions. The SHC is an ESP32 one. The problem is that I checked the voltage at the source (voltage regulator on the controller) and read exactly 4.2V. When I remove everything it reads 5.09V (which is what I trimmed it to). So the drop is connected to something that is working as is, as OnStep is working. Could it be the two TMC5160s?

Thanks for your help

Andrea


andrea tasselli
 

Maybe. The power supply wasn't meant for full power-on test, just to power the controller to check everything is in order and to upload the software. It's meagre 2A 12V PSU. I also tested whether the boot mode made any difference and it does; in flash mode the regulator it delivers 4.8V and in run mode 4.2V. I guess I need to change the PSU? What about the TNC1560s. They are BTT but I didn't cut the CLK pin (following advice for Khalid). What if I do? Would it make any difference?

Cheers

Andrea 


Dave Schwartz
 

If that PSU is a Chinese switching one, wall-wart or laptop-style, I don't doubt its the problem. I've posted before that I've had 0% success with about 5 of those of varying sizes. I have one of those 150 watt battery/power supply testers that shows voltage and current and has a variable load. When there is no load, I get the rated voltage but as soon as the load starts to increase, the output voltage starts declining and by the time I get to about 20% of the rated current, the voltage collapses to near zero. That's why I only use 10 or 20 amp linear ham radio power supplies... never had one fail yet.

On 2021-01-10 4:01 p.m., andrea tasselli via groups.io wrote:
Maybe. The power supply wasn't meant for full power-on test, just to power the controller to check everything is in order and to upload the software. It's meagre 2A 12V PSU. I also tested whether the boot mode made any difference and it does; in flash mode the regulator it delivers 4.8V and in run mode 4.2V. I guess I need to change the PSU? What about the TNC1560s. They are BTT but I didn't cut the CLK pin (following advice for Khalid). What if I do? Would it make any difference?

Cheers

Andrea