mirror of https://github.com/ARMmbed/mbed-os.git
commit
d92806c11e
34
.travis.yml
34
.travis.yml
|
|
@ -1,3 +1,19 @@
|
||||||
|
dist: xenial
|
||||||
|
language: python
|
||||||
|
python: 2.7
|
||||||
|
|
||||||
|
install:
|
||||||
|
# Get arm-none-eabi-gcc
|
||||||
|
- sudo add-apt-repository -y ppa:team-gcc-arm-embedded/ppa
|
||||||
|
- sudo apt-get update -qq
|
||||||
|
- sudo apt-get install -qq gcc-arm-embedded
|
||||||
|
# Get dependencies
|
||||||
|
- git clone https://github.com/armmbed/mbed-os.git
|
||||||
|
# Install python dependencies
|
||||||
|
# - python -m pip install --upgrade pip==18.1
|
||||||
|
# - python -m pip install --upgrade setuptools==40.4.3
|
||||||
|
- pip install -r mbed-os/requirements.txt
|
||||||
|
|
||||||
script:
|
script:
|
||||||
# Check that examples compile
|
# Check that examples compile
|
||||||
- sed -n '/``` cpp/,${/```$/q;/```/d;p}' README.md > main.cpp &&
|
- sed -n '/``` cpp/,${/```$/q;/```/d;p}' README.md > main.cpp &&
|
||||||
|
|
@ -8,21 +24,3 @@ script:
|
||||||
PYTHONPATH=mbed-os python mbed-os/tools/make.py -t GCC_ARM -m K82F
|
PYTHONPATH=mbed-os python mbed-os/tools/make.py -t GCC_ARM -m K82F
|
||||||
--source=. --build=BUILD/K82F/GCC_ARM -j0 &&
|
--source=. --build=BUILD/K82F/GCC_ARM -j0 &&
|
||||||
rm main.cpp
|
rm main.cpp
|
||||||
|
|
||||||
# Check that tests compile
|
|
||||||
- rm -r BUILD && PYTHONPATH=mbed-os python mbed-os/tools/test.py
|
|
||||||
-t GCC_ARM -m K82F --source=. --build=BUILD/TESTS/K82F/GCC_ARM -j0
|
|
||||||
-n tests*
|
|
||||||
|
|
||||||
python:
|
|
||||||
- "2.7"
|
|
||||||
|
|
||||||
install:
|
|
||||||
# Get arm-none-eabi-gcc
|
|
||||||
- sudo add-apt-repository -y ppa:terry.guo/gcc-arm-embedded
|
|
||||||
- sudo apt-get update -qq
|
|
||||||
- sudo apt-get install -qq gcc-arm-none-eabi --force-yes
|
|
||||||
# Get dependencies
|
|
||||||
- git clone https://github.com/armmbed/mbed-os.git
|
|
||||||
# Install python dependencies
|
|
||||||
- sudo pip install -r mbed-os/requirements.txt
|
|
||||||
|
|
|
||||||
|
|
@ -147,3 +147,8 @@ bd_size_t I2CEEBlockDevice::size() const
|
||||||
{
|
{
|
||||||
return _size;
|
return _size;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const char *I2CEEBlockDevice::get_type() const
|
||||||
|
{
|
||||||
|
return "I2CEE";
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@
|
||||||
#ifndef MBED_I2CEEPROM_BLOCK_DEVICE_H
|
#ifndef MBED_I2CEEPROM_BLOCK_DEVICE_H
|
||||||
#define MBED_I2CEEPROM_BLOCK_DEVICE_H
|
#define MBED_I2CEEPROM_BLOCK_DEVICE_H
|
||||||
|
|
||||||
#include <mbed.h>
|
#include "mbed.h"
|
||||||
#include "BlockDevice.h"
|
#include "BlockDevice.h"
|
||||||
|
|
||||||
|
|
||||||
|
|
@ -157,6 +157,12 @@ public:
|
||||||
*/
|
*/
|
||||||
virtual bd_size_t size() const;
|
virtual bd_size_t size() const;
|
||||||
|
|
||||||
|
/** Get the BlockDevice class type.
|
||||||
|
*
|
||||||
|
* @return A string representation of the BlockDevice class type.
|
||||||
|
*/
|
||||||
|
virtual const char *get_type() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
I2C * _i2c;
|
I2C * _i2c;
|
||||||
uint32_t _i2c_buffer[sizeof(I2C) / sizeof(uint32_t)];
|
uint32_t _i2c_buffer[sizeof(I2C) / sizeof(uint32_t)];
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue