DevI2C wrappers for Javascript.
Dependents: ST_SENSOR_JS MQTT_JS
DevI2C-js.h@1:9004b187e772, 2017-10-25 (annotated)
- Committer:
- akhtar.syedzeeshan@gmail.com
- Date:
- Wed Oct 25 14:04:24 2017 +0200
- Revision:
- 1:9004b187e772
- Parent:
- 0:948fd0e96aaa
- Child:
- 2:c899857665c6
Added information and disclaimer
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 1 | /** |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 2 | ****************************************************************************** |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 3 | * @file LSM6DSL_JS-js.cpp |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 4 | * @author ST |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 5 | * @version V1.0.0 |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 6 | * @date 25 October 2017 |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 7 | * @brief Implementation of an LSM6DSL Accelerometer and gyroscope sensor for |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 8 | * use with Javascript. |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 9 | ****************************************************************************** |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 10 | * @attention |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 11 | * |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 12 | * <h2><center>© COPYRIGHT(c) 2016 STMicroelectronics</center></h2> |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 13 | * |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 14 | * Redistribution and use in source and binary forms, with or without modification, |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 15 | * are permitted provided that the following conditions are met: |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 16 | * 1. Redistributions of source code must retain the above copyright notice, |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 17 | * this list of conditions and the following disclaimer. |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 18 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 19 | * this list of conditions and the following disclaimer in the documentation |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 20 | * and/or other materials provided with the distribution. |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 21 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 22 | * may be used to endorse or promote products derived from this software |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 23 | * without specific prior written permission. |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 24 | * |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 25 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 26 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 27 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 28 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 29 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 30 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 31 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 32 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 33 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 34 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 35 | * |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 36 | ****************************************************************************** |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 37 | */ |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 38 | |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 39 | #ifndef _DEVI2C_JS_H |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 40 | #define _DEVI2C_JS_H |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 41 | |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 42 | /* Includes ------------------------------------------------------------------*/ |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 43 | #include "DevI2C.h" |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 44 | #include "jerryscript-mbed-library-registry/wrap_tools.h" |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 45 | |
akhtar.syedzeeshan@gmail.com | 1:9004b187e772 | 46 | /* Class Implementation ------------------------------------------------------*/ |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 47 | DECLARE_CLASS_CONSTRUCTOR(DevI2C); |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 48 | |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 49 | // Define a wrapper, we can load the wrapper in `main.cpp`. |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 50 | // This makes it possible to load libraries optionally. |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 51 | DECLARE_JS_WRAPPER_REGISTRATION (DevI2C_JS_library) { |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 52 | REGISTER_CLASS_CONSTRUCTOR(DevI2C); |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 53 | } |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 54 | |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 55 | |
akhtar.syedzeeshan@gmail.com | 0:948fd0e96aaa | 56 | #endif // _DEVI2C_H |