The pfSense Store

Author Topic: nanobsd boot slice selection via switch plugged on gpio port (for Alix) ?  (Read 1779 times)

0 Members and 1 Guest are viewing this topic.

Offline df

  • Jr. Member
  • **
  • Posts: 32
  • Karma: +0/-0
    • View Profile
I use my alixes on the road, i like to have different kinds of setups on each slice (wifi to ethernet bridge / regular wan + wifi hotspot / etc)
And i was struck by how beautifull it would be to just select what slice to boot, before applying power to the unit, by triggering a switch mounted on the case ..
 
I guess this would involve making a simple schematic to hook a switch to the gpio port on Alix (or any GPIO enabled) motherboards.
Could be 2 way switch or rotary switch (if more than 2 nanobsd images on the storage device)

Only problem i have no clues what / how the active slice is setup for the next reboot.
Nor if it is "easilly" possible to add some code (understand in my case php, or shell) *somewhere*

Any advices are welcomed

Offline df

  • Jr. Member
  • **
  • Posts: 32
  • Karma: +0/-0
    • View Profile
Re: nanobsd boot slice selection via switch plugged on gpio port (for Alix) ?
« Reply #1 on: September 03, 2009, 04:09:18 am »
Another approach, still using GPIO, and possibly easier to do, would be to still hook a push button to the gpio, but, this time, while the board is lit..
If the button is pressed, trigger the slice selection routine, than reboot the box
But i really feel it'll be better if done before the board is turned on ..