Author Topic: PC motherboard as embedded controller - no HDD etc  (Read 5241 times)

0 Members and 1 Guest are viewing this topic.

Offline CirclotronTopic starter

  • Super Contributor
  • ***
  • Posts: 3567
  • Country: au
PC motherboard as embedded controller - no HDD etc
« on: July 27, 2015, 12:46:28 pm »
Has anyone ever seen a project where a PC motherboard is used but the BIOS is rewritten to make the mobo work basically as a large format Raspberry Pi or Arduino? No HDD and the entire firmware is entirely in the BIOS chip. Old motherboard costs zero. Has serial and parallel I/O.
 

Offline McBryce

  • Super Contributor
  • ***
  • Posts: 2798
  • Country: de
Re: PC motherboard as embedded controller - no HDD etc
« Reply #1 on: July 27, 2015, 01:21:35 pm »
Yes, there were a couple of projects that embedded an entire Linux dist in the BIOS chip, but I think they were fine tuned to work on only very particular motherboards.

McBryce.
30 Years making cars more difficult to repair.
 

Offline Kalvin

  • Super Contributor
  • ***
  • Posts: 2178
  • Country: fi
  • Embedded SW/HW.
Re: PC motherboard as embedded controller - no HDD etc
« Reply #2 on: July 27, 2015, 01:25:25 pm »
Configuring the motherboard's chipset would be a nightmare. BIOS hides the complex (and quite often poorly documented) chipset from the OS and provides "standard" set of services to be used by the OS. Also, whenever the chipset changes, the "standard" software interface will remain unchanged or at least remain backwards compatible. I would not bother to go for 100% bare-metal solution unless the payoffs are high enough.

The BIOS contains a simple bootloader which loads the OS startup code from the HDD or from a USB memory stick. I would first consider using the USB stick as a substitute for the HDD and load the complete OS and the application from the USB into the RAM. Small 1GB - 2GB USB sticks are very cheap. You would also have the BIOS services available for your OS and the application.

One may argue that the USB sticks are unreliable and are prone to wear. Well, if you do not ever write to the USB, they will not get corrupt --- as you will not going write to the BIOS either.

Just my 2c.
 

Offline ChristofferB

  • Frequent Contributor
  • **
  • Posts: 948
  • Country: dk
  • Chemistry phd student!
    • My channel:
Re: PC motherboard as embedded controller - no HDD etc
« Reply #3 on: July 27, 2015, 01:28:55 pm »
It may be a nightmare, but it's a really cool idea! Maybe using an older motherboard. ISA ports provide good slow (2-6 MHz or so) I/O.

--Christoffer //IG:Chromatogiraffery
Check out my scientific instruments diy (GC, HPLC, NMR, etc) Channel: https://www.youtube.com/channel/UCZ8l6SdZuRuoSdze1dIpzAQ
 

Offline technix

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: PC motherboard as embedded controller - no HDD etc
« Reply #4 on: July 27, 2015, 02:40:42 pm »
This is actually doable if you are using some kind of PCI(e) card or USB device, without rewriting the BIOS.

The special purpose PCIe card have two functionalities: GPIO expander for controlling stuff, and either some Option ROM or mass storage (e.g. SSD) to allow booting to the corresponding firmware. The BIOS will give your Option ROM a chance to run after it finished its business properly configuring the chipset etc, or can be configured to boot off the onboard mass storage.

The special purpose USB device present itself to the system as both a control interface and a mass storage device (aka flash drive.) The BIOS can be configured into booting off the embedded flash drive and it can include the required controlling software.

A good example of the latter would be a 2-port USB hub, a flash drive with a Linux distribution and controlling software installed, and an Arduino, wrapped in one package (or bundled into one board)
« Last Edit: July 27, 2015, 02:52:17 pm by technix »
 

Offline technix

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: PC motherboard as embedded controller - no HDD etc
« Reply #5 on: July 27, 2015, 02:46:04 pm »
Configuring the motherboard's chipset would be a nightmare. BIOS hides the complex (and quite often poorly documented) chipset from the OS and provides "standard" set of services to be used by the OS. Also, whenever the chipset changes, the "standard" software interface will remain unchanged or at least remain backwards compatible. I would not bother to go for 100% bare-metal solution unless the payoffs are high enough.

