-
-
Notifications
You must be signed in to change notification settings - Fork 436
/
Copy pathboards.ts
47 lines (44 loc) · 1.37 KB
/
boards.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import { BoardsConfig } from '../../../browser/boards/boards-config';
import { Board, BoardsPackage, Port } from '../../../common/protocol';
export const aBoard: Board = {
fqbn: 'some:board:fqbn',
name: 'Some Arduino Board',
port: { address: '/lol/port1234', protocol: 'serial' },
};
export const aPort: Port = {
address: aBoard.port!.address,
protocol: aBoard.port!.protocol,
};
export const aBoardConfig: BoardsConfig.Config = {
selectedBoard: aBoard,
selectedPort: aPort,
};
export const anotherBoard: Board = {
fqbn: 'another:board:fqbn',
name: 'Another Arduino Board',
port: { address: '/kek/port5678', protocol: 'serial' },
};
export const anotherPort: Port = {
address: anotherBoard.port!.address,
protocol: anotherBoard.port!.protocol,
};
export const anotherBoardConfig: BoardsConfig.Config = {
selectedBoard: anotherBoard,
selectedPort: anotherPort,
};
export const aPackage: BoardsPackage = {
author: 'someAuthor',
availableVersions: ['some.ver.sion', 'some.other.version'],
boards: [aBoard],
deprecated: false,
description: 'Some Arduino Board, Some Other Arduino Board',
id: 'some:arduinoCoreId',
installable: true,
moreInfoLink: 'http://www.some-url.lol/',
name: 'Some Arduino Package',
summary: 'Boards included in this package:',
};
export const anInstalledPackage: BoardsPackage = {
...aPackage,
installedVersion: 'some.ver.sion',
};