Skip to content

Commit faf93fc

Browse files
committed
Merge branch 'master' of https://gitee.com/lyon1998/pikascript
2 parents 26f4354 + a7cd159 commit faf93fc

File tree

6 files changed

+118
-111
lines changed

6 files changed

+118
-111
lines changed

.github/workflows/codeql.yml

Lines changed: 107 additions & 107 deletions
Original file line numberDiff line numberDiff line change
@@ -1,122 +1,122 @@
1-
# For most projects, this workflow file will not need changing; you simply need
2-
# to commit it to your repository.
3-
#
4-
# You may wish to alter this file to override the set of languages analyzed,
5-
# or to provide custom queries or build logic.
6-
#
7-
# ******** NOTE ********
8-
# We have attempted to detect the languages in your repository. Please check
9-
# the `language` matrix defined below to confirm you have the correct set of
10-
# supported CodeQL languages.
11-
#
12-
name: "CodeQL"
1+
# # For most projects, this workflow file will not need changing; you simply need
2+
# # to commit it to your repository.
3+
# #
4+
# # You may wish to alter this file to override the set of languages analyzed,
5+
# # or to provide custom queries or build logic.
6+
# #
7+
# # ******** NOTE ********
8+
# # We have attempted to detect the languages in your repository. Please check
9+
# # the `language` matrix defined below to confirm you have the correct set of
10+
# # supported CodeQL languages.
11+
# #
12+
# name: "CodeQL"
1313

14-
on:
15-
# push:
16-
# branches: [ "main", "master" ]
17-
schedule:
18-
- cron: '0 0 * * *'
19-
pull_request:
20-
branches: '*'
14+
# on:
15+
# # push:
16+
# # branches: [ "main", "master" ]
17+
# schedule:
18+
# - cron: '0 0 * * *'
19+
# pull_request:
20+
# branches: '*'
2121

22-
jobs:
23-
analyze:
24-
name: Analyze
25-
# Runner size impacts CodeQL analysis time. To learn more, please see:
26-
# - https://gh.io/recommended-hardware-resources-for-running-codeql
27-
# - https://gh.io/supported-runners-and-hardware-resources
28-
# - https://gh.io/using-larger-runners
29-
# Consider using larger runners for possible analysis time improvements.
30-
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-20.04' }}
31-
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
32-
permissions:
33-
actions: read
34-
contents: read
35-
security-events: write
22+
# jobs:
23+
# analyze:
24+
# name: Analyze
25+
# # Runner size impacts CodeQL analysis time. To learn more, please see:
26+
# # - https://gh.io/recommended-hardware-resources-for-running-codeql
27+
# # - https://gh.io/supported-runners-and-hardware-resources
28+
# # - https://gh.io/using-larger-runners
29+
# # Consider using larger runners for possible analysis time improvements.
30+
# runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-20.04' }}
31+
# timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
32+
# permissions:
33+
# actions: read
34+
# contents: read
35+
# security-events: write
3636

37-
strategy:
38-
fail-fast: false
39-
matrix:
40-
language: [ 'cpp' ]
41-
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
42-
# Use only 'java' to analyze code written in Java, Kotlin or both
43-
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
44-
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
37+
# strategy:
38+
# fail-fast: false
39+
# matrix:
40+
# language: [ 'cpp' ]
41+
# # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
42+
# # Use only 'java' to analyze code written in Java, Kotlin or both
43+
# # Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
44+
# # Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
4545

46-
steps:
47-
- name: Checkout repository
48-
uses: actions/checkout@v3
49-
with:
50-
submodules: recursive
46+
# steps:
47+
# - name: Checkout repository
48+
# uses: actions/checkout@v3
49+
# with:
50+
# submodules: recursive
5151

