BB Black Power Button

This forum is for supported devices using an ARMv7 Texas Instruments (TI) SoC.

BB Black Power Button

Postby photomankc » Tue Jan 14, 2014 6:05 pm

Hello,

Does anyone know if the Black is currently expected to perform a shutdown when the power button is pressed on the board, or to power-off when the the command to do so is issued from the OS? I run into a lot of posts on the Beagle forums that suggest the way it is supposed to work is that pressing the power button while running is supposed to interrupt the OS and start an orderly shutdown, and it's not clear if that is then expected to turn off power completely or not after some delay. At present with my Arch install nothing occurs when the power button is pressed and I can see no indication that the OS saw anything at all. The command "poweroff" shuts down but does not power off the board.


One of my reasons to purchase this board was having the power button linked to the OS already to simplify getting putting a power button on my product that will shutdown the device properly. Is the interrupt ignored in Arch?

If so I'll have to connect a GPIO to an external button and go back to the userland service to monitor the pin and run the shutdown command and signal an external controller to kill the power. A lot of complexity to make a power button.
photomankc
 
Posts: 16
Joined: Mon Mar 04, 2013 10:00 pm

Re: BB Black Power Button

Postby WarheadsSE » Tue Jan 14, 2014 6:38 pm

Fair chance says that it might be in the events, but is not being watched to cause the shutdown.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: BB Black Power Button

Postby photomankc » Thu Jan 16, 2014 2:53 pm

So would that be an oversight that one would expect to see corrected or is that going to remain the case? I've never run anything other than Arch on these for fast boot time but I'm sure that early on they did at least power off from a "poweroff" command. I'm not completely sure about the power button.

I'm thinking I'll have to go back to a RaspberryPi like setup where an outboard uC generates an interrupt pulse when a button is pushed that my own apps can detect and act on and return a KILL signal to start a delayed power-off countdown. That would offer enough flexibility to use the BBB power button if it later starts to work but would not rely on it working as my current arrangement does.

My old arrangement had the uC start a 60 sec countdown when KILL was pulled high and then watch the KILL line during the count. On the RaspPi the system would release the GPIO and the KILL line would fall back to a default low which was the signal that the shutdown was complete and to power off now rather than continue the countdown.
photomankc
 
Posts: 16
Joined: Mon Mar 04, 2013 10:00 pm

Re: BB Black Power Button

Postby photomankc » Fri Jan 24, 2014 2:09 pm

Well.... I guess that is not promising.
photomankc
 
Posts: 16
Joined: Mon Mar 04, 2013 10:00 pm

Re: BB Black Power Button

Postby photomankc » Sat Jan 25, 2014 10:01 pm

Appears to be related to kernel 3.12.X. I installed Arch on a second BBB and that install has a 3.8 kernel and poweroff works as expected (board powers off completely) although the button does nothing with a powered on system. Still the power-down at the end is enough for my own solution to work much cleaner.
photomankc
 
Posts: 16
Joined: Mon Mar 04, 2013 10:00 pm

Re: BB Black Power Button

Postby WarheadsSE » Sat Jan 25, 2014 11:21 pm

That is the linux-am33x-legacy kernel package, btw.
Core Developer
Remember: Arch Linux ARM is entirely community donation supported!
WarheadsSE
Developer
 
Posts: 6807
Joined: Mon Oct 18, 2010 2:12 pm

Re: BB Black Power Button

Postby photomankc » Mon Feb 03, 2014 2:37 pm

As long as it behaves the way I need it to I'm fine with it being legacy. I got my circuit boards in today for my soft power switch design and it works quite well with the 3.8 kernel. SYS_3V3 works to signal the full system shutdown when it falls low as the BBB powers down. 2ms after that, the whole robot system is powered off as well. Only a single GPIO needed to signal a buton press so a program or script can perform a 'poweroff' command.

I was able to find a way to make it easily re-programmable though so I can also use a GPIO and a rising edge to signal shutdown with a programmable delay. So if this breaks in the future I can time the shutdown process and go that route although less desirable.

One other mode allows it to act like the Polulu power switch and cut power immediately after a rising edge is detected.

Image
photomankc
 
Posts: 16
Joined: Mon Mar 04, 2013 10:00 pm


Return to Texas Instruments (TI)

Who is online

Users browsing this forum: No registered users and 2 guests