Machine Power-On Sequence
-
@Zdenko you could use a loop near the start of config.g to wait until VIN is high enough before proceeding with the rest of config.g.
-
Hello David, thank you for the replay.
In that case, I would need to use one gpIn[1].value as a "sensor" where I connect +24V to detect its presence, right? Or is there some other elegant solution?
Or is it better to do it over daemon.g and config.g together and to implement some kind of continuous monitoring?
Thank you,
-
@Zdenko Why do you have USB connected anyway? Do you need to communicate over USB when power is off to the rest of the system? You could modify the USB cable so it doesn't provide +5V.
What dc42 is suggesting is to query the object model, and the loop would be in config.g. No need for external power monitor. I think the correct variable to check is
boards[0].vIn.current
. It would mean that the board is not accessible until main power is turned on.Ian
-
Hello Ian,
Thank you for the replay,
I do not need to communicate with the system when the main power is off.
It was also my idea to modify the cable as you mentioned or to remove the +5V regulator from PCI-E which is used only for Duet 3 Main Board 6XD.
I will investigate if I can implement it with boards[0].vIn.current, thanks for the tip!
-
@Zdenko I would modify the cheap cable, rather than risking desoldering anything from the expensive PC motherboard, or expensive Duet. Putting a piece of Kapton tape over the +5V contact (assuming USB 2 cable) might be enough.
Ian
-
@droftarts
Hi Ian,I have 4 separate PCI-E to USB controllers connected to MB, one is like 8Eur and one of them is only dedicated to Duet, so removing 5V regulator from a single card is not an issue.
I tried to modify the config.g with boards[0].vIn.current, but I end up in some kind of a loop, need to investigate that approach in more detail.
Thank you,
-
@Zdenko Something like this at the beginning of config.g:
while boards[0].vIn.current < 10 G4 S2
That should check if VIN is less than 10V every two seconds. If it is less than 10, it loops, if it is more than 10, it continues through the config.g.
Ian
-
Cheers Ian,
That works as intended, but unfortunately, it is not "bulletproof" as much as I hoped so.
In case Main switch is powered off, extension boards lose power but Duet 3 Main Board 6XD still has power from USB meaning extension boards drop the CAN connection, and powering up the main switch from the enclosure will not re-initialize the config.g to sync extension boards.
It seems to me I will need to cut/remove the USB power, or make some constant monitoring loop.
Thank you,
-
@Zdenko you could use daemon.g to reset the board if VIN power is lost.
-
Hey @dc42,
Currently I removed +5V from dedicated PCI-Ex to USB adapter for Duet 3 Main Board 6XD and the system is working as intended.
When I catch some time I will investigate the option with daemon.g and VIN power monitoring so that this external modification is not needed.
Thank you,