-
Notifications
You must be signed in to change notification settings - Fork 13
Expand file tree
/
Copy pathMyCustomDevice_platformio.ini
More file actions
75 lines (71 loc) · 4.67 KB
/
MyCustomDevice_platformio.ini
File metadata and controls
75 lines (71 loc) · 4.67 KB
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
; ******************************************************************************************
; working environment for template of custom firmware
; ******************************************************************************************
; Common build settings across this custom device
[env_template]
build_flags =
${env.build_flags} ; include standard build flags
-DMF_CUSTOMDEVICE_SUPPORT=1 ; Required for Custom Devices
;-DMF_CUSTOMDEVICE_HAS_UPDATE ; if the custom device needs to be updated, uncomment this. W/o the following define it will be done each loop()
;-DMF_CUSTOMDEVICE_POLL_MS=10 ; time in ms between updating custom device, uncomment this if custom device needs to be updated regulary
;-DHAS_CONFIG_IN_FLASH ; undefine this and add your configuration to MFCustomDevicesConfig.h to save the config in Flash !!Core FW version must be at least 2.5.2!!
-I./src/src/MF_CustomDevice ; don't change this one!
-I./Template ; Include files for your custom device, replace "Template" by your folder name
build_src_filter =
+<../Template> ; build files for your custom device, replace "Template" by your folder name
lib_deps = ; You can add additional libraries if required
custom_core_firmware_version = 2.5.1 ; define the version from the core firmware files your build should base on
custom_device_folder = Template ; path to your Custom Device Sources, replace "Template" by your folder name
custom_community_project = Your_Project ; Should match "Project" from section "Community" within the board.json file, it's the name of the ZIP file
; Build settings for the Arduino Mega with Custom Firmware Template
[env:mobiflight_template_mega]
platform = atmelavr
board = megaatmega2560
framework = arduino
; nothing needs to be changed above this line
build_flags =
${env_template.build_flags} ; don't change this one!
-I./src/_Boards/Atmel/Board_Mega ; Include the required board definition. If you need your own definition, adapt this to your path (e.g. -I./CustomDevices/_template/_Boards)
'-DMOBIFLIGHT_TYPE="Mobiflight Template Mega"' ; this must match with "MobiFlightType" within the .json file
'-DMOBIFLIGHT_NAME="Mobiflight Template"' ; this will show up as Name in the settings dialog unless it gets change from there
build_src_filter =
${env.build_src_filter} ; don't change this one!
${env_template.build_src_filter} ; don't change this one!
lib_deps =
${env.lib_deps} ; don't change this one!
${env.custom_lib_deps_Atmel} ; don't change this one!
${env_template.lib_deps} ; don't change this one!
monitor_speed = 115200 ; don't change this one!
extra_scripts =
${env.extra_scripts} ; don't change this one!
custom_core_firmware_version = ${env_template.custom_core_firmware_version} ; don't change this one!
custom_community_project = ${env_template.custom_community_project} ; don't change this one!
custom_device_folder = ${env_template.custom_device_folder} ; don't change this one!
; Build settings for the Raspberry Pico with Custom Firmware Template
[env:mobiflight_template_raspberrypico]
platform = https://github.com/maxgerhardt/platform-raspberrypi.git
board = pico
framework = arduino
board_build.core = earlephilhower
board_build.filesystem_size = 0M
lib_ldf_mode = chain+
upload_protocol = mbed
; nothing needs to be changed above this line
build_flags =
${env_template.build_flags} ; don't change this one!
-I./src/_Boards/RaspberryPi/Pico ; Include the required board definition. If you need your own definition, adapt this to your path (e.g. -I./CustomDevices/_template/_Boards)
'-DMOBIFLIGHT_TYPE="Mobiflight Template RaspiPico"' ; this must match with "MobiFlightType" within the .json file
'-DMOBIFLIGHT_NAME="Mobiflight Template"' ; this will show up as Name in the settings dialog unless it gets change from there
build_src_filter =
${env.build_src_filter} ; don't change this one!
${env_template.build_src_filter} ; don't change this one!
lib_deps =
${env.lib_deps} ; don't change this one!
${env_template.lib_deps} ; don't change this one!
${env.custom_lib_deps_Pico} ; don't change this one!
monitor_speed = 115200 ; don't change this one!
extra_scripts =
${env.extra_scripts} ; don't change this one!
custom_core_firmware_version = ${env_template.custom_core_firmware_version} ; don't change this one!
custom_community_project = ${env_template.custom_community_project} ; don't change this one!
custom_device_folder = ${env_template.custom_device_folder} ; don't change this one!