WEBVTT
Kind: captions
Language: en

00:00:00.320 --> 00:00:09.060
♪ Control ♪

00:00:09.700 --> 00:00:10.560
Hello.

00:00:10.560 --> 00:00:13.420
We're demonstrating 
an on/off servo control system

00:00:13.420 --> 00:00:17.140
using a Smart Magnetometer,
with a magnet on the actuator

00:00:19.280 --> 00:00:22.960
a Smart Angle Sensor 
underneath the magnetic knob,

00:00:25.200 --> 00:00:27.260
and an Arduino board.

00:00:27.840 --> 00:00:30.180
We have a three-position solenoid valve,

00:00:30.180 --> 00:00:32.720
but these valves don't release pressure 
when they're off,

00:00:32.720 --> 00:00:35.200
so the actuator tends to drift.

00:00:37.360 --> 00:00:39.480
Our control moves the cylinder

00:00:39.480 --> 00:00:42.480
when the position is outside 
a deadband.

00:00:49.040 --> 00:00:52.520
The angle sensor detects 
the rotation of a magnetic knob

00:00:52.520 --> 00:00:55.120
and sets the desired position.

00:00:55.120 --> 00:00:58.240
The magnetometer's sensitivity and wide range

00:00:58.240 --> 00:01:02.080
gives us control over 
about a 50-millimeter range.

00:01:03.920 --> 00:01:07.480
This valve provides on/off control 
like a thermostat.

00:01:07.880 --> 00:01:10.960
We could have smoother control with a 
proportional flow valve,

00:01:10.960 --> 00:01:13.760
but those valves are a lot more expensive.

00:01:16.800 --> 00:01:18.820
Here's a diagram:

00:01:18.820 --> 00:01:21.480
Both sensors have SPI interfaces,

00:01:21.480 --> 00:01:24.880
so we just connected them in parallel
with different Slave Selects.

00:01:25.740 --> 00:01:27.720
The Arduino drives the valve solenoids

00:01:27.720 --> 00:01:29.160
via transistors.

00:01:31.240 --> 00:01:33.600
Here's the Arduino program:

00:01:33.840 --> 00:01:35.760
There's a procedure 
for reading the sensors,

00:01:35.760 --> 00:01:38.000
which is a simple four-byte sequence.

00:01:38.820 --> 00:01:40.240
We read the angle sensor

00:01:40.760 --> 00:01:42.320
and the magnetometer.

00:01:43.560 --> 00:01:47.240
For this demo we use a simple 
inverse square root approximation

00:01:47.240 --> 00:01:49.320
for distance as function of field.

00:01:50.220 --> 00:01:54.340
For better accuracy, we could 
calibrate a piecewise linear lookup table

00:01:54.340 --> 00:01:56.640
as we demonstrated in another video.

00:01:57.580 --> 00:02:02.260
The cylinder is moved in or out
if the error is beyond the deadband tolerance.

00:02:04.320 --> 00:02:08.800
Here are the demo components 
and where to get them:

00:02:11.040 --> 00:02:13.520
Click, e-mail, or call
for more information,

00:02:13.520 --> 00:02:15.360
or to buy Smart Sensors,

00:02:15.360 --> 00:02:18.720
breakout boards, or evaluation kits.