The BIOS contains a simple bootloader which loads the OS startup code from the HDD or from a USB memory stick. I would first consider using the USB stick as a substitute for the HDD and load the complete OS and the application from the USB into the RAM. Small 1GB - 2GB USB sticks are very cheap. You would also have the BIOS services available for your OS and the application.

One may argue that the USB sticks are unreliable and are prone to wear. Well, if you do not ever write to the USB, they will not get corrupt --- as you will not going write to the BIOS either.

Just my 2c.

You don't need to rewrite the BIOS at all, just find a way to give your special purpose card PCI(e) bus access and present an Option ROM to the BIOS. The original BIOS will initialize the chipset for you and call the Option ROM on your PCI(e) card. This will work for a PCIe card using a PCIe slot in the computer, an ExpressCard on a laptop, and a external box attached through Thunderbolt.

Alternatively, your device can be designed to connect to the USB port, presenting both a control interface and a mass storage device (aka flash drive). The BIOS can then be configured to boot off the embedded storage on the device you designed and that includes the code that controls the rest of the box.

By the way, if you went the ExpressCard route, since the interface including both PCIe x1 and USB 2.0, the control interface and the boot device can be located on both buses separately - e.g. a flash drive equivalent boot device on USB 2.0 and the control interface on PCIe x1 bus.
« Last Edit: July 27, 2015, 02:55:40 pm by technix »
 

Offline albert22

  • Regular Contributor
  • *
  • Posts: 177
Re: PC motherboard as embedded controller - no HDD etc
« Reply #6 on: July 27, 2015, 02:54:22 pm »
I used a laptop motherboard found at the dumpster to experiment. It had no HDD, floppy and it cannot boot from USB or pcmcia card.
Finally I had success in booting linux from the network because its network card supported PXE. With only 64M of RAM it was able to run dsl (damm small linux).  DSL runs entirely on RAM has a graphic desktop and supported all the peripherals on the crippled motherboard: Usb, pcmcia, network, sound and video. After booting it can be disconnected from the network and run standalone... until you power it down.
Not much as a useful application but great for me to start learning embedded linux.
 

Offline Kalvin

  • Super Contributor
  • ***
  • Posts: 2178
  • Country: fi
  • Embedded SW/HW.
Re: PC motherboard as embedded controller - no HDD etc
« Reply #7 on: July 27, 2015, 02:59:12 pm »
I had an impression that the OP didn't want to add any new hardware to the motherboard. So, even my suggestion of using a USB memory stick for storing the OS and application code may not be usable.
 

Offline technix

  • Super Contributor
  • ***
  • Posts: 3508
  • Country: cn
  • From Shanghai With Love
    • My Untitled Blog
Re: PC motherboard as embedded controller - no HDD etc
« Reply #8 on: July 27, 2015, 03:10:55 pm »
I had an impression that the OP didn't want to add any new hardware to the motherboard. So, even my suggestion of using a USB memory stick for storing the OS and application code may not be usable.

There is usually no way to use existing PC hardware as GPIO so some extra hardware have to be added. And the two most popular way to add such hardware - PCIe bus and USB, will allow the very extra hardware to carry an operating system on it.
 

Offline codeboy2k

  • Super Contributor
  • ***
  • Posts: 1836
  • Country: ca
Re: PC motherboard as embedded controller - no HDD etc
« Reply #9 on: July 28, 2015, 04:44:30 am »
I used a laptop motherboard found at the dumpster to experiment. It had no HDD, floppy and it cannot boot from USB or pcmcia card.
Finally I had success in booting linux from the network because its network card supported PXE. With only 64M of RAM it was able to run dsl (damm small linux).  DSL runs entirely on RAM has a graphic desktop and supported all the peripherals on the crippled motherboard: Usb, pcmcia, network, sound and video. After booting it can be disconnected from the network and run standalone... until you power it down.
Not much as a useful application but great for me to start learning embedded linux.


Something like that can be put behind a picture frame to make a smart frame that boots from your local net.  Add wifi and a power supply.

I boot my NAS (NAS4Free) with only a USB stick.  It's running on a fanless mItx board from ASUS, the C60M1-I.  It's a nice little board with 6 sata ports. The hard drives are only for storage and contain no OS.  The USB stick runs an embedded version of FreeBSD from the NAS4Free site and is designed not to write back to the flash while running, but only boots from it.  It uses memory for temp space and only writes configuration changes to the USB flash when a change is made.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf

 

-->