mirror of
https://gitee.com/Lyon1998/pikapython.git
synced 2025-01-29 17:22:56 +08:00
auto release packages form linux port
This commit is contained in:
parent
b9a0109c61
commit
ee9d1e696a
@ -1,2 +1,3 @@
|
|||||||
gitpython
|
gitpython
|
||||||
toml
|
toml
|
||||||
|
sh
|
||||||
|
@ -5,7 +5,7 @@ img.read("test/assets/test2.jpg")
|
|||||||
|
|
||||||
cv.Converter.toGray(img)
|
cv.Converter.toGray(img)
|
||||||
data = img.data()
|
data = img.data()
|
||||||
print(str(binascii.b2a_hex(img.data())))
|
print(binascii.b2a_hex(img.data()).decode())
|
||||||
cv.Converter.toBMP(img)
|
cv.Converter.toBMP(img)
|
||||||
img.write("test/out/test.bmp")
|
img.write("test/out/test.bmp")
|
||||||
|
|
||||||
|
@ -16,3 +16,4 @@ class Test:
|
|||||||
test = Test()
|
test = Test()
|
||||||
while test._val != 3:
|
while test._val != 3:
|
||||||
time.sleep(0.1)
|
time.sleep(0.1)
|
||||||
|
time.sleep(0.1)
|
||||||
|
@ -4,5 +4,4 @@ wlan = network.WLAN(network.STA_IF)
|
|||||||
wlan.active(True)
|
wlan.active(True)
|
||||||
wlan.connect('testssid', 'testpassword')
|
wlan.connect('testssid', 'testpassword')
|
||||||
wlan.isconnected()
|
wlan.isconnected()
|
||||||
wlan.ifconfig()
|
|
||||||
wlan.close()
|
wlan.close()
|
||||||
|
@ -122,7 +122,11 @@ class Transforms:
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def rotateDown(image: Image):
|
def rotateDown(image: Image):
|
||||||
"""Rotate the image """
|
"""Rotate the image """
|
||||||
def threshold(image: Image, thre: int, maxval: int, thresholdType: int):
|
def threshold(
|
||||||
|
image: Image,
|
||||||
|
thre: int,
|
||||||
|
maxval: int,
|
||||||
|
thresholdType: int):
|
||||||
"""
|
"""
|
||||||
0:THRESH_BINARY
|
0:THRESH_BINARY
|
||||||
1:THRESH_BINARY_INV
|
1:THRESH_BINARY_INV
|
||||||
@ -144,7 +148,11 @@ class Transforms:
|
|||||||
TODO:
|
TODO:
|
||||||
1:BILINEAR
|
1:BILINEAR
|
||||||
"""
|
"""
|
||||||
def adaptiveThreshold(image: Image, maxval: int, subsize: int, c: int, method: int):
|
def adaptiveThreshold(image: Image,
|
||||||
|
maxval: int,
|
||||||
|
subsize: int,
|
||||||
|
c: int,
|
||||||
|
method: int):
|
||||||
"""
|
"""
|
||||||
AdaptiveThreshold
|
AdaptiveThreshold
|
||||||
method
|
method
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
#include "TemplateDevice.h"
|
|
||||||
|
|
||||||
extern PikaEventListener* g_pika_device_event_listener;
|
|
||||||
|
|
||||||
void TemplateDevice___del__(PikaObj *self){
|
|
||||||
pks_eventLisener_deinit(&g_pika_device_event_listener);
|
|
||||||
}
|
|
@ -1,85 +0,0 @@
|
|||||||
import PikaStdDevice
|
|
||||||
|
|
||||||
|
|
||||||
class GPIO(PikaStdDevice.GPIO):
|
|
||||||
# overrid
|
|
||||||
def platformHigh(self): ...
|
|
||||||
def platformLow(self): ...
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformSetMode(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
def eventTest(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class Time(PikaStdDevice.Time):
|
|
||||||
# override
|
|
||||||
def sleep_s(self, s: int): ...
|
|
||||||
def sleep_ms(self, ms: int): ...
|
|
||||||
def platformGetTick(): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class ADC(PikaStdDevice.ADC):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class UART(PikaStdDevice.UART):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformWrite(self): ...
|
|
||||||
def platformWriteBytes(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformReadBytes(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class IIC(PikaStdDevice.IIC):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformWrite(self): ...
|
|
||||||
def platformWriteBytes(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformReadBytes(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class PWM(PikaStdDevice.PWM):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformSetFrequency(self): ...
|
|
||||||
def platformSetDuty(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class SPI(PikaStdDevice.SPI):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformWrite(self): ...
|
|
||||||
def platformWriteBytes(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformReadBytes(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
class CAN(PikaStdDevice.CAN):
|
|
||||||
# override
|
|
||||||
def platformEnable(self): ...
|
|
||||||
def platformWrite(self): ...
|
|
||||||
def platformWriteBytes(self): ...
|
|
||||||
def platformRead(self): ...
|
|
||||||
def platformReadBytes(self): ...
|
|
||||||
def platformDisable(self): ...
|
|
||||||
def platformGetEventId(self): ...
|
|
||||||
|
|
||||||
|
|
||||||
def __del__(self): ...
|
|
@ -1,17 +0,0 @@
|
|||||||
#include "TemplateDevice_ADC.h"
|
|
||||||
|
|
||||||
void TemplateDevice_ADC_platformDisable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_ADC_platformEnable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_ADC_platformRead(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_ADC_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
#include "TemplateDevice_CAN.h"
|
|
||||||
|
|
||||||
void TemplateDevice_CAN_platformDisable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_CAN_platformEnable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_CAN_platformRead(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_CAN_platformReadBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_CAN_platformWrite(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_CAN_platformWriteBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_CAN_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,28 +0,0 @@
|
|||||||
#include "TemplateDevice_GPIO.h"
|
|
||||||
|
|
||||||
void TemplateDevice_GPIO_platformDisable(PikaObj* self) {}
|
|
||||||
void TemplateDevice_GPIO_platformEnable(PikaObj* self) {}
|
|
||||||
void TemplateDevice_GPIO_platformHigh(PikaObj* self) {}
|
|
||||||
void TemplateDevice_GPIO_platformLow(PikaObj* self) {}
|
|
||||||
void TemplateDevice_GPIO_platformRead(PikaObj* self) {}
|
|
||||||
void TemplateDevice_GPIO_platformSetMode(PikaObj* self) {}
|
|
||||||
|
|
||||||
const uint32_t GPIO_PA8_EVENT_ID = 0x08;
|
|
||||||
void TemplateDevice_GPIO_platformGetEventId(PikaObj* self) {
|
|
||||||
char* pin = obj_getStr(self, "pin");
|
|
||||||
if (strEqu(pin, "PA8")) {
|
|
||||||
obj_setInt(self, "eventId", GPIO_PA8_EVENT_ID);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
extern PikaEventListener* g_pika_device_event_listener;
|
|
||||||
#define EVENT_SIGNAL_IO_RISING_EDGE 0x01
|
|
||||||
#define EVENT_SIGNAL_IO_FALLING_EDGE 0x02
|
|
||||||
#define GPIO_PA8_EVENT_ID 0x08
|
|
||||||
|
|
||||||
void TemplateDevice_GPIO_eventTest(PikaObj* self) {
|
|
||||||
pks_eventLisener_sendSignal(g_pika_device_event_listener, GPIO_PA8_EVENT_ID,
|
|
||||||
EVENT_SIGNAL_IO_FALLING_EDGE);
|
|
||||||
pks_eventLisener_sendSignal(g_pika_device_event_listener, GPIO_PA8_EVENT_ID,
|
|
||||||
EVENT_SIGNAL_IO_RISING_EDGE);
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
#include "TemplateDevice_IIC.h"
|
|
||||||
|
|
||||||
void TemplateDevice_IIC_platformDisable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_IIC_platformEnable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_IIC_platformRead(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_IIC_platformReadBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_IIC_platformWrite(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_IIC_platformWriteBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_IIC_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
#include "TemplateDevice_PWM.h"
|
|
||||||
|
|
||||||
void TemplateDevice_PWM_platformDisable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_PWM_platformEnable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_PWM_platformSetDuty(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_PWM_platformSetFrequency(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_PWM_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
#include "TemplateDevice_SPI.h"
|
|
||||||
|
|
||||||
void TemplateDevice_SPI_platformDisable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_SPI_platformEnable(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_SPI_platformRead(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_SPI_platformReadBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_SPI_platformWrite(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_SPI_platformWriteBytes(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_SPI_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,18 +0,0 @@
|
|||||||
#include "TemplateDevice_Time.h"
|
|
||||||
|
|
||||||
void TemplateDevice_Time_sleep_ms(PikaObj *self, int ms){
|
|
||||||
|
|
||||||
}
|
|
||||||
void TemplateDevice_Time_sleep_s(PikaObj *self, int s){
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
static volatile uint64_t tick_ms = 0;
|
|
||||||
void TemplateDevice_Time_platformGetTick(PikaObj *self){
|
|
||||||
tick_ms += 50;
|
|
||||||
obj_setInt(self, "tick", tick_ms);
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_Time_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
#include "TemplateDevice_UART.h"
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
void TemplateDevice_UART_platformDisable(PikaObj* self) {}
|
|
||||||
void TemplateDevice_UART_platformEnable(PikaObj* self) {}
|
|
||||||
void TemplateDevice_UART_platformRead(PikaObj* self) {}
|
|
||||||
void TemplateDevice_UART_platformReadBytes(PikaObj* self) {
|
|
||||||
int length = obj_getInt(self, "length");
|
|
||||||
uint8_t bytes_buff[] = {0x00, 0x01, 0x02, 0x03, 0x04,
|
|
||||||
0x05, 0x06, 0x07, 0x08};
|
|
||||||
obj_setBytes(self, "readData", bytes_buff, length);
|
|
||||||
}
|
|
||||||
void TemplateDevice_UART_platformWrite(PikaObj* self) {}
|
|
||||||
void TemplateDevice_UART_platformWriteBytes(PikaObj* self) {
|
|
||||||
uint8_t* bytes = obj_getBytes(self, "writeData");
|
|
||||||
int length = obj_getBytesSize(self, "writeData");
|
|
||||||
printf("[debug]: write to uart: [ ");
|
|
||||||
for (int i = 0; i < length; i++) {
|
|
||||||
printf("0x%02X ", bytes[i]);
|
|
||||||
}
|
|
||||||
printf("]\n");
|
|
||||||
}
|
|
||||||
|
|
||||||
void TemplateDevice_UART_platformGetEventId(PikaObj *self){
|
|
||||||
|
|
||||||
}
|
|
@ -13,7 +13,7 @@ static int hex2int(char c) {
|
|||||||
Arg* binascii_a2b_hex(PikaObj* self, char* val) {
|
Arg* binascii_a2b_hex(PikaObj* self, char* val) {
|
||||||
/* a2b_hex */
|
/* a2b_hex */
|
||||||
int len = strGetSize(val);
|
int len = strGetSize(val);
|
||||||
Arg* ret = arg_setBytes(NULL, "", NULL, len / 2);
|
Arg* ret = arg_newBytes(NULL, len / 2);
|
||||||
uint8_t* res_hex = arg_getBytes(ret);
|
uint8_t* res_hex = arg_getBytes(ret);
|
||||||
for (int i = 0; i < len; i += 2) {
|
for (int i = 0; i < len; i += 2) {
|
||||||
res_hex[i / 2] = (hex2int(val[i]) << 4) | hex2int(val[i + 1]);
|
res_hex[i / 2] = (hex2int(val[i]) << 4) | hex2int(val[i + 1]);
|
||||||
@ -26,11 +26,11 @@ Arg* binascii_b2a_hex(PikaObj* self, Arg* val) {
|
|||||||
if (arg_getType(val) != ARG_TYPE_BYTES) {
|
if (arg_getType(val) != ARG_TYPE_BYTES) {
|
||||||
obj_setErrorCode(self, PIKA_RES_ERR_RUNTIME_ERROR);
|
obj_setErrorCode(self, PIKA_RES_ERR_RUNTIME_ERROR);
|
||||||
__platform_printf("TypeError: cannot convert value to bytes\r\n");
|
__platform_printf("TypeError: cannot convert value to bytes\r\n");
|
||||||
return arg_setNull(NULL);
|
return arg_newNull();
|
||||||
}
|
}
|
||||||
|
|
||||||
/* b2a_hex */
|
/* b2a_hex */
|
||||||
Arg* hex_str = arg_setStr(NULL, "", "");
|
Arg* hex_str = arg_newStr("");
|
||||||
for (int i = 0; i < (int)arg_getBytesSize(val); i++) {
|
for (int i = 0; i < (int)arg_getBytesSize(val); i++) {
|
||||||
uint8_t* bytes = arg_getBytes(val);
|
uint8_t* bytes = arg_getBytes(val);
|
||||||
uint8_t byte = bytes[i];
|
uint8_t byte = bytes[i];
|
||||||
@ -38,7 +38,7 @@ Arg* binascii_b2a_hex(PikaObj* self, Arg* val) {
|
|||||||
__platform_sprintf(hex_byte, "%02X", byte);
|
__platform_sprintf(hex_byte, "%02X", byte);
|
||||||
hex_str = arg_strAppend(hex_str, hex_byte);
|
hex_str = arg_strAppend(hex_str, hex_byte);
|
||||||
}
|
}
|
||||||
Arg* hex_bytes = arg_setBytes(NULL, "", (uint8_t*)arg_getStr(hex_str),
|
Arg* hex_bytes = arg_newBytes((uint8_t*)arg_getStr(hex_str),
|
||||||
strGetSize(arg_getStr(hex_str)));
|
strGetSize(arg_getStr(hex_str)));
|
||||||
arg_deinit(hex_str);
|
arg_deinit(hex_str);
|
||||||
return hex_bytes;
|
return hex_bytes;
|
||||||
|
@ -56,7 +56,7 @@ void ctypes_create_string_buffer___init__(PikaObj* self, int size) {
|
|||||||
uint8_t* buffer;
|
uint8_t* buffer;
|
||||||
obj_setBytes(self, "raw", NULL, size);
|
obj_setBytes(self, "raw", NULL, size);
|
||||||
buffer = obj_getBytes(self, "raw");
|
buffer = obj_getBytes(self, "raw");
|
||||||
__platform_printf("0x%x", &buffer);
|
__platform_printf("0x%lx", (uintptr_t)&buffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
int ctypes_create_string_buffer___getitem__(PikaObj* self, int __key) {
|
int ctypes_create_string_buffer___getitem__(PikaObj* self, int __key) {
|
||||||
@ -98,7 +98,6 @@ void ctypes_c_buffer___init__(PikaObj *self, Arg* value, int size){
|
|||||||
strGetSize((char*)value_buffer) + 1);
|
strGetSize((char*)value_buffer) + 1);
|
||||||
} else {
|
} else {
|
||||||
__platform_printf("value type is not support!");
|
__platform_printf("value type is not support!");
|
||||||
while (1)
|
__platform_panic_handle();
|
||||||
;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -51,8 +51,13 @@
|
|||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
#include <stddef.h>
|
#include <stddef.h>
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
#include "PikaObj.h"
|
||||||
#include "pika_adapter_rtt.h"
|
#include "pika_adapter_rtt.h"
|
||||||
|
|
||||||
|
#if !PIKASCRIPT_VERSION_REQUIRE_MINIMUN(1, 12, 0)
|
||||||
|
#error "pika_vsnprintf.c requires at least PikaScript 1.12.0"
|
||||||
|
#endif
|
||||||
|
|
||||||
// 'ntoa' conversion buffer size, this must be big enough to hold one converted
|
// 'ntoa' conversion buffer size, this must be big enough to hold one converted
|
||||||
// numeric number including padded zeros (dynamically created on stack)
|
// numeric number including padded zeros (dynamically created on stack)
|
||||||
#ifndef PRINTF_INTEGER_BUFFER_SIZE
|
#ifndef PRINTF_INTEGER_BUFFER_SIZE
|
||||||
@ -486,19 +491,17 @@ struct scaling_factor {
|
|||||||
// to divide by it
|
// to divide by it
|
||||||
};
|
};
|
||||||
|
|
||||||
static double apply_scaling(double num, struct scaling_factor normalization) {
|
double apply_scaling(double num, struct scaling_factor normalization) {
|
||||||
return normalization.multiply ? num * normalization.raw_factor
|
return normalization.multiply ? num * normalization.raw_factor
|
||||||
: num / normalization.raw_factor;
|
: num / normalization.raw_factor;
|
||||||
}
|
}
|
||||||
|
|
||||||
static double unapply_scaling(double normalized,
|
double unapply_scaling(double normalized, struct scaling_factor normalization) {
|
||||||
struct scaling_factor normalization) {
|
|
||||||
return normalization.multiply ? normalized / normalization.raw_factor
|
return normalization.multiply ? normalized / normalization.raw_factor
|
||||||
: normalized * normalization.raw_factor;
|
: normalized * normalization.raw_factor;
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct scaling_factor update_normalization(
|
struct scaling_factor update_normalization(struct scaling_factor sf,
|
||||||
struct scaling_factor sf,
|
|
||||||
double extra_multiplicative_factor) {
|
double extra_multiplicative_factor) {
|
||||||
struct scaling_factor result;
|
struct scaling_factor result;
|
||||||
if (sf.multiply) {
|
if (sf.multiply) {
|
||||||
@ -1258,16 +1261,10 @@ static int __vsnprintf(out_fct_type out,
|
|||||||
*
|
*
|
||||||
* @return The number of characters actually written to buffer.
|
* @return The number of characters actually written to buffer.
|
||||||
*/
|
*/
|
||||||
static int pika_vsnprintf(char* buf,
|
|
||||||
rt_size_t size,
|
|
||||||
const char* fmt,
|
|
||||||
va_list args) {
|
|
||||||
return __vsnprintf(out_buffer, buf, size, fmt, args);
|
|
||||||
}
|
|
||||||
|
|
||||||
int __platform_vsnprintf(char* buff,
|
int pika_platform_vsnprintf(char* buff,
|
||||||
size_t size,
|
size_t size,
|
||||||
const char* fmt,
|
const char* fmt,
|
||||||
va_list args) {
|
va_list args) {
|
||||||
return pika_vsnprintf(buff, size, fmt, args);
|
return __vsnprintf(out_buffer, buff, size, fmt, args);
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,7 @@ void pika_lua_eval(PikaObj* self, char* cmd) {
|
|||||||
int res = luaL_dostring(pika_L, cmd);
|
int res = luaL_dostring(pika_L, cmd);
|
||||||
if (LUA_OK != res) {
|
if (LUA_OK != res) {
|
||||||
obj_setErrorCode(self, PIKA_RES_ERR_OPERATION_FAILED);
|
obj_setErrorCode(self, PIKA_RES_ERR_OPERATION_FAILED);
|
||||||
obj_setSysOut(self, "Error: Lua dostring faild.\r\n");
|
obj_setSysOut(self, "Error: Lua dostring failed.\r\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
#include <time.h>
|
#include <time.h>
|
||||||
|
|
||||||
void random___init__(PikaObj *self){
|
void random___init__(PikaObj *self){
|
||||||
srand(pika_platform_getTick());
|
srand(pika_platform_get_tick());
|
||||||
}
|
}
|
||||||
|
|
||||||
int random_randint(PikaObj *self, int a, int b){
|
int random_randint(PikaObj *self, int a, int b){
|
||||||
|
@ -1,93 +0,0 @@
|
|||||||
PCRE LICENCE
|
|
||||||
------------
|
|
||||||
|
|
||||||
PCRE is a library of functions to support regular expressions whose syntax
|
|
||||||
and semantics are as close as possible to those of the Perl 5 language.
|
|
||||||
|
|
||||||
Release 8 of PCRE is distributed under the terms of the "BSD" licence, as
|
|
||||||
specified below. The documentation for PCRE, supplied in the "doc"
|
|
||||||
directory, is distributed under the same terms as the software itself. The data
|
|
||||||
in the testdata directory is not copyrighted and is in the public domain.
|
|
||||||
|
|
||||||
The basic library functions are written in C and are freestanding. Also
|
|
||||||
included in the distribution is a set of C++ wrapper functions, and a
|
|
||||||
just-in-time compiler that can be used to optimize pattern matching. These
|
|
||||||
are both optional features that can be omitted when the library is built.
|
|
||||||
|
|
||||||
|
|
||||||
THE BASIC LIBRARY FUNCTIONS
|
|
||||||
---------------------------
|
|
||||||
|
|
||||||
Written by: Philip Hazel
|
|
||||||
Email local part: Philip.Hazel
|
|
||||||
Email domain: gmail.com
|
|
||||||
|
|
||||||
University of Cambridge Computing Service,
|
|
||||||
Cambridge, England.
|
|
||||||
|
|
||||||
Copyright (c) 1997-2021 University of Cambridge
|
|
||||||
All rights reserved.
|
|
||||||
|
|
||||||
|
|
||||||
PCRE JUST-IN-TIME COMPILATION SUPPORT
|
|
||||||
-------------------------------------
|
|
||||||
|
|
||||||
Written by: Zoltan Herczeg
|
|
||||||
Email local part: hzmester
|
|
||||||
Email domain: freemail.hu
|
|
||||||
|
|
||||||
Copyright(c) 2010-2021 Zoltan Herczeg
|
|
||||||
All rights reserved.
|
|
||||||
|
|
||||||
|
|
||||||
STACK-LESS JUST-IN-TIME COMPILER
|
|
||||||
--------------------------------
|
|
||||||
|
|
||||||
Written by: Zoltan Herczeg
|
|
||||||
Email local part: hzmester
|
|
||||||
Email domain: freemail.hu
|
|
||||||
|
|
||||||
Copyright(c) 2009-2021 Zoltan Herczeg
|
|
||||||
All rights reserved.
|
|
||||||
|
|
||||||
|
|
||||||
THE C++ WRAPPER FUNCTIONS
|
|
||||||
-------------------------
|
|
||||||
|
|
||||||
Contributed by: Google Inc.
|
|
||||||
|
|
||||||
Copyright (c) 2007-2012, Google Inc.
|
|
||||||
All rights reserved.
|
|
||||||
|
|
||||||
|
|
||||||
THE "BSD" LICENCE
|
|
||||||
-----------------
|
|
||||||
|
|
||||||
Redistribution and use in source and binary forms, with or without
|
|
||||||
modification, are permitted provided that the following conditions are met:
|
|
||||||
|
|
||||||
* Redistributions of source code must retain the above copyright notice,
|
|
||||||
this list of conditions and the following disclaimer.
|
|
||||||
|
|
||||||
* Redistributions in binary form must reproduce the above copyright
|
|
||||||
notice, this list of conditions and the following disclaimer in the
|
|
||||||
documentation and/or other materials provided with the distribution.
|
|
||||||
|
|
||||||
* Neither the name of the University of Cambridge nor the name of Google
|
|
||||||
Inc. nor the names of their contributors may be used to endorse or
|
|
||||||
promote products derived from this software without specific prior
|
|
||||||
written permission.
|
|
||||||
|
|
||||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
||||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
||||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
|
||||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
||||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
||||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
||||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
||||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
||||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
||||||
POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
|
|
||||||
End
|
|
@ -13,9 +13,7 @@ static void _do_sleep_ms_tick(uint32_t ms) {
|
|||||||
uint32_t tick = pika_platform_get_tick();
|
uint32_t tick = pika_platform_get_tick();
|
||||||
while (pika_platform_get_tick() - tick < ms) {
|
while (pika_platform_get_tick() - tick < ms) {
|
||||||
#if PIKA_EVENT_ENABLE
|
#if PIKA_EVENT_ENABLE
|
||||||
// _VMEvent_pickupEvent();
|
_VMEvent_pickupEvent();
|
||||||
//! can not pickup event in this function, because it will cause the GIL
|
|
||||||
//! lock error.
|
|
||||||
#endif
|
#endif
|
||||||
pika_platform_thread_delay();
|
pika_platform_thread_delay();
|
||||||
}
|
}
|
||||||
|
@ -78,11 +78,11 @@ class TestCase:
|
|||||||
mem_before = mem.getNow()
|
mem_before = mem.getNow()
|
||||||
self.test_fn()
|
self.test_fn()
|
||||||
mem_after = mem.getNow()
|
mem_after = mem.getNow()
|
||||||
print("[ OK ] %s.%s" % (suite_name, name))
|
print("\x1b[1m\x1b[32m[ OK ] %s.%s\x1b[0m" % (suite_name, name))
|
||||||
if mem_after != mem_before:
|
if mem_after != mem_before:
|
||||||
print("[ MEM LACK ]", mem_after - mem_before)
|
print("\x1b[33m[ MEM LACK ]", mem_after - mem_before,"\x1b[0m")
|
||||||
except:
|
except:
|
||||||
print("[ FAILED ] %s.%s" % (suite_name, name))
|
print("\x1b[1m\x1b[31m[ FAILED ]\x1b[0m %s.%s" % (suite_name, name))
|
||||||
result.errorsNum += 1
|
result.errorsNum += 1
|
||||||
|
|
||||||
|
|
||||||
@ -109,13 +109,12 @@ class TextTestRunner:
|
|||||||
print('')
|
print('')
|
||||||
print('[==========]')
|
print('[==========]')
|
||||||
if res.failuresNum > 0 or res.errorsNum > 0:
|
if res.failuresNum > 0 or res.errorsNum > 0:
|
||||||
print("[ FAILED ] (%d errors, %d failures)" % (
|
print("\x1b[1m\x1b[31m[ FAILED ](%d errors, %d failures)\x1b[0m" % (res.errorsNum, res.failuresNum))
|
||||||
res.errorsNum, res.failuresNum))
|
|
||||||
else:
|
else:
|
||||||
msg = ""
|
msg = ""
|
||||||
if res.skippedNum > 0:
|
if res.skippedNum > 0:
|
||||||
msg += " (skipped=%d)" % res.skippedNum
|
msg += " (skipped=%d)" % res.skippedNum
|
||||||
print(msg)
|
print(msg)
|
||||||
print("[ PASSED ] %d tests" % res.testsRun)
|
print("\x1b[1m\x1b[32m[ PASSED ] %d tests\x1b[0m" % res.testsRun)
|
||||||
|
|
||||||
return res
|
return res
|
||||||
|
106
packages.toml
106
packages.toml
@ -76,7 +76,8 @@ releases = [
|
|||||||
"v1.11.7 97b8268a31f195092a9ec1d848fbe49168c42c19",
|
"v1.11.7 97b8268a31f195092a9ec1d848fbe49168c42c19",
|
||||||
"v1.11.8 1a66a70893702174294214d227aee3ec8e4498af",
|
"v1.11.8 1a66a70893702174294214d227aee3ec8e4498af",
|
||||||
"v1.11.9 b2f397a990f0aa88129104d460174339531ee808",
|
"v1.11.9 b2f397a990f0aa88129104d460174339531ee808",
|
||||||
"v1.12.0 eb519fb78ed769c8862577713fd80be882d09457"
|
"v1.12.0 eb519fb78ed769c8862577713fd80be882d09457",
|
||||||
|
"v1.12.1 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -145,7 +146,8 @@ releases = [
|
|||||||
"v1.11.7 97b8268a31f195092a9ec1d848fbe49168c42c19",
|
"v1.11.7 97b8268a31f195092a9ec1d848fbe49168c42c19",
|
||||||
"v1.11.8 1a66a70893702174294214d227aee3ec8e4498af",
|
"v1.11.8 1a66a70893702174294214d227aee3ec8e4498af",
|
||||||
"v1.11.9 b2f397a990f0aa88129104d460174339531ee808",
|
"v1.11.9 b2f397a990f0aa88129104d460174339531ee808",
|
||||||
"v1.12.0 eb519fb78ed769c8862577713fd80be882d09457"
|
"v1.12.0 eb519fb78ed769c8862577713fd80be882d09457",
|
||||||
|
"v1.12.1 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -184,7 +186,8 @@ releases = [
|
|||||||
"v2.3.2 94624f9a4af756c597291ed0646c446ecf25ac16",
|
"v2.3.2 94624f9a4af756c597291ed0646c446ecf25ac16",
|
||||||
"v2.3.3 5282cff66fe8f003c75fd82c54c0144aa7da8277",
|
"v2.3.3 5282cff66fe8f003c75fd82c54c0144aa7da8277",
|
||||||
"v2.3.4 69cea1d7188b35b84d819ed8cb8f41b3a64d39d1",
|
"v2.3.4 69cea1d7188b35b84d819ed8cb8f41b3a64d39d1",
|
||||||
"v2.3.5 cd0029b6d1b4340b252532fcee1320667231038c"
|
"v2.3.5 cd0029b6d1b4340b252532fcee1320667231038c",
|
||||||
|
"v2.3.6 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -193,7 +196,7 @@ releases = [
|
|||||||
"v0.0.1 31146e2395e80b5785a4b2e526913a4590160e66",
|
"v0.0.1 31146e2395e80b5785a4b2e526913a4590160e66",
|
||||||
"v0.1.0 793634882044af25f30bb59c6511c615e56f85c5",
|
"v0.1.0 793634882044af25f30bb59c6511c615e56f85c5",
|
||||||
"v0.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
"v0.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
||||||
"v0.2.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v0.2.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -201,7 +204,7 @@ name = "PikaCV"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 b463e812bf0334b55835a3b31cda0c2f6c526e06",
|
"v0.0.1 b463e812bf0334b55835a3b31cda0c2f6c526e06",
|
||||||
"v0.1.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
"v0.1.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
||||||
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -209,14 +212,14 @@ name = "unittest"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 cd6dfbbb714228e7e0f147515d58450644e7dadf",
|
"v0.1.0 cd6dfbbb714228e7e0f147515d58450644e7dadf",
|
||||||
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
"v0.1.2 2aafbbdc84eed84edcf5dcd7462a842a14f26a92"
|
"v0.1.2 2aafbbdc84eed84edcf5dcd7462a842a14f26a92",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "re"
|
name = "re"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 87da4d26d1ebf9525f66e9fe7acd5ea62f9b7f74",
|
"v0.1.0 87da4d26d1ebf9525f66e9fe7acd5ea62f9b7f74",
|
||||||
"v0.1.1 728e9dce9ad2c47d5ac16165a583a794043a2e2b"
|
"v0.1.1 728e9dce9ad2c47d5ac16165a583a794043a2e2b",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -225,14 +228,15 @@ releases = [
|
|||||||
"v0.1.0 f09ea25237cd35a27fd071198ff771c8b4a088ad",
|
"v0.1.0 f09ea25237cd35a27fd071198ff771c8b4a088ad",
|
||||||
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
"v0.1.2 6898f52a71e3a43b3126a73487770370a4a7f02c",
|
"v0.1.2 6898f52a71e3a43b3126a73487770370a4a7f02c",
|
||||||
"v0.1.3 2aafbbdc84eed84edcf5dcd7462a842a14f26a92"
|
"v0.1.3 2aafbbdc84eed84edcf5dcd7462a842a14f26a92",
|
||||||
|
"v0.1.4 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "random"
|
name = "random"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 7244267b6839b8af2238b6cdd9a73e4a3aebb347",
|
"v0.1.0 7244267b6839b8af2238b6cdd9a73e4a3aebb347",
|
||||||
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v0.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -240,7 +244,7 @@ name = "configparser"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 d3a9f6e226bb9cfccbfc588cc465672cefea9e82",
|
"v0.1.0 d3a9f6e226bb9cfccbfc588cc465672cefea9e82",
|
||||||
"v0.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
"v0.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
||||||
"v0.2.1 5fa138c9c19a315d66d8e02fa5901479e30ca892"
|
"v0.2.1 5fa138c9c19a315d66d8e02fa5901479e30ca892",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -251,12 +255,12 @@ releases = [
|
|||||||
"v1.0.0 cbde99793b1e631ab7f54775cba3f5372895b560",
|
"v1.0.0 cbde99793b1e631ab7f54775cba3f5372895b560",
|
||||||
"v1.0.1 5148412411e2de0d23e9c5857b0b4843f479a5be",
|
"v1.0.1 5148412411e2de0d23e9c5857b0b4843f479a5be",
|
||||||
"v1.1.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
"v1.1.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
||||||
"v1.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v1.1.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "binascii"
|
name = "binascii"
|
||||||
releases = [ "v0.0.1 88896715867c2a89df3e3b733cba38cc84f5347c" ]
|
releases = ["v0.0.1 88896715867c2a89df3e3b733cba38cc84f5347c"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pika_cjson"
|
name = "pika_cjson"
|
||||||
@ -267,7 +271,7 @@ releases = [
|
|||||||
"v1.1.1 68b28c780861190639452ed0642e2f4064fa44c3",
|
"v1.1.1 68b28c780861190639452ed0642e2f4064fa44c3",
|
||||||
"v1.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
"v1.2.0 211569c5a0169dbb700885d21fbbe0c678126e9e",
|
||||||
"v1.2.1 4ed606173318d9d5e405b1fef03f217d1b7c8ccc",
|
"v1.2.1 4ed606173318d9d5e405b1fef03f217d1b7c8ccc",
|
||||||
"v1.2.2 0b5be3c57c4e0355bd6fc77c1b22f833eec27060"
|
"v1.2.2 0b5be3c57c4e0355bd6fc77c1b22f833eec27060",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -287,12 +291,12 @@ releases = [
|
|||||||
"v0.4.1 6f5c4bfae50fc5ae347609e58650f2d185171f9f",
|
"v0.4.1 6f5c4bfae50fc5ae347609e58650f2d185171f9f",
|
||||||
"v0.4.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
"v0.4.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
"v0.4.3 312e708525fdb887ea39cc28652bbdae04675fc8",
|
"v0.4.3 312e708525fdb887ea39cc28652bbdae04675fc8",
|
||||||
"v0.4.4 fe6d343b613badcf62854c560bb689ca36007328"
|
"v0.4.4 fe6d343b613badcf62854c560bb689ca36007328",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pika_lua"
|
name = "pika_lua"
|
||||||
releases = [ "v0.0.1 b5da16e285a378a74fa7b7734cdd89be703d6f07" ]
|
releases = ["v0.0.1 b5da16e285a378a74fa7b7734cdd89be703d6f07"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pikaRTThread"
|
name = "pikaRTThread"
|
||||||
@ -302,14 +306,14 @@ releases = [
|
|||||||
"v1.1.1 ac4247e5fd3e221eb110a1b41276849c623049ec",
|
"v1.1.1 ac4247e5fd3e221eb110a1b41276849c623049ec",
|
||||||
"v1.2.0 e2e94bb3a349985641fa686341757cfbd18207e2",
|
"v1.2.0 e2e94bb3a349985641fa686341757cfbd18207e2",
|
||||||
"v1.3.0 9f3a52558338503571b37c034a12219566f27aa2",
|
"v1.3.0 9f3a52558338503571b37c034a12219566f27aa2",
|
||||||
"v1.3.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v1.3.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "PikaVSF"
|
name = "PikaVSF"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 f755ec10042f4deefef1c5491f5e91a651f71a1b",
|
"v0.0.1 f755ec10042f4deefef1c5491f5e91a651f71a1b",
|
||||||
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -327,12 +331,12 @@ releases = [
|
|||||||
"v0.4.1 0892f1d426e3d69daaff1251d8e45d2ef60d1ad4",
|
"v0.4.1 0892f1d426e3d69daaff1251d8e45d2ef60d1ad4",
|
||||||
"v0.5.0 c25d624cda5cc10bbdf803e1c343fc553e32477f",
|
"v0.5.0 c25d624cda5cc10bbdf803e1c343fc553e32477f",
|
||||||
"v0.6.0 cbf1fdbea742957d59d3ec1486a1b39896105f19",
|
"v0.6.0 cbf1fdbea742957d59d3ec1486a1b39896105f19",
|
||||||
"v0.6.1 2fa7916db1bb8f9afa957513a1ef5339d6581861"
|
"v0.6.1 2fa7916db1bb8f9afa957513a1ef5339d6581861",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "PLOOC"
|
name = "PLOOC"
|
||||||
releases = [ "v1.0.0 e2a630358c0d490b198f7e8682fb61569eb7ec56" ]
|
releases = ["v1.0.0 e2a630358c0d490b198f7e8682fb61569eb7ec56"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pikaRTDevice"
|
name = "pikaRTDevice"
|
||||||
@ -340,7 +344,7 @@ releases = [
|
|||||||
"v0.0.1 fe900b79d8d1075bb7e4e3dd9d4e1e187e0c9195",
|
"v0.0.1 fe900b79d8d1075bb7e4e3dd9d4e1e187e0c9195",
|
||||||
"v1.0.0 ac4247e5fd3e221eb110a1b41276849c623049ec",
|
"v1.0.0 ac4247e5fd3e221eb110a1b41276849c623049ec",
|
||||||
"v1.0.1 61e6a7352b65adbce0f2ad82ea1fc992dcbb603",
|
"v1.0.1 61e6a7352b65adbce0f2ad82ea1fc992dcbb603",
|
||||||
"v1.1.0 9f3a52558338503571b37c034a12219566f27aa2"
|
"v1.1.0 9f3a52558338503571b37c034a12219566f27aa2",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -356,7 +360,7 @@ releases = [
|
|||||||
"v1.3.2 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
"v1.3.2 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
||||||
"v1.4.0 4611a62ecf25c614b516ccef059f0933d822c26c",
|
"v1.4.0 4611a62ecf25c614b516ccef059f0933d822c26c",
|
||||||
"v1.5.0 24c8f7644e81d37855472ae5bbe984e32bcf0190",
|
"v1.5.0 24c8f7644e81d37855472ae5bbe984e32bcf0190",
|
||||||
"v2.0.0 4ec5e905587f474250c682b665f8105a2c4a4d30"
|
"v2.0.0 4ec5e905587f474250c682b665f8105a2c4a4d30",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -369,7 +373,8 @@ releases = [
|
|||||||
"v1.1.0 186b951078c76b1c80b8111d76097970c21a3004",
|
"v1.1.0 186b951078c76b1c80b8111d76097970c21a3004",
|
||||||
"v1.1.1 567d0b19ce998a290fa538845d107c744ccd0258",
|
"v1.1.1 567d0b19ce998a290fa538845d107c744ccd0258",
|
||||||
"v1.1.2 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
"v1.1.2 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
||||||
"v1.1.3 7a68bf910047fb055e5dbc0bdfdfec1366ca2469"
|
"v1.1.3 7a68bf910047fb055e5dbc0bdfdfec1366ca2469",
|
||||||
|
"v1.1.4 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -378,7 +383,7 @@ releases = [
|
|||||||
"v0.1.0 ee7e38e9422970bba86f5cd7774db8654edd38dc",
|
"v0.1.0 ee7e38e9422970bba86f5cd7774db8654edd38dc",
|
||||||
"v0.2.0 93591e92863f5e192dc89aed6666fd9dab4f7a82",
|
"v0.2.0 93591e92863f5e192dc89aed6666fd9dab4f7a82",
|
||||||
"v0.3.0 8202a1ab52f15f70cd93abb0d409aa03da8170b0",
|
"v0.3.0 8202a1ab52f15f70cd93abb0d409aa03da8170b0",
|
||||||
"v0.3.1 918464a8567f84c87ddda68de99f3d032ee812e0"
|
"v0.3.1 918464a8567f84c87ddda68de99f3d032ee812e0",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -388,7 +393,7 @@ releases = [
|
|||||||
"v0.0.2 8bcb5ad868ec8961f2a3f08329a46ab0b780596b",
|
"v0.0.2 8bcb5ad868ec8961f2a3f08329a46ab0b780596b",
|
||||||
"v0.1.0 ac05e34d026344d0590f562a55c142b6e0879933",
|
"v0.1.0 ac05e34d026344d0590f562a55c142b6e0879933",
|
||||||
"v0.1.1 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
"v0.1.1 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
||||||
"v0.1.2 27150fba49fd783536c2c6d0702f813604d3f0d8"
|
"v0.1.2 27150fba49fd783536c2c6d0702f813604d3f0d8",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -406,21 +411,21 @@ releases = [
|
|||||||
"v1.1.3 f755ec10042f4deefef1c5491f5e91a651f71a1b",
|
"v1.1.3 f755ec10042f4deefef1c5491f5e91a651f71a1b",
|
||||||
"v1.2.0 9f3a52558338503571b37c034a12219566f27aa2",
|
"v1.2.0 9f3a52558338503571b37c034a12219566f27aa2",
|
||||||
"v1.3.0 9d7b155af3260c0fc00be05598c807b71d7cc198",
|
"v1.3.0 9d7b155af3260c0fc00be05598c807b71d7cc198",
|
||||||
"v1.4.0 a567e7705f5049ec5bb44b4bcc7497666cb125b3"
|
"v1.4.0 a567e7705f5049ec5bb44b4bcc7497666cb125b3",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "CH32V103"
|
name = "CH32V103"
|
||||||
releases = [
|
releases = [
|
||||||
"v1.0.0 4ce839297f208b0ac4fc1e7f16fef16ab605e70d",
|
"v1.0.0 4ce839297f208b0ac4fc1e7f16fef16ab605e70d",
|
||||||
"v1.0.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v1.0.1 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "SmartLoong"
|
name = "SmartLoong"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 a5437de66e8cff600be247eae63ac9114b6b153f",
|
"v0.0.1 a5437de66e8cff600be247eae63ac9114b6b153f",
|
||||||
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81"
|
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -429,7 +434,7 @@ releases = [
|
|||||||
"v0.0.1 88f4e507f1665ca7ceda149aabf029f4e21e22c7",
|
"v0.0.1 88f4e507f1665ca7ceda149aabf029f4e21e22c7",
|
||||||
"v1.0.0 7ae9cd062fa48ecfe4b843c9f13b0daef0efd79d",
|
"v1.0.0 7ae9cd062fa48ecfe4b843c9f13b0daef0efd79d",
|
||||||
"v1.1.0 c53bf1483d015555b4823f129864444198227403",
|
"v1.1.0 c53bf1483d015555b4823f129864444198227403",
|
||||||
"v1.1.1 55164edbf2ab7e2e9e754663579e3c93040da8fa"
|
"v1.1.1 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -438,18 +443,18 @@ releases = [
|
|||||||
"v1.0.0 7cdb0cf9ed161c3fc6802028a9e34c9f94b56244",
|
"v1.0.0 7cdb0cf9ed161c3fc6802028a9e34c9f94b56244",
|
||||||
"v1.1.0 bfc01e09fd71c26a7140d23864c1d3052f23d087",
|
"v1.1.0 bfc01e09fd71c26a7140d23864c1d3052f23d087",
|
||||||
"v1.1.1 268c8433a1add8c902d694808682890a2df8c1fc",
|
"v1.1.1 268c8433a1add8c902d694808682890a2df8c1fc",
|
||||||
"v1.1.2 55164edbf2ab7e2e9e754663579e3c93040da8fa"
|
"v1.1.2 55164edbf2ab7e2e9e754663579e3c93040da8fa",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "MM32F5277E9P"
|
name = "MM32F5277E9P"
|
||||||
releases = [ "v0.0.1 176232225939eccfaedfea412699a2e53c38ace1" ]
|
releases = ["v0.0.1 176232225939eccfaedfea412699a2e53c38ace1"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "AIR32F1"
|
name = "AIR32F1"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 9f9579c54ebddb12c66afc8da64a987767ff512f",
|
"v0.0.1 9f9579c54ebddb12c66afc8da64a987767ff512f",
|
||||||
"v0.1.0 faa9c6230149d09188114af7af822e5d34af6b55"
|
"v0.1.0 faa9c6230149d09188114af7af822e5d34af6b55",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -457,14 +462,15 @@ name = "modbus"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 729ce8a497d73b53888180b9f6d0dfdac145df26",
|
"v0.0.1 729ce8a497d73b53888180b9f6d0dfdac145df26",
|
||||||
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
"v0.0.3 cd0029b6d1b4340b252532fcee1320667231038c"
|
"v0.0.3 cd0029b6d1b4340b252532fcee1320667231038c",
|
||||||
|
"v0.0.4 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pika_fatfs"
|
name = "pika_fatfs"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 280700b8a8eee1849d16ac68871d014392edf269",
|
"v0.0.1 280700b8a8eee1849d16ac68871d014392edf269",
|
||||||
"v0.1.0 8ab8cd90be83f1cb86e2b2bcbb3b68d99d034815"
|
"v0.1.0 8ab8cd90be83f1cb86e2b2bcbb3b68d99d034815",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -472,28 +478,28 @@ name = "mqtt"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
|
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
|
||||||
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
"v0.0.2 ae13ede96f87b2dc9767b5e89c77dabf95c76e81",
|
||||||
"v0.0.3 73e056141b23dba24087a9c0b1ce07c4eef1b909"
|
"v0.0.3 73e056141b23dba24087a9c0b1ce07c4eef1b909",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "requests"
|
name = "requests"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
|
"v0.0.1 04a174a7d3e02d8861124214f5a3551eaab2bfee",
|
||||||
"v1.0.0 c67a894fc27ab3fe7b7aac825f1880e5073b0020"
|
"v1.0.0 c67a894fc27ab3fe7b7aac825f1880e5073b0020",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "hashlib"
|
name = "hashlib"
|
||||||
releases = [
|
releases = [
|
||||||
"v1.0.0 ce05a5f03c4bfac536db60fe24f83705a1b58b02",
|
"v1.0.0 ce05a5f03c4bfac536db60fe24f83705a1b58b02",
|
||||||
"v1.0.1 a91c3698abce8a6624929243cfb7cc79badaa156"
|
"v1.0.1 a91c3698abce8a6624929243cfb7cc79badaa156",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "hmac"
|
name = "hmac"
|
||||||
releases = [
|
releases = [
|
||||||
"v1.0.0 ca8fe36d68be16722317860394fdf78c620e3e2d",
|
"v1.0.0 ca8fe36d68be16722317860394fdf78c620e3e2d",
|
||||||
"v1.0.1 d75ce00c377e48c6058bbe1f824474802383e5e7"
|
"v1.0.1 d75ce00c377e48c6058bbe1f824474802383e5e7",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -503,29 +509,29 @@ releases = [
|
|||||||
"v0.2.0 eee8e1848eed77f3ebed777230104ebb4dfc3263",
|
"v0.2.0 eee8e1848eed77f3ebed777230104ebb4dfc3263",
|
||||||
"v0.3.0 fc69ce4145c053d0a5f9191e8706014c5bee4ca8",
|
"v0.3.0 fc69ce4145c053d0a5f9191e8706014c5bee4ca8",
|
||||||
"v0.4.0 bcb2f3aac147cfb7b0f655b877d964e3fc0699c8",
|
"v0.4.0 bcb2f3aac147cfb7b0f655b877d964e3fc0699c8",
|
||||||
"v0.4.1 e28d9ee48feaf2125c018e5a18db60f648f038f8"
|
"v0.4.1 e28d9ee48feaf2125c018e5a18db60f648f038f8",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "BLMCU"
|
name = "BLMCU"
|
||||||
releases = [ "v0.1.0 2551ac3fbeaa0d744a909c6cf48ba301c3af1cca" ]
|
releases = ["v0.1.0 2551ac3fbeaa0d744a909c6cf48ba301c3af1cca"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "aes"
|
name = "aes"
|
||||||
releases = [ "v0.0.1 5c45cba0c39d447fbe7a4a082ee3170188c3bcb7" ]
|
releases = ["v0.0.1 5c45cba0c39d447fbe7a4a082ee3170188c3bcb7"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "base64"
|
name = "base64"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 1ae3ac23759fb2b5e0f77866af40986ac94e356d",
|
"v0.0.1 1ae3ac23759fb2b5e0f77866af40986ac94e356d",
|
||||||
"v1.0.0 29ad2b44817c5a72ace9f6d09cea7df6beb516f9"
|
"v1.0.0 29ad2b44817c5a72ace9f6d09cea7df6beb516f9",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "pika_libc"
|
name = "pika_libc"
|
||||||
releases = [
|
releases = [
|
||||||
"v1.0.0 42a3cebb085a4a995d80031685dbf630e053aa55",
|
"v1.0.0 42a3cebb085a4a995d80031685dbf630e053aa55",
|
||||||
"v1.0.1 b77d20d7b2f5fd29ac3d55daeec65e77d15a9b72"
|
"v1.0.1 b77d20d7b2f5fd29ac3d55daeec65e77d15a9b72",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -534,18 +540,18 @@ releases = [
|
|||||||
"v0.1.0 79df1cf1cc97436a4925c3065aef4a8f32d077d8",
|
"v0.1.0 79df1cf1cc97436a4925c3065aef4a8f32d077d8",
|
||||||
"v0.1.1 cd0029b6d1b4340b252532fcee1320667231038c",
|
"v0.1.1 cd0029b6d1b4340b252532fcee1320667231038c",
|
||||||
"v0.1.2 0d27c99cdc1fb86370d0e7519ae6db3a3b28f743",
|
"v0.1.2 0d27c99cdc1fb86370d0e7519ae6db3a3b28f743",
|
||||||
"v0.1.3 2aafbbdc84eed84edcf5dcd7462a842a14f26a92"
|
"v0.1.3 2aafbbdc84eed84edcf5dcd7462a842a14f26a92",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "at_client"
|
name = "at_client"
|
||||||
releases = [ "v0.0.1 353e5e5ac2d725a1cc14cd6e690b451c3ac61e3f" ]
|
releases = ["v0.0.1 353e5e5ac2d725a1cc14cd6e690b451c3ac61e3f"]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "json"
|
name = "json"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 02d6151cac594f2278c04e616f03cf37bae3069b",
|
"v0.1.0 02d6151cac594f2278c04e616f03cf37bae3069b",
|
||||||
"v0.1.1 94624f9a4af756c597291ed0646c446ecf25ac16"
|
"v0.1.1 94624f9a4af756c597291ed0646c446ecf25ac16",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
@ -553,16 +559,20 @@ name = "network"
|
|||||||
releases = [
|
releases = [
|
||||||
"v0.1.0 94624f9a4af756c597291ed0646c446ecf25ac16",
|
"v0.1.0 94624f9a4af756c597291ed0646c446ecf25ac16",
|
||||||
"v0.1.1 5282cff66fe8f003c75fd82c54c0144aa7da8277",
|
"v0.1.1 5282cff66fe8f003c75fd82c54c0144aa7da8277",
|
||||||
"v0.1.2 69cea1d7188b35b84d819ed8cb8f41b3a64d39d1"
|
"v0.1.2 69cea1d7188b35b84d819ed8cb8f41b3a64d39d1",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "_thread"
|
name = "_thread"
|
||||||
releases = [
|
releases = [
|
||||||
"v0.0.1 73e056141b23dba24087a9c0b1ce07c4eef1b909",
|
"v0.0.1 73e056141b23dba24087a9c0b1ce07c4eef1b909",
|
||||||
"v0.0.2 2aafbbdc84eed84edcf5dcd7462a842a14f26a92"
|
"v0.0.2 2aafbbdc84eed84edcf5dcd7462a842a14f26a92",
|
||||||
|
"v0.0.3 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
]
|
]
|
||||||
|
|
||||||
[[packages]]
|
[[packages]]
|
||||||
name = "weakref"
|
name = "weakref"
|
||||||
releases = [ "v0.0.1 93f22cb39e02e1f51735753dc253f8a7768ba16f" ]
|
releases = [
|
||||||
|
"v0.0.1 93f22cb39e02e1f51735753dc253f8a7768ba16f",
|
||||||
|
"v0.0.2 b9a0109c6125d16270cf02b2a07421a4baf9973c",
|
||||||
|
]
|
||||||
|
5
port/linux/.vscode/settings.json
vendored
5
port/linux/.vscode/settings.json
vendored
@ -124,5 +124,8 @@
|
|||||||
"clangd.arguments": [
|
"clangd.arguments": [
|
||||||
"-compile-commands-dir=build",
|
"-compile-commands-dir=build",
|
||||||
"-header-insertion=never"
|
"-header-insertion=never"
|
||||||
]
|
],
|
||||||
|
"[toml]": {
|
||||||
|
"editor.defaultFormatter": "tamasfe.even-better-toml"
|
||||||
|
}
|
||||||
}
|
}
|
@ -1,15 +1,25 @@
|
|||||||
import os
|
import os
|
||||||
import git
|
import git
|
||||||
|
import subprocess
|
||||||
from release_helper import *
|
from release_helper import *
|
||||||
|
|
||||||
repo = git.Repo(REPO_PATH)
|
repo = git.Repo(REPO_PATH)
|
||||||
commit_head = repo.head.commit.hexsha
|
commit_head = repo.head.commit.hexsha
|
||||||
pkgReleases = PackageReleaseList(PACKAGE_RELEASE_PATH)
|
pkgReleases = PackageReleaseList(PACKAGE_RELEASE_PATH)
|
||||||
|
|
||||||
|
for folder in os.listdir(LINUX_PACKAGE_PATH):
|
||||||
|
# skip PikaStdLib
|
||||||
|
if folder == "PikaStdLib" or folder == "GTestTask" or folder == "TemplateDevice":
|
||||||
|
continue
|
||||||
|
# call `bash pkg-push $folder`
|
||||||
|
cmd = f"./pkg-push.sh {folder}"
|
||||||
|
output = subprocess.check_output(["bash", "-c", cmd])
|
||||||
|
print(output)
|
||||||
|
|
||||||
# for each folder in package, run the following command
|
# for each folder in package, run the following command
|
||||||
for folder in os.listdir(PACKAGE_PATH):
|
for folder in os.listdir(PACKAGE_PATH):
|
||||||
# skip PikaStdLib
|
# skip PikaStdLib
|
||||||
if folder == "PikaStdLib":
|
if folder == "PikaStdLib" or folder == "GTestTask" or folder == "TemplateDevice":
|
||||||
continue
|
continue
|
||||||
if os.path.isdir(PACKAGE_PATH + "/" + folder):
|
if os.path.isdir(PACKAGE_PATH + "/" + folder):
|
||||||
# check git diff
|
# check git diff
|
||||||
|
@ -4,6 +4,7 @@ import toml
|
|||||||
|
|
||||||
REPO_PATH = "../.."
|
REPO_PATH = "../.."
|
||||||
PACKAGE_PATH = REPO_PATH + "/package"
|
PACKAGE_PATH = REPO_PATH + "/package"
|
||||||
|
LINUX_PACKAGE_PATH = REPO_PATH + "/port/linux/package/pikascript/pikascript-lib"
|
||||||
PACKAGE_RELEASE_PATH = REPO_PATH + "/packages.toml"
|
PACKAGE_RELEASE_PATH = REPO_PATH + "/packages.toml"
|
||||||
WORK_DIR = os.getcwd()
|
WORK_DIR = os.getcwd()
|
||||||
|
|
||||||
|
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user