I'm not saying this is your problem, but the BBB (and most ARM SBCs) are pretty sensitive to the power supply and cannot be reliably driven by typical USB ports. I typically run my 12V CRAMPS systems using an ATX power supply with the 5V standby power going to the +5V connection on the AUXPWR connector (P404) with the BBB/CRAMPS board turning on the ATX supply via P301 (which is basically the same as powering the BBB via the P1 5VDC "barrel" power jack).

For my 24V systems, I have a separate 24V supply for the high power rails and use a 5V "wall wart" to the BBB DC input (P1).

I also run the BBB "stand alone", with a physical Ethernet cable connected to the BBB and using the HDMI output for video and a standard USB KB/mouse for the console (sometimes with a serial link as well if I'm debugging). Connecting via the USB gadget interfaces _should_ work, but it's not how I test and I don't think it's a common configuration for most developers.

It's strange the therm input doesn't work stand-alone but does when you're powered from the laptop. I'm not sure what could cause that, but some basic debugging ought to be able to root out the cause. Run halmeter or halscope and monitor the temperature outputs from the hal_temp_bbb component. You should be able to see the values change with the temperature (eg: hold the thermister between your fingers vs. letting it sit at room temperature). If that's not working, you likely have a device-tree issue or something which is causing the ADC to not be working properly. If you see the values change, there's probably something wrong in your HAL file.

On 1/26/2021 7:11 PM, Pete McKenna wrote:
Thanks Charles, and thanks for creating the CRAMPS!

I noticed as I was working with it last night that I have different aspects
working depending upon, how I'm getting access to the BBB. I just got a
monitor for it so I set it up as a stand alone device and had the monitor
with keyboard, mouse on a USB hub, and power via V5 adaptor to the usb port
no computer connected.
In that state.
The E0 heater will come up as expected based on the bias setting, but there
is no therm input, so it will just run away.

I switched back to the laptop powering the BBB over the USB connection
using that as the network connection as well to run Axis over X. This
resulted in no output from the E0 FET, but I have the therm input working
again.

Power rails wise I have no bed and have 24VDC running to  P201, and P402
and the screw terminals, V+ and G.
The CRAMPS is v2.2

I appreciate the help. The power connections were based on a picture of the
board be wired up, that I found online. Its a very strange set of
conditions, and it is repeatable when I switch from stand-alone to with a
PC connected.

I can set the halcmd setp for the FAN FET, but when trying to do so for the
E0, it tells me there is a pin assigned or something like that, but I'll
try it again. and I see the LEDs for all of the FETs now so I'll pay
attention to if I have the expected control of them when halcmd setp.

Thanks
Pete






On Tuesday, January 26, 2021 at 5:55:45 PM UTC-6 [email protected]
wrote:

There's not really enough detail to determine exactly what's wrong.

Since you indicate you can set the hpg.pwmgen.00.out.xx.value signals
and get expected results, it sounds like the PRU is properly generating
PWM signals. Note that by default the value signal is normalized, so
0.0 is "always off", 1.0 is "always on" and 0.5 is "on half of the time".

I do like to explicitly set the PRU period, but I doubt that's causing
your problems:

https://github.com/cdsteinkuehler/machine-configs/blob/master/configs/CoreXZ/CoreXZ.ini#L3

So if the PWM is working correctly the problem is likely with the PID or
temperature code. Use halmeter, halsscope, or just "halcmd show pin" to
see what the signals are doing. If you can't tell what's wrong, post
some additional debugging from these utilities and maybe we can spot
what's going wrong.

Finally, one thing that trips up a lot of CRAMPS users is you have a
bunch of different power supply connections. There are three different
supplies for the CRAMPS FET outputs:

P402: EXTPWR (E0, E1, E2)
P403: BEDPWR (BEDHTR output)
P404: AUXPWR V+ (FET5, FET6)

Make sure you have all the necessary supply rails connected. The LED
next to the FET output connector should light when the FET is on and
power is properly applied. For testing, you can use halcmd to set any
signals that are not being actively driven (eg: halcmd setp
hpg.pwmgen.00.out.02.value 1.0) without having to edit your HAL file and
relaunch.

On 1/25/2021 9:58 PM, Pete McKenna wrote:

My first attempts at posting haven't worked. I'll post the files if this
post works.

I have an Ordbot I'm adding BBB+ CRAMPs control too. I have the motion
control working reasonably well, but I can't get control of the FETs for
the extruder and fan control, if I hack the hpg.pwmgen.00.out.xx.value I
can enable them, but not with any pid / feedback control. ( I can confirm
the FETs work and the extruder heats and the fan runs via hacking the
vaule
)
I have checked the thermistor, and it works as expected. What I can't
figure out is how to get the commanded temp to go to anything other than
0.
I have pre-heat settings, I've tried to use the remaped M codes for 104
and
109 (and 106 for the fan) but I get nothing. My configs are attached, if
anyone has a BBB and CRAMPS working for 3D printing, or FET controls I'd
love to get your advice.

Thanks
Pete



--
Charles Steinkuehler
[email protected]



--
Charles Steinkuehler
[email protected]

--
website: http://www.machinekit.io blog: http://blog.machinekit.io github: 
https://github.com/machinekit
--- You received this message because you are subscribed to the Google Groups "Machinekit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/machinekit/828a6a61-37e1-a597-f1e1-451091f2c207%40steinkuehler.net.

Reply via email to