Skip to content

Instantly share code, notes, and snippets.

View maciejbocianski's full-sized avatar

Maciej Bociański maciejbocianski

  • Poland, Poznań
View GitHub Profile
@maciejbocianski
maciejbocianski / TestFile.h
Created February 2, 2018 14:13
IAR file test
/* mbed Microcontroller Library
* Copyright (c) 2018 ARM Limited
*
* 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
@maciejbocianski
maciejbocianski / critical_section_test.h
Last active January 24, 2018 09:48
hal criticla section test
/* mbed Microcontroller Library
* Copyright (c) 2017 ARM Limited
*
* 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
/* mbed Microcontroller Library
* Copyright (c) 2017 ARM Limited
*
* 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
@maciejbocianski
maciejbocianski / ScopedLock.h
Created November 21, 2017 14:02
ScopedLock 2
/* mbed Microcontroller Library
* Copyright (c) 2017 ARM Limited
*
* 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
@maciejbocianski
maciejbocianski / CriticalSectionLock.h
Created November 21, 2017 09:44
CriticalSectionLock
/*
* PackageLicenseDeclared: Apache-2.0
* Copyright (c) 2017 ARM Limited
*
* 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
*
@maciejbocianski
maciejbocianski / ScopedLock.h
Created November 21, 2017 09:09
ScopedLock
/* mbed Microcontroller Library
* Copyright (c) 2017 ARM Limited
*
* 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
template <typename LockType>
class ScopedLock {
public:
ScopedLock()
{
_lock.lock();
}
~ScopedLock()
{
template <typename LockType>
class ScopedLock {
public:
ScopedLock()
{
_lock.lock();
}
~ScopedLock()
{