Problem with comparison.
/Modules/Sensors/ALTIMET01A/SW/Python/ALTIMET_test.ipynb
0,0 → 1,2543
{
"metadata": {
"name": ""
},
"nbformat": 3,
"nbformat_minor": 0,
"worksheets": [
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"P\u0159esn\u00e9 m\u011b\u0159en\u00ed tlaku a jeho pou\u017eit\u00ed k ur\u010den\u00ed nadmo\u0159sk\u00e9 v\u00fd\u0161ky\n",
"=======\n",
"\n",
"P\u0159\u00edklad vyu\u017e\u00edv\u00e1 modulovou stavebnici MLAB a jej\u00ed Python knihovnu [pymlab](https://github.com/MLAB-project/MLAB-I2c-modules)\n",
"\n",
"Pou\u017eit\u00fd sn\u00edma\u010d [MPL3115A2](http://www.freescale.com/webapp/sps/site/prod_summary.jsp?code=MPL3115A2) m\u00e1 n\u00e1sleduj\u00edc\u00ed katalogov\u00e9 parametry: \n",
"\n",
"* Tlakov\u00e9 rozli\u0161en\u00ed: 1,5 Pa\n",
"* Relativn\u00ed p\u0159esnost: 0,1 kPa\n",
"* Absolutn\u00ed tlakov\u00e1 p\u0159esnost 0,4 kPa\n",
"\n",
"Katalogov\u00fd rozsah m\u011b\u0159en\u00ed tlaku je 50 kPa a\u017e 110 kPa, co\u017e by odpov\u00eddalo rozsahu m\u011b\u0159en\u00fdch v\u00fd\u0161ek p\u0159ibli\u017en\u011b -1 km a\u017e 6 km. Z [jin\u00fdch experiment\u016f](http://wiki.mlab.cz/doku.php?id=cs:altimet#parametry) s t\u00edmto tlakov\u00fdm \u010didlem ale v\u00edme \u017ee jeho m\u011b\u0159\u00edc\u00ed rozsah je podstatn\u011b v\u011bt\u0161\u00ed zejm\u00e9na v oblasti n\u00edzk\u00fdch tlak\u016f, a lze s n\u00edm m\u011b\u0159it minim\u00e1ln\u011b do v\u00fd\u0161ky 16 km. \n",
"\n",
"Zprovozn\u011bn\u00ed demo k\u00f3du\n",
"---------------------\n",
"\n",
"Nejd\u0159\u00edve zjist\u00edme zda m\u00e1me p\u0159\u00edstup pro z\u00e1pis a \u010dten\u00ed do syst\u00e9mov\u00e9ho za\u0159\u00edzen\u00ed. A jak\u00e9 \u010d\u00edslo m\u00e1 I\u00b2C sb\u011brnice na kterou m\u00e1me p\u0159ipojen\u00e1 \u010didla. \n"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"!i2cdetect -l"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"i2c-0\ti2c \ti915 gmbus ssc \tI2C adapter\r\n",
"i2c-1\ti2c \ti915 gmbus vga \tI2C adapter\r\n",
"i2c-2\ti2c \ti915 gmbus panel \tI2C adapter\r\n",
"i2c-3\ti2c \ti915 gmbus dpc \tI2C adapter\r\n",
"i2c-4\ti2c \ti915 gmbus dpb \tI2C adapter\r\n",
"i2c-5\ti2c \ti915 gmbus dpd \tI2C adapter\r\n",
"i2c-6\ti2c \tDPDDC-C \tI2C adapter\r\n",
"i2c-7\ti2c \tDPDDC-D \tI2C adapter\r\n",
"i2c-8\ti2c \ti2c-tiny-usb at bus 001 device 008\tI2C adapter\r\n"
]
}
],
"prompt_number": 1
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Proto\u017ee pro p\u0159ipojen\u00ed \u010didel k po\u010d\u00edta\u010di pou\u017e\u00edv\u00e1me adapt\u00e9r i2c-tiny-usb. Vid\u00edme, \u017ee sb\u011brnice m\u00e1 aktu\u00e1ln\u011b ozna\u010den\u00ed nap\u0159\u00edklad i2c-8. \n",
"\n",
"V p\u0159\u00edpad\u011b, \u017ee v\u00fd\u0161e uveden\u00fd p\u0159\u00edklad vr\u00e1t\u00ed chybu, nebo pojmenov\u00e1n\u00ed \"unknown\" tak nem\u00e1me p\u0159\u00edstup k syst\u00e9mov\u00fdm rozhran\u00edm. Ten z\u00edsk\u00e1me vytvo\u0159en\u00edm souboru s n\u00e1sleduj\u00edc\u00edm obsahem ve slo\u017ece: /etc/udev/rules.d/i2c-devices.rules"
]
},
{
"cell_type": "raw",
"metadata": {},
"source": [
"KERNEL==\"i2c-[0-9]*\", GROUP=\"i2c\""
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Toto ozna\u010den\u00ed budeme je\u0161t\u011b d\u00e1le pot\u0159ebovat, proto si jej ulo\u017e\u00edme da prom\u011bnn\u00e9. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"port = 8"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 2
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Budeme pokra\u010dovat na\u010dten\u00edm pot\u0159ebn\u00fdch modul\u016f pro zach\u00e1zen\u00ed s I\u00b2C sn\u00edma\u010di."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import time\n",
"import datetime\n",
"import sys\n",
"\n",
"from pymlab import config\n",
"import matplotlib.pyplot as plt\n",
"import numpy as np"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 3
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Nyn\u00ed si nadefinujeme strukturu p\u0159ipojen\u00ed jednotliv\u00fdch \u010didel na I\u00b2C sb\u011brnici."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"cfg = config.Config(\n",
" i2c = {\n",
" \"port\": port,\n",
" },\n",
" bus = [\n",
" {\n",
" \"type\": \"i2chub\",\n",
" \"address\": 0x72,\n",
" \n",
" \"children\": [\n",
" {\"name\": \"altimet\", \"type\": \"altimet01\" , \"channel\": 7, }, \n",
" ],\n",
" },\n",
" ],\n",
")"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 8
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Tuto strukturu inicializujeme, aby jsme dos\u00e1hli definovan\u00e9 konfigurace \u010didel."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"cfg.initialize()\n",
"gauge = cfg.get_device(\"altimet\")\n",
"time.sleep(0.5)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stderr",
"text": [
"WARNING:pymlab.sensors.iic:HID device does not exist, we will try SMBus directly...\n"
]
}
],
"prompt_number": 9
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Nyn\u00ed u\u017e m\u016f\u017eeme p\u0159\u00edmo komunikovat se za\u0159\u00edzen\u00edm pojmenovan\u00fdm jako gauge. A vy\u010d\u00edst z n\u011bj s\u00e9rii 100 vzork\u016f. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"MEASUREMENTS = 100\n",
"t = np.zeros(MEASUREMENTS)\n",
"p = np.zeros(MEASUREMENTS)\n",
"\n",
"# gauge.route() V p\u0159\u00edpad\u011b v\u00edce \u010didel je pot\u0159eba ke ka\u017ed\u00e9mu p\u0159ed jeho pou\u017eit\u00edm nechat vyroutovat cesutu na sb\u011brnici.\n",
"for n in range(MEASUREMENTS):\n",
" (t[n], p[n]) = gauge.get_tp()\n",
" print(n,t[n], p[n])"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"(0, 22.625, 98286.0)\n",
"(1, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(2, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(3, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(4, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(5, 22.625, 98284.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(6, 22.625, 98284.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(7, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(8, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(9, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(10, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(11, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(12, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(13, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(14, 22.625, 98284.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(15, 22.625, 98284.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(16, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(17, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(18, 22.625, 98284.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(19, 22.625, 98284.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(20, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(21, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(22, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(23, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(24, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(25, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(26, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(27, 22.625, 98290.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(28, 22.625, 98290.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(29, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(30, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(31, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(32, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(33, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(34, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(35, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(36, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(37, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(38, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(39, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(40, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(41, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(42, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(43, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(44, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(45, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(46, 22.625, 98288.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(47, 22.625, 98288.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(48, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(49, 22.625, 98286.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(50, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(51, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(52, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(53, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(54, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(55, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(56, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(57, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(58, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(59, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(60, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(61, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(62, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(63, 22.625, 98282.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(64, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(65, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(66, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(67, 22.625, 98288.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(68, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(69, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(70, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(71, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(72, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(73, 22.625, 98286.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(74, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(75, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(76, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(77, 22.625, 98284.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(78, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(79, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(80, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(81, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(82, 22.625, 98290.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(83, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(84, 22.625, 98286.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(85, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(86, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(87, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(88, 22.625, 98288.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(89, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(90, 22.625, 98286.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(91, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(92, 22.625, 98290.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(93, 22.625, 98288.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(94, 22.625, 98288.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(95, 22.625, 98288.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(96, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(97, 22.625, 98290.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(98, 22.625, 98290.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(99, 22.625, 98290.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n"
]
}
],
"prompt_number": 34
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Nam\u011b\u0159en\u00e1 data si ulo\u017e\u00edme pro pozd\u011bj\u0161\u00ed zpracov\u00e1n\u00ed. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"np.savez(\"data_desk\", temp = t, preassure = p)"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 35
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Nyn\u00ed p\u0159em\u00edst\u00edme m\u011b\u0159\u00edc\u00ed p\u0159\u00edpravek ze stolu na zem, a zopakujeme m\u011b\u0159en\u00ed"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"MEASUREMENTS = 100\n",
"t = np.zeros(MEASUREMENTS)\n",
"p = np.zeros(MEASUREMENTS)\n",
"\n",
"# gauge.route() V p\u0159\u00edpad\u011b v\u00edce \u010didel je pot\u0159eba ke ka\u017ed\u00e9mu p\u0159ed jeho pou\u017eit\u00edm nechat vyroutovat cesutu na sb\u011brnici.\n",
"for n in range(MEASUREMENTS):\n",
" (t[n], p[n]) = gauge.get_tp()\n",
" print(n,t[n], p[n])"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"(0, 22.5625, 98296.25)\n",
"(1, 22.5625, 98296.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(2, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(3, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(4, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(5, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(6, 22.5625, 98302.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(7, 22.5625, 98302.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(8, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(9, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(10, 22.5625, 98304.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(11, 22.5625, 98304.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(12, 22.5625, 98304.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(13, 22.5625, 98304.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(14, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(15, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(16, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(17, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(18, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(19, 22.5625, 98304.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(20, 22.5625, 98304.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(21, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(22, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(23, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(24, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(25, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(26, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(27, 22.5625, 98296.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(28, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(29, 22.5625, 98306.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(30, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(31, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(32, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(33, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(34, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(35, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(36, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(37, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(38, 22.5625, 98296.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(39, 22.5625, 98296.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(40, 22.5625, 98296.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(41, 22.5625, 98296.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(42, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(43, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(44, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(45, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(46, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(47, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(48, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(49, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(50, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(51, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(52, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(53, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(54, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(55, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(56, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(57, 22.5625, 98296.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(58, 22.5625, 98296.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(59, 22.5625, 98296.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(60, 22.5625, 98298.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(61, 22.5625, 98298.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(62, 22.5625, 98298.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(63, 22.5625, 98298.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(64, 22.5625, 98304.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(65, 22.5625, 98304.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(66, 22.5625, 98298.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(67, 22.5625, 98298.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(68, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(69, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(70, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(71, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(72, 22.5625, 98298.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(73, 22.5625, 98298.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(74, 22.5625, 98298.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(75, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(76, 22.5625, 98302.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(77, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(78, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(79, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(80, 22.5625, 98300.25)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(81, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(82, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(83, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(84, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(85, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(86, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(87, 22.5625, 98302.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(88, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(89, 22.5625, 98300.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(90, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(91, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(92, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(93, 22.5625, 98300.0)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(94, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(95, 22.5625, 98298.5)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(96, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(97, 22.5625, 98298.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(98, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n",
"(99, 22.5625, 98300.75)"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"\n"
]
}
],
"prompt_number": 10
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"np.savez(\"data_floor\", temp = t, preassure = p)"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 11
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"D\u00e1le bude pracov\u00e1no s daty ulo\u017een\u00fdmi do souboru, kter\u00e9 m\u016f\u017eeme na\u010d\u00edst n\u00e1sleduj\u00edc\u00edm blokem."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"data = np.load('./data_desk.npz')\n",
"th=data['temp']\n",
"ph=data['preassure']"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 3
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Na\u010dten\u00e1 data nyn\u00ed budeme statisticky analyzovat. Najdeme minim\u00e1ln\u00ed a maxim\u00e1ln\u00ed hodnoty a spo\u010d\u00edt\u00e1me sm\u011brodatnou odchylku. "
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Minim\u00e1ln\u00ed nam\u011b\u0159en\u00e1 hodnota tlaku:"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amin(ph)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 27,
"text": [
"98346.0"
]
}
],
"prompt_number": 27
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Minim\u00e1ln\u00ed nam\u011b\u0159en\u00e1 hodnota teploty:"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amin(th)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 28,
"text": [
"22.5625"
]
}
],
"prompt_number": 28
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Maxim\u00e1ln\u00ed tlak"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amax(ph)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 29,
"text": [
"98358.25"
]
}
],
"prompt_number": 29
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Maxim\u00e1ln\u00ed hodnota teploty"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amax(th)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 30,
"text": [
"22.625"
]
}
],
"prompt_number": 30
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Sm\u011brodatn\u00e1 odchylka tlaku"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"std(ph)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 31,
"text": [
"2.3781768226942255"
]
}
],
"prompt_number": 31
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Sm\u011brodatn\u00e1 odchylka teploty"
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"std(th)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 32,
"text": [
"0.024518806557416305"
]
}
],
"prompt_number": 32
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Otev\u0159eme soubor s m\u011b\u0159en\u00edm z podlahy a zpo\u010d\u00edt\u00e1me znovu statistick\u00e9 parametry. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"data = np.load('./data_floor.npz')\n",
"tl=data['temp']\n",
"pl=data['preassure']"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 1
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amin(pl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 15,
"text": [
"98296.0"
]
}
],
"prompt_number": 15
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amin(tl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 16,
"text": [
"22.5625"
]
}
],
"prompt_number": 16
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amax(pl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 17,
"text": [
"98306.75"
]
}
],
"prompt_number": 17
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"amax(tl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 18,
"text": [
"22.5625"
]
}
],
"prompt_number": 18
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"std(pl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 19,
"text": [
"2.2464082442868674"
]
}
],
"prompt_number": 19
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"std(tl)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 14,
"text": [
"0.0"
]
}
],
"prompt_number": 14
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Pro porovn\u00e1n\u00ed je nyn\u00ed mo\u017en\u00e9 vykreslit graf z hodnot nam\u011b\u0159en\u00fdch na stole a na zemi. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#fig, ax = plt.subplots()\n",
"\n",
"plt.plot( pl, label=\"Podlaha\")\n",
"plt.plot( ph, label=\"Stul\")\n",
"plt.legend(loc=2); # upper left corner\n",
"plt.xlabel('vzorek')\n",
"plt.ylabel('Tlak [Pa]')\n",
"plt.title('Namerene tlaky');\n",
"plt.show()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYEAAAEVCAYAAAAGrllxAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzsnXd8U/X+/19pWroXpUBLCwWKQBmllNEWKG1RliAFAUVk\nKAqiXhyI43tVcFWG4PYi1ys40Kven4iAICAtqKWMIkuQClLoBDpI98zn98fxpBknyTlpTpI27+fj\nwUOTnPHJ6cl5fd7zo2CMMRAEQRBOiYu9B0AQBEHYDxIBgiAIJ4ZEgCAIwokhESAIgnBiSAQIgiCc\nGBIBgiAIJ4ZEgLA7ubm5cHFxwX/+8x+d99944w3cd999dhqVfOzatQsrV64EAGzZsgVTp041uX1u\nbi58fX1tMTTCCSERIBwCFxcXrFixAn/++afmPYVCYccRycexY8dQVlZm72EQBAASAcJB8PT0xPLl\nyzFnzhw0NjYCALTrGHNycnDbbbchISEBERERSE1NRX19PQDAw8MD//d//4fBgwcjIiIC33zzDWbP\nno3+/ftj3LhxqKmpAQCcP38eEyZMwLBhwxATE4PNmzcDADIyMhAdHY1Ro0YhJiYGDQ0N2LFjB+Li\n4jB06FCMHj0aWVlZAIBVq1Zh4cKFmDhxIvr374/ExEQUFRUBAAoKCjBjxgwMGzYM0dHReP311w2+\n55EjR/Dhhx/iq6++wvPPP68jdFlZWRg7dizi4uLQo0cP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Ii\nFqYQEBGxMIWAiIiFKQRERCxMISAiYmEKARERC1MIiIhYmEJARMTCfgCZinoJ0V/GkAAAAABJRU5E\nrkJggg==\n",
"text": [
"<matplotlib.figure.Figure at 0x7fd03e30b090>"
]
}
],
"prompt_number": 4
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#fig, ax = plt.subplots()\n",
"\n",
"plt.plot( tl, label=\"Podlaha\")\n",
"plt.plot( th, label=\"Stul\")\n",
"plt.legend(loc=2); # upper left corner\n",
"plt.xlabel('vzorek')\n",
"plt.ylabel('Teplota [deg C]')\n",
"plt.title('Namerene teploty');\n",
"plt.show()"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "display_data",
"png": "iVBORw0KGgoAAAANSUhEUgAAAYkAAAEVCAYAAAAVeRmFAAAABHNCSVQICAgIfAhkiAAAAAlwSFlz\nAAALEgAACxIB0t1+/AAAIABJREFUeJzt3Xl0Tff+//HnydASkiOK3rRXq8RQsyLhnCCHK0m/LUXR\n0haVpg3uj1thVeegxn6rt8NqKW24HdwOX1IpWrEqUiK5olcpIYZLFTXmZjBlOPv3R5ZTaWwRcpKQ\n12Mta+Wcz9mf895bzn7lcz57sBiGYSAiInIZHlVdgIiIVF8KCRERMaWQEBERUwoJERExpZAQERFT\nCgkRETGlkJBq5cCBA3h4ePDhhx+WeP5///d/efLJJ6uoKvdZuXIlr7766nX14eHhwenTp93+PlIz\nKSSk2vHw8GDy5Mns2bPH9ZzFYqnCitxn8+bNZe7gb6T3kZuPQkKqndq1axMTE8OwYcMoKCgA4NJz\nPjMzM+nbty82m40mTZowYMAALly4AECtWrV44YUXaN++PU2aNOHLL79k6NCh3HvvvfTp04ezZ88C\nkJGRQXh4OF26dKFTp07ExcUBkJSURIcOHbDb7XTq1In8/HwSEhLo1q0b9913HyEhIaSmpgIQGxvL\nqFGjiIiI4N5776Vnz54cPXoUgMOHDzNo0CC6dOlChw4dmDVrVqn1TEtLY8GCBXz++ee8/PLLAHz4\n4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v2lbHaNcofj2R6++23\n2bBhg+vxzJkzGThwILfffjt33XUXDz/8MHv37i217KV/pV/K29ubr7/+mgkTJjB37lwKCgqYPn06\n3bt3JykpqcQyrVu35oMPPuDRRx/FMAy8vb1JSEjAx8enVP+XPv7ss8/461//Svv27cnPz2f48OEM\nGzasVC19+vRh0KBB3Hrrrbz11ls899xz9O3bFw8PD6xWK8uXL3f1XbduXXr06EFWVhYPP/yw65Dg\ni+8ZGRnJoUOHCAoKwul00rx5c1cQ/vF9GjZsSNeuXWndunWJEYpIKZU9CVJRYmNjjQULFhiGYRg7\nduwwWrZsaWzbtu2yr3U6nUZYWJgxZ86cEs9PmTLFmDt3rmEYhrF161aje/fuhmEYRpcuXYwffvjB\nMIziCen33nvPWLFihfH0008bhlE8WTp16lTXhOXFejRxLe4yatSoUr+/1+PEiRPGPffcY/z6668V\n1qfcnNwyknA6nYwdO5Zt27Zx6623smjRIpo1a+ZqT0hIYPr06Xh5eTF69GieeuopFi9ezJIlSwA4\nd+4cP/30E8eOHcPPz++y73HpiUEvvPAC+fn5jB8/HoB69eqxfPly3nzzTQIDAykqKiI5OZmCggJW\nr14NwOzZs5kyZQqPP/44q1atwsvLi8WLFwPFhyGOGzeOwsJCmjZtyuuvv46XlxdJSUn07NmTvLw8\nBg0aVOK7a7h5j+WXm8vChQt58cUXefHFF7nzzjuruhyp5iyGUfGzrcuWLeObb77ho48+Ii0tjVmz\nZhEfHw8UTxq3bt2a9PR0fHx8sNvtfPPNNzRq1Mi1/F//+lc6duzIU089VdGliYhIObhl4nrjxo1E\nREQAEBwcTHp6uqstIyODwMBArFYr3t7ehISEkJyc7GpPT09nx44dCggRkWrALSGRk5NT4msiT09P\nnE6nq81qtbrafH19yc7Odj2eOXMmsbGx7ihLRETKyS1zEn5+fuTm5roeO51OPDyK88hqtZZoy83N\ndR0H/t///pfMzEzXkUWXExgYyL59+9xRtojITatZs2auowDLwy0jCbvdzqpVqwBITU0tcZhoq1at\n2LNnD1lZWeTn55OcnO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hQAa9eu\nxcvLS189SbWnkYTIH3h4eDBkyBCio6MZOHAgv/zyC8OGDePTTz913eTo3nvv5YcffgCKL7e8fft2\n7rnnHtfyF18zbNgw1q1bx9dff83QoUOpX78+ACtWrMDf358FCxZUwRqKXD1d4E/kMg4dOkRgYCB7\n9uxh7Nix7N27lzvvvBOn08ndd9/NwoULiYqKYt++fZw7d44JEybwxBNP4HA4WLBgAS1atCA/P5+o\nqCgOHjxITk4O48aNIzIykqZNm7Jr1y7OnDlDUFAQ3377Lc2aNavqVRa5LIWEiIiY0tdNIiJiSiEh\nIiKmFBIiImJKISEiIqYUEiIiYkohISIiphQSIiJiSiEhIiKm/j99TrGB0ZKj+wAAAABJRU5ErkJg\ngg==\n",
"text": [
"<matplotlib.figure.Figure at 0x7fd03e275390>"
]
}
],
"prompt_number": 5
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Z nam\u011b\u0159en\u00fdch hodnot je mo\u017en\u00e9 spo\u010d\u00edtat v\u00fd\u0161ku. Pou\u017eijeme k tomu barometrickou rovnici. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"from sympy import *\n",
"init_printing()\n",
"\n",
"#p0 = Symbol('p_0')\n",
"#l = Symbol('L')\n",
"#cp = Symbol('C_p')\n",
"#t0 = Symbol('T_0')\n",
"#g = Symbol('g')\n",
"#m = Symbol('M')\n",
"#r = Symbol('R')\n",
"#p = Symbol('p')\n",
"#h = Symbol('h')\n",
"\n",
"po = Symbol('po')\n",
"l = Symbol('l')\n",
"cp = Symbol('cp')\n",
"to = Symbol('to')\n",
"g = Symbol('g')\n",
"m = Symbol('m')\n",
"r = Symbol('r')\n",
"p = Symbol('p')\n",
"h = Symbol('h')\n",
"\n",
"bf = Eq(po*(1 - (l*h)/to)**((g*m)/(r*l)), p)\n",
"\n",
"bf"
],
"language": "python",
"metadata": {},
"outputs": [
{
"latex": [
"$$po \\left(- \\frac{h l}{to} + 1\\right)^{\\frac{g m}{l r}} = p$$"
],
"metadata": {},
"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Cx88oLc126OuUxeCdgtK/PgSDZanyM1KqYiG2QCp\nBUjPkhW3wyXd0RTIyMnaTudSp3OH8uiNSp4izCa3rgmNd/8AbJgiY4tD3qic4kZZ9BZcqJO4INsH\nICelh94XUlGDT2cN+UYlP4swG6BUGXsGc5Ams5Fz35DrQvVGBTlRo9kAy5ccqIK1ii4LyON9lVn5\nlT3uudfn7gZiqcK7VIBmA9CTEut3DKdgfk0BibLDNyQaEyuD9lmWRq/LEAPQlMEw20aFL1bMnZ4U\niunNFuaYRdnXPtdE/ZVICCannKSWvCVJ2VHQpBRIy4qkCfSogE1htGqZfenklhqrwkwTr6b7sDhm\nuiUygJvkXB5VYdxB2aIOOdJRLfjywqqwYopFHdWK0hv0KwCrwoop0k2FqJNSeO3ZhLIqrBhaqilE\nrXQZOVI9OM6qMOoISddTiFoJj7LazhSrwoqhtxWaXir4oqdYn+FVWNRDnNKU/vgIquCvk5nNZFlE\nVTg+INwA4rpOQWUx2XzDS+4f1Eu+FRk2+7GhUbY5xu/6Yu8TkMdr2O4b+uK2bC2uqRT+Y5GqU6OF\n27jGBHDM01qo4RvdYgkTer/nUAAAAABJRU5ErkJggg==\n",
"prompt_number": 26,
"text": [
" g\u22c5m \n",
" \u2500\u2500\u2500 \n",
" l\u22c5r \n",
" \u239b h\u22c5l \u239e \n",
"po\u22c5\u239c- \u2500\u2500\u2500 + 1\u239f = p\n",
" \u239d to \u23a0 "
]
}
],
"prompt_number": 26
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Ze kter\u00e9 vyj\u00e1d\u0159\u00edme v\u00fd\u0161ku v z\u00e1vislosti na tlaku a dosad\u00edme nam\u011b\u0159en\u00e9 tlaky a zn\u00e1m\u00e9 konstanty."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"#bf.subs(p0, 101325,simultaneous=True); # standardn\u00ed tlak v Pa na hladin\u011b mo\u0159e\n",
"#bf.subs(l, 0.0065,simultaneous=True); # Pokles teploty s v\u00fd\u0161kou [K/m]\n",
"#bf.subs(cp, 1007,simultaneous=True); # specifick\u00e9 teplo p\u0159i konstantn\u00edm tlaku J/(kg\u2022K)\n",
"#bf.subs(t0, 288.15,simultaneous=True); # standardn\u00ed teplota na hladin\u011b mo\u0159e K\n",
"#bf.subs(g, 9.80665,simultaneous=True); # standardn\u00ed gravita\u010dn\u00ed zrychlen\u00ed na povrchu zem\u011b\n",
"#bf.subs(m, 0.0289644,simultaneous=True); # mol\u00e1rn\u00ed hmotnost such\u00e9ho vzduchu\tkg/mol\n",
"#bf.subs(r, 8.31447,simultaneous=True); # univerz\u00e1ln\u00ed plynov\u00e1 konstanta J/(mol\u2022K)\n",
"\n",
"bfh=solve(bf, h)\n",
"\n",
"#bfh.subs([(p0,101325), (l,0.0065), (cp,1007), (t0,288.15), (g,9.80665), (m,0.0289644), (r, 8.31447), (p, 98296.0)],simultaneous=True).evalf()\n",
"\n",
"\n",
"\n",
"#bf.subs(p, 98296.0)\n",
"#N(bf,5)\n",
"#bf.evalf(n=3)"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 27
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"lambdify(bf,h)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"ename": "SyntaxError",
"evalue": "invalid syntax (<string>, line 1)",
"output_type": "pyerr",
"traceback": [
"\u001b[0;36m File \u001b[0;32m\"<string>\"\u001b[0;36m, line \u001b[0;32m1\u001b[0m\n\u001b[0;31m lambda po*(-h*l/to + 1)**(g*m/(l*r)) == p: (h)\u001b[0m\n\u001b[0m ^\u001b[0m\n\u001b[0;31mSyntaxError\u001b[0m\u001b[0;31m:\u001b[0m invalid syntax\n"
]
}
],
"prompt_number": 28
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"type(cp)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"metadata": {},
"output_type": "pyout",
"prompt_number": 60,
"text": [
"sympy.core.symbol.Symbol"
]
}
],
"prompt_number": 60
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"\n",
"\n",
"import sys\n",
"import time\n",
"\n",
"\n",
"\n",
"from IPython.display import clear_output\n",
"for i in range(10):\n",
" time.sleep(0.25)\n",
" clear_output()\n",
" print i\n",
" sys.stdout.flush()\n",
"\n"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"9\n"
]
}
],
"prompt_number": 10
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"V\u00fdvoj hodnot v \u010dase\n",
"------------------\n",
"\n",
"Vid\u00edme, \u017ee nam\u011b\u0159en\u00e9 hodnoty nevykazuj\u00ed \u017e\u00e1dn\u00fd trend, a m\u011b\u0159en\u00e9 chyby jsou zp\u016fsobeny pravd\u011bpodobn\u011b \u0161umem obvod\u016f \u010didla. Je to d\u016fsledek tepeln\u00e9 stability \u010didla, a faktu, \u017ee tlakov\u00e9 zm\u011bny v atmosf\u00e9\u0159e jsou relativn\u011b pomal\u00e9. S \u010dasovou konstantou minim\u00e1ln\u011b jednotky minut a na\u0161e m\u011b\u0159en\u00ed trvalo \u0159\u00e1dov\u011b des\u00edtky sekund. \n",
"\n",
"Absolutn\u00ed kalibrace tlaku\n",
"------------------\n",
"\n",
"V p\u0159\u00edpad\u011b, \u017ee by jsme pot\u0159ebovali tlakov\u00fd senzor pota\u017emo v\u00fd\u0161kom\u011br absolutn\u011b zkalibrovat, tak si k tomuto \u00fa\u010delu m\u016f\u017eeme p\u016fj\u010dit data z n\u011bkter\u00e9 kalibrovan\u00e9 stanice. V Praze pou\u017eijeme nap\u0159\u00edklad stanici CHMI pro Prahu 10. "
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"import openweather\n",
"from datetime import datetime\n",
"\n",
"ow = openweather.OpenWeather()\n",
"print ow.get_weather(61457)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"{u'main': {u'pressure': 1016, u'temp': 299.25, u'humidity': 38}, u'name': u'Prague 10', u'rain': {u'1h': 0}, u'station': {u'zoom': 10}, u'coord': {u'lat': 50.0787, u'lon': 14.4966}, u'date': u'2014-05-21 15:55:04', u'dt': 1400687704, u'calc': {u'dewpoint': 10.7}, u'id': 61457, u'wind': {u'gust': 12.1, u'deg': 225}}\n"
]
}
],
"prompt_number": 57
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Proto\u017ee datov\u00fd set byl nam\u011b\u0159en\u00fd v minulosti, mus\u00edme si st\u00e1hnout data pro toto \u010dasov\u00e9 obdob\u00ed."
]
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"start_date = datetime(2014, 4, 20)\n",
"end_date = datetime(2014, 4, 22)\n",
"print ow.get_historic_weather(61457, start_date, end_date)"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stderr",
"text": [
"OpenWeather.do_request() got ValueError: No JSON object could be decoded (1. attempt)\n",
"OpenWeather.do_request() got ValueError: No JSON object could be decoded (2. attempt)\n"
]
},
{
"output_type": "stream",
"stream": "stdout",
"text": [
"None\n"
]
},
{
"output_type": "stream",
"stream": "stderr",
"text": [
"OpenWeather.do_request() got ValueError: No JSON object could be decoded (3. attempt)\n"
]
}
],
"prompt_number": 60
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"stations = ow.find_stations_near(\n",
" 14.45, # longitude\n",
" 50.07, # latitude\n",
" 100 # kilometer radius\n",
")"
],
"language": "python",
"metadata": {},
"outputs": [],
"prompt_number": 66
},
{
"cell_type": "code",
"collapsed": false,
"input": [
"print stations"
],
"language": "python",
"metadata": {},
"outputs": [
{
"output_type": "stream",
"stream": "stdout",
"text": [
"{u'list': [], u'message': u'', u'calctime': u'', u'cod': u'200', u'cnt': 0}\n"
]
}
],
"prompt_number": 64
},
{
"cell_type": "code",
"collapsed": false,
"input": [],
"language": "python",
"metadata": {},
"outputs": []
}
],
"metadata": {}
}
]
}
/Modules/Sensors/ALTIMET01A/SW/Python/data_desk.npz
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Property changes:
Added: svn:mime-type
+application/octet-stream
\ No newline at end of property
/Modules/Sensors/ALTIMET01A/SW/Python/data_floor.npz
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Property changes:
Added: svn:mime-type
+application/octet-stream
\ No newline at end of property
/Modules/Sensors/ALTIMET01A/SW/Python/data_ground.npz
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Property changes:
Added: svn:mime-type
+application/octet-stream
\ No newline at end of property
/Modules/Sensors/ALTIMET01A/SW/Python/data_logger.py
0,0 → 1,116
#!/usr/bin/python
 
