Skip to content

Commit

Permalink
IM01 2
Browse files Browse the repository at this point in the history
  • Loading branch information
KalbeAbbas committed Nov 9, 2020
1 parent 3911329 commit 200aded
Show file tree
Hide file tree
Showing 21 changed files with 2,842 additions and 115 deletions.
Binary file removed .github/makecode/blocks.png
Binary file not shown.
29 changes: 0 additions & 29 deletions .github/workflows/makecode.yml

This file was deleted.

44 changes: 44 additions & 0 deletions .github/workflows/maker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: maker

on:
push:
branches:
- master
schedule:
- cron: '0 0 5,20 * *'

jobs:
prepare:
runs-on: ubuntu-latest
if: "! contains(github.event.head_commit.message, '[skip ci]')"
steps:
- run: echo "${{ github.event.head_commit.message }}"

build:
needs: prepare
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [8.x]

steps:
- uses: actions/checkout@v1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}

- name: maker pxt.json
uses: datamonsters/replace-action@master
with:
files: 'pxt.json'
replacements: 'core=xinabox-cs11,test.ts=dummy.ts'
- name: maker compilation
run: |
npm install -g pxt
pxt target maker
pxt install
pxt build --cloud
env:
CI: true
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
# MakeCode
built
node_modules
yotta_modules
Expand All @@ -8,4 +7,9 @@ _site
*.db
*.tgz
.header.json
.simstate.json
main.ts
main.blocks
Gemfile
_config.yml
tsconfig.json
.vscode
23 changes: 0 additions & 23 deletions .vscode/settings.json

This file was deleted.

30 changes: 0 additions & 30 deletions .vscode/tasks.json

This file was deleted.

2 changes: 0 additions & 2 deletions Gemfile

This file was deleted.

21 changes: 13 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,36 @@
[![GitHub Issues](https://img.shields.io/github/issues/xinabox/pxt-CS11.svg)](https://github.com/xinabox/pxt-CS11/issues)
![GitHub Commit](https://img.shields.io/github/last-commit/xinabox/pxt-CS11)
![Maintained](https://img.shields.io/maintenance/yes/2020)
![Build status badge](https://github.com/xinabox/pxt-CS11/workflows/maker/badge.svg)
![Developer](https://img.shields.io/badge/Developer-lb-blue)

> Open this page at [https://xinabox.github.io/pxt-im01-2/](https://xinabox.github.io/pxt-im01-2/)
> Open this page at [https://.github.io//](https://.github.io//)
## Use as Extension

This repository can be added as an **extension** in MakeCode.

* open [https://makecode.microbit.org/](https://makecode.microbit.org/)
* open []()
* click on **New Project**
* click on **Extensions** under the gearwheel menu
* search for **https://github.com/xinabox/pxt-im01-2** and import
* search for **https://github.com/** and import

## Edit this project ![Build status badge](https://github.com/xinabox/pxt-im01-2/workflows/MakeCode/badge.svg)
## Edit this project ![Build status badge](https://github.com//workflows/MakeCode/badge.svg)

To edit this repository in MakeCode.

* open [https://makecode.microbit.org/](https://makecode.microbit.org/)
* open []()
* click on **Import** then click on **Import URL**
* paste **https://github.com/xinabox/pxt-im01-2** and click import
* paste **https://github.com/** and click import

## Blocks preview

This image shows the blocks code from the last commit in master.
This image may take a few minutes to refresh.

![A rendered view of the blocks](https://github.com/xinabox/pxt-im01-2/raw/master/.github/makecode/blocks.png)
![A rendered view of the blocks](https://github.com//raw/master/.github/makecode/blocks.png)

#### Metadata (used for search, rendering)

* for PXT/microbit
* for PXT/
<script src="https://makecode.com/gh-pages-embed.js"></script><script>makeCodeRender("{{ site.makecode.home_url }}", "{{ site.github.owner_name }}/{{ site.github.repository_name }}");</script>
8 changes: 0 additions & 8 deletions _config.yml

This file was deleted.

38 changes: 38 additions & 0 deletions diskio.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
#include "ff.h"
#ifndef _DISKIO_DEFINED
#define _DISKIO_DEFINED

typedef BYTE DSTATUS;

typedef enum
{
RES_OK = 0,
RES_ERROR,
RES_WRPRT,
RES_NOTRDY,
RES_PARERR
} DRESULT;

DSTATUS disk_initialize(BYTE pdrv);
DSTATUS disk_status(BYTE pdrv);
DRESULT disk_read(BYTE pdrv, BYTE *buff, LBA_t sector, UINT count);
DRESULT disk_write(BYTE pdrv, const BYTE *buff, LBA_t sector, UINT count);
DRESULT disk_ioctl(BYTE pdrv, BYTE cmd, void *buff);

#define STA_NOINIT 0x01

#define STA_PROTECT 0x04

#define CTRL_SYNC 0
#define GET_SECTOR_COUNT 1
#define GET_SECTOR_SIZE 2
#define GET_BLOCK_SIZE 3
#define CTRL_TRIM 4

#define CT_MMC 0x01
#define CT_SD1 0x02
#define CT_SD2 0x04
#define CT_SDC (CT_SD1 | CT_SD2)
#define CT_BLOCK 0x08

#endif
1 change: 1 addition & 0 deletions dummy.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@

Loading

0 comments on commit 200aded

Please sign in to comment.