Stop without skidding, and maintain control of the vehicle. That's the premise of ABS. It was first introduced in the 1980's and has been undergoing constant refinement ever since. The system is typically comprised of 4 ABS rings, 4 sensors, an ABS computer and a pressure-management system in the brake line. The ABS rings are attached either to the wheels, or more often, to the brake discs. They look like a notched ring - see the image below.
The sensors are magnetic field sensors which are held very close to the ABS rings and can detect the slight change in magnetic field as the teeth on the ring pass them. The pulsing field tells the ABS computer that the wheels are spinning, and how fast they're spinning.
When you brake, the wheel rotation starts to slow down. The ABS computer "listens" to the input from the sensors and can detect if one wheel is slowing down much quicker than the others - the precursor to the wheel locking up. This all happens in milliseconds, by the way. When the computer detects this condition, the pressure regulator interrupts the pressure in the brake lines by momentarily reducing the pressure so that the brakes give the wheels a chance to keep spinning rather than locking up. The computer then instructs the regulator to re-apply full pressure and again measures the wheel rotation. This on/off/measure cycle happens around 15 to 30 times a second. If the ABS kicks in, you'll feel it through the brake pedal as a vibration because the pulsing in the brake circuit affects all the components.
Newer generation ABS systems
As technology marches on, so does the control / feedback system used in ABS. It used to be the case that any single wheel approaching lockup would cause the ABS system to pulse the brake pressure for all the wheels. With the latest vehicles, the ABS computer is connected to 4 pressure regulators instead of just the one. This means it can selectively apply pulsed braking only to the wheel(s) that need it. So if three of the tyres are gripping well, but the front-left is beginning to skid, the ABS can unlock the front-left brake and pulse it to try to regain grip. It's all very James Bond.
ABS and skid control
The biggest misconception about ABS is that it will make you stop faster. This is absolutely not true. ABS has nothing to do with stopping power and everything to do with maintaining control of your vehicle, be it a car, truck or motorbike. The problem with skidding whilst braking is that it removes you from ultimate control of where the vehicle is going. On a motorbike, skidding invariably causes highsides, flips and general thoughts of "huh?" to the rider as he's flying through the air towards certain pain. In a car or truck, skidding stops the vehicle from going where you want it to, and instead makes it straight-line based on the camber of the road, the speed of the vehicle and how much damage it can do to your insurance policy.
Skidding is caused because the wheels lock up. Once they stop rotating, the tyres can no longer grip the road surface and begin to skate across it. When that happens, it really makes no difference where the steering is pointing because without grip, steering is useless.
With ABS, the idea is that the wheels don't ever lock up, so you still have control over the steering. The wheels keep going around, so the tyres keep gripping, so the steering is effective. That's where ABS gets its name - Anti-Lock Brakes.
The bone of contention with ABS
So many people think ABS gives them a license to drive faster, because they mistakenly believe that ABS will get them out of any situation. It's yet another technical placebo that has been put into vehicles which is making the standard of driving worse. The more gadgets and "driver aids" that get put into a car, the worse the drivers become because they live in a pink-spectacled world where they believe that the car will get them out of any problem they cause. It bothers me so much I have a "rant" page dedicated to it here : Nanny Cars.
Personally I don't like ABS. I don't like the idea of a computer interrupting the connection between my right foot and the brakes. It also doesn't work worth a damn on gravel or in the snow. With regular brakes, in the snow, you can jam them on and at least stand a chance of the tyres digging in and finding the road surface. With ABS the system will just take the brakes off and you'll skate merrily along on the snow with no chance of slowing down.
The hidden gremlin of ABS - what they don't advertise.
If you look at the statistics for crashes, a large percentage of them are "fender benders" - low-speed impacts that only do a little damage and so slow that the vehicle occupants are in no danger. Less than 15mph normally. I'll give you one guess what the typical "minimum activation speed" is for ABS. That's right. Your average ABS system is useless much below 15mph. Seriously. Try it yourself. Find an empty road on a slight downhill grade - even better if its on a dewy morning. Run your ABS-equipped car up to about 15mph and jam on the brakes as hard as you can. The car will skid to a stop and the ABS system will remain totally silent.
Aftermarket ABS systems
To the best of my knowledge, there's no such thing. A few years back a couple of companies tried to market what they called ABS systems that could be retrofitted to any vehicle. The product was a cylinder with a pressure-relief valve in it. The idea was that you inserted this system into the brake circuit somewhere. When you stomped on the brakes - symptomatic of locking up the wheels - the pressure relief valve opened and bled off some brake fluid into the cylinder, thus lowering the braking pressure being sent to the wheels. The idea was to take the "spike" off the initial push of the brake pedal so it wasn't ABS at all. The whole idea of putting something like this into a brake circuit makes me shudder - I wouldn't want to be the person trying to get their insurance and medical claims through after an accident when the investigators found one of these contraptions in their brake line!