# Python example utility for MLAB ALTIMET01A testing bed with DPI145.
 
import time
import datetime
import sys
import serial
 
from pymlab import config
 
 
#### Script Arguments ###############################################
 
if len(sys.argv) != 2:
sys.stderr.write("Invalid number of arguments.\n")
sys.stderr.write("Usage: %s #I2CPORT\n" % (sys.argv[0], ))
sys.exit(1)
 
port = eval(sys.argv[1])
 
 
#### Sensor Configuration ###########################################
 
cfg = config.Config(
port = port,
bus = [
{
"type": "i2chub",
"address": 0x72,
"children": [
{
"type": "i2chub",
"address": 0x70,
"channel": 3,
"children": [
{"name": "altimet1", "type": "altimet01" , "channel": 0, },
{"name": "altimet2", "type": "altimet01" , "channel": 3, },
{"name": "altimet3", "type": "altimet01" , "channel": 4, },
{"name": "altimet4", "type": "altimet01" , "channel": 5, },
{"name": "altimet5", "type": "altimet01" , "channel": 6, },
{"name": "altimet6", "type": "altimet01" , "channel": 7, },
],
},
{"name": "altimet8", "type": "altimet01" , "channel": 6, },
],
},
 
# {
# "type": "i2chub",
# "address": 0x72,
# "children": [
# {"name": "altimet", "type": "altimet01" , "channel": 6, },
# ],
# },
 
 
],
)
cfg.initialize()
 
gauge1 = cfg.get_device("altimet1")
gauge2 = cfg.get_device("altimet2")
gauge3 = cfg.get_device("altimet3")
gauge4 = cfg.get_device("altimet4")
gauge5 = cfg.get_device("altimet5")
gauge6 = cfg.get_device("altimet6")
 
gauge8 = cfg.get_device("altimet8")
time.sleep(0.5)
 
#### Data Logging ###################################################
 
sys.stdout.write("ALTIMET data acquisition system started \n")
ser = serial.Serial('/dev/ttyUSB0', 9600, timeout=1)
 
try:
with open("temperature.log", "a") as f:
while True:
sys.stdout.write("Start measurement now? [ENTER]")
sys.stdin.readline()
 
ser.write(':DISP?\n')
Prefstart = eval(ser.readline(100))
 
gauge1.route()
(t1, p1) = gauge1.get_tp()
gauge2.route()
(t2, p2) = gauge2.get_tp()
gauge3.route()
(t3, p3) = gauge3.get_tp()
gauge4.route()
(t4, p4) = gauge4.get_tp()
gauge5.route()
(t5, p5) = gauge5.get_tp()
gauge6.route()
(t6, p6) = gauge6.get_tp()
# gauge7.route()
# (t7, p7) = gauge7.get_tp()
gauge8.route()
(t8, p8) = gauge8.get_tp()
 
ser.write(':DISP?\n')
Prefstop = eval(ser.readline(100))
 
sys.stdout.write(" Temperature: %.2f %.2f %.2f %.2f %.2f %.2f %.2f Pressure: %d %d %d %d %d %d %d %s %s Note: " % (t1, t2, t3, t4, t5, t6, t8, p1, p2, p3, p4, p5, p6, p8, Prefstart, Prefstop ))
note = sys.stdin.readline()
f.write("%d\t%s\t%.2f\t%.2f\t%.2f\t%.2f\t%.2f\t%.2f\t%.2f\t%d\t%d\t%d\t%d\t%d\t%d\t%d\t%s\t%s\t%s\n" % (time.time(), datetime.datetime.now().isoformat(),t1, t2, t3, t4, t5, t6, t8, p1, p2, p3, p4, p5, p6, p8, Prefstart, Prefstop, note, ))
sys.stdout.flush()
# time.sleep(0.5)
except KeyboardInterrupt:
ser.close()
sys.exit(0)
 
/Modules/Sensors/ALTIMET01A/SW/Python/data_top.npz
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Property changes:
Added: svn:mime-type
+application/octet-stream
\ No newline at end of property
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/PIC/PIC16F887/MPL115A1.c
0,0 → 1,127
/*
MPL115A1 SDN - +3.3V (always power on)
MPL115A1 #CS - PIN_C2
MPL115A1 DOUT - PIN_C4
MPL115A1 DIN - PIN_C5
MPL115A1 SCLK - PIN_C3
MPL115A1 GND - GND
MPL115A1 VDD - +3.3V
*/
 
 
// SPI mode definitions.
#define SPI_MODE_0 (SPI_L_TO_H | SPI_XMIT_L_TO_H)
#define SPI_MODE_1 (SPI_L_TO_H)
#define SPI_MODE_2 (SPI_H_TO_L)
#define SPI_MODE_3 (SPI_H_TO_L | SPI_XMIT_L_TO_H)
 
float a0; // correctiaon coefficients
float b1;
float b2;
float c12;
 
 
void MPL_init()
{
unsigned int8 a0_MSB, a0_LSB;
unsigned int8 b1_MSB, b1_LSB;
unsigned int8 b2_MSB, b2_LSB;
unsigned int8 c12_MSB, c12_LSB;
 
output_low(CSN_SPI);
 
spi_write(0x88); // get MSB for a0
a0_MSB = spi_read(0x00);
spi_write(0x8A); // get LSB for a0
a0_LSB = spi_read(0x00);
 
spi_write(0x8C); // get MSB for b1
b1_MSB = spi_read(0x00);
spi_write(0x8E); // get LSB for b1
b1_LSB = spi_read(0x00);
 
spi_write(0x90); // get MSB for b2
b2_MSB = spi_read(0x00);
spi_write(0x92); // get LSB for b2
b2_LSB = spi_read(0x00);
 
spi_write(0x94); // get MSB for c12
c12_MSB = spi_read(0x00);
spi_write(0x96); // get LSB for c12
c12_LSB = spi_read(0x00);
 
spi_read(0x00);
output_high(CSN_SPI);
// translate to floating point number
 
printf("%d %d %d %d %d %d %d %d ",a0_MSB, a0_LSB,b1_MSB, b1_LSB, b2_MSB, b2_LSB, c12_MSB, c12_LSB);
a0 = ((unsigned int16) a0_MSB << 5) + (a0_LSB >> 3) + (a0_LSB & 0x07)/8.0;
b1 = ((((b1_MSB & 0x1F) * 0x100) + b1_LSB) / 8192.0) - 3;
b2 = ((((unsigned int16) (b2_MSB - 0x80) << 8) + b2_LSB)/ 16384.0) - 2;
c12 =(((c12_MSB * 0x100) + c12_LSB)/16777216.0);
}
 