52-
# Initializes the CodeQL tools for scanning.
53-
- name: Initialize CodeQL
54-
uses: github/codeql-action/init@v2
55-
with:
56-
languages: ${{ matrix.language }}
57-
# If you wish to specify custom queries, you can do so here or in a config file.
58-
# By default, queries listed here will override any specified in a config file.
59-
# Prefix the list here with "+" to use these queries and those in the config file.
52+
# # Initializes the CodeQL tools for scanning.
53+
# - name: Initialize CodeQL
54+
# uses: github/codeql-action/init@v2
55+
# with:
56+
# languages: ${{ matrix.language }}
57+
# # If you wish to specify custom queries, you can do so here or in a config file.
58+
# # By default, queries listed here will override any specified in a config file.
59+
# # Prefix the list here with "+" to use these queries and those in the config file.
6060

61-
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
62-
# queries: security-extended,security-and-quality
63-
queries: security-and-quality
61+
# # For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
62+
# # queries: security-extended,security-and-quality
63+
# queries: security-and-quality
6464

6565

66-
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
67-
# If this step fails, then you should remove it and run the build manually (see below)
68-
#- name: Autobuild
69-
# uses: github/codeql-action/autobuild@v2
66+
# # Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
67+
# # If this step fails, then you should remove it and run the build manually (see below)
68+
# #- name: Autobuild
69+
# # uses: github/codeql-action/autobuild@v2
7070

71-
# ℹ️ Command-line programs to run using the OS shell.
72-
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
71+
# # ℹ️ Command-line programs to run using the OS shell.
72+
# # 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
7373

74-
# If the Autobuild fails above, remove it and uncomment the following three lines.
75-
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
74+
# # If the Autobuild fails above, remove it and uncomment the following three lines.
75+
# # modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
7676

77-
- run: |
78-
cd src
79-
mkdir build && cd build && cmake ../ && make
77+
# - run: |
78+
# cd src
79+
# mkdir build && cd build && cmake ../ && make
8080

81-
- name: Perform CodeQL Analysis
82-
uses: github/codeql-action/analyze@v2
83-
with:
84-
category: "/language:${{matrix.language}}"
85-
upload: false
86-
id: step1
81+
# - name: Perform CodeQL Analysis
82+
# uses: github/codeql-action/analyze@v2
83+
# with:
84+
# category: "/language:${{matrix.language}}"
85+
# upload: false
86+
# id: step1
8787

