supla-device
Toggle main menu visibility
Loading...
Searching...
No Matches
src
supla-common
lck.h
1
/*
2
Copyright (C) AC SOFTWARE SP. Z O.O.
3
4
This program is free software; you can redistribute it and/or
5
modify it under the terms of the GNU General Public License
6
as published by the Free Software Foundation; either version 2
7
of the License, or (at your option) any later version.
8
9
This program is distributed in the hope that it will be useful,
10
but WITHOUT ANY WARRANTY; without even the implied warranty of
11
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
GNU General Public License for more details.
13
14
You should have received a copy of the GNU General Public License
15
along with this program; if not, write to the Free Software
16
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17
*/
18
19
#ifndef LCK_H_
20
#define LCK_H_
21
22
#if defined(ESP8266)
23
#include <mem.h>
24
#define LCK_ICACHE_FLASH ICACHE_FLASH_ATTR
25
#endif
26
27
#if defined(ARDUINO)
28
#undef LCK_ICACHE_FLASH
29
#endif
/*defined(ARDUINO)*/
30
31
#ifndef LCK_ICACHE_FLASH
32
#define LCK_ICACHE_FLASH
33
#endif
/*LCK_ICACHE_FLASH*/
34
35
#ifdef __cplusplus
36
extern
"C"
{
37
#endif
38
39
void
LCK_ICACHE_FLASH lck_lock(
void
*lck);
40
41
char
LCK_ICACHE_FLASH lck_lock_with_timeout(
void
*lck,
int
timeout_sec);
42
void
LCK_ICACHE_FLASH lck_unlock(
void
*lck);
43
int
LCK_ICACHE_FLASH lck_unlock_r(
void
*lck,
int
result);
44
void
*LCK_ICACHE_FLASH lck_init(
void
);
45
void
LCK_ICACHE_FLASH lck_free(
void
*lck);
46
47
#ifdef __cplusplus
48
}
49
#endif
50
51
#endif
/* LCK_H_ */
Generated by
1.17.0