• Updated 2023-07-12: Hello, Guest! Welcome back, and be sure to check out this follow-up post about our outage a week or so ago.

Building a Mac SE/30 with soft power on

amedeo_68k

Well-known member
Hi guys, I clearly remember when I have first seen the soft power on Macintosh II as it was today. I loved it.
Last day I was replacing the PSU on a Mac SE/30 ( my most loved compact Mac ), I have put in a Seasonic PSU, as already done by other people, then I was wondering…
it would be relatively easy to power on the PSU by the keyboard ADB poweron pw pin, then with a simple relay keep the PSU in on state, the trickiest part is powering the machine off.

We need:

- create an hardware that disconnects the PSU power on signal, may this can be a “NuBUS” card inside the already fantastic @Bolle powercache adapter, it already contains an ethernet board, may be it is possible to add such new device.
- patch the ROM to support the soft power off
- additional idea, as @Bolle board has Ethernet… wake on lan 🙃

What do you think?
 

Phipli

Well-known member
Heh, weird coincidence - I was trying to think about what was needed to do this on an LC yesterday.

Power on wouldn't take too much. A replacement PSU that supports soft power, a connection to the trickle power and a little circuit linked to the soft power pin on the ADB ports...

Powering off is a challenge. I haven't thought of a way yet.

The SE/30 though has the ROM from the IIx and IIcx which support soft power. But that is just a pointless fact if there isn't a signal to pick up on the board.
 

cheesestraws

Well-known member
Powering off is a challenge. I haven't thought of a way yet.

You'd have to have software support. Don't know how the ROM does it and don't have the energy to check at the moment, but I'm sure you could hook the shutdown manager somehow...
 

Phipli

Well-known member
You'd have to have software support. Don't know how the ROM does it and don't have the energy to check at the moment, but I'm sure you could hook the shutdown manager somehow...
I wish there was spare GPIO on mac boards - couple of spare pins on a VIA or something. Perhaps there is. I've never looked.
 

cheesestraws

Well-known member
I wish there was spare GPIO on mac boards - couple of spare pins on a VIA or something. Perhaps there is. I've never looked.

Well, on the SE/30, as far as I can see, the POWEROFF line is still present on VIA2:

Screenshot 2022-08-29 at 11.33.16.png
The only place this seems to go is the PDS slot (!), per page 1:

Screenshot 2022-08-29 at 11.37.22.png

So, from a hardware point of view, not only could you hook up to this line out of the VIA, you could probably do so non-intrusively by means of a PDS card riser type affair.

What about software? The shutdown code looks at the Gestalt manager to find out whether the hardware has soft power features, so that's fairly easily patchable. If the Gestalt claims that soft shutdown is working, it calls _PowerOff, and as far as I can see, that should just twiddle the VIA line directly, even on the SE/30 (this is easy to test: call _PowerOff from a bit of code with an oscilloscope hooked up to that line and see if it does anything).

So it'd probably need a small INIT and a little bit of hardware to do power off, but nothing particularly complicated.
 

Phipli

Well-known member
Well, on the SE/30, as far as I can see, the POWEROFF line is still present on VIA2:

The only place this seems to go is the PDS slot (!), per page 1:


So, from a hardware point of view, not only could you hook up to this line out of the VIA, you could probably do so non-intrusively by means of a PDS card riser type affair.

What about software? The shutdown code looks at the Gestalt manager to find out whether the hardware has soft power features, so that's fairly easily patchable. If the Gestalt claims that soft shutdown is working, it calls _PowerOff, and as far as I can see, that should just twiddle the VIA line directly, even on the SE/30 (this is easy to test: call _PowerOff from a bit of code with an oscilloscope hooked up to that line and see if it does anything).

So it'd probably need a small INIT and a little bit of hardware to do power off, but nothing particularly complicated.
You could test by using Wish I Were as a IIcx? Plus an LED on the PDS slot.
 

Phipli

Well-known member
I guess everyone knows but, when soft power is broken on a machine, it shows the black "Now safe to switch off..." screen. Guess it triggers it after asserting power off.
 

Phipli

Well-known member
If you could find a way for my modern iMac to do this over USB, I'd pay you.
I think power off is possible, doesn't it already work if you use a USB/ADB adapter? Power on would require more hardware hacking than you'd be willing to see on a machine - you'd probably have to hack into the power button.

I started work on an ADB adapter with an integrated relay to switch the power switch on an ATX case, but need to return to it and make version 2.

SlimSocial_1661772387154.jpg
 

Phipli

Well-known member
Well, on the SE/30, as far as I can see, the POWEROFF line is still present on VIA2:

The only place this seems to go is the PDS slot (!), per page 1:


So, from a hardware point of view, not only could you hook up to this line out of the VIA, you could probably do so non-intrusively by means of a PDS card riser type affair.

What about software? The shutdown code looks at the Gestalt manager to find out whether the hardware has soft power features, so that's fairly easily patchable. If the Gestalt claims that soft shutdown is working, it calls _PowerOff, and as far as I can see, that should just twiddle the VIA line directly, even on the SE/30 (this is easy to test: call _PowerOff from a bit of code with an oscilloscope hooked up to that line and see if it does anything).

So it'd probably need a small INIT and a little bit of hardware to do power off, but nothing particularly complicated.
Excellent work by the way - I hadn't even dug out the schemes yet. In my defense, there was a cat sat on me.
 

Bolle

Well-known member
this is easy to test: call _PowerOff from a bit of code with an oscilloscope hooked up to that line and see if it does anything
It doesn't toggle on the SE/30 when you select "Shutdown" from the menu at least... I did test that before.
 

ironborn65

Well-known member
I think power off is possible, doesn't it already work if you use a USB/ADB adapter? Power on would require more hardware hacking than you'd be willing to see on a machine - you'd probably have to hack into the power button.

I started work on an ADB adapter with an integrated relay to switch the power switch on an ATX case, but need to return to it and make version 2.

View attachment 45689
It seems to be "only" a hardware solution to starts it up. From the software you should be able to turn it off.
If you trigger a second time the start button from the ADB you could abruptly turn it off: not very safe.
How to notify the software?
 

Phipli

Well-known member
It seems to be "only" a hardware solution to starts it up. From the software you should be able to turn it off.
If you trigger a second time the start button from the ADB you could abruptly turn it off: not very safe.
How to notify the software?
On my machine it would put it to sleep, it doesn't cut the power unless you long press?

But regardless, the keyboard sends a keypress signal which displays the "are you sure you want to shutdown?". That even works on my linux laptop with an ADB adapter.
 
Last edited:

cheesestraws

Well-known member
Someone who has time can see what this does to that line. That won't be me for a couple of weeks.
 

Attachments

  • softpowerenbl.sit
    16.8 KB · Views: 3

Phipli

Well-known member
Cool, I'm going to try this one as soon as possible
To be clear, the aim here is to trigger a pin on the PDS connector and confirm that it is possible. There won't be any impact on the computer's ability to soft power without hardware mods.
 
Top