88-
# Filter out rules with low severity or high false positve rate
89-
# Also filter out warnings in third-party code
90-
- name: Filter out unwanted errors and warnings
91-
uses: advanced-security/filter-sarif@v1
92-
with:
93-
patterns: |
94-
-**:cpp/path-injection
95-
-**:cpp/world-writable-file-creation
96-
-**:cpp/poorly-documented-function
97-
-**:cpp/potentially-dangerous-function
98-
-**:cpp/use-of-goto
99-
-**:cpp/integer-multiplication-cast-to-long
100-
-**:cpp/comparison-with-wider-type
101-
-**:cpp/leap-year/*
102-
-**:cpp/ambiguously-signed-bit-field
103-
-**:cpp/suspicious-pointer-scaling
104-
-**:cpp/suspicious-pointer-scaling-void
105-
-**:cpp/unsigned-comparison-zero
106-
-**/cmake*/Modules/**
107-
input: ${{ steps.step1.outputs.sarif-output }}/cpp.sarif
108-
output: ${{ steps.step1.outputs.sarif-output }}/cpp.sarif
88+
# # Filter out rules with low severity or high false positve rate
89+
# # Also filter out warnings in third-party code
90+
# - name: Filter out unwanted errors and warnings
91+
# uses: advanced-security/filter-sarif@v1
92+
# with:
93+
# patterns: |
94+
# -**:cpp/path-injection
95+
# -**:cpp/world-writable-file-creation
96+
# -**:cpp/poorly-documented-function
97+
# -**:cpp/potentially-dangerous-function
98+
# -**:cpp/use-of-goto
99+
# -**:cpp/integer-multiplication-cast-to-long
100+
# -**:cpp/comparison-with-wider-type
101+
# -**:cpp/leap-year/*
102+
# -**:cpp/ambiguously-signed-bit-field
103+
# -**:cpp/suspicious-pointer-scaling
104+
# -**:cpp/suspicious-pointer-scaling-void
105+
# -**:cpp/unsigned-comparison-zero
106+
# -**/cmake*/Modules/**
107+
# input: ${{ steps.step1.outputs.sarif-output }}/cpp.sarif
108+
# output: ${{ steps.step1.outputs.sarif-output }}/cpp.sarif
109109

110-
- name: Upload CodeQL results to code scanning
111-
uses: github/codeql-action/upload-sarif@v2
112-
with:
113-
sarif_file: ${{ steps.step1.outputs.sarif-output }}
114-
category: "/language:${{matrix.language}}"
110+
# - name: Upload CodeQL results to code scanning
111+
# uses: github/codeql-action/upload-sarif@v2
112+
# with:
113+
# sarif_file: ${{ steps.step1.outputs.sarif-output }}
114+
# category: "/language:${{matrix.language}}"
115115

116-
- name: Upload CodeQL results as an artifact
117-
if: success() || failure()
118-
uses: actions/upload-artifact@v3
119-
with:
120-
name: codeql-results
121-
path: ${{ steps.step1.outputs.sarif-output }}
122-
retention-days: 5
116+
# - name: Upload CodeQL results as an artifact
117+
# if: success() || failure()
118+
# uses: actions/upload-artifact@v3
119+
# with:
120+
# name: codeql-results
121+
# path: ${{ steps.step1.outputs.sarif-output }}
122+
# retention-days: 5

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[submodule "port/linux/package/lvgl/lvgl"]
22
path = port/linux/package/lvgl/lvgl
33
url = https://gitee.com/Lyon1998/lvgl
4+
[submodule "bsp/MicroLink"]
5+
path = bsp/MicroLink
6+
url = https://github.com/Aladdin-Wang/MicroLink.git

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ The board based on STM32G030C8T6 MCU, only 64kB Flash, 8kB RAM can run pikapytho
6565
CH340 is deployed to support USB to serial with Type-C USB, support download python script py serial, there are 4 RGB on the board and support the [LCD](https://item.taobao.com/item.htm?spm=a1z10.3-c.w4002-23991764791.12.16f97c58fsLjVk&id=660745643102).
6666

6767
# Related Projects
68+
- 🎮 [MicroLink](https://github.com/Aladdin-Wang/MicroLink) 一款集多功能于一体的嵌入式系统开发工具
6869

6970
- ▶️ [pikapython Binding For LVGL](https://github.com/lvgl/lv_binding_pikascript)
7071

README_zh.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@ PikaPython 串口终端、脚本下载、模块管理工具。
8888

8989
## 相关开源项目
9090

91+
- 🎮 [MicroLink](https://github.com/Aladdin-Wang/MicroLink) 一款集多功能于一体的嵌入式系统开发工具
92+
9193
- ▶️ [pikapython Binding For LVGL](https://github.com/lvgl/lv_binding_pikascript)
9294

9395
-[pikapython Bluepill Demo In PlatformIO — Python-like REPL 🐍🔌](https://github.com/maxgerhardt/pikascript-pio-bluepill)

bsp/MicroLink

Submodule MicroLink added at 448b486

src/PikaVM.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -327,14 +327,14 @@ PIKA_RES __eventListener_popEvent(PikaEventListener** lisener_p,
327327
if (NULL == cq) {
328328
return PIKA_RES_ERR_SIGNAL_EVENT_EMPTY;
329329
}
330-
*id = cq->id[g_PikaVMState.cq.head];
330+
*id = cq->id[cq->head];
331331
if (cq == &g_PikaVMState.cq) {
332-
*data = cq->data[g_PikaVMState.cq.head].arg;
332+
*data = cq->data[cq->head].arg;
333333
} else {
334-
*signal = cq->data[g_PikaVMState.cq.head].signal;
334+
*signal = cq->data[cq->head].signal;
335335
*data = NULL;
336336
}
337-
*lisener_p = cq->listener[g_PikaVMState.cq.head];
337+
*lisener_p = cq->listener[cq->head];
338338
*head = cq->head;
339339
cq->head = (cq->head + 1) % PIKA_EVENT_LIST_SIZE;
340340
return PIKA_RES_OK;

0 commit comments

Comments
 (0)