float MPL_get_pressure()
{
unsigned int8 LSB_data, MSB_data;
unsigned int16 ADC_pressure, ADC_temperature;
float Pcomp;
 
output_low(CSN_SPI); //Start temperature and pressure conversion
spi_write(0x24);
spi_write(0x00);
output_high(CSN_SPI);
 
delay_ms(10);
output_low(CSN_SPI); // get MSB for Pressure
spi_write(0x80);
MSB_data = spi_read(0x00);
spi_write(0x82); // get LSB for Pressure
LSB_data = spi_read(0x00);
output_high(CSN_SPI);
 
ADC_pressure = (((unsigned int16) MSB_data << 8) + LSB_data ) >> 6; // conversion of 8bit registers to 16bit variable
 
output_low(CSN_SPI);
spi_write(0x84);
MSB_data = spi_read(0x00);
spi_write(0x86); // get LSB for Temperature
LSB_data = spi_read(0x00);
spi_read(0x00);
output_high(CSN_SPI);
 
ADC_temperature = (((unsigned int16) MSB_data << 8) + LSB_data ) >> 6; // conversion of 8bit registers to 16bit variable
Pcomp = (a0 + (b1 + c12 * ADC_temperature) * ADC_pressure + b2 * ADC_temperature ); // compute relative compensated pressure
 
return (Pcomp * ((115.0 - 50.0)/1023.0) + 50.0); // return absolute pressure
}
 
float MPL_get_temperature()
{
unsigned int8 LSB_data, MSB_data;
unsigned int16 ADC_temperature;
 
output_low(CSN_SPI); //Start temperature and pressure conversion
spi_write(0x22);
spi_write(0x00);
output_high(CSN_SPI);
 
delay_ms(10);
output_low(CSN_SPI);
spi_write(0x84);
MSB_data = spi_read(0x00);
spi_write(0x86); // get LSB for Temperature
LSB_data = spi_read(0x00);
spi_read(0x00);
output_high(CSN_SPI);
 
ADC_temperature = (((unsigned int16) MSB_data << 8) + LSB_data ) >> 6; // conversion of 8bit registers to 16bit variable
return ( ((float) ADC_temperature - 498.0)/-5.35) + 25.0; // return temperature in deg C
}
 
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/PIC/PIC16F887/main.hex
0,0 → 1,305
:1000000008308A00F5280000533A613974100D0554
:10001000000083168613831286130830F800102818
:100020000000F8172128F813C60C03188617031CC4
:100030008613781721287813F80B14281F2800003E
:1000400086173F308400840B23280000F81B1328F8
:10005000781B1B280800831603178C170C1400004C
:10006000000083120C087F3903196F280313B100B5
:1000700003170D080313B20003170F080313B3008F
:100080003108C6000920320803178D000313330816
:1000900003178F0083168C170C14000000008312C6
:1000A0000C0D0E0D7F3903196F280313B1000317D0
:1000B0000D080313B20003170F080313B300310830
:1000C000C6000920320803178D00031333080317F5
:1000D0008F008D0A03198F0A03132B2803170313AC
:1000E0008A150A121A293B30840083130008031969
:1000F00086280230F800F701F70B7C28F80B7B28E4
:100100009730F700F70B8228800B79280800400809
:10011000F8013F0203188F283F08F7009B28F701DA
:100120000830C100BF0DF70D400877020318F70033
:10013000F80DC10B9228080020303A1E3030BB0069
:100140003908F700B91FAB28F709F70A7708B90093
:100150002D30BB00BA173908BF006430C0008720BB
:100160007708B90030307807BC003908BF000A3082
:10017000C000872030307707BE0030307807BD00E0
:100180003B08F700BA1DC628BA1F3A113A1AD328FD
:10019000BA1FEE283A19EE287708BC00BA18EE28E4
:1001A0007708BD00EE2830303C02031DEE287708AA
:1001B000BC002030BB00BA1DE1283A11BA14BA1FA6
:1001C000BA1030303D02031DEE287708BD00203004
:1001D000BC00BA1DE128BA10BA1F3A103A1DF32824
:1001E0003B08C6000920BA1CF8283C08C6000920B4
:1001F0003A1CFD283D08C60009203E08C60009201B
:1002000008008E30F7004208F8004108F900FA01B2
:10021000F808031D15297908F800F9010830F702DC
:10022000F808031D1529F7011D290310F81B1C29C7
:10023000F90DF80DF7031529F81308003E08031906
:10024000E329CA0042080319E329CA02031C2D2925
:100250007F30CA070318E32933298130CA02031CFF
:10026000E3290319E3294A08F700F801F901FA0123
:10027000C9013F08C800C8174008C7004108C600A8
:100280001930CA004508C602031856290130C702B2
:1002900003185629C80203185629C90203185629FB
:1002A000C90AC80AC70A4508C60788294408C702F8
:1002B000031871290130C80203187129C9020318F3
:1002C0007129C90AC80A4408C7074508C607031C9C
:1002D0008829C70A031D8829C80A031D8829C90A55
:1002E000882943088038C802031887290130C902C9
:1002F00003188729C90A43088038C8074408C70774
:10030000031C6529C80A031D6529C90A65297A14D1
:10031000CA0B8B2996290310C60DC70DC80DC90D30
:100320000310FA0DF90DF80DCB0D42294B1C9E2937
:100330000310F80CF90CFA0CCB0CA129F7030319E4
:10034000E329CB1BCA290310C60DC70DC80DC90D63
:100350004508C6020318B6290130C7020318B6299A
:10036000C8020318B629C902031CD9294408C702C8
:100370000318C1290130C8020318C129C902031C8E
:10038000D92943088038C8020318CA290130C90294
:10039000031CD929FA0A031DD929F90A031DD929F1
:1003A000F80A031DD929F70A0319E329F80CF90CF7
:1003B000FA0C3F08CA004308CA06CA1FE129F81709
:1003C000E729F813E729F701F801F901FA01080014
:1003D00080308318C606CB01CC014208CA0046080B
:1003E000CA0641080319D82AC900F70045080319AD
:1003F000E12AC90203197D2A031C3B2A4608CF00C3
:10040000CF174708CE004808CD00CC010310CF0C11
:10041000CE0CCD0CCC0CC90B052ACA1F122A4B14CA
:10042000F52A4B1049104B164430840083130A2BD5
:100430004B12CA1B252A491C302ACF0CCE0CCD0CDE
:10044000CC0CF70A0319F02A302ACF1B332A0310E9
:10045000CC0DCD0DCE0DCF0DF7030319F02A252AB3
:100460004B179D2A4B134208CA00CA1F392ACF17BF
:10047000E92ACF13E92A4508C900F7004108C90253
:100480004208CF00CF174308CE004408CD00CC016E
:100490000310CF0CCE0CCD0CCC0CC90B472ACA1FB5
:1004A000542ACB14F52ACB104910CB1648308400BF
:1004B00083130A2BCB12CA1B672A491C722ACF0C42
:1004C000CE0CCD0CCC0CF70A0319F02A722ACF1BE4
:1004D000752A0310CC0DCD0DCE0DCF0DF7030319EA
:1004E000F02A672ACB179D2ACB134608CA00CA1FD9
:1004F0007B2ACF17E92ACF13E92A4608CF00CF1766
:100500004708CE004808CD00CA1F8A2ACF134B15D2
:10051000F52A4B11CC0149104430840083130A2B77
:10052000CA1BB32A4208CA00491C9D2ACF0CCE0C14
:10053000CD0CCC0CF70A0319F02ACC1FAE2ACD0A39
:10054000031DAE2ACE0A031DAE2ACF0A031DAE2A12
:10055000CF0CCE0CCD0CF70A0319F02A4B1B322A14
:10056000CB1B742AD22A8030CF06CF1FBB2AF52A94
:100570004608CA00C82A4208CA00CF08031DC82A74
:10058000CE08031DC82ACD08031DC82AF701E92A91
:10059000CF1BD22A0310CC0DCD0DCE0DCF0DF70BF6
:1005A000C82AF02ACA1FD62ACF17E92ACF13E92A68
:1005B0004508F7004608CF004708CE004808CD00A0
:1005C000E92A4108F7004208CF004308CE0044085A
:1005D000CD004F08F8004E08F9004D08FA00282B0E
:1005E000F701F801F901FA01282BCC01CD09CE0958
:1005F000CF09CC09CC0A031D032BCD0A031D032B05
:10060000CE0A0319CF0A4B18112ACB18532A4B19BB
:10061000892AB82A0008CD07031C142BCE0A031D13
:10062000142BCF0A0319491484030008CE07031CB6
:100630001C2BCF0A0319491484030008801F803A39
:10064000CF07031849144B1A182ACB1A5A2A902A92
:100650000800301130088316870083120711130831
:10066000883093008316140C031C332B8312130859
:1006700093018316140C031C3A2B83121308B10048
:1006800013088A3093008316140C031C442B831226
:10069000130893018316140C031C4B2B83121308AD
:1006A000B20013088C3093008316140C031C552BD6
:1006B0008312130893018316140C031C5C2B831202
:1006C0001308B30013088E3093008316140C031C18
:1006D000662B8312130893018316140C031C6D2BD5
:1006E00083121308B4001308903093008316140C7F
:1006F000031C772B8312130893018316140C031C1D
:100700007E2B83121308B5001308923093008316D2
:10071000140C031C882B8312130893018316140CEA
:10072000031C8F2B83121308B60013089430930018
:100730008316140C031C992B831213089301831640
:10074000140C031CA02B83121308B7001308963057
:1007500093008316140C031CAA2B83121308930115
:100760008316140C031CB12B83121308B800130852
:1007700093018316140C031CBA2B8312301130081A
:1007800083168700831207153108B9001F30BA009D
:100790009C202030C60009203208B9001F30BA0062
:1007A0009C202030C60009203308B9001F30BA0051
:1007B0009C202030C60009203408B9001F30BA0040
:1007C0009C202030C60009203508B9001F30BA002F
:1007D0009C202030C60009203608B9001F30BA001E
:1007E0009C202030C60009203708B9001F30BA000D
:1007F0009C202030C60009203808B9001F30BA00FC
:100800009C202030C6000920BA013108B900B90D7A
:10081000BA0DB90DBA0DB90DBA0DB90DBA0DB90DA4
:10082000BA0DE030B905320CF700F70CF70C1F30A9
:10083000F7057708B9070318BA0A32080739C20161
:10084000C10001217A08C1007908C0007808BF0002
:100850007708BE00C501C401C3018230C2001E2159
:100860007708BD007808BE007908BF007A08C0008C
:100870003A08C2003908C100012183107A08C40077
:100880007908C3007808C2007708C1004008C80092
:100890003F08C7003E08C6003D08C500E8217A08A9
:1008A000A3007908A2007808A1007708A000330807
:1008B0001F39FA01BA00B9013408B9070318BA0A96
:1008C0003A08C2003908C10001217A08C10079083C
:1008D000C0007808BF007708BE00C501C401C3018D
:1008E0008C30C2001E217708B9007808BA00790858
:1008F000BB007A08BC0083147A08C4007908C300DE
:100900007808C2007708C100C801C7014030C6009E
:100910008030C500E8217A08A7007908A600780889
:10092000A5007708A40080303502BA01B900BA00EA
:10093000B9013608B9070318BA0A3A08C2003908DB
:10094000C10001217A08C1007908C0007808BF0001
:100950007708BE00C501C401C3018D30C2001E214D
:100960007708B9007808BA007908BB007A08BC009B
:1009700083147A08C4007908C3007808C200770895
:10098000C100C801C701C6018030C500E8217A084E
:10099000AB007908AA007808A9007708A800FA0136
:1009A0003708BA00B9013808B9070318BA0A3A0873
:1009B000C2003908C10001217A08C1007908C000CD
:1009C0007808BF007708BE00C501C401C301973095
:1009D000C2001E217A08AF007908AE007808AD0089
:1009E0007708AC008A150A123E2946080319652DBE
:1009F000CE004A080319652DCE070318062D7F3057
:100A0000CE02031C652D0319652D0A2D8130CE07FA
:100A10000318652D4E08F700F801F901FA0147089F
:100A2000D200D2174808D1004908D0001830CE00B3
:100A3000CF01501C332D4D08FA07031C252DF90A50
:100A4000031D252DF80A0319CF174C08F907031CBD
:100A50002C2DF80A0319CF174B08C800C8174808EF
:100A6000F8070318CF17CF0DF80CF90CFA0CD20CBD
:100A7000D10CD00C0310CE0B182D0130F707031842
:100A8000652DF81B4A2DD20DFA0DF90DF80DF7035F
:100A90000319652DD21F5B2DFA0A031D5B2DF90A80
:100AA000031D5B2DF80A031D5B2DF80CF90CFA0CE5
:100AB000F70A0319652D4708CF004B08CF06CF1F53
:100AC000632DF817692DF813692DF701F801F90165
:100AD000FA010800301130088316870083120711CD
:100AE0001308243093008316140C031C742D8312F6
:100AF000130893018316140C031C7B2D83123011F1
:100B0000300883168700831207150A30BB00732054
:100B100030113008831687008312071113088030C4
:100B200093008316140C031C922D83121308930157
:100B30008316140C031C992D83121308B20013089A
:100B4000823093008316140C031CA32D8312130808
:100B500093018316140C031CAA2D83121308B100F1
:100B6000301130088316870083120715BC01320844
:100B7000BB00BC00BB013108BB070318BC0A3C0C1E
:100B8000B4003B0CB300B40CB30CB40CB30CB40CF9
:100B9000B30CB40CB30CB40CB30C0330B40530116B
:100BA00030088316870083120711130884309300DE
:100BB0008316140C031CD92D83121308930183167A
:100BC000140C031CE02D83121308B20013088630A6
:100BD00093008316140C031CEA2D8312130893014F
:100BE0008316140C031CF12D83121308B100130893
:100BF00093018316140C031CFA2D83123011300854
:100C00008316870083120715BC013208BB00BC00A5
:100C1000BB013108BB070318BC0A3C0CB6003B0CF7
:100C2000B500B60CB50CB60CB50CB60CB50CB60CC4
:100C3000B50CB60CB50C0330B6053608C200350845
:100C4000C10001212F08C9002E08C8002D08C700C7
:100C50002C08C6007A08CD007908CC007808CB00B3
:100C60007708CA00F52483102708C4002608C300AB
:100C70002508C2002408C1007A08C8007908C70006
:100C80007808C6007708C500E8217708BB00780817
:100C9000BC007908BD007A08BE003408C2003308E1
:100CA000C10001213E08C9003D08C8003C08C7003A
:100CB0003B08C6007A08CD007908CC007808CB0044
:100CC0007708CA00F52483102308C4002208C30053
:100CD0002108C2002008C1007A08C8007908C700AE
:100CE0007808C6007708C500E8217708BB007808B7
:100CF000BC007908BD007A08BE003608C20035087D
:100D0000C10001212B08C9002A08C8002908C70012
:100D10002808C6007A08CD007908CC007808CB00F6
:100D20007708CA00F52483103E08C4003D08C300BC
:100D30003C08C2003B08C1007A08C8007908C70017
:100D40007808C6007708C500E8217A08BA00790853
:100D5000B9007808B8007708B7003A08C900390820
:100D6000C8003808C7003708C6008830CD002030DA
:100D7000CC000230CB007B30CA00F5247708BB00E2
:100D80007808BC007908BD007A08BE0083107A0894
:100D9000C4007908C3007808C2007708C100C80100
:100DA000C7014830C6008430C500E8218A150A1200
:100DB0004129301130088316870083120711130868
:100DC000223093008316140C031CE32E83121308A5
:100DD00093018316140C031CEA2E83123011300881
:100DE00083168700831207150A30BB007320301169
:100DF000300883168700831207111308843093008C
:100E00008316140C031C012F8312130893018316FD
:100E1000140C031C082F83121308B6001308863025
:100E200093008316140C031C122F831213089301D2
:100E30008316140C031C192F83121308B500130812
:100E400093018316140C031C222F831230113008D7
:100E50008316870083120715BA013608B900BA0055
:100E6000B9013508B9070318BA0A3A0CB800390CA9
:100E7000B700B80CB70CB80CB70CB80CB70CB80C62
:100E8000B70CB80CB70C0330B8053808C2003708E7
:100E9000C10001217708B9007808BA007908BB00C1
:100EA0007A08BC0083147A08C4007908C300780863
:100EB000C2007708C100C801C7017930C600873079
:100EC000C500E8217708B9007808BA007908BB00A6
:100ED0007A08BC00C1007908C0007808BF00770814
:100EE000BE003330C500C400AB30C3008130C20047
:100EF0001E217708B9007808BA007908BB007A0883
:100F0000BC0083107A08C4007908C3007808C200C6
:100F10007708C100C801C7014830C6008330C5004A
:100F2000E8218A150A124C29F701F801F901FA01A2
:100F3000CE01CF01D001D1014D084C044B044A042D
:100F40000319D22F2030D2000310C60DC70DC80DD3
:100F5000C90DCE0DCF0DD00DD10D4D085102031D81
:100F6000BB2F4C085002031DBB2F4B084F02031D23
:100F7000BB2F4A084E02031CCC2F4A08CE024B0856
:100F8000031C4B0FCF024C08031C4C0FD0024D0822
:100F9000031C4D0FD1020314F70DF80DF90DFA0DD6
:0C0FA000D20BA42F4E30840083130800F5
:101000000408BE003D08C000031921283C08C9009F
:101010003B08C8003A08C7003908C600CD01CC011A
:101020002030CB008230CA008A11F5248A157A0854
:10103000BC007908BB007808BA007708B900C00B7B
:1010400006283C08C9003B08C8003A08C700390810
:10105000C6004608B63CC600FA014708CA00C717D2
:101060000310C70CC80CC90CFA0CF90CF80CF70CDF
:10107000C60B3028CA1F4728F709F809F909FA09E9
:10108000F70A0319F80A0319F90A0319FA0A7A0880
:10109000BC007908BB007808BA007708B900BC1F0B
:1010A0005E28BE03BE16B909BA09BB09BC09B90A54
:1010B0000319BA0A0319BB0A0319BC0A3B30C5005D
:1010C0009A30C400CA30C300C2010A30C0003D08D3
:1010D0000319BE0A3C08C9003B08C8003A08C7000B
:1010E0003908C6004508CD004408CC004308CB00B1
:1010F0004208CA008A1194278A150008B900840A98
:101100000008BA00840A0008BB00840A0008BC007A
:10111000FD308407F708031DA0283D0A400203198B
:10112000A0283E080319A2280F39400203199A2863
:101130000318DA28BE1BDA283E1BA2282030D42848
:101140002030BE05BE1EB228BE123D08031DBE03E0
:101150007708BE002D30C6008A1109208A153E0886
:10116000F700BE013D084002031DC2287708BE00FB
:101170002E30C6008A1109208A153E08F70020305B
:10118000BE0500303030BE1ED428BE123D08031DFF
:10119000BE037708BE002D30C6008A1109208A15CB
:1011A0003E08F700BE013030F7077708C6008A1105
:1011B00009208A154508C9004408C8004308C7002B
:1011C0004208C600CD01CC01CB010A30CA008A1109
:1011D00094278A157A08C5007908C4007808C300E6
:1011E0007708C200C00B6A280800840183131F30EF
:1011F0008305713083168F000F08861383128617BC
:10120000831603170908C039890003131F129F12A0
:101210000030031788008312870188018901FF309D
:101220000313B000043003178D0000308F008A11C3
:1012300003132B288A159412B012300883168700E6
:10124000831230163008831687008312B0113008DD
:101250008316870022308312940040308316940056
:10126000831230113008831687008312071564300B
:10127000BB008A1173208A158A11292B8A158A11BD
:101280006A2D8A157708B1007808B2007908B30092
:101290007A08B4008A11D92E8A157708B500780823
:1012A000B6007908B7007A08B8008930840034089D
:1012B000BC003308BB003208BA003108B900023064
:1012C000BD0000202030C6008A1109208A1589300F
:1012D00084003808BC003708BB003608BA0035085F
:1012E000B9000230BD0000202030C6008A1109205C
:1012F0008A150D30C6008A1109208A150A30C600E9
:101300008A1109208A150230B100FA30BB008A1117
:0C13100073208A15B10B85293F2963006A
:04400E00F52CFF3F4F
:00000001FF
;PIC16F887
;CRC=D61B CREATED="28-XI-13 00:17"
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/PIC/PIC16F887/main.pjt
0,0 → 1,31
[PROJECT]
Target=main.hex
Development_Mode=
Processor_Text=PIC16F887
ToolSuite=CCS
Processor=0x887F
[main]
Type=4
Path=
FileList=
BuildTool=
OptionString=
AdditionalOptionString=
[mru-list]
1=main.c
[Windows]
0=0000 %S 0 0 796 451 3 0
[Opened Files]
1=main.c
2=main.h
3=C:\Program Files\PICC\devices\16F887.h
4=MPL115A1.c
5=
6=..\1wire.c
7=
[Target Data]
OptionString=-p +FM
FileList=Z:\home\kaklik\svnMLAB\Modules\Sensors\ALTIMET01A\SW\MPL115A1\PIC\PIC16F887\main.c
[Units]
Count=1
1=main (main)
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/PIC/PIC16F887/main.c
0,0 → 1,30
#include <main.h>
 
