knx
ETS configurable knx-stack
datapoint_types.h
Go to the documentation of this file.
1 /*
2  * datapoint_types.h - Conversion functions for datapoint types.
3  *
4  * Copyright (c) 2014 Stefan Taferner <stefan.taferner@gmx.at>
5  *
6  * This program is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License version 3 as
8  * published by the Free Software Foundation.
9  */
10 
11 #pragma once
12 #include <stdint.h>
13 
18 #define INVALID_DPT_FLOAT 2147483647U
19 
28 uint16_t dptToFloat(int32_t value);
29 
37 int32_t dptFromFloat(uint16_t dptValue);
int32_t dptFromFloat(uint16_t dptValue)
Convert a value from 2 uint8_t float (DPT9/EIS5) to integer.
uint16_t dptToFloat(int32_t value)
Convert a value from uint32_t to 2 uint8_t float (DPT9/EIS5).