code stringlengths 1 1.05M | repo_name stringlengths 6 83 | path stringlengths 3 242 | language stringclasses 222
values | license stringclasses 20
values | size int64 1 1.05M |
|---|---|---|---|---|---|
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/machine_pulse.h | C | apache-2.0 | 1,576 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/machine_signal.c | C | apache-2.0 | 6,230 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/machine_signal.h | C | apache-2.0 | 1,444 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/machine_spi.c | C | apache-2.0 | 11,190 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/machine_spi.h | C | apache-2.0 | 3,006 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014-2016 Damien P. George
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/misc.h | C | apache-2.0 | 1,911 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018 Ayke van Laethem
* Copyright (c) 2019-2020 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation fi... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modbluetooth.c | C | apache-2.0 | 72,930 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018 Ayke van Laethem
* Copyright (c) 2019-2020 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation fi... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modbluetooth.h | C | apache-2.0 | 24,915 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modbtree.c | C | apache-2.0 | 13,136 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modframebuf.c | C | apache-2.0 | 37,849 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2019 Damien P. George
* Copyright (c) 2015 Galen Hazelwood
* Copyright (c) 2015-2017 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modlwip.c | C | apache-2.0 | 62,127 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2015-2017 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modonewire.c | C | apache-2.0 | 5,780 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2020 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduasyncio.c | C | apache-2.0 | 12,021 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modubinascii.c | C | apache-2.0 | 8,458 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017-2018 Paul Sokolovsky
* Copyright (c) 2018 Yonatan Goldschmidt
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentat... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moducryptolib.c | C | apache-2.0 | 12,522 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014-2018 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moductypes.c | C | apache-2.0 | 28,152 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduhashlib.c | C | apache-2.0 | 13,512 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduheapq.c | C | apache-2.0 | 4,599 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modujson.c | C | apache-2.0 | 13,568 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modurandom.c | C | apache-2.0 | 8,637 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modure.c | C | apache-2.0 | 15,705 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Damien P. George
* Copyright (c) 2015-2017 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduselect.c | C | apache-2.0 | 13,729 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2015-2019 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modussl_axtls.c | C | apache-2.0 | 11,897 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Linaro Ltd.
* Copyright (c) 2019 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (th... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modussl_mbedtls.c | C | apache-2.0 | 14,950 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Damien P. George
* Copyright (c) 2016-2017 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modutimeq.c | C | apache-2.0 | 7,973 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduwebsocket.c | C | apache-2.0 | 11,159 |
#ifndef MICROPY_INCLUDED_EXTMOD_MODUWEBSOCKET_H
#define MICROPY_INCLUDED_EXTMOD_MODUWEBSOCKET_H
#define FRAME_OPCODE_MASK 0x0f
enum {
FRAME_CONT, FRAME_TXT, FRAME_BIN,
FRAME_CLOSE = 0x8, FRAME_PING, FRAME_PONG
};
#endif // MICROPY_INCLUDED_EXTMOD_MODUWEBSOCKET_H
| YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduwebsocket.h | C | apache-2.0 | 273 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014-2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/moduzlib.c | C | apache-2.0 | 7,410 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/modwebrepl.c | C | apache-2.0 | 12,597 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2020 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Soft... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/mpbthci.c | C | apache-2.0 | 1,451 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/mpbthci.h | C | apache-2.0 | 2,306 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/network_cyw43.c | C | apache-2.0 | 18,853 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/network_cyw43.h | C | apache-2.0 | 1,423 |
// empty
| YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/bsp/bsp.h | C | apache-2.0 | 9 |
// empty
| YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/hal/hal_gpio.h | C | apache-2.0 | 9 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/hal/hal_uart.c | C | apache-2.0 | 3,692 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2020 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Soft... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/hal/hal_uart.h | C | apache-2.0 | 2,113 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Damien P. George
* Copyright (c) 2019-2020 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation fi... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/modbluetooth_nimble.c | C | apache-2.0 | 79,213 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Jim Mussared
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Soft... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/modbluetooth_nimble.h | C | apache-2.0 | 2,976 |
# Makefile directives for Apache Mynewt NimBLE component
ifeq ($(MICROPY_BLUETOOTH_NIMBLE),1)
EXTMOD_DIR = extmod
NIMBLE_EXTMOD_DIR = $(EXTMOD_DIR)/nimble
EXTMOD_SRC_C += $(NIMBLE_EXTMOD_DIR)/modbluetooth_nimble.c
CFLAGS_MOD += -DMICROPY_BLUETOOTH_NIMBLE=1
# Use NimBLE from the submodule in lib/mynewt-nimble by de... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/nimble.mk | Makefile | apache-2.0 | 3,420 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/nimble/nimble_npl_os.c | C | apache-2.0 | 17,014 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/nimble/nimble_npl_os.h | C | apache-2.0 | 3,023 |
#ifndef MICROPY_INCLUDED_EXTMOD_NIMBLE_SYSCFG_H
#define MICROPY_INCLUDED_EXTMOD_NIMBLE_SYSCFG_H
#include "py/mphal.h"
#include "mpnimbleport.h"
void *nimble_malloc(size_t size);
void nimble_free(void *ptr);
void *nimble_realloc(void *ptr, size_t size);
// Redirect NimBLE malloc to the GC heap.
#define malloc(size) ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/nimble/syscfg/syscfg.h | C | apache-2.0 | 7,418 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019 Damien P. George
from .core import *
__version__ = (3, 0, 0)
_attrs = {
"wait_for": "funcs",
"wait_for_ms": "funcs",
"gather": "funcs",
"Event": "event",
"ThreadSafeFlag": "event",
"Lock": "lock",
"open_connection": "stream",... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/__init__.py | Python | apache-2.0 | 709 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019 Damien P. George
from time import ticks_ms as ticks, ticks_diff, ticks_add
import sys, select
# Import TaskQueue and Task, preferring built-in C code over Python code
try:
from _uasyncio import TaskQueue, Task
except:
from .task import TaskQueue,... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/core.py | Python | apache-2.0 | 9,399 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019-2020 Damien P. George
from . import core
# Event class for primitive events that can be waited on, set, and cleared
class Event:
def __init__(self):
self.state = False # False=unset; True=set
self.waiting = core.TaskQueue() # Queue ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/event.py | Python | apache-2.0 | 1,926 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019-2020 Damien P. George
from . import core
async def wait_for(aw, timeout, sleep=core.sleep):
aw = core._promote_to_task(aw)
if timeout is None:
return await aw
def runner(waiter, aw):
nonlocal status, result
try:
... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/funcs.py | Python | apache-2.0 | 2,184 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019-2020 Damien P. George
from . import core
# Lock class for primitive mutex capability
class Lock:
def __init__(self):
# The state can take the following values:
# - 0: unlocked
# - 1: locked
# - <Task>: unlocked but thi... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/lock.py | Python | apache-2.0 | 1,782 |
# This list of frozen files doesn't include task.py because that's provided by the C module.
freeze(
"..",
(
"uasyncio/__init__.py",
"uasyncio/core.py",
"uasyncio/event.py",
"uasyncio/funcs.py",
"uasyncio/lock.py",
"uasyncio/stream.py",
),
opt=3,
)
| YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/manifest.py | Python | apache-2.0 | 313 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019-2020 Damien P. George
from . import core
class Stream:
def __init__(self, s, e={}):
self.s = s
self.e = e
self.out_buf = b""
def get_extra_info(self, v):
return self.e[v]
async def __aenter__(self):
... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/stream.py | Python | apache-2.0 | 4,391 |
# MicroPython uasyncio module
# MIT license; Copyright (c) 2019-2020 Damien P. George
# This file contains the core TaskQueue based on a pairing heap, and the core Task class.
# They can optionally be replaced by C implementations.
from . import core
# pairing-heap meld of 2 heaps; O(1)
def ph_meld(h1, h2):
if ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uasyncio/task.py | Python | apache-2.0 | 5,409 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
* Copyright (c) 2017-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/uos_dupterm.c | C | apache-2.0 | 6,859 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2016 Damien P. George
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/utime_mphal.c | C | apache-2.0 | 4,144 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2016 Damien P. George
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/utime_mphal.h | C | apache-2.0 | 1,890 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs.c | C | apache-2.0 | 19,964 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs.h | C | apache-2.0 | 5,304 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_blockdev.c | C | apache-2.0 | 5,749 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2014 Damien P. George
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation file... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_fat.c | C | apache-2.0 | 15,384 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013, 2014 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* i... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_fat.h | C | apache-2.0 | 1,800 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* Original template for this file comes from:
* Low level disk I/O module skeleton for FatFs, (C)ChaN, 2013
*
* The MIT License (MIT)
*
* Copyright (c) 2013, 2014 Damien P. George
*
* Permission is hereby granted, free of charge, to ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_fat_diskio.c | C | apache-2.0 | 5,668 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013, 2014 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* i... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_fat_file.c | C | apache-2.0 | 10,093 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019-2020 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_lfs.c | C | apache-2.0 | 4,801 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_lfs.h | C | apache-2.0 | 1,675 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019-2020 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_lfsx.c | C | apache-2.0 | 19,584 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019-2020 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_lfsx_file.c | C | apache-2.0 | 8,995 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2017-2018 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_posix.c | C | apache-2.0 | 21,439 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the ... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_posix.h | C | apache-2.0 | 1,653 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2018 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_posix_file.c | C | apache-2.0 | 9,679 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2013-2017 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/vfs_reader.c | C | apache-2.0 | 3,118 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/virtpin.c | C | apache-2.0 | 1,688 |
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2016 Paul Sokolovsky
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the S... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/virtpin.h | C | apache-2.0 | 1,893 |
freeze(".", ("webrepl.py", "webrepl_setup.py", "websocket_helper.py"))
| YifuLiu/AliOS-Things | components/py_engine/engine/extmod/webrepl/manifest.py | Python | apache-2.0 | 71 |
# This module should be imported from REPL, not run from command line.
import socket
import uos
import network
import uwebsocket
import websocket_helper
import _webrepl
listen_s = None
client_s = None
def setup_conn(port, accept_handler):
global listen_s
listen_s = socket.socket()
listen_s.setsockopt(soc... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/webrepl/webrepl.py | Python | apache-2.0 | 2,186 |
import sys
# import uos as os
import os
import machine
RC = "./boot.py"
CONFIG = "./webrepl_cfg.py"
def input_choice(prompt, choices):
while 1:
resp = input(prompt)
if resp in choices:
return resp
def getpass(prompt):
return input(prompt)
def input_pass():
while 1:
... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/webrepl/webrepl_setup.py | Python | apache-2.0 | 2,783 |
try:
import usys as sys
except ImportError:
import sys
try:
import ubinascii as binascii
except:
import binascii
try:
import uhashlib as hashlib
except:
import hashlib
DEBUG = 0
def server_handshake(sock):
clr = sock.makefile("rwb", 0)
l = clr.readline()
# sys.stdout.write(repr(l... | YifuLiu/AliOS-Things | components/py_engine/engine/extmod/webrepl/websocket_helper.py | Python | apache-2.0 | 1,717 |
from __future__ import print_function
import re
import sys
import platform
if platform.python_version_tuple()[0] == '2':
bytes_cons = lambda val, enc=None: bytearray(val)
from htmlentitydefs import codepoint2name
elif platform.python_version_tuple()[0] == '3':
bytes_cons = bytes
from html.entities imp... | YifuLiu/AliOS-Things | components/py_engine/engine/genhdr/gen_qstr.py | Python | apache-2.0 | 2,037 |
# @(#)Makefile.inc 8.2 (Berkeley) 2/21/94
#
CFLAGS+=-D__DBINTERFACE_PRIVATE
.include "${.CURDIR}/db/btree/Makefile.inc"
.include "${.CURDIR}/db/db/Makefile.inc"
.include "${.CURDIR}/db/hash/Makefile.inc"
.include "${.CURDIR}/db/man/Makefile.inc"
.include "${.CURDIR}/db/mpool/Makefile.inc"
.include "${.CURDIR}/db/recno... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/Makefile.inc | Makefile | apache-2.0 | 335 |
# @(#)Makefile 8.9 (Berkeley) 7/14/94
LIBDB= libdb.a
OBJ1= hash.o hash_bigkey.o hash_buf.o hash_func.o hash_log2.o hash_page.o \
hsearch.o ndbm.o
OBJ2= bt_close.o bt_conv.o bt_debug.o bt_delete.o bt_get.o bt_open.o \
bt_overflow.o bt_page.o bt_put.o bt_search.o bt_seq.o bt_split.o \
bt_utils.o
OBJ3= db.o
OBJ4= mpoo... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/Makefile | Makefile | apache-2.0 | 3,354 |
# @(#)Makefile 8.9 (Berkeley) 7/14/94
LIBDB= libdb.a
OBJ1= hash.o hash_bigkey.o hash_buf.o hash_func.o hash_log2.o hash_page.o \
hsearch.o ndbm.o
OBJ2= bt_close.o bt_conv.o bt_debug.o bt_delete.o bt_get.o bt_open.o \
bt_overflow.o bt_page.o bt_put.o bt_search.o bt_seq.o bt_split.o \
bt_utils.o
OBJ3= db.o
OBJ4= mpoo... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/Makefile | Makefile | apache-2.0 | 3,365 |
../../include/cdefs.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/cdefs.h | C | apache-2.0 | 21 |
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copy... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/compat.h | C | apache-2.0 | 7,281 |
../../include/db.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/db.h | C | apache-2.0 | 18 |
../../include/mpool.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/mpool.h | C | apache-2.0 | 21 |
../../include/ndbm.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/ndbm.h | C | apache-2.0 | 20 |
../../include/queue.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/aix.3.2/include/queue.h | C | apache-2.0 | 21 |
../Makefile | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/Makefile | Makefile | apache-2.0 | 11 |
../../include/cdefs.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/cdefs.h | C | apache-2.0 | 21 |
../../include/compat.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/compat.h | C | apache-2.0 | 22 |
/*-
* Copyright (c) 1990, 1993, 1994
* The Regents of the University of California. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the abov... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/db.h | C | apache-2.0 | 7,857 |
../../include/mpool.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/mpool.h | C | apache-2.0 | 21 |
../../include/ndbm.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/ndbm.h | C | apache-2.0 | 20 |
../../include/queue.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsd.4.4/include/queue.h | C | apache-2.0 | 21 |
../Makefile | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/Makefile | Makefile | apache-2.0 | 11 |
/*-
* Copyright (c) 1990 The Regents of the University of California.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/assert.h | C | apache-2.0 | 2,264 |
../../include/cdefs.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/cdefs.h | C | apache-2.0 | 21 |
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copy... | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/compat.h | C | apache-2.0 | 7,284 |
../../include/db.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/db.h | C | apache-2.0 | 18 |
../../include/mpool.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/mpool.h | C | apache-2.0 | 21 |
../../include/ndbm.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/ndbm.h | C | apache-2.0 | 20 |
../../include/queue.h | YifuLiu/AliOS-Things | components/py_engine/engine/lib/berkeley-db-1.xx/PORT/bsdi.1.0/include/queue.h | C | apache-2.0 | 21 |