/*
MPL115A1 SDN - +3.3V (always power on)
MPL115A1 #CS - PIN_C2
MPL115A1 DOUT - PIN_C4
MPL115A1 DIN - PIN_C5
MPL115A1 SCLK - PIN_C3
MPL115A1 GND - GND
MPL115A1 VDD - +3.3V
*/
 
#define CSN_SPI PIN_C2
#include "MPL115A1.c"
 
void main()
{
printf("Start \r\n");
setup_spi(SPI_MASTER | SPI_MODE_0 | SPI_CLK_DIV_64);
output_high(CSN_SPI);
delay_ms(100);
 
MPL_init(); // get correction coefficients from the sensor
 
while(true)
{
printf("%f %f \r\n", MPL_get_pressure(), MPL_get_temperature());
delay_ms(500);
}
}
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/PIC/PIC16F887/main.h
0,0 → 1,20
#include <16F887.h>
#device adc=10
 
#FUSES NOWDT //No Watch Dog Timer
#FUSES INTRC //Internal RC Osc
#FUSES NOPUT //No Power Up Timer
#FUSES MCLR //Master Clear pin enabled
#FUSES NOPROTECT //Code not protected from reading
#FUSES NOCPD //No EE protection
#FUSES NOBROWNOUT //No brownout reset
#FUSES IESO //Internal External Switch Over mode enabled
#FUSES FCMEN //Fail-safe clock monitor enabled
#FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O
#FUSES NODEBUG //No Debug mode for ICD
#FUSES NOWRT //Program memory not write protected
#FUSES BORV40 //Brownout reset at 4.0V
 
#use delay(clock=8000000)
#use rs232(baud=9600,parity=N,xmit=PIN_B7,rcv=PIN_B6,bits=8)
 
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/AVR/ATmega328/MPL115A1.h
0,0 → 1,17
#define PRESH 0x00 // 80
#define PRESL 0x02 // 82
#define TEMPH 0x04 // 84
#define TEMPL 0x06 // 86
 
#define A0MSB 0x08 // 88
#define A0LSB 0x0A // 8A
#define B1MSB 0x0C // 8C
#define B1LSB 0x0E // 8E
#define B2MSB 0x10 // 90
#define B2LSB 0x12 // 92
#define C12MSB 0x14 // 94
#define C12LSB 0x16 // 96
#define C11MSB 0x18 // 98
#define C11LSB 0x1A // 9A
#define C22MSB 0x1C // 9C
#define C22LSB 0x1E // 9E
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/AVR/ATmega328/Makefile
0,0 → 1,667
# Hey Emacs, this is a -*- makefile -*-
#----------------------------------------------------------------------------
# WinAVR Makefile Template written by Eric B. Weddington, Jörg Wunsch, et al.
#
# Released to the Public Domain
#
# Additional material for this makefile was written by:
# Peter Fleury
# Tim Henigan
# Colin O'Flynn
# Reiner Patommel
# Markus Pfaff
# Sander Pool
# Frederik Rouleau
# Carlos Lamas
#
#----------------------------------------------------------------------------
# On command line:
#
# make all = Make software.
#
# make clean = Clean out built project files.
#
# make coff = Convert ELF to AVR COFF.
#
# make extcoff = Convert ELF to AVR Extended COFF.
#
# make program = Download the hex file to the device, using avrdude.
# Please customize the avrdude settings below first!
#
# make debug = Start either simulavr or avarice as specified for debugging,
# with avr-gdb or avr-insight as the front end for debugging.
#
# make filename.s = Just compile filename.c into the assembler code only.
#
# make filename.i = Create a preprocessed source file for use in submitting
# bug reports to the GCC project.
#
# To rebuild project do "make clean" then "make all".
#----------------------------------------------------------------------------
 
 
# MCU name
MCU = atmega328p
 
 
# Processor frequency.
# This will define a symbol, F_CPU, in all source code files equal to the
# processor frequency. You can then use this symbol in your source code to
# calculate timings. Do NOT tack on a 'UL' at the end, this will be done
# automatically to create a 32-bit value in your source code.
# Typical values are:
# F_CPU = 1000000
# F_CPU = 1843200
# F_CPU = 2000000
# F_CPU = 3686400
# F_CPU = 4000000
# F_CPU = 7372800
# F_CPU = 8000000
# F_CPU = 11059200
# F_CPU = 14745600
# F_CPU = 16000000
# F_CPU = 18432000
# F_CPU = 20000000
F_CPU = 8000000
 
 
# Output format. (can be srec, ihex, binary)
FORMAT = ihex
 
 
# Target file name (without extension).
TARGET = main
 
 
# Object files directory
# To put object files in current directory, use a dot (.), do NOT make
# this an empty or blank macro!
OBJDIR = .
 
 
# List C source files here. (C dependencies are automatically generated.)
SRC = $(TARGET).c
#SRC += LCD_driver.c
 
 
# List C++ source files here. (C dependencies are automatically generated.)
CPPSRC =
 
 
# List Assembler source files here.
# Make them always end in a capital .S. Files ending in a lowercase .s
# will not be considered source files but generated files (assembler
# output from the compiler), and will be deleted upon "make clean"!
# Even though the DOS/Win* filesystem matches both .s and .S the same,
# it will preserve the spelling of the filenames, and gcc itself does
# care about how the name is spelled on its command-line.
ASRC =
 
 
# Optimization level, can be [0, 1, 2, 3, s].
# 0 = turn off optimization. s = optimize for size.
# (Note: 3 is not always the best optimization level. See avr-libc FAQ.)
OPT = s
 
 
# Debugging format.
# Native formats for AVR-GCC's -g are dwarf-2 [default] or stabs.
# AVR Studio 4.10 requires dwarf-2.
# AVR [Extended] COFF format requires stabs, plus an avr-objcopy run.
DEBUG = dwarf-2
 
 
# List any extra directories to look for include files here.
# Each directory must be seperated by a space.
# Use forward slashes for directory separators.
# For a directory that has spaces, enclose it in quotes.
EXTRAINCDIRS =
 
 
# Compiler flag to set the C Standard level.
# c89 = "ANSI" C
# gnu89 = c89 plus GCC extensions
# c99 = ISO C99 standard (not yet fully implemented)
# gnu99 = c99 plus GCC extensions
CSTANDARD = -std=gnu99
 
 
# Place -D or -U options here for C sources
CDEFS = -DF_CPU=$(F_CPU)UL
 
 
# Place -D or -U options here for ASM sources
ADEFS = -DF_CPU=$(F_CPU)
 
 
# Place -D or -U options here for C++ sources
CPPDEFS = -DF_CPU=$(F_CPU)UL
#CPPDEFS += -D__STDC_LIMIT_MACROS
#CPPDEFS += -D__STDC_CONSTANT_MACROS
 
 
 
#---------------- Compiler Options C ----------------
# -g*: generate debugging information
# -O*: optimization level
# -f...: tuning, see GCC manual and avr-libc documentation
# -Wall...: warning level
# -Wa,...: tell GCC to pass this to the assembler.
# -adhlns...: create assembler listing
CFLAGS = -g$(DEBUG)
CFLAGS += $(CDEFS)
CFLAGS += -O$(OPT)
CFLAGS += -funsigned-char
CFLAGS += -funsigned-bitfields
CFLAGS += -fpack-struct
CFLAGS += -fshort-enums
CFLAGS += -Wall
CFLAGS += -Wstrict-prototypes
#CFLAGS += -mshort-calls
#CFLAGS += -fno-unit-at-a-time
#CFLAGS += -Wundef
#CFLAGS += -Wunreachable-code
#CFLAGS += -Wsign-compare
CFLAGS += -Wa,-adhlns=$(<:%.c=$(OBJDIR)/%.lst)
CFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))
CFLAGS += $(CSTANDARD)
 
 
#---------------- Compiler Options C++ ----------------
# -g*: generate debugging information
# -O*: optimization level
# -f...: tuning, see GCC manual and avr-libc documentation
# -Wall...: warning level
# -Wa,...: tell GCC to pass this to the assembler.
# -adhlns...: create assembler listing
CPPFLAGS = -g$(DEBUG)
CPPFLAGS += $(CPPDEFS)
CPPFLAGS += -O$(OPT)
CPPFLAGS += -funsigned-char
CPPFLAGS += -funsigned-bitfields
CPPFLAGS += -fpack-struct
CPPFLAGS += -fshort-enums
CPPFLAGS += -fno-exceptions
CPPFLAGS += -Wall
CFLAGS += -Wundef
#CPPFLAGS += -mshort-calls
#CPPFLAGS += -fno-unit-at-a-time
#CPPFLAGS += -Wstrict-prototypes
#CPPFLAGS += -Wunreachable-code
#CPPFLAGS += -Wsign-compare
CPPFLAGS += -Wa,-adhlns=$(<:%.cpp=$(OBJDIR)/%.lst)
CPPFLAGS += $(patsubst %,-I%,$(EXTRAINCDIRS))
#CPPFLAGS += $(CSTANDARD)
 
 
#---------------- Assembler Options ----------------
# -Wa,...: tell GCC to pass this to the assembler.
# -adhlns: create listing
# -gstabs: have the assembler create line number information; note that
# for use in COFF files, additional information about filenames
# and function names needs to be present in the assembler source
# files -- see avr-libc docs [FIXME: not yet described there]
# -listing-cont-lines: Sets the maximum number of continuation lines of hex
# dump that will be displayed for a given single line of source input.
ASFLAGS = $(ADEFS) -Wa,-adhlns=$(<:%.S=$(OBJDIR)/%.lst),-gstabs,--listing-cont-lines=100
 
 
#---------------- Library Options ----------------
# Minimalistic printf version
PRINTF_LIB_MIN = -Wl,-u,vfprintf -lprintf_min
 
# Floating point printf version (requires MATH_LIB = -lm below)
PRINTF_LIB_FLOAT = -Wl,-u,vfprintf -lprintf_flt
 
# If this is left blank, then it will use the Standard printf version.
#PRINTF_LIB =
#PRINTF_LIB = $(PRINTF_LIB_MIN)
PRINTF_LIB = $(PRINTF_LIB_FLOAT)
 
 
# Minimalistic scanf version
SCANF_LIB_MIN = -Wl,-u,vfscanf -lscanf_min
 
# Floating point + %[ scanf version (requires MATH_LIB = -lm below)
SCANF_LIB_FLOAT = -Wl,-u,vfscanf -lscanf_flt
 
# If this is left blank, then it will use the Standard scanf version.
SCANF_LIB =
#SCANF_LIB = $(SCANF_LIB_MIN)
#SCANF_LIB = $(SCANF_LIB_FLOAT)
 
 
MATH_LIB = -lm
 
 
# List any extra directories to look for libraries here.
# Each directory must be seperated by a space.
# Use forward slashes for directory separators.
# For a directory that has spaces, enclose it in quotes.
EXTRALIBDIRS =
 
 
 
#---------------- External Memory Options ----------------
 
# 64 KB of external RAM, starting after internal RAM (ATmega128!),
# used for variables (.data/.bss) and heap (malloc()).
#EXTMEMOPTS = -Wl,-Tdata=0x801100,--defsym=__heap_end=0x80ffff
 
# 64 KB of external RAM, starting after internal RAM (ATmega128!),
# only used for heap (malloc()).
#EXTMEMOPTS = -Wl,--section-start,.data=0x801100,--defsym=__heap_end=0x80ffff
 
EXTMEMOPTS =
 
 
 
#---------------- Linker Options ----------------
# -Wl,...: tell GCC to pass this to linker.
# -Map: create map file
# --cref: add cross reference to map file
LDFLAGS = -Wl,-Map=$(TARGET).map,--cref
LDFLAGS += $(EXTMEMOPTS)
LDFLAGS += $(patsubst %,-L%,$(EXTRALIBDIRS))
LDFLAGS += $(PRINTF_LIB) $(SCANF_LIB) $(MATH_LIB)
#LDFLAGS += -T linker_script.x
 
 
 
#---------------- Programming Options (avrdude) ----------------
 
# Programming hardware: alf avr910 avrisp bascom bsd
# dt006 pavr picoweb pony-stk200 sp12 stk200 stk500
#
# Type: avrdude -c ?
# to get a full listing.
#
#AVRDUDE_PROGRAMMER = stk200
AVRDUDE_PROGRAMMER = ponyser
 
# com1 = serial port. Use lpt1 to connect to parallel port.
#AVRDUDE_PORT = lpt1
AVRDUDE_PORT = com1
# programmer connected to serial device
 
AVRDUDE_WRITE_FLASH = -U flash:w:$(TARGET).hex
#AVRDUDE_WRITE_EEPROM = -U eeprom:w:$(TARGET).eep
 
 
# Uncomment the following if you want avrdude's erase cycle counter.
# Note that this counter needs to be initialized first using -Yn,
# see avrdude manual.
#AVRDUDE_ERASE_COUNTER = -y
 
# Uncomment the following if you do /not/ wish a verification to be
# performed after programming the device.
#AVRDUDE_NO_VERIFY = -V
 
# Increase verbosity level. Please use this when submitting bug
# reports about avrdude. See <http://savannah.nongnu.org/projects/avrdude>
# to submit bug reports.
#AVRDUDE_VERBOSE = -v -v
 
AVRDUDE_FLAGS = -p $(MCU) -P $(AVRDUDE_PORT) -c $(AVRDUDE_PROGRAMMER)
AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)
AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)
AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)
 
#---------------- Programming Options (STK500) ----------------
# Programming hardware: stk500
 
STK500 = stk500
 
# Location of STK500.exe - no trailing '\'
STK500_PATH = C:\Program Files\Atmel\AVR Tools\STK500
 
# The STK500 AVR ISP MKII is USB. The USB drivers must already be installed.
# Do this normally by installing AVR Studio.
STK500_PORT = USB
 
#-erase chip -Program Flash -Verify Flash -File name -Serial programing(ISP)
STK500_WRITE_FLASH = -e -pf -vf -if$(TARGET).hex -ms
STK500_WRITE_FLASH += -s
 
#Program the Fuse Bytes
#STK500_FLAGS = -d$(MCU) -c$(STK500_PORT) -fFF79 -FFF79
#Skip the Fuse Bytes
STK500_FLAGS = -d$(MCU) -c$(STK500_PORT)
 
#-Set ISP frequency to 250kHz. Limit is 1/4 of internal osc which is default 1MHz
STK500_FLAGS += -I250kHz
 
#---------------- Programming Options (avrdude serial bootloader) ----------------
 
#"C:\arduino\hardware\tools\avr\bin\avrdude" -PCOM28 -c stk500v1 -patmega168 -b19200 -Uflash:w:Simon-PTH-v1.hex -V -F -C"C:\arduino\hardware\tools\avr\etc\avrdude.conf"
SERIAL_AVRDUDE = "C:\Program Files\arduino-0018\arduino-0018\hardware\tools\avr\bin\avrdude"
SERIAL_AVRDUDE_CONFIG = "C:\Program Files\arduino-0018\arduino-0018\hardware\tools\avr\etc\avrdude.conf"
SERIAL_AVRDUDE_PORT = COM6
SERIAL_AVRDUDE_SPEED = 57600
SERIAL_AVRDUDE_PROGRAMMER = stk500v1
 
SERIAL_AVRDUDE_FLAGS = -p $(MCU) -P $(SERIAL_AVRDUDE_PORT) -c $(SERIAL_AVRDUDE_PROGRAMMER) -b $(SERIAL_AVRDUDE_SPEED)
SERIAL_AVRDUDE_FLAGS += -C$(SERIAL_AVRDUDE_CONFIG)
SERIAL_AVRDUDE_FLAGS += $(AVRDUDE_NO_VERIFY)
SERIAL_AVRDUDE_FLAGS += $(AVRDUDE_VERBOSE)
SERIAL_AVRDUDE_FLAGS += $(AVRDUDE_ERASE_COUNTER)
 
#---------------- Debugging Options ----------------
 
# For simulavr only - target MCU frequency.
DEBUG_MFREQ = $(F_CPU)
 
# Set the DEBUG_UI to either gdb or insight.
# DEBUG_UI = gdb
DEBUG_UI = insight
 
# Set the debugging back-end to either avarice, simulavr.
DEBUG_BACKEND = avarice
#DEBUG_BACKEND = simulavr
 
# GDB Init Filename.
GDBINIT_FILE = __avr_gdbinit
 
# When using avarice settings for the JTAG
JTAG_DEV = /dev/com1
 
# Debugging port used to communicate between GDB / avarice / simulavr.
DEBUG_PORT = 4242
 
# Debugging host used to communicate between GDB / avarice / simulavr, normally
# just set to localhost unless doing some sort of crazy debugging when
# avarice is running on a different computer.
DEBUG_HOST = localhost
 
 
 
#============================================================================
 
 
# Define programs and commands.
SHELL = sh
CC = avr-gcc
OBJCOPY = avr-objcopy
OBJDUMP = avr-objdump
SIZE = avr-size
AR = avr-ar rcs
NM = avr-nm
AVRDUDE = avrdude
REMOVE = rm -f
REMOVEDIR = rm -rf
COPY = cp
WINSHELL = cmd
 
 
# Define Messages
# English
MSG_ERRORS_NONE = Errors: none
MSG_BEGIN = -------- begin --------
MSG_END = -------- end --------
MSG_SIZE_BEFORE = Size before:
MSG_SIZE_AFTER = Size after:
MSG_COFF = Converting to AVR COFF:
MSG_EXTENDED_COFF = Converting to AVR Extended COFF:
MSG_FLASH = Creating load file for Flash:
MSG_EEPROM = Creating load file for EEPROM:
MSG_EXTENDED_LISTING = Creating Extended Listing:
MSG_SYMBOL_TABLE = Creating Symbol Table:
MSG_LINKING = Linking:
MSG_COMPILING = Compiling C:
MSG_COMPILING_CPP = Compiling C++:
MSG_ASSEMBLING = Assembling:
MSG_CLEANING = Cleaning project:
MSG_CREATING_LIBRARY = Creating library:
 
 
 
 
# Define all object files.
OBJ = $(SRC:%.c=$(OBJDIR)/%.o) $(CPPSRC:%.cpp=$(OBJDIR)/%.o) $(ASRC:%.S=$(OBJDIR)/%.o)
 
# Define all listing files.
LST = $(SRC:%.c=$(OBJDIR)/%.lst) $(CPPSRC:%.cpp=$(OBJDIR)/%.lst) $(ASRC:%.S=$(OBJDIR)/%.lst)
 
 
# Compiler flags to generate dependency files.
GENDEPFLAGS = -MMD -MP -MF .dep/$(@F).d
 
 
# Combine all necessary flags and optional flags.
# Add target processor to flags.
ALL_CFLAGS = -mmcu=$(MCU) -I. $(CFLAGS) $(GENDEPFLAGS)
ALL_CPPFLAGS = -mmcu=$(MCU) -I. -x c++ $(CPPFLAGS) $(GENDEPFLAGS)
ALL_ASFLAGS = -mmcu=$(MCU) -I. -x assembler-with-cpp $(ASFLAGS)
 
 
 
 
 
# Default target.
all: begin gccversion sizebefore build sizeafter end
 
# Change the build target to build a HEX file or a library.
build: elf hex eep lss sym
#build: lib
 
 
elf: $(TARGET).elf
hex: $(TARGET).hex
eep: $(TARGET).eep
lss: $(TARGET).lss
sym: $(TARGET).sym
LIBNAME=lib$(TARGET).a
lib: $(LIBNAME)
 
 
 
# Eye candy.
# AVR Studio 3.x does not check make's exit code but relies on
# the following magic strings to be generated by the compile job.
begin:
@echo
@echo $(MSG_BEGIN)
 
end:
@echo $(MSG_END)
@echo
 
 
# Display size of file.
HEXSIZE = $(SIZE) --target=$(FORMAT) $(TARGET).hex
ELFSIZE = $(SIZE) --mcu=$(MCU) --format=avr $(TARGET).elf
 
sizebefore:
@if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_BEFORE); $(ELFSIZE); \
2>/dev/null; echo; fi
 
sizeafter:
@if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); \
2>/dev/null; echo; fi
 
 
 
# Display compiler version information.
gccversion :
@$(CC) --version
 
 
 
# Program the device.
program: $(TARGET).hex $(TARGET).eep
$(AVRDUDE) $(AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH) $(AVRDUDE_WRITE_EEPROM)
 
program_stk500: $(TARGET).hex $(TARGET).eep
$(STK500_PATH)\$(STK500) $(STK500_FLAGS) $(STK500_WRITE_FLASH)
program_serial: $(TARGET).hex $(TARGET).eep
$(SERIAL_AVRDUDE) $(SERIAL_AVRDUDE_FLAGS) $(AVRDUDE_WRITE_FLASH)
 
# Generate avr-gdb config/init file which does the following:
# define the reset signal, load the target file, connect to target, and set
# a breakpoint at main().
gdb-config:
@$(REMOVE) $(GDBINIT_FILE)
@echo define reset >> $(GDBINIT_FILE)
@echo SIGNAL SIGHUP >> $(GDBINIT_FILE)
@echo end >> $(GDBINIT_FILE)
@echo file $(TARGET).elf >> $(GDBINIT_FILE)
@echo target remote $(DEBUG_HOST):$(DEBUG_PORT) >> $(GDBINIT_FILE)
ifeq ($(DEBUG_BACKEND),simulavr)
@echo load >> $(GDBINIT_FILE)
endif
@echo break main >> $(GDBINIT_FILE)
 
debug: gdb-config $(TARGET).elf
ifeq ($(DEBUG_BACKEND), avarice)
@echo Starting AVaRICE - Press enter when "waiting to connect" message displays.
@$(WINSHELL) /c start avarice --jtag $(JTAG_DEV) --erase --program --file \
$(TARGET).elf $(DEBUG_HOST):$(DEBUG_PORT)
@$(WINSHELL) /c pause
 
else
@$(WINSHELL) /c start simulavr --gdbserver --device $(MCU) --clock-freq \
$(DEBUG_MFREQ) --port $(DEBUG_PORT)
endif
@$(WINSHELL) /c start avr-$(DEBUG_UI) --command=$(GDBINIT_FILE)
 
 
 
 
# Convert ELF to COFF for use in debugging / simulating in AVR Studio or VMLAB.
COFFCONVERT = $(OBJCOPY) --debugging
COFFCONVERT += --change-section-address .data-0x800000
COFFCONVERT += --change-section-address .bss-0x800000
COFFCONVERT += --change-section-address .noinit-0x800000
COFFCONVERT += --change-section-address .eeprom-0x810000
 
 
 
coff: $(TARGET).elf
@echo
@echo $(MSG_COFF) $(TARGET).cof
$(COFFCONVERT) -O coff-avr $< $(TARGET).cof
 
 
extcoff: $(TARGET).elf
@echo
@echo $(MSG_EXTENDED_COFF) $(TARGET).cof
$(COFFCONVERT) -O coff-ext-avr $< $(TARGET).cof
 
 
 
# Create final output files (.hex, .eep) from ELF output file.
%.hex: %.elf
@echo
@echo $(MSG_FLASH) $@
$(OBJCOPY) -O $(FORMAT) -R .eeprom $< $@
 
%.eep: %.elf
@echo
@echo $(MSG_EEPROM) $@
-$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \
--change-section-lma .eeprom=0 --no-change-warnings -O $(FORMAT) $< $@ || exit 0
 
# Create extended listing file from ELF output file.
%.lss: %.elf
@echo
@echo $(MSG_EXTENDED_LISTING) $@
$(OBJDUMP) -h -S $< > $@
 
# Create a symbol table from ELF output file.
%.sym: %.elf
@echo
@echo $(MSG_SYMBOL_TABLE) $@
$(NM) -n $< > $@
 
 
 
# Create library from object files.
.SECONDARY : $(TARGET).a
.PRECIOUS : $(OBJ)
%.a: $(OBJ)
@echo
@echo $(MSG_CREATING_LIBRARY) $@
$(AR) $@ $(OBJ)
 
 
# Link: create ELF output file from object files.
.SECONDARY : $(TARGET).elf
.PRECIOUS : $(OBJ)
%.elf: $(OBJ)
@echo
@echo $(MSG_LINKING) $@
$(CC) $(ALL_CFLAGS) $^ --output $@ $(LDFLAGS)
 
 
# Compile: create object files from C source files.
$(OBJDIR)/%.o : %.c
@echo
@echo $(MSG_COMPILING) $<
$(CC) -c $(ALL_CFLAGS) $< -o $@
 
 
# Compile: create object files from C++ source files.
$(OBJDIR)/%.o : %.cpp
@echo
@echo $(MSG_COMPILING_CPP) $<
$(CC) -c $(ALL_CPPFLAGS) $< -o $@
 
 
# Compile: create assembler files from C source files.
%.s : %.c
$(CC) -S $(ALL_CFLAGS) $< -o $@
 
 
# Compile: create assembler files from C++ source files.
%.s : %.cpp
$(CC) -S $(ALL_CPPFLAGS) $< -o $@
 
 
# Assemble: create object files from assembler source files.
$(OBJDIR)/%.o : %.S
@echo
@echo $(MSG_ASSEMBLING) $<
$(CC) -c $(ALL_ASFLAGS) $< -o $@
 
 
# Create preprocessed source for use in sending a bug report.
%.i : %.c
$(CC) -E -mmcu=$(MCU) -I. $(CFLAGS) $< -o $@
 
 
# Target: clean project.
clean: begin clean_list end
 
clean_list :
@echo
@echo $(MSG_CLEANING)
$(REMOVE) $(TARGET).hex
$(REMOVE) $(TARGET).eep
$(REMOVE) $(TARGET).cof
$(REMOVE) $(TARGET).elf
$(REMOVE) $(TARGET).map
$(REMOVE) $(TARGET).sym
$(REMOVE) $(TARGET).lss
$(REMOVE) $(SRC:%.c=$(OBJDIR)/%.o)
$(REMOVE) $(SRC:%.c=$(OBJDIR)/%.lst)
$(REMOVE) $(SRC:.c=.s)
$(REMOVE) $(SRC:.c=.d)
$(REMOVE) $(SRC:.c=.i)
$(REMOVEDIR) .dep
 
 
# Create object files directory
$(shell mkdir $(OBJDIR) 2>/dev/null)
 
 
# Include the dependency files.
-include $(shell mkdir .dep 2>/dev/null) $(wildcard .dep/*)
 
 
# Listing of phony targets.
.PHONY : all begin finish end sizebefore sizeafter gccversion \
build elf hex eep lss sym coff extcoff \
clean clean_list program debug gdb-config
 
 
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/AVR/ATmega328/main.c
0,0 → 1,355
/*
MPL115A1 SPI Digital Barometer Test Code
Created on: April 20, 2010
By: Jim Lindblom - jim at sparkfun.com
This is a simple test program for the MPL115A1 Pressure Sensor (SPI version).
UBRR0 is set to 51 and U2X0 is not set, so the baud rate will be 9600@8MHz and 19200@16MHz.
Press the spacebar to get the pressure measurement.
Hardware: ATmega328 (I used the Arduino Pro platform)
Powered at 3.3V, running at 8MHz.
The sensor is 5V tolerant, and this code should also work on 5V/16MHz Arduinos.
MPL115A1 Breakout ------------- Arduino
----------------- -------
SDN ------------------- D9 (PB1)
CSN ------------------- D8 (PB0)
SDO ------------------- D12 (PB4)
SDI ------------------- D11 (PB3)
SCK ------------------- D13 (PB5)
GND --------------------- GND
VDD ------------------- VCC (3.3V)
License: CCAv3.0 Attribution-ShareAlike (http://creativecommons.org/licenses/by-sa/3.0/)
You're free to use this code for any venture, but I'd love to hear about what you do with it,
and any awesome changes you make to it. Attribution is greatly appreciated.
*/
 
//======================//
// Includes //
//======================//
#include <avr/io.h>
#include <stdio.h>
#include "MPL115A1.h"
 
//======================//
// Macros //
//======================//
#define sbi(var, mask) ((var) |= (uint8_t)(1 << mask))
#define cbi(var, mask) ((var) &= (uint8_t)~(1 << mask))
 
//======================//
// MPL115A1 Defines //
//======================//
#define CS 0 //pin for chip select
#define SDN 1 // pin for interrupt
 
//======================//
// General Functions //
//======================//
void ioinit(void);
void delay_ms(uint16_t x);
void delay_us(uint16_t x);
static int uart_putchar(char c, FILE *stream);
uint8_t uart_getchar(void);
static FILE mystdout = FDEV_SETUP_STREAM(uart_putchar, NULL, _FDEV_SETUP_WRITE);
 
//======================//
// MPL115A1 Functions //
//======================//
void init_SPI(void);
void txdata(char data);
char rxdata(void);
char read(uint8_t address);
void write(uint8_t address, char data);
float calculatePressure(void);
 
//======================//
// Global Variables //
//======================//
signed char sia0MSB, sia0LSB;
signed char sib1MSB, sib1LSB;
signed char sib2MSB, sib2LSB;
signed char sic12MSB, sic12LSB;
signed char sic11MSB, sic11LSB;
signed char sic22MSB, sic22LSB;
signed int sia0, sib1, sib2, sic12, sic11, sic22, siPcomp;
float decPcomp;
signed long lt1, lt2, lt3, si_c11x1, si_a11, si_c12x2;
signed long si_a1, si_c22x2, si_a2, si_a1x1, si_y1, si_a2x2;
unsigned int uiPadc, uiTadc;
unsigned char uiPH, uiPL, uiTH, uiTL;
 
 
int main(void)
{
ioinit();
init_SPI();
sbi(PORTB,CS); // CS Idle High
sbi(PORTB,SDN); // SDN high turns sensor on
printf("\n***************MPR115A1 Test****************\n\n");
// main program loop
while(1){
printf("\nPress space to print pressure\n");
while( !(UCSR0A & (1<<RXC0)) )
;
if (UDR0 == ' ')
printf("Pressure = %f\n", calculatePressure());
}
}
 
float calculatePressure()
{
write(0x24, 0x00); // Start Both Conversions
// write(0x20, 0x00); // Start Pressure Conversion
// write(0x22, 0x00); // Start temperature conversion
delay_ms(10); // Typical wait time is 3ms
// Read pressure
uiPH = read(PRESH);
uiPL = read(PRESL);
uiTH = read(TEMPH);
uiTL = read(TEMPL);
uiPadc = (unsigned int) uiPH << 8;
uiPadc += (unsigned int) uiPL & 0x00FF;
uiTadc = (unsigned int) uiTH << 8;
uiTadc += (unsigned int) uiTL & 0x00FF;
// Placing Coefficients into 16-bit Variables
// a0
sia0MSB = read(A0MSB);
sia0LSB = read(A0LSB);
sia0 = (signed int) sia0MSB << 8;
sia0 += (signed int) sia0LSB & 0x00FF;
// b1
sib1MSB = read(B1MSB);
sib1LSB = read(B1LSB);
sib1 = (signed int) sib1MSB << 8;
sib1 += (signed int) sib1LSB & 0x00FF;
// b2
sib2MSB = read(B2MSB);
sib2LSB = read(B2LSB);
sib2 = (signed int) sib2MSB << 8;
sib2 += (signed int) sib2LSB & 0x00FF;
// c12
sic12MSB = read(C12MSB);
sic12LSB = read(C12LSB);
sic12 = (signed int) sic12MSB << 8;
sic12 += (signed int) sic12LSB & 0x00FF;
// c11
sic11MSB = read(C11MSB);
sic11LSB = read(C11LSB);
sic11 = (signed int) sic11MSB << 8;
sic11 += (signed int) sic11LSB & 0x00FF;
// c22
sic22MSB = read(C22MSB);
sic22LSB = read(C22LSB);
sic22 = (signed int) sic22MSB << 8;
sic22 += (signed int) sic22LSB & 0x00FF;
// Coefficient 9 equation compensation
uiPadc = uiPadc >> 6;
uiTadc = uiTadc >> 6;
// Step 1 c11x1 = c11 * Padc
lt1 = (signed long) sic11;
lt2 = (signed long) uiPadc;
lt3 = lt1*lt2;
si_c11x1 = (signed long) lt3;
// Step 2 a11 = b1 + c11x1
lt1 = ((signed long)sib1)<<14;
lt2 = (signed long) si_c11x1;
lt3 = lt1 + lt2;
si_a11 = (signed long)(lt3>>14);
// Step 3 c12x2 = c12 * Tadc
lt1 = (signed long) sic12;
lt2 = (signed long) uiTadc;
lt3 = lt1*lt2;
si_c12x2 = (signed long)lt3;
// Step 4 a1 = a11 + c12x2
lt1 = ((signed long)si_a11<<11);
lt2 = (signed long)si_c12x2;
lt3 = lt1 + lt2;
si_a1 = (signed long) lt3>>11;
// Step 5 c22x2 = c22*Tadc
lt1 = (signed long)sic22;
lt2 = (signed long)uiTadc;
lt3 = lt1 * lt2;
si_c22x2 = (signed long)(lt3);
// Step 6 a2 = b2 + c22x2
lt1 = ((signed long)sib2<<15);
lt2 = ((signed long)si_c22x2>1);
lt3 = lt1+lt2;
si_a2 = ((signed long)lt3>>16);
// Step 7 a1x1 = a1 * Padc
lt1 = (signed long)si_a1;
lt2 = (signed long)uiPadc;
lt3 = lt1*lt2;
si_a1x1 = (signed long)(lt3);
// Step 8 y1 = a0 + a1x1
lt1 = ((signed long)sia0<<10);
lt2 = (signed long)si_a1x1;
lt3 = lt1+lt2;
si_y1 = ((signed long)lt3>>10);
// Step 9 a2x2 = a2 * Tadc
lt1 = (signed long)si_a2;
lt2 = (signed long)uiTadc;
lt3 = lt1*lt2;
si_a2x2 = (signed long)(lt3);
// Step 10 pComp = y1 + a2x2
lt1 = ((signed long)si_y1<<10);
lt2 = (signed long)si_a2x2;
lt3 = lt1+lt2;
// Fixed point result with rounding
//siPcomp = ((signed int)lt3>>13);
siPcomp = lt3/8192;
// decPcomp is defined as a floating point number
// Conversion to decimal value from 1023 ADC count value
// ADC counts are 0 to 1023, pressure is 50 to 115kPa respectively
decPcomp = ((65.0/1023.0)*siPcomp)+50;
return decPcomp;
}
 
void write(uint8_t address, char data)
{
//write any data byte to any single address
//adds a 0 to the MSB of the address byte (WRITE mode)
 
address &= 0x7F;
 
//printf("\nWriting 0x%x to 0x%x\n", data, address);
 
cbi(PORTB,CS);
delay_ms(1);
txdata(address);
delay_ms(1);
txdata(data);
delay_ms(1);
sbi(PORTB,CS);
}
 
char read(uint8_t address)
{
//returns the contents of any 1 byte register from any address
//sets the MSB for every address byte (READ mode)
 
char byte;
 
address |= 0x80;
 
cbi(PORTB,CS);
txdata(address);
byte = rxdata();
sbi(PORTB,CS);
 
return byte;
}
 
char rxdata(void)
{
SPDR = 0x55;
while((SPSR&0x80) == 0x00)
;
 
return SPDR;
}
 
void txdata(char data)
{
SPDR = data;
while((SPSR&0x80) == 0x00)
;
}
 
void init_SPI(void)
{
sbi(SPCR,MSTR); //make SPI master
cbi(SPCR,CPOL); cbi(SPCR,CPHA); //SCL idle low, sample data on rising edge
cbi(SPCR,SPR1); cbi(SPCR,SPR0); sbi(SPSR,SPI2X); //Fosc/4 is SPI frequency
sbi(SPCR,SPE); //enable SPI
}
 
static int uart_putchar(char c, FILE *stream)
{
if (c == '\n') uart_putchar('\r', stream);
 
loop_until_bit_is_set(UCSR0A, UDRE0);
UDR0 = c;
 
return 0;
}
 
uint8_t uart_getchar(void)
{
while( !(UCSR0A & (1<<RXC0)) )
;
return(UDR0);
}
 
 
void ioinit (void)
{
int MYUBRR = 51; // Results in 9600bps@8MHz or 19200bps@16MHz
//1 = output, 0 = input
//DDRA = 0b00000000; //ADC inputs
DDRB = 0b11101111; //MISO input
DDRC = 0b11111111; //All outputs
DDRD = 0b11111110; //PORTD (RX on PD0)
stdout = &mystdout; //Required for printf init
 
UBRR0H = (MYUBRR) >> 8;
UBRR0L = MYUBRR;
UCSR0B = (1<<RXEN0)|(1<<TXEN0);
UCSR0C = (3<<UCSZ00);
 
TCCR2B = (1<<CS21);
}
 
//General short delays
void delay_ms(uint16_t x)
{
for (; x > 0 ; x--)
delay_us(1000);
}
 
//General short delays
void delay_us(uint16_t x)
{
while(x > 256)
{
TIFR2 = (1<<TOV2); //Clear any interrupt flags on Timer2
TCNT2 = 0; //256 - 125 = 131 : Preload timer 2 for x clicks. Should be 1us per click
while( (TIFR2 & (1<<TOV2)) == 0);
 
x -= 256;
}
 
TIFR2 = (1<<TOV2); //Clear any interrupt flags on Timer2
TCNT2= 256 - x; //256 - 125 = 131 : Preload timer 2 for x clicks. Should be 1us per click
while( (TIFR2 & (1<<TOV2)) == 0);
}
 
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/AVR/ATmega328/main.hex
0,0 → 1,368
:100000000C94B5000C94D2000C94D2000C94D20045
:100010000C94D2000C94D2000C94D2000C94D20018
:100020000C94D2000C94D2000C94D2000C94D20008
:100030000C94D2000C94D2000C94D2000C94D200F8
:100040000C94D2000C94D2000C94D2000C94D200E8
:100050000C94D2000C94D2000C94D2000C94D200D8
:100060000C94D2000C94D2006E616E00696E660032
:1000700000407A10F35A00A0724E18090010A5D45F
:10008000E80000E87648170000E40B54020000CABC
:100090009A3B000000E1F505000080969800000002
:1000A00040420F000000A086010000001027000061
:1000B0000000E803000000006400000000000A00E7
:1000C000000000000100000000002C76D888DC67EA
:1000D0004F0823DFC1DFAE59E1B1B796E5E3E45342
:1000E000C63AE651997696E8E6C28426EB898C9B5F
:1000F00062ED407C6FFCEFBC9C9F40F2BAA56FA5FF
:10010000F490055A2AF75C936B6CF9676DC11BFC80
:10011000E0E40D47FEF520E6B500D0ED902E03009B
:10012000943577050080841E080000204E0A0000E8
:1001300000C80C333333330F986E12831141EF8DA7
:100140002114893BE65516CFFEE6DB18D1844B38E7
:100150001BF77C1D901DA4BBE424203284725E2218
:100160008100C9F124ECA1E53D2711241FBECFEF8A
:10017000D8E0DEBFCDBF11E0A0E0B1E0E2E6F6E1FD
:1001800002C005900D92A837B107D9F711E0A8E792
:10019000B1E001C01D92A43DB107E1F70E94C40384
:1001A0000C942F0B0C940000806828988EBD0DB421
:1001B00007FEFDCF85E58EBD0DB407FEFDCF8EB5E4
:1001C000289A089585E58EBD0DB407FEFDCF8EB546
:1001D00008958EBD0DB407FEFDCF08958CB58061E6
:1001E0008CBD8CB5877F8CBD8CB58B7F8CBD8CB561
:1001F0008D7F8CBD8CB58E7F8CBD8DB581608DBDA6
:100200008CB580648CBD08951F93182F8A3019F423
:100210008DE00E9404018091C00085FFFCCF109307
:10022000C60080E090E01F9108958091C00087FF94
:10023000FCCF8091C60008958FEE84B98FEF87B907
:100240008EEF8AB989E691E09093D1018093D00135
:100250001092C50083E38093C40088E18093C100BD
:1002600086E08093C20082E08093B10008959C01F3
:1002700081E007C087BB1092B200B89BFECF205030
:10028000314091E021303907A8F781E087BB822F08
:1002900081958093B200B89BFECF0895CF93DF93F2
:1002A000EC0105C088EE93E00E943701219720976A
:1002B000C9F7DF91CF9108950F931F93062F182F41
:1002C0001F77289881E090E00E944E011EBD0DB47A
:1002D00007FEFDCF81E090E00E944E010EBD0DB4FF
:1002E00007FEFDCF81E090E00E944E01289A1F9109
:1002F0000F9108952F923F924F925F926F927F924B
:100300008F929F92AF92BF92CF92DF92EF92FF9225
:100310000F931F9384E260E00E945C018AE090E00A
:100320000E944E0180E00E94D4008093A20182E0EE
:100330000E94D4008093B50184E00E94D400809391
:10034000B40186E00E94D4008093BF013091A201E5
:1003500020E09091B501290F311D3093CD012093FC
:10036000CC013091B40120E0280F311D30938D0174
:1003700020938C0188E00E94D400809398018AE049
:100380000E94D4008093B20120919801332727FD69
:100390003095322F2227280F311D3093CA01209328
:1003A000C9018CE00E94D4008093B3018EE00E94CA
:1003B000D4008093C8012091B301332727FD3095E5
:1003C000322F2227280F311D3093B9012093B80115
:1003D00080E10E94D4008093A80182E10E94D400B1
:1003E0008093BA012091A801332727FD3095322F41
:1003F0002227280F311D3093B1012093B00184E1F1
:100400000E94D40080939F0186E10E94D4008093D3
:10041000A10120919F01332727FD3095322F2227FC
:10042000280F311D3093B7012093B60188E10E9457
:10043000D4008093CB018AE10E94D4008093A00174
:100440002091CB01332727FD3095322F2227280F0B
:10045000311D3093AF012093AE018CE10E94D40096
:100460008093A9018EE10E94D4008093A701A090FF
:10047000A901BB24A7FCB094BA2CAA24A80EB11CD5
:10048000B0929301A09292018091CC019091CD0104
:1004900006E0969587950A95E1F79093CD018093B4
:1004A000CC0180908C0190908D0116E096948794F9
:1004B0001A95E1F790928D0180928C011C014424E1
:1004C00055242091AE013091AF01442737FD40956E
:1004D000542FC201B1010E94D3086093C4017093EC
:1004E000C5018093C6019093C701E090B801F090D8
:1004F000B9010027F7FC0095102FBEE0EE0CFF1CA1
:10050000001F111FBA95D1F7E60EF71E081F191F1D
:10051000AEE015950795F794E794AA95D1F7E09288
:100520008E01F0928F01009390011093910134019C
:10053000882499242091B6013091B701442737FDD2
:100540004095542FC401B3010E94D3086093AA01BF
:100550007093AB018093AC019093AD01FBE0EE0C86
:10056000FF1C001F111FFA95D1F76E0D7F1D801F14
:10057000911FEBE09595879577956795EA95D1F76B
:1005800060937C0170937D0180937E0190937F0145
:10059000CC24B7FCC094DC2CC601B501A4019301A6
:1005A0000E94D3086093A3017093A4018093A501D6
:1005B0009093A601A090B001B090B101CC24B7FCFB
:1005C000C094DC2CD594C794B794A794A0928801CA
:1005D000B0928901C0928A01D0928B0120917C0156
:1005E00030917D0140917E0150917F01C201B101A6
:1005F0000E94D30860939B0170939C0180939D019E
:1006000090939E01E090C901F090CA010027F7FC89
:100610000095102F4AE0EE0CFF1C001F111F4A9599
:10062000D1F7E60EF71E081F191F3AE0159507953A
:10063000F794E7943A95D1F7E0928001F092810126
:100640000093820110938301C601B501A4019301B7
:100650000E94D30860939401709395018093960152
:10066000909397012AE0EE0CFF1C001F111F2A95A2
:10067000D1F7E092BB01F092BC010093BD01109351
:10068000BE01609378017093790180937A01909311
:100690007B016E0D7F1D801F911F609384017093FD
:1006A0008501809386019093870120E030E240E04D
:1006B00050E00E94F20830939A0120939901442758
:1006C00037FD4095542FCA01B9010E94E40728E87C
:1006D00030E242E85DE30E94700820E030E048E448
:1006E00052E40E947E079B01AC012093C00130932D
:1006F000C1014093C2015093C3011F910F91FF901C
:10070000EF90DF90CF90BF90AF909F908F907F90B1
:100710006F905F904F903F902F900895FF920F93AE
:100720001F93CF93DF938AE090E00E94950AFF2405
:10073000C0E0D1E00F2D10E08F2D0E94D40000D03A
:1007400000D000D0EDB7FEB73196ADB7BEB7129668
:10075000DC93CE93119713830283848315820E94C6
:10076000800A077010708DB79EB706960FB6F89482
:100770009EBF0FBE8DBF0730110521F48AE090E0C7
:100780000E94950AF394D6CFCF93DF930E941C0169
:100790000E94EE00289A299A8CE091E00E949C0A1F
:1007A000CAE5D1E08BE391E00E949C0A8091C000F1
:1007B00087FFFCCF8091C6008032A1F70E947A01AA
:1007C00000D000D000D0EDB7FEB7D283C1836383E1
:1007D0007483858396830E94800A8DB79EB70696A0
:1007E0000FB6F8949EBF0FBE8DBFDCCFA1E1B0E085
:1007F000ECEFF3E00C940D093C017F876E876A01F2
:10080000FC0117821682838181FD03C06FEF7FEFA9
:100810006FC39E012F5F3F4F398B288BF3012381DC
:10082000EE85FF8523FD859123FF8191FF87EE876C
:10083000882309F45AC3853251F4EE85FF8523FDE0
:10084000859123FF8191FF87EE87853229F490E01F
:10085000B3010E94540AE2CF982F10E08824992413
:100860001032B0F49B3269F09C3228F4903251F08F
:10087000933271F40BC09D3239F0903349F411601A
:1008800028C01260146025C0186023C0106121C008
:1008900017FD2AC0892F80538A3078F416FF06C0CE
:1008A000FAE09F9E902C1124980E13C03AE0839E8C
:1008B000802C1124880E10620CC09E3221F416FD8B
:1008C00014C3106406C09C3611F4106802C0983638
:1008D00059F4EE85FF8523FD959123FF9191FF87C4
:1008E000EE87992309F0BCCF892F8554833020F4FB
:1008F000812F8061905E07C0892F8556833008F074
:100900009FC1812F8F7E86FD02C076E0972E6FE318
:10091000F62EF822953619F4F0E4FF2A07C0963631
:1009200019F420E8F22A02C091109A94F7FE0AC046
:100930003BE3391518F45CE3B52E02C0B92CB3942F
:1009400027E009C047E0491520F4BB2447E0942E76
:10095000F7CF292DBB24C60104969D878C87F6010D
:100960006081718182819381AE014F5F5F4F0B2D5A
:100970000E9466096C010981202E332400FF04C007
:1009800003FD02C01DE209C0F1FE02C01BE205C06A
:10099000F2FC02C010E001C010E2C1018C70907046
:1009A000892BB9F1112311F483E001C084E088158B
:1009B00010F088240AC0881AF3FC07C080E290E097
:1009C000B3010E94540A8A94C9F7112329F0812F98
:1009D00090E0B3010E94540A23FE03C008E610E031
:1009E0000EC00CE610E00BC0E114F10409F08052D7
:1009F00090E0B3010E94540A0F5F1F4F05C0EF2C17
:100A0000FF24F0E1EF22FF24F8018491882361F7AD
:100A100014C1F7FE12C0BC0C24FE04C08A818133CD
:100A200009F4BA941B141CF0BB24B3942DC0F8E055
:100A3000FB1550F538E0B32E27C0F6FC25C0892DF4
:100A400090E08C159D054CF02CEFC2162FEFD206CE
:100A500024F030E8F32A01C09A94992049F0E2E0AA
:100A6000F0E0EC0FFD1FE90DF11D80818033A1F353
:100A7000F7FE0AC0B92CB394892D90E0C816D906A8
:100A800014F0992401C09C18F7FC03C025E030E065
:100A900009C01C141D041CF021E030E003C09601C5
:100AA0002F5F3F4F112311F02F5F3F4F992029F007
:100AB000892D90E00196280F391F882D90E0281786
:100AC000390714F0882401C0821A4F2C5524C20122
:100AD00089709070892B39F008C080E290E0B301F2
:100AE0000E94540A8A948820C1F7112329F0812F8B
:100AF00090E0B3010E94540A43FE07C008C080E39F
:100B000090E0B3010E94540A8A948820C1F7F7FE4E
:100B100046C08601D7FE02C000E010E076010894CE
:100B2000E11CF11CE01AF10A41E050E04C0F5D1F9E
:100B3000E40EF51E26014B185108892D90E0AA24D9
:100B4000BB24A81AB90A5FEF0F3F150729F48EE2FC
:100B500090E0B3010E94540AC016D10634F040164A
:100B600051061CF4F701808101C080E30150104060
:100B70000894E11CF11C0A151B052CF090E0B30150
:100B80000E94540AE0CF0C151D0539F49A81963362
:100B900018F4953311F424FE81E390E04BC08A8170
:100BA000813309F00F7E90E0B3010E94540A99202E
:100BB000A1F08EE290E0B3010E94540A12E0E1E05D
:100BC000F0E0EC0FFD1FE10FF11D1F5F808190E051
:100BD000B3010E94540A9A9491F744FC03C085E63D
:100BE00090E002C085E490E0B3010E94540AD7FC73
:100BF00005C0C114D10441F404FF06C0D094C194CF
:100C0000D108D3948DE201C08BE290E0B3010E9441
:100C1000540A80E305C08F5F26EF3FEFC20ED31E5C
:100C20003AE0C316D104BCF790E0B3010E94540A25
:100C3000C601C096B3010E94540ACC84DD8452C11F
:100C4000933631F0933799F0933509F059C023C0AA
:100C5000F601808189835E010894A11CB11C22E009
:100C600030E0C20ED31E21E0E22EF12C12C0F601BC
:100C7000A080B18016FD03C06FEF7FEF02C0692D29
:100C800070E022E030E0C20ED31EC5010E94490A86
:100C90007C011F7713C0F601A080B18016FD03C050
:100CA0006FEF7FEF02C0692D70E022E030E0C20EEE
:100CB000D31EC5010E943E0A7C01106813FF07C0C5
:100CC0001BC080E290E0B3010E94540A8A94882DF0
:100CD00090E0E816F906A8F30FC0F50117FD85911D
:100CE00017FF81915F0190E0B3010E94540A8110C7
:100CF0008A940894E108F108E114F10471F7F2C054
:100D0000943611F0993689F517FF08C0F601208155
:100D100031814281538184E090E00AC0F6018081F4
:100D200091819C01442737FD4095542F82E090E04B
:100D3000C80ED91E9FE6F92EF12257FF09C0509523
:100D40004095309521953F4F4F4F5F4F90E8F92ADE
:100D5000CA01B901AE014F5F5F4F2AE030E00E9447
:100D6000D10AE82EE889EE1A41C0953721F41F7E9A
:100D70002AE030E01CC0197F9F3661F0903720F4E4
:100D8000983509F0B2C00FC0903739F0983709F0A4
:100D9000ACC004C028E030E00AC0106114FD14604B
:100DA00020E130E004C014FD166020E132E017FFBE
:100DB00008C0F601608171818281938144E050E036
:100DC00008C0F60180819181BC0180E090E042E0A2
:100DD00050E0C40ED51EAE014F5F5F4F0E94D10A96
:100DE000E82E5889E51A8FE7F82EF122F6FE0BC09F
:100DF0008EEFF822E91438F4F4FE07C0F2FC05C0C7
:100E00009FEEF92202C01E2D01C0192DF4FE0DC067
:100E1000FE01EE0DF11D8081803319F4E9EEFE2212
:100E200008C01F5FF2FE05C003C08F2D867809F051
:100E30001F5F0F2DF3FC14C0F0FE0FC0181510F04B
:100E40009E2C0BC09E2C980C911A182D06C080E287
:100E500090E0B3010E94540A1F5F1815C0F304C04C
:100E6000181510F4811A01C0882404FF0FC080E314
:100E700090E0B3010E94540A02FF1DC001FD03C0AF
:100E800088E790E00EC088E590E00BC0802F867860
:100E900091F001FF02C08BE201C080E2F7FC8DE21D
:100EA00090E0B3010E94540A06C080E390E0B301D1
:100EB0000E94540A9A94E914C0F3EA94E1E0F0E045
:100EC000EC0FFD1FEE0DF11D808190E0B3010E943B
:100ED000540AEE2091F706C080E290E0B3010E9430
:100EE000540A8A948820C1F799CCF30166817781EE
:100EF000CB016196E2E10C9429095058BB27AA273F
:100F00000ED0B4C0A5D030F0AAD020F031F49F3F6D
:100F100011F41EF49AC00EF4E095E7FB90C0E92F9F
:100F2000B6D080F3BA17620773078407950718F0E5
:100F300071F49EF5CEC00EF4E0950B2EBA2FA02DC5
:100F40000B01B90190010C01CA01A0011124FF2776
:100F5000591B99F0593F50F4503E68F11A16F04071
:100F6000A22F232F342F4427585FF3CF4695379570
:100F70002795A795F0405395C9F77EF41F16BA0B35
:100F8000620B730B840BBAF09150A1F0FF0FBB1FE3
:100F9000661F771F881FC2F70EC0BA0F621F731F2C
:100FA000841F48F4879577956795B795F7959E3F89
:100FB00008F0B3CF9395880F08F09927EE0F979517
:100FC00087950895E89409C097FB3EF49095809525
:100FD000709561957F4F8F4F9F4F9923A9F0F92FFF
:100FE00096E9BB279395F695879577956795B7957D
:100FF000F111F8CFFAF4BB0F11F460FF1BC06F5F63
:101000007F4F8F4F9F4F16C0882311F096E911C074
:10101000772321F09EE8872F762F05C0662371F095
:1010200096E8862F70E060E02AF09A95660F771FA9
:10103000881FDAF7880F9695879597F9089597F99D
:101040009F6780E870E060E008959FEF80EC08956E
:1010500000240A9416161706180609060895002497
:101060000A9412161306140605060895092E039411
:10107000000C11F4882352F0BB0F40F4BF2B11F485
:1010800060FF04C06F5F7F4F8F4F9F4F089557FDE4
:101090009058440F551F59F05F3F71F04795880FE6
:1010A00097FB991F61F09F3F79F08795089512167D
:1010B00013061406551FF2CF4695F1DF08C0161629
:1010C00017061806991FF1CF8695710561050894DA
:1010D0000895E894BB2766277727CB0197F90895F1
:1010E0000BD0C4CFB5DF28F0BADF18F0952309F094
:1010F000A6CFABCF1124EECFCADFA0F3959FD1F3DB
:10110000950F50E0551F629FF001729FBB27F00DB5
:10111000B11D639FAA27F00DB11DAA1F649F66270A
:10112000B00DA11D661F829F2227B00DA11D621F59
:10113000739FB00DA11D621F839FA00D611D221F13
:10114000749F3327A00D611D231F849F600D211DF7
:10115000822F762F6A2F11249F5750408AF0E1F09A
:1011600088234AF0EE0FFF1FBB1F661F771F881FE3
:1011700091505040A9F79E3F510570F060CFAACF23
:101180005F3FECF3983EDCF3869577956795B795CE
:10119000F795E7959F5FC1F7FE2B880F911D9695F8
:1011A000879597F90895629FD001739FF001829F00
:1011B000E00DF11D649FE00DF11D929FF00D839FE6
:1011C000F00D749FF00D659FF00D9927729FB00D83
:1011D000E11DF91F639FB00DE11DF91FBD01CF0196
:1011E0001124089597FB092E05260ED057FD04D033
:1011F0004BD00AD0001C38F450954095309521957D
:101200003F4F4F4F5F4F0895F6F79095809570953B
:1012100061957F4F8F4F9F4F08952F923F924F922E
:101220005F926F927F928F929F92AF92BF92CF9276
:10123000DF92EF92FF920F931F93CF93DF93CDB77F
:10124000DEB7CA1BDB0B0FB6F894DEBF0FBECDBFF7
:1012500009942A88398848885F846E847D848C84C8
:101260009B84AA84B984C884DF80EE80FD800C81D1
:101270001B81AA81B981CE0FD11D0FB6F894DEBFB4
:101280000FBECDBFED010895A1E21A2EAA1BBB1B14
:10129000FD010DC0AA1FBB1FEE1FFF1FA217B30742
:1012A000E407F50720F0A21BB30BE40BF50B661F58
:1012B000771F881F991F1A9469F76095709580951C
:1012C00090959B01AC01BD01CF010895283008F035
:1012D00027E03327DA01990F311D87FD91600096D1
:1012E0006105710539F432602E5F3D9330E32A9534
:1012F000E1F708959F3F30F080387105610509F0EE
:101300003C5F3C5F3D93913008F08068911DDF9316
:10131000CF931F930F93FF92EF92192F987F96957B
:10132000E92F96959695E90FFF27E653FF4F9927EA
:101330003327EE24FF24A701E701059008940794C2
:1013400028F4360FE71EF81E491F511D660F771F40
:10135000881F991F0694A1F70590079428F4E70EBB
:10136000F81E491F561FC11D770F881F991F661F42
:101370000694A1F70590079428F4F80E491F561F0C
:10138000C71FD11D880F991F661F771F0694A1F7ED
:101390000590079420F4490F561FC71FD81F990FB7
:1013A000661F771F881F0694A9F784911095177000
:1013B00041F0D695C79557954795F794E7941A95B8
:1013C000C1F7E0E7F0E068941590159135916591CB
:1013D000959105907FE27395E118F10A430B560B46
:1013E000C90BD009C0F7E10CF11E431F561FC91FDE
:1013F000D01D7EF4703311F48A95E6CFE894015045
:1014000030F0080F0AF40027021708F4202F239564
:10141000022F7A3328F079E37D932A95E9F710C0FB
:101420007D932A9589F60694979567953795179534
:101430001794E118F10A430B560BC90BD00998F029
:1014400023957E9173957A3308F070E37C93201393
:10145000B8F77E9170617D9330F0839571E37D9351
:1014600070E32A95E1F71124EF90FF900F911F91FF
:10147000CF91DF91992787FD90950895FC01059004
:10148000615070400110D8F7809590958E0F9F1F86
:101490000895FC016150704001900110D8F78095CB
:1014A00090958E0F9F1F08950F931F93CF93DF93F7
:1014B0008C01EB018B8181FF1BC082FF0DC02E814F
:1014C0003F818C819D812817390764F4E881F98177
:1014D0000193F983E88306C0E885F985802F099593
:1014E000892B31F48E819F8101969F838E8302C068
:1014F0000FEF1FEFC801DF91CF911F910F9108955A
:10150000A0E0B0E0E6E8FAE00C941D09FE01359693
:10151000619171918091D0019091D101AF010E94B0
:10152000F6032096E2E00C9439096091D0017091A5
:10153000D1010E94540A08950F931F93CF93DF9314
:101540008C01E091D001F091D101838181FF21C014
:10155000C0E0D0E00DC0E091D001F091D101208534
:101560003185BF01F9010995892B11F0CFEFDFEF2C
:10157000F80181918F01882371F7E091D001F091FA
:10158000D101208531858AE0BF01F9010995892BB8
:1015900011F0CFEFDFEFCE01DF91CF911F910F91CF
:1015A0000895FA01AA27283051F1203181F1E894F9
:1015B0006F936E7F6E5F7F4F8F4F9F4FAF4FB1E046
:1015C0003ED0B4E03CD0670F781F891F9A1FA11D41
:1015D000680F791F8A1F911DA11D6A0F711D811D42
:1015E000911DA11D20D009F468943F912AE0269F07
:1015F00011243019305D3193DEF6CF010895462F66
:101600004770405D4193B3E00FD0C9F7F6CF462F46
:101610004F70405D4A3318F0495D31FD40524193AF
:1016200002D0A9F7EACFB4E0A6959795879577956C
:101630006795BA95C9F700976105710508959B01F3
:10164000AC010A2E06945795479537952795BA957C
:10165000C9F7620F731F841F951FA01D0895F8948A
:02166000FFCFBA
:10166200307825783A203078257809000A2A2A2A03
:101672002A2A2A2A2A2A2A2A2A2A2A2A4D50523150
:101682003135413120546573742A2A2A2A2A2A2A9A
:101692002A2A2A2A2A2A2A2A2A0A000A5072657320
:1016A2007320737061636520746F207072696E7449
:1016B200207072657373757265005072657373750D
:1016C2007265203D2025660A00000000020000002D
:0816D20000040100000000000B
:00000001FF
/Modules/Sensors/ALTIMET01A/SW/MPL115A1/Wiring/MPL115A1/MPL115A1.ino
0,0 → 1,118
/*
MPL115A1 sparkfun breakout baropressure meter
SDN : pin 7
CSN : pin 10
SDI/MOSI : pin 11
SDO/MISO : pin 12
SCK : pin 13
*/
 
// the sensor communicates using SPI, so include the library:
#include <SPI.h>
 
#define PRESH 0x80
#define PRESL 0x82
#define TEMPH 0x84
#define TEMPL 0x86
 
#define A0MSB 0x88
#define A0LSB 0x8A
#define B1MSB 0x8C
#define B1LSB 0x8E
#define B2MSB 0x90
#define B2LSB 0x92
#define C12MSB 0x94
#define C12LSB 0x96
 
#define CONVERT 0x24
 
#define chipSelectPin 10
#define shutDown 7
 
float A0_;
float B1_;
float B2_;
float C12_;
 
void setup() {
Serial.begin(115200);
 
// start the SPI library:
SPI.begin();
 
// initalize the data ready and chip select pins:
pinMode(shutDown, OUTPUT);
digitalWrite(shutDown, HIGH);
pinMode(chipSelectPin, OUTPUT);
digitalWrite(chipSelectPin, HIGH);
delay (10);
// read registers that contain the chip-unique parameters to do the math
unsigned int A0H = readRegister(A0MSB);
unsigned int A0L = readRegister(A0LSB);
A0_ = (A0H << 5) + (A0L >> 3) + (A0L & 0x07) / 8.0;
unsigned int B1H = readRegister(B1MSB);
unsigned int B1L = readRegister(B1LSB);
B1_ = ( ( ( (B1H & 0x1F) * 0x100)+B1L) / 8192.0) - 3 ;
unsigned int B2H = readRegister(B2MSB);
unsigned int B2L = readRegister(B2LSB);
B2_ = ( ( ( (B2H - 0x80) << 8) + B2L) / 16384.0 ) - 2 ;
unsigned int C12H = readRegister(C12MSB);
unsigned int C12L = readRegister(C12LSB);
C12_ = ( ( ( C12H * 0x100 ) + C12L) / 16777216.0 ) ;
}
 
void loop() {
Serial.print("de druk is : ");
Serial.println(baropPessure());
delay(1000);
}
 
//Read registers
unsigned int readRegister(byte thisRegister ) {
unsigned int result = 0; // result to return
digitalWrite(chipSelectPin, LOW);
delay(10);
SPI.transfer(thisRegister);
result = SPI.transfer(0x00);
digitalWrite(chipSelectPin, HIGH);
return(result);
}
 
//read pressure
float baropPessure(){
digitalWrite(chipSelectPin, LOW);
delay(3);
SPI.transfer(0x24);
SPI.transfer(0x00);
digitalWrite(chipSelectPin, HIGH);
delay(3);
digitalWrite(chipSelectPin, LOW);
SPI.transfer(PRESH);
unsigned int presH = SPI.transfer(0x00);
delay(3);
SPI.transfer(PRESL);
unsigned int presL = SPI.transfer(0x00);
delay(3);
SPI.transfer(TEMPH);
unsigned int tempH = SPI.transfer(0x00);
delay(3);
SPI.transfer(TEMPL);
unsigned int tempL = SPI.transfer(0x00);
delay(3);
SPI.transfer(0x00);
delay(3);
digitalWrite(chipSelectPin, HIGH);
 
unsigned long press = ((presH *256) + presL)/64;
unsigned long temp = ((tempH *256) + tempL)/64;
 
float pressure = A0_+(B1_+C12_*temp)*press+B2_*temp;
float preskPa = pressure* (65.0/1023.0)+50.0;
 
return(preskPa);
}
 
/Modules/Sensors/ALTIMET01A/SW/MPL3115/MPL3115.c
0,0 → 1,105
void mpl3115_setA (void) //nastavení pro výšku
{
 
i2c_start(); //STANDBY mode
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x26);
I2C_write(0xB8);
i2c_stop();
i2c_start(); //PT_DATA_CFG set
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x13);
I2C_write(0x07); //hodnota
i2c_stop();
i2c_start(); //ACTIVE mode
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x26);
I2C_write(0xB9);
i2c_stop();
}
void mpl3115_setP (void) //nastavení pro tlak
{
 
i2c_start(); //STANDBY mode
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x26);
I2C_write(0xB8);
i2c_stop();
i2c_start(); //PT_DATA_CFG set
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x13);
I2C_write(0x07); //hodnota
i2c_stop();
i2c_start(); //ACTIVE mode
I2C_Write(MPL3115_ADDR_W);
I2C_write(0x26);
I2C_write(0x39);
i2c_stop();
}
 
 
byte mpl3115_read (byte reg)
{
byte i;
i2c_start();
I2C_Write(MPL3115_ADDR_W);
I2C_write(reg);
i2c_start();
I2C_Write(MPL3115_ADDR_R);
i=i2c_read(0);
i2c_stop();
return i;
}
 
 
float mpl3115_T (void) //teplota ve stupnich
{
int m;
float l, t;
m = mpl3115_read (0x04);
l = (float)(mpl3115_read(0x05)>>4)/16.0;
t = (float)(M + L);
return t;
}
 
float mpl3115_A (void) //vyska v m
{
 
int16 m, c;
float l, a;
m = mpl3115_read (0x01);
c = mpl3115_read (0x02);
l = (float)(mpl3115_read(0x03)>>4)/16.0;
a = (float)((m << 8)|c) + l;
return a;
}
 
 
float mpl3115_P (void) //tlak v Pa
{
unsigned int32 m;
unsigned int16 c;
unsigned int l;
float p, l1;
m = mpl3115_read (0x01);
c = mpl3115_read (0x02);
l = mpl3115_read(0x03);
 
l1= (float)(l>>4)/4.0;
p = (float)((m << 10)|(c<<2)|(l>>6)) + l1;
 
return p;
}
 
/Modules/Sensors/ALTIMET01A/SW/MPL3115/MPL3115.h
0,0 → 1,10
//microchip pic library for Freescale MPL3115 barometer sensor
 
/*void mpl3115_setA (void) //setup sensor for altitude measurement
void mpl3115_setP (void) //setup sensor for preasure measurement
float mpl3115_T (void) //temperature in Celsius degrees
float mpl3115_A (void) //altitude in metres
float mpl3115_P (void) //preassure in pascals
*/
 
#include "MPL3115.c"
/Modules/Sensors/ALTIMET01A/SW/MPL3115/PIC16F887/main.c
0,0 → 1,39
#define VERSION "0.1"
#define ID "$Id: main.c 2916 2013-04-14 17:42:03Z kaklik $"
 
#include "main.h"
 
#use i2c(master, sda=PIN_C4, scl=PIN_C3)
#use rs232(baud=9600,parity=N,xmit=PIN_C6,rcv=PIN_C7,bits=8) //rcv TXD xmit RXD
 
#define MPL3115_ADDR_R 0xC1 //addresa pro cteni
#define MPL3115_ADDR_W 0xC0
 
#include "../MPL3115.h"
 
 
void main()
{
 
float p, t, a;
printf("\r\nMLAB Barometer and Altimeter demo code \r\n",);
printf("Temperature [deg C] Preassure [Pa] Altitude [m] \r\n",);
while(TRUE)
{
mpl3115_setP(); //nastaveni pro tlak a teplotu
delay_ms (500);
t=mpl3115_T();
p=mpl3115_P();
mpl3115_setA(); //nastaveni pro vysku a teplotu
delay_ms (500);
a=mpl3115_A();
 
printf("%3.1f %6.1f %5.2f \r\n", t, p, a);
 
delay_ms (1000);
}
}
 
 
/Modules/Sensors/ALTIMET01A/SW/MPL3115/PIC16F887/main.hex
0,0 → 1,284
:1000000006308A00AA2E00000D054D264121202130
:100010006139EF36653A6539A0306E32A0206C3A0E
:10002000E936653A65392032E5366F10E337E43258
:10003000A0060A00D4326D386539613A7539651009
:100040005B32E533A0215D105039E530F339753965
:1000500065105B28E12EA0206C3A693A7532651074
:10006000DB365D100D050001831603178C170C1489
:100070000000000083120C087F3903197A2803134B
:10008000AD0003170D080313AE0003170F08031389
:10009000AF002D080C1E4A2899002E0803178D006A
:1000A00003132F0803178F0083168C170C140000FE
:1000B000000083120C0D0E0D7F3903197A280313EB
:1000C000AD0003170D080313AE0003170F08031349
:1000D000AF002D080C1E6A2899002E0803178D000A
:1000E00003132F0803178F008D0A03198F0A0313B8
:1000F00034280317031308000830F80000008711A4
:10010000A01120088316870000008312BE0D07127D
:10011000031C902820162008831687009428831239
:10012000201220088316870000008312A0152008E3
:10013000831687008312871D9B28F80B7E280000FA
:100140008711A01120088316870000008312201653
:10015000200883168700000000008312A0152008E5
:10016000831687008312871DB328F8010000071A41
:1001700078148711A01120088316870083120712B4
:1001800020122008831687008312080020162008FA
:100190008316870000008312A015200883168700AD
:1001A0000000831207122012200883168700000027
:1001B00083128711A011200883168700C030831294
:1001C000BE007C202630BE007C20B830BE007C20E3
:1001D000201220088316870000008312A015200833
:1001E000831687008312871DF3280000F72800007C
:1001F000201620088316870000008312201620088E
:100200008316870000008312A0152008831687003C
:1002100000008312071220122008831687000000B6
:1002200083128711A011200883168700C030831223
:10023000BE007C201330BE007C200730BE007C2036
:10024000201220088316870000008312A0152008C2
:10025000831687008312871D2B2900002F29000099
:10026000201620088316870000008312201620081D
:100270008316870000008312A015200883168700CC
:100280000000831207122012200883168700000046
:1002900083128711A011200883168700C0308312B3
:1002A000BE007C202630BE007C203930BE007C2081
:1002B000201220088316870000008312A015200852
:1002C000831687008312871D6329000067290000B9
:1002D0002016200883168700000083128A110A1254
:1002E000DD2E2E3084008313000803198429023088
:1002F000F800F701F70B7A29F80B79299730F70006
:10030000F70B8029800B7729080020162008831618
:10031000870000008312A0152008831687000000C4
:100320008312071220122008831687000000831210
:100330008711A011200883168700C0308312BE00E9
:100340007C203C08BE007C202016200883168700F5
:1003500000008312A0152008831687000000831276
:10036000871DB0290712201220088316870000007D
:1003700083128711A011200883168700C1308312D1
:10038000BE007C20F7010830BF007708C0002016AF
:1003900020088316870000008312A015200883160A
:1003A00087008312871DD229071A0314071E031022
:1003B000F80D0000A0112008831687008312871112
:1003C000BF0BC72920162008831687000000831260
:1003D000071240080319F12920122008831687000C
:1003E00083120000A0152008831687008312871D42
:1003F000F72900008711A01120088316870000004C
:1004000083120712201220088316870078088312AF
:10041000BD00201220088316870000008312A0155B
:100420002008831687008312871D142A0000182ACB
:1004300000002016200883168700000083123D0864
:10044000F80008008E30F7003E08F8003D08F9007B
:10045000FA01F808031D362A7908F800F901083076
:10046000F702F808031D362AF7013E2A0310F81B8D
:100470003D2AF90DF80DF703362AF8130800410854
:100480000319042BCD0045080319042BCD02031CCE
:100490004E2A7F30CD070318042B542A8130CD0219
:1004A000031C042B0319042B4D08F700F801F90174
:1004B000FA01CC014208CB00CB174308CA0044081C
:1004C000C9001930CD004808C9020318772A013045
:1004D000CA020318772ACB020318772ACC02031822
:1004E000772ACC0ACB0ACA0A4808C907A92A4708AA
:1004F000CA020318922A0130CB020318922ACC02B6
:100500000318922ACC0ACB0A4708CA074808C90729
:10051000031CA92ACA0A031DA92ACB0A031DA92A5A
:10052000CC0AA92A46088038CB020318A82A013031
:10053000CC020318A82ACC0A46088038CB07470803
:10054000CA07031C862ACB0A031D862ACC0A862AE0
:100550007A14CD0BAC2AB72A0310C90DCA0DCB0DE6
:10056000CC0D0310FA0DF90DF80DCE0D632A4E1CBB
:10057000BF2A0310F80CF90CFA0CCE0CC22AF703B0
:100580000319042BCE1BEB2A0310C90DCA0DCB0D8A
:10059000CC0D4808C9020318D72A0130CA02031833
:1005A000D72ACB020318D72ACC02031CFA2A470801
:1005B000CA020318E22A0130CB020318E22ACC0255
:1005C000031CFA2A46088038CB020318EB2A0130B4
:1005D000CC02031CFA2AFA0A031DFA2AF90A031D9F
:1005E000FA2AF80A031DFA2AF70A0319042BF80C51
:1005F000F90CFA0C4208CD004608CD06CD1F022B9F
:10060000F817082BF813082BF701F801F901FA0184
:10061000080080308318C806CD01CE014408CC0004
:100620004808CC0643080319F92BCB00F70047080C
:100630000319022CCB0203199E2B031C5C2B4808C8
:10064000D100D1174908D0004A08CF00CE010310CD
:10065000D10CD00CCF0CCE0CCB0B262BCC1F332BBC
:100660004D14162C4D104B104D164630840083133C
:100670002B2C4D12CC1B462B4B1C512BD10CD00CD0
:10068000CF0CCE0CF70A0319112C512BD11B542B74
:100690000310CE0DCF0DD00DD10DF7030319112C82
:1006A000462B4D17BE2B4D134408CC00CC1F5A2BA4
:1006B000D1170A2CD1130A2C4708CB00F7004308A6
:1006C000CB024408D100D1174508D0004608CF001E
:1006D000CE010310D10CD00CCF0CCE0CCB0B682B61
:1006E000CC1F752BCD14162CCD104B10CD164A30C7
:1006F000840083132B2CCD12CC1B882B4B1C932BEB
:10070000D10CD00CCF0CCE0CF70A0319112C932B63
:10071000D11B962B0310CE0DCF0DD00DD10DF703AD
:100720000319112C882BCD17BE2BCD134808CC00F4
:10073000CC1F9C2BD1170A2CD1130A2C4808D100AE
:10074000D1174908D0004A08CF00CC1FAB2BD113DA
:100750004D15162C4D11CE014B10463084008313DD
:100760002B2CCC1BD42B4408CC004B1CBE2BD10C07
:10077000D00CCF0CCE0CF70A0319112CCE1FCF2BA7
:10078000CF0A031DCF2BD00A031DCF2BD10A031D87
:10079000CF2BD10CD00CCF0CF70A0319112C4D1B09
:1007A000532BCD1B952BF32B8030D106D11FDC2B87
:1007B000162C4808CC00E92B4408CC00D108031DB6
:1007C000E92BD008031DE92BCF08031DE92BF70106
:1007D0000A2CD11BF32B0310CE0DCF0DD00DD10D54
:1007E000F70BE92B112CCC1FF72BD1170A2CD113A7
:1007F0000A2C4708F7004808D1004908D0004A08E9
:10080000CF000A2C4308F7004408D1004508D00067
:100810004608CF005108F8005008F9004F08FA00C8
:10082000492CF701F801F901FA01492CCE01CF0951
:10083000D009D109CE09CE0A031D242CCF0A031DED
:10084000242CD00A0319D10A4D18322BCD18742B41
:100850004D19AA2BD92B0008CF07031C352CD00A21
:10086000031D352CD10A03194B1484030008D0074B
:10087000031C3D2CD10A03194B1484030008801F6C
:10088000803AD10703184B144D1A392BCD1A7B2B04
:10089000B12B08000430BC0085217808AD0005307C
:1008A000BC008521780EF7000F30F7057708BE01F0
:1008B000BD0022227708B6007808B7007908B80092
:1008C0007A08B900C4007908C3007808C200770824
:1008D000C100C801C701C6018330C5003F227A08A4
:1008E000B1007908B0007808AF007708AE00BE010B
:1008F0002D08BD00222283107A08C6007908C500A1
:100900007808C4007708C3003108CA003008C9005D
:100910002F08C8002E08C70009237A08B5007908F7
:10092000B4007808B3007708B2003208F700330843
:10093000F8003408F9003508FA008A110A12E52E89
:100940000130BC008521B001AF01AE017808AD00D7
:100950000230BC008521B2017808B1000330BC0030
:1009600085217808B300330EF7000F30F7057708BC
:10097000BE01BD0022227708BD007808BE007908BC
:10098000BF007A08C000C4007908C3007808C2001C
:100990007708C100C801C701C6018130C5003F22E8
:1009A0007A08BB007908BA007808B9007708B8005F
:1009B000BD012D0DBE002E0DBF002F0DC000BE0DC0
:1009C000BF0DC00DFC30BE05310DF900320DFA002F
:1009D000F90DFA0DFC30F9057908BD047A08BE045A
:1009E000330EF700F70CF70C0330F70577083D04DA
:1009F000F7003E08F8003F08F9004008FA007A08BE
:100A0000C6007908C5007808C4007708C300B6306E
:100A1000F700FA01F901F8014308440445044604CB
:100A2000031D142DF701212D0310F81B202DC30DDC
:100A3000C40DC50DC60DFA0DF90DF80DF70B142DEB
:100A4000F8137708BD007808BE007908BF007A085F
:100A5000C00083107A08C6007908C5007808C40071
:100A60007708C3003B08CA003A08C9003908C80023
:100A70003808C70009237A08B7007908B600780853
:100A8000B5007708B4003408F7003508F8003608D8
:100A9000F9003708FA008A110A12EE2E20162008F3
:100AA0008316870000008312A01520088316870094
:100AB000000083120712201220088316870000000E
:100AC00083128711A011200883168700C03083127B
:100AD000BE007C202630BE007C20B830BE007C20CA
:100AE000201220088316870000008312A01520081A
:100AF000831687008312871D7B2D00007F2D000049
:100B00002016200883168700000083122016200874
:100B10008316870000008312A01520088316870023
:100B2000000083120712201220088316870000009D
:100B300083128711A011200883168700C03083120A
:100B4000BE007C201330BE007C200730BE007C201D
:100B5000201220088316870000008312A0152008A9
:100B6000831687008312871DB32D0000B72D000068
:100B70002016200883168700000083122016200804
:100B80008316870000008312A015200883168700B3
:100B9000000083120712201220088316870000002D
:100BA00083128711A011200883168700C03083129A
:100BB000BE007C202630BE007C20B930BE007C20E8
:100BC000201220088316870000008312A015200839
:100BD000831687008312871DEB2D0000EF2D000088
:100BE0002016200883168700000083128A110A123B
:100BF000F72E0130BC008521AE017808AD0002302F
:100C0000BC008521B0017808AF000330BC0085210D
:100C1000780EF7000F30F7057708BE01BD002222DD
:100C20007708B9007808BA007908BB007A08BC00D8
:100C3000C4007908C3007808C2007708C100C80161
:100C4000C701C6018330C5003F227A08B400790885
:100C5000B3007808B2007708B1002D08BB00BA01D4
:100C60003A082F04F7002D083004FA007708BD0079
:100C70007A08BE0022227708BA007808BB007908FB
:100C8000BC007A08BD0083107A08C6007908C50048
:100C90007808C4007708C3003408CA003308C900C4
:100CA0003208C8003108C70009237A08B80079085B
:100CB000B7007808B6007708B5003508F7003608A1
:100CC000F8003708F9003808FA008A110A12FF2ED6
:100CD000F701F801F901FA01C201C301C401C5011C
:100CE000410840043F043E040319A62E2030C600EC
:100CF0000310BA0DBB0DBC0DBD0DC20DC30DC40D4F
:100D0000C50D41084502031D8F2E40084402031DF6
:100D10008F2E3F084302031D8F2E3E084202031C04
:100D2000A02E3E08C2023F08031C3F0FC30240082A
:100D3000031C400FC4024108031C410FC5020314E9
:100D4000F70DF80DF90DFA0DC60B782E4230840020
:100D500083130800840183131F30830571308316C9
:100D60008F000F08031787110C3003139900A2306E
:100D70009800903083129800831603170908C03931
:100D8000890003131F129F1200300317880083127B
:100D9000870188018901FF300313A0000430031785
:100DA0008D0000308F00031334201A3003178D009C
:100DB00000308F0003133420C6280230AD00FA3013
:100DC000AE007121AD0BDF2E4A2C7A08A8007908FD
:100DD000A7007808A6007708A500A02C7A08A40030
:100DE0007908A3007808A2007708A1004E2D0230F0
:100DF000AD00FA30AE007121AD0BF92EF92D7A0855
:100E0000AC007908AB007808AA007708A900023086
:100E100084002808B0002708AF002608AE00250887
:100E2000AD000130B1008A1500208A1120300C1E5F
:100E3000172F9900053084002408B0002308AF0064
:100E40002208AE002108AD000130B1008A15002053
:100E50008A1120300C1E2A2F9900043084002C089F
:100E6000B0002B08AF002A08AE002908AD00023000
:100E7000B1008A1500208A1120300C1E3D2F9900E8
:100E80000D300C1E412F99000A300C1E452F990081
:100E90000430AD00FA30AE007121AD0B4A2FDC2ECC
:020EA0006300ED
:101000000408B2003108B400031992283008BD006A
:101010002F08BC002E08BB002D08BA00C101C0017A
:101020002030BF008230BE003A0803198428C20075
:101030003E0803198428C207031825287F30C202FE
:10104000031C84280319842829288130C207031827
:1010500084284208F700F801F901FA013B08C600AC
:10106000C6173C08C5003D08C4001830C200C301C3
:10107000441C52284108FA07031C4428F90A031D9E
:101080004428F80A0319C3174008F907031C4B2822
:10109000F80A0319C3173F08BC00BC173C08F8073F
:1010A0000318C317C30DF80CF90CFA0CC60CC50CC9
:1010B000C40C0310C20B37280130F707031884282B
:1010C000F81B6928C60DFA0DF90DF80DF703031981
:1010D0008428C61F7A28FA0A031D7A28F90A031DF4
:1010E0007A28F80A031D7A28F80CF90CFA0CF70A8A
:1010F000031984283B08C3003F08C306C31F822886
:10110000F8178828F8138828F701F801F901FA017F
:101110007A08B0007908AF007808AE007708AD0013
:10112000B40B06283008BD002F08BC002E08BB00F9
:101130002D08BA003A08B63CBA00FA013B08BE00D6
:10114000BB170310BB0CBC0CBD0CFA0CF90CF80C53
:10115000F70CBA0BA128BE1FB828F709F809F9093E
:10116000FA09F70A0319F80A0319F90A0319FA0A1E
:101170007A08B0007908AF007808AE007708AD00B3
:10118000B01FCF28B203B216AD09AE09AF09B0093E
:10119000AD0A0319AE0A0319AF0A0319B00A3B30AE
:1011A000B9009A30B800CA30B700B6010A30B400AE
:1011B00031080319B20A3008BD002F08BC002E0800
:1011C000BB002D08BA003908C1003808C000370834
:1011D000BF003608BE008A1168268A150008AD00D7
:1011E000840A0008AE00840A0008AF00840A0008E0
:1011F000B000FD308407F708031D1129310A3402BD
:10120000031911293208031913290F39340203195C
:101210000B2903184729B21B4729321B13292030F9
:1012200042292030B205B21E2229B2123108031D14
:10123000B2037708B2002D300C1E1C299900320829
:10124000F700B20131083402031D31297708B200DA
:101250002E300C1E292999003208F7002030B205E3
:1012600000303030B21E4229B2123108031DB203E1
:101270007708B2002D300C1E3B2999003208F70088
:10128000B2013030F70777080C1E4429990039085D
:10129000BD003808BC003708BB003608BA00C101E1
:1012A000C001BF010A30BE008A1168268A157A087B
:1012B000B9007908B8007808B7007708B600B40B11
:0412C000DB2808001F
:04400E00F52CFF3F4F
:00000001FF
;PIC16F887
;CRC=79AB CREATED="25-VIII-13 15:29"
/Modules/Sensors/ALTIMET01A/SW/MPL3115/PIC16F887/main.pjt
0,0 → 1,30
[PROJECT]
Target=main.hex
Development_Mode=
Processor_Text=PIC16F887
ToolSuite=CCS
Processor=0x887F
[main]
Type=4
Path=
FileList=
BuildTool=
OptionString=
AdditionalOptionString=
[mru-list]
1=main.c
[Windows]
0=0000 %S 0 0 796 451 3 0
[Opened Files]
1=main.c
2=..\MPL3115.h
3=main.h
4=C:\Program Files (x86)\PICC\devices\16F887.h
5=..\MPL3115.c
6=
[Target Data]
OptionString=-p +FM
FileList=Z:\home\kaklik\svnMLAB\Modules\Sensors\ALTIMET01A\SW\MPL3115\PIC16F887\main.c
[Units]
Count=1
1=main (main)
/Modules/Sensors/ALTIMET01A/SW/MPL3115/PIC16F887/main.err
0,0 → 1,2
Memory usage: ROM=27% RAM=5% - 15%
0 Errors, 0 Warnings.
/Modules/Sensors/ALTIMET01A/SW/MPL3115/PIC16F887/main.h
0,0 → 1,19
#include <16F887.h>
#device adc=8
 
#FUSES NOWDT //No Watch Dog Timer
#FUSES INTRC //Internal RC Osc
#FUSES NOPUT //No Power Up Timer
#FUSES MCLR //Master Clear pin enabled
#FUSES NOPROTECT //Code not protected from reading
#FUSES NOCPD //No EE protection
#FUSES NOBROWNOUT //No brownout reset
#FUSES IESO //Internal External Switch Over mode enabled
#FUSES FCMEN //Fail-safe clock monitor enabled
#FUSES NOLVP //No low voltage prgming, B3(PIC16) or B5(PIC18) used for I/O
#FUSES NODEBUG //No Debug mode for ICD
#FUSES NOWRT //Program memory not write protected
#FUSES BORV40 //Brownout reset at 4.0V
 
#use delay(clock=8000000)
 
/Modules/Sensors/ALTIMET01A/SW/ARM/MPL115A1.cpp
0,0 → 1,221
/* mbed MPL115A1 (Barometric Pressure Sensor) Library
*
* This code is based on application notes and
* Sparkfun example code, written by Jim Lindblom <jim at sparkfun.com>
*
* Copyright (c) 2012 Mitja Kleider
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
 
// TODO: support shutdown pin
 
 
#include "MPL115A1.h"
 
MPL115A1::MPL115A1(SPI& spi, PinName ncs) : _spi(spi), _cs(ncs)
{
_cs = 1;
// sdn = 1; // sensor on
// SCL idle low, sample data on rising edge
_spi.format(8, 0); // 8bit, POL 0, PHA 0
_spi.frequency(1000000); // 1MHz
}
 
void MPL115A1::write_register(uint8_t address, char data)
{
//write any data byte to any single address
//adds a 0 to the MSB of the address byte (WRITE mode)
 
address &= 0x7F;
 
_cs = 0;
wait_ms(1);
_spi.write(address);
wait_ms(1);
_spi.write(data);
wait_ms(1);
_cs = 1;
}
 
char MPL115A1::read_register(uint8_t address)
{
// returns the contents of any 1 byte register from any address
// sets the MSB for every address byte (READ mode)
 
char byte;
 
address |= 0x80;
 
_cs = 0;
_spi.write(address);
byte = _spi.write(0x00);
_cs = 1;
 
return byte;
}
 
float MPL115A1::readPressure()
{
// read pressure, temperature and coefficients, calculate and return absolute pressure [kPa]
 
write_register(MPL115A1_STARTBOTH, 0x00); // start temperature and pressure conversions
wait_ms(10); // AN: data is typically ready after 3ms, DS for both: max. 1ms
// read raw pressure
uiPH = read_register(MPL115A1_PRESH);
uiPL = read_register(MPL115A1_PRESL);
uiTH = read_register(MPL115A1_TEMPH);
uiTL = read_register(MPL115A1_TEMPL);
uiPadc = (unsigned int) uiPH << 8;
uiPadc += (unsigned int) uiPL & 0x00FF;
uiTadc = (unsigned int) uiTH << 8;
uiTadc += (unsigned int) uiTL & 0x00FF;
// read coefficients, put into 16-bit Variables
// a0, pressure offset coefficient
sia0MSB = read_register(MPL115A1_A0MSB);
sia0LSB = read_register(MPL115A1_A0LSB);
sia0 = (signed int) sia0MSB << 8;
sia0 += (signed int) sia0LSB & 0x00FF;
// b1, pressure sensitivity coefficient
sib1MSB = read_register(MPL115A1_B1MSB);
sib1LSB = read_register(MPL115A1_B1LSB);
sib1 = (signed int) sib1MSB << 8;
sib1 += (signed int) sib1LSB & 0x00FF;
// b2, 1st order temperature offset coefficient (TCO)
sib2MSB = read_register(MPL115A1_B2MSB);
sib2LSB = read_register(MPL115A1_B2LSB);
sib2 = (signed int) sib2MSB << 8;
sib2 += (signed int) sib2LSB & 0x00FF;
// c12, temperature sensitivity coefficient (TCS)
sic12MSB = read_register(MPL115A1_C12MSB);
sic12LSB = read_register(MPL115A1_C12LSB);
sic12 = (signed int) sic12MSB << 8;
sic12 += (signed int) sic12LSB & 0x00FF;
// c11, pressure linearity (2nd order) coefficient
sic11MSB = read_register(MPL115A1_C11MSB);
sic11LSB = read_register(MPL115A1_C11LSB);
sic11 = (signed int) sic11MSB << 8;
sic11 += (signed int) sic11LSB & 0x00FF;
// c22, 2nd order temperature offset coefficient
sic22MSB = read_register(MPL115A1_C22MSB);
sic22LSB = read_register(MPL115A1_C22LSB);
sic22 = (signed int) sic22MSB << 8;
sic22 += (signed int) sic22LSB & 0x00FF;
// Coefficient 9 equation compensation
// 10bit stored in 16bit, shift right
uiPadc = uiPadc >> 6;
uiTadc = uiTadc >> 6;
// Step 1: c11x1 = c11 * Padc
lt1 = (signed long) sic11;
lt2 = (signed long) uiPadc;
lt3 = lt1*lt2;
si_c11x1 = (signed long) lt3;
// Step 2: a11 = b1 + c11x1
lt1 = ((signed long)sib1)<<14;
lt2 = (signed long) si_c11x1;
lt3 = lt1 + lt2;
si_a11 = (signed long)(lt3>>14);
// Step 3: c12x2 = c12 * Tadc
lt1 = (signed long) sic12;
lt2 = (signed long) uiTadc;
lt3 = lt1*lt2;
si_c12x2 = (signed long)lt3;
// Step 4: a1 = a11 + c12x2
lt1 = ((signed long)si_a11<<11);
lt2 = (signed long)si_c12x2;
lt3 = lt1 + lt2;
si_a1 = (signed long) lt3>>11;
// Step 5: c22x2 = c22*Tadc
lt1 = (signed long)sic22;
lt2 = (signed long)uiTadc;
lt3 = lt1 * lt2;
si_c22x2 = (signed long)(lt3);
// Step 6: a2 = b2 + c22x2
lt1 = ((signed long)sib2<<15);
lt2 = ((signed long)si_c22x2>1);
lt3 = lt1+lt2;
si_a2 = ((signed long)lt3>>16);
// Step 7: a1x1 = a1 * Padc
lt1 = (signed long)si_a1;
lt2 = (signed long)uiPadc;
lt3 = lt1*lt2;
si_a1x1 = (signed long)(lt3);
// Step 8: y1 = a0 + a1x1
lt1 = ((signed long)sia0<<10);
lt2 = (signed long)si_a1x1;
lt3 = lt1+lt2;
si_y1 = ((signed long)lt3>>10);
// Step 9: a2x2 = a2 * Tadc
lt1 = (signed long)si_a2;
lt2 = (signed long)uiTadc;
lt3 = lt1*lt2;
si_a2x2 = (signed long)(lt3);
// Step 10: pComp = y1 + a2x2
lt1 = ((signed long)si_y1<<10);
lt2 = (signed long)si_a2x2;
lt3 = lt1+lt2;
// Fixed point result with rounding
//siPcomp = ((signed int)lt3>>13);
siPcomp = lt3/8192;
// decPcomp is defined as a floating point number
// Conversion to decimal value from 1023 ADC count value
// ADC counts are 0 to 1023, pressure is 50 to 115kPa respectively
decPcomp = ((65.0/1023.0)*siPcomp)+50;
return decPcomp;
}
 
float MPL115A1::readTemperature()
{
// read, calculate and return temperature
 
write_register(MPL115A1_STARTTEMP, 0x00); // start temperature conversion
wait_ms(10); // AN: data is typically ready after 3ms, DS for temp: max. 0.7ms
// read raw temperature
uiTH = read_register(MPL115A1_TEMPH);
uiTL = read_register(MPL115A1_TEMPL);
uiTadc = (unsigned int) uiTH << 8;
uiTadc += (unsigned int) uiTL & 0x00FF;
// 10bit stored in 16bit, shift right
uiTadc = uiTadc >> 6;
// Tadc is 472 counts at 25degC, -5.35 counts/degC
// return ((float)uiTadc - 472.0)/(-5.35) + 25
return (605.75-uiTadc)*0.186916;
}
/Modules/Sensors/ALTIMET01A/SW/ARM/MPL115A1.h
0,0 → 1,87
#ifndef MPL115A1_H
#define MPL115A1_H
 
#include "mbed.h"
 
/** barometric pressure and temperature sensor MPL115A1 control class, based on SPI
*
* Example:
* @code
* #include "mbed.h"
* #include "MPL115A1.h"
*
* SPI spi(p11,p12,p13);
* MPL115A1 bar(spi, p14);
*
* Serial pc(USBTX, USBRX);
*
* int main() {
* while(1) {
* wait(10);
* pc.printf("Pressure is %f\n", bar.readPressure());
* pc.printf("Temperature is %f\n", bar.readTemperature());
* }
* }
* @endcode
*/
 
// real addresses, in read_register: address |= 0x80
#define MPL115A1_PRESH 0x00 // 80
#define MPL115A1_PRESL 0x02 // 82
#define MPL115A1_TEMPH 0x04 // 84
#define MPL115A1_TEMPL 0x06 // 86
 
#define MPL115A1_A0MSB 0x08 // 88
#define MPL115A1_A0LSB 0x0A // 8A
#define MPL115A1_B1MSB 0x0C // 8C
#define MPL115A1_B1LSB 0x0E // 8E
#define MPL115A1_B2MSB 0x10 // 90
#define MPL115A1_B2LSB 0x12 // 92
#define MPL115A1_C12MSB 0x14 // 94
#define MPL115A1_C12LSB 0x16 // 96
#define MPL115A1_C11MSB 0x18 // 98
#define MPL115A1_C11LSB 0x1A // 9A
#define MPL115A1_C22MSB 0x1C // 9C
#define MPL115A1_C22LSB 0x1E // 9E
 
#define MPL115A1_STARTPRES 0x20 // start pressure measurement
#define MPL115A1_STARTTEMP 0x22 // start temperature measurement
#define MPL115A1_STARTBOTH 0x24 // start both simultaneously
 
class MPL115A1 {
private:
SPI& _spi;
DigitalOut _cs; // chip select, active low
//DigitalOut sdn; // shutdown pin, high=on, low=off
public:
/** Create a barometer object connected to the SPI bus and specified chip select pin
*
* @param spi SPI master object
* @param ncs chip select pin
*/
MPL115A1(SPI& spi, PinName ncs);
/** start measurement, read registers, calculate and return pressure */
float readPressure();
/** start measurement, read registers, calculate and return temperature */
float readTemperature();
 
private:
void write_register(uint8_t address, char data);
char read_register(uint8_t address);
 
signed char sia0MSB, sia0LSB;
signed char sib1MSB, sib1LSB;
signed char sib2MSB, sib2LSB;
signed char sic12MSB, sic12LSB;
signed char sic11MSB, sic11LSB;
signed char sic22MSB, sic22LSB;
signed int sia0, sib1, sib2, sic12, sic11, sic22, siPcomp;
float decPcomp;
signed long lt1, lt2, lt3, si_c11x1, si_a11, si_c12x2;
signed long si_a1, si_c22x2, si_a2, si_a1x1, si_y1, si_a2x2;
unsigned int uiPadc, uiTadc;
unsigned char uiPH, uiPL, uiTH, uiTL;
};
 
#endif