SDK3.1.1.2 для Keil и GCC
This commit is contained in:
parent
d159ecb489
commit
a70092dd64
646 changed files with 18120 additions and 8454 deletions
29
README.md
29
README.md
|
|
@ -3,7 +3,7 @@ Custom firmware for Tuya [THB2](https://pvvx.github.io/THB2).
|
|||
|
||||
* Проект в начальной стадии разработки, до появления функционального OTA.
|
||||
|
||||
Прошивка V0.2 (файл TestTHB2.hex или TestTHB2_phy6222.hexf). Всё, кроме OTA работает стабильно.
|
||||
Прошивка V0.3 (файл TestTHB2.hex). Всё, кроме OTA работает стабильно.
|
||||
|
||||
## Основные характеристики:
|
||||
|
||||
|
|
@ -15,25 +15,12 @@ Custom firmware for Tuya [THB2](https://pvvx.github.io/THB2).
|
|||
|
||||
## Прошивка:
|
||||
|
||||
Прошить устройство возможно через USB-COM адаптер с выходами на 3.3В с помощью программы [PhyPlusKit](https://github.com/pvvx/PHY62x2/raw/master/PhyPlusKit/PhyPlusKit_v2.5.2c.rar):
|
||||
|
||||
1. Подключаются выводы GND, TX, RX, VCC (+3.3B).
|
||||
2. Вывод TM соединяется с VCC.
|
||||
3. В PhyPlusKit открываем COM порт, выбрав 115200 Baud.
|
||||
4. Во вкладке “HEX”, позиции рядом с кнопкой “Megre” выбираем файл прошивки с расширением “.hexf”.
|
||||
5. Кратковременно замыкаем вывод RESET на GND. В логе программы появляется “cmd>>:”. Вывод TM можно отключить от VCC.
|
||||
6. Нажимаем кнопку “Erase”. Ожидаем выполнения - в логе “Erase successfully!”.
|
||||
7. Нажимаем кнопку “Write”. Ожидаем выполнения - в логе “ Write registers successfully!”.
|
||||
8. Отключаем провода и устанавливаем батарейки. На этом пепрошивка устройтсва закончена.
|
||||
|
||||
Для запуска после прошивки при быстрой отладке - отключите TM от VCC и введите команду “reset” в нижней строке PhyPlusKit.
|
||||
|
||||
Другой вариант прошивки с помощью USB-COM адаптера с выходами на 3.3В:
|
||||
Прошить устройство возможно через USB-COM адаптер с выходами на 3.3В:
|
||||
|
||||
1. Соединить GND, TX, RX, RTS–RESET, VCC (+3.3B).
|
||||
2. Запустить:
|
||||
```
|
||||
python3 rdwr_phy6222.py -p COM11 -b 1000000 -r wh TestTHB2.hex
|
||||
python3 rdwr_phy6222.py -p COM11 -r wh TestTHB2.hex
|
||||
```
|
||||
3. Прошивка зашита. Устройство работает.
|
||||
|
||||
|
|
@ -48,7 +35,7 @@ python3 rdwr_phy6222.py -p COM11 -b 1000000 -r wh TestTHB2.hex
|
|||
1. Соединить GND, TX, RX, RTS–RESET, VCC (+3.3B).
|
||||
2. Запустить:
|
||||
```
|
||||
python3 rdwr_phy6222.py -p COM11 -b 1000000 -r rc 0x11000000 0x80000 ff_thb2.bin
|
||||
python3 rdwr_phy6222.py -p COM11 -r rc 0x11000000 0x80000 ff_thb2.bin
|
||||
```
|
||||
3. Полученный файл ff_thb2.bin сохранить.
|
||||
|
||||
|
|
@ -60,7 +47,15 @@ python3 rdwr_phy6222.py -p COM11 -b 1000000 -r rc 0x11000000 0x80000 ff_thb2.bin
|
|||
```
|
||||
python3 rdwr_phy6222.py -p COM11 -b 1000000 -r we 0 ff_thb2.bin
|
||||
```
|
||||
Не все адаптеры USB-COM поддерживают 1Mbit. Тогда удалите опцию `-b 1000000` или выберите другой Baud rate.
|
||||
|
||||
4. Прошивка зашита. Устройство работает.
|
||||
|
||||
|
||||
## Сборка прошивки.
|
||||
|
||||
Для сборки прошивки используется GNU Arm Embedded Toolchain или Keil.
|
||||
|
||||
Для работы в Eclipce используете импорт проекта и установите toolchain.path.
|
||||
|
||||
Дополнительная информация по чипам [PHY62xx](https://github.com/pvvx/PHY62x2).
|
||||
|
|
|
|||
5841
TestTHB2.hex
5841
TestTHB2.hex
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
43
bthome_phy6222/.autotools
Normal file
43
bthome_phy6222/.autotools
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<configurations>
|
||||
<configuration id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871">
|
||||
<option id="configure" value="configure"/>
|
||||
<option id="configdir" value=""/>
|
||||
<option id="cache-file" value=""/>
|
||||
<option id="help" value="false"/>
|
||||
<option id="no-create" value="false"/>
|
||||
<option id="quiet" value="false"/>
|
||||
<option id="version" value="false"/>
|
||||
<option id="host" value=""/>
|
||||
<option id="build" value=""/>
|
||||
<option id="target" value=""/>
|
||||
<option id="prefix" value=""/>
|
||||
<option id="exec-prefix" value=""/>
|
||||
<option id="libdir" value=""/>
|
||||
<option id="bindir" value=""/>
|
||||
<option id="sbindir" value=""/>
|
||||
<option id="includedir" value=""/>
|
||||
<option id="datadir" value=""/>
|
||||
<option id="sysconfdir" value=""/>
|
||||
<option id="infodir" value=""/>
|
||||
<option id="mandir" value=""/>
|
||||
<option id="srcdir" value=""/>
|
||||
<option id="localstatedir" value=""/>
|
||||
<option id="sharedstatedir" value=""/>
|
||||
<option id="libexecdir" value=""/>
|
||||
<option id="oldincludedir" value=""/>
|
||||
<option id="program-prefix" value=""/>
|
||||
<option id="program-suffix" value=""/>
|
||||
<option id="program-transform-name" value=""/>
|
||||
<option id="env_vars" value=""/>
|
||||
<option id="enable-maintainer-mode" value="false"/>
|
||||
<flag id="CFLAGS" value="CFLAGS|CXXFLAGS">
|
||||
<flagvalue id="cflags-debug" value="false"/>
|
||||
<flagvalue id="cflags-gprof" value="false"/>
|
||||
<flagvalue id="cflags-gcov" value="false"/>
|
||||
</flag>
|
||||
<option id="user" value=""/>
|
||||
<option id="autogen" value="autogen.sh"/>
|
||||
<option id="autogenOpts" value=""/>
|
||||
</configuration>
|
||||
</configurations>
|
||||
313
bthome_phy6222/.cproject
Normal file
313
bthome_phy6222/.cproject
Normal file
|
|
@ -0,0 +1,313 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871" moduleId="org.eclipse.cdt.core.settings" name="Default">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildProperties="" description="" id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871" name="Default" optionalBuildProperties="org.eclipse.cdt.docker.launcher.containerbuild.property.dockerdpath=,org.eclipse.cdt.docker.launcher.containerbuild.property.selectedvolumes=,org.eclipse.cdt.docker.launcher.containerbuild.property.volumes=" parent="org.eclipse.cdt.build.core.emptycfg">
|
||||
<folderInfo id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871.266191087" name="/" resourcePath="">
|
||||
<toolChain id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.321694806" name="Arm Cross GCC" superClass="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.2086137351" name="Architecture" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.architecture" value="ilg.gnuarmeclipse.managedbuild.cross.option.architecture.arm" valueType="enumerated"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix.1573243177" name="Prefix" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.prefix" value="arm-none-eabi-" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.suffix.2138977258" name="Suffix" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.suffix"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.c.496867299" name="C compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.c" value="gcc" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp.936656027" name="C++ compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.cpp" value="g++" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar.1277882401" name="Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.ar" value="ar" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy.64596022" name="Hex/Bin converter" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objcopy" value="objcopy" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump.1458924034" name="Listing generator" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.objdump" value="objdump" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.size.938741901" name="Size command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.size" value="size" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.make.1492431029" name="Build command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.make" value="make" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm.1435432446" name="Remove command" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.command.rm" value="rm" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath.1464967514" name="Use global path" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.useglobalpath"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.path.1105476225" name="Path" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.path"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.preferxpacksbin.935991251" name="Prefer xpacks/.bin" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.preferxpacksbin"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash.873874392" name="Create flash image" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createflash" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting.1249648689" name="Create extended listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.createlisting"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize.1093860890" name="Print size" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.addtools.printsize" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family.2006743873" name="Arm family (-mcpu)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.family" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.mcpu.cortex-m3" valueType="enumerated"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.architecture.807643629" name="Architecture (-march)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.architecture"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.998069334" name="Instruction set" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset" value="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.instructionset.thumb" valueType="enumerated"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.thumbinterwork.1908242427" name="Thumb interwork (-mthumb-interwork)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.thumbinterwork"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.endianness.1050190925" name="Endianness" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.endianness"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi.734584129" name="Float ABI" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.abi"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.unit.929775413" name="FPU Type" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.fpu.unit"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.unalignedaccess.2001661923" name="Unaligned access" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.unalignedaccess"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.mcmse.1078013278" name="TrustZone (-mcmse)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.arm.target.mcmse"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.family.1941546685" name="AArch64 family" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.family"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.crc.1952959404" name="Feature crc" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.crc"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.crypto.320688700" name="Feature crypto" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.crypto"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.fp.178664094" name="Feature fp" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.fp"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.simd.1946464323" name="Feature simd" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.feature.simd"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.cmodel.937607648" name="Code model" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.cmodel"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.strictalign.2035669794" name="Strict align (-mstrict-align)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.aarch64.target.strictalign"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.target.other.27204535" name="Other target flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.target.other"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level.790340251" name="Optimization Level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.level"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength.1518428613" name="Message length (-fmessage-length=0)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.messagelength"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar.413362812" name="'char' is signed (-fsigned-char)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.signedchar"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections.1300431824" name="Function sections (-ffunction-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.functionsections"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections.109839203" name="Data sections (-fdata-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.datasections"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon.1067100544" name="No common unitialized (-fno-common)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nocommon"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.noinlinefunctions.200341451" name="Do not inline functions (-fno-inline-functions)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.noinlinefunctions"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding.1769485083" name="Assume freestanding environment (-ffreestanding)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.freestanding"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin.1863194821" name="Disable builtin (-fno-builtin)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nobuiltin"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.spconstant.1404466087" name="Single precision constants (-fsingle-precision-constant)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.spconstant"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.PIC.476982625" name="Position independent code (-fPIC)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.PIC"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto.479416798" name="Link-time optimizer (-flto)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.lto"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nomoveloopinvariants.1875122041" name="Disable loop invariant move (-fno-move-loop-invariants)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.nomoveloopinvariants"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.other.781505121" name="Other optimization flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.optimization.other"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name.1934752823" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.name" value="GNU Tools for ARM Embedded Processors" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.id.590314933" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.toolchain.id" value="1287942917" valueType="string"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.syntaxonly.1758398611" name="Check syntax only (-fsyntax-only)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.syntaxonly"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pedantic.573233365" name="Pedantic (-pedantic)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pedantic"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pedanticerrors.510073757" name="Pedantic warnings as errors (-pedantic-errors)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pedanticerrors"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn.2036948871" name="Inhibit all warnings (-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.nowarn"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unused.1223830765" name="Warn on various unused elements (-Wunused)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.unused"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.uninitialized.1824101706" name="Warn on uninitialized variables (-Wuninitialised)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.uninitialized"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn.1746084522" name="Enable all common warnings (-Wall)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.allwarn"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn.65724203" name="Enable extra warnings (-Wextra)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.extrawarn"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration.1448591806" name="Warn on undeclared global function (-Wmissing-declaration)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.missingdeclaration"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion.506733683" name="Warn on implicit conversions (-Wconversion)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.conversion"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith.378165963" name="Warn if pointer arithmetic (-Wpointer-arith)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.pointerarith"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.padded.1345248400" name="Warn if padding is included (-Wpadded)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.padded"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow.1176587908" name="Warn if shadowed variable (-Wshadow)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.shadow"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop.24978179" name="Warn if suspicious logical ops (-Wlogical-op)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.logicalop"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn.1254259808" name="Warn if struct is returned (-Wagreggate-return)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.agreggatereturn"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal.391824535" name="Warn if floats are compared as equal (-Wfloat-equal)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.floatequal"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors.390549241" name="Generate errors instead of warnings (-Werror)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.toerrors"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.other.1381667987" name="Other warning flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.warnings.other"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level.1320692606" name="Debug level" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.level"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format.1764505575" name="Debug format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.format"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.prof.867335275" name="Generate prof information (-p)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.prof"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.gprof.1423046471" name="Generate gprof information (-pg)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.gprof"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.other.951936091" name="Other debugging flags" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.debugging.other"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.showDevicesTab.1778901874" name="showDevicesTab" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.showDevicesTab"/>
|
||||
<targetPlatform archList="all" binaryParser="org.eclipse.cdt.core.ELF" id="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform.1362119159" isAbstract="false" osList="all" superClass="ilg.gnuarmeclipse.managedbuild.cross.targetPlatform"/>
|
||||
<builder buildPath="${workspace_loc:/${ProjName}}/" enableAutoBuild="false" id="ilg.gnuarmeclipse.managedbuild.cross.builder.214507476" keepEnvironmentInBuildfile="false" managedBuildOn="false" name="Gnu Make Builder" parallelBuildOn="true" parallelizationNumber="optimal" superClass="ilg.gnuarmeclipse.managedbuild.cross.builder"/>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.521605472" name="GNU Arm Cross Assembler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor.832172772" name="Use preprocessor" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.assembler.usepreprocessor" value="true" valueType="boolean"/>
|
||||
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input.598587326" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.assembler.input"/>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1775991431" name="GNU Arm Cross C Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler">
|
||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths.1576445581" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.include.paths" useByScannerDiscovery="true" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""D:\MCU\GNU_Tools_ARM_Embedded\10.2021.10\arm-none-eabi\include""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/source}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/led_light}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/ota_app}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/DevInfo}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/SimpleProfile}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/Roles}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/misc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/inc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/clock}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/gpio}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/arch/cm0}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/include}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/controller}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/hci}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/host}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/libraries/secure}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/osal/include}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/key}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/uart}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/log}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/adc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/pwrmgr}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/timer}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/spi}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/pwm}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/kscan}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/dma}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/flash}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/spiflash}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/watchdog}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/i2c}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/libraries/fs}""/>
|
||||
</option>
|
||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs.387683329" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.compiler.defs" useByScannerDiscovery="true" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="DEBUG_INFO=0"/>
|
||||
<listOptionValue builtIn="false" value="MTU_SIZE=247"/>
|
||||
<listOptionValue builtIn="false" value="CFG_CP"/>
|
||||
<listOptionValue builtIn="false" value="OSAL_CBTIMER_NUM_TASKS=1"/>
|
||||
<listOptionValue builtIn="false" value="HOST_CONFIG=4"/>
|
||||
<listOptionValue builtIn="false" value="HCI_TL_NONE=1"/>
|
||||
<listOptionValue builtIn="false" value="ENABLE_LOG_ROM_=0"/>
|
||||
<listOptionValue builtIn="false" value="_BUILD_FOR_DTM_=0"/>
|
||||
<listOptionValue builtIn="false" value="DBG_ROM_MAIN=0"/>
|
||||
<listOptionValue builtIn="false" value="APP_CFG=0"/>
|
||||
<listOptionValue builtIn="false" value="OSALMEM_METRICS=0"/>
|
||||
<listOptionValue builtIn="false" value="PHY_MCU_TYPE=MCU_BUMBEE_M0"/>
|
||||
<listOptionValue builtIn="false" value="CFG_SLEEP_MODE=PWR_MODE_SLEEP"/>
|
||||
<listOptionValue builtIn="false" value="DEF_GAPBOND_MGR_ENABLE=0"/>
|
||||
<listOptionValue builtIn="false" value="USE_FS=0"/>
|
||||
<listOptionValue builtIn="false" value="MAX_NUM_LL_CONN=1"/>
|
||||
<listOptionValue builtIn="false" value="ADV_NCONN_CFG=0x01"/>
|
||||
<listOptionValue builtIn="false" value="ADV_CONN_CFG=0x02"/>
|
||||
<listOptionValue builtIn="false" value="SCAN_CFG=0x04"/>
|
||||
<listOptionValue builtIn="false" value="INIT_CFG=0x08"/>
|
||||
<listOptionValue builtIn="false" value="BROADCASTER_CFG=0x01"/>
|
||||
<listOptionValue builtIn="false" value="OBSERVER_CFG=0x02"/>
|
||||
<listOptionValue builtIn="false" value="PERIPHERAL_CFG=0x04"/>
|
||||
<listOptionValue builtIn="false" value="CENTRAL_CFG=0x08"/>
|
||||
</option>
|
||||
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.1659095882" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.1120283720" name="GNU Arm Cross C++ Compiler" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler">
|
||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.include.paths.1769584270" name="Include paths (-I)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.include.paths" useByScannerDiscovery="true" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value=""D:\MCU\GNU_Tools_ARM_Embedded\10.2021.10\arm-none-eabi\include""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/source}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/led_light}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/ota_app}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/DevInfo}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/SimpleProfile}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/profiles/Roles}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/misc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/inc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/clock}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/gpio}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/arch/cm0}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/include}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/controller}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/hci}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/ble/host}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/libraries/secure}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/osal/include}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/key}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/uart}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/log}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/adc}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/pwrmgr}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/timer}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/spi}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/libraries/fs}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/pwm}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/kscan}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/dma}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/flash}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/spiflash}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/watchdog}""/>
|
||||
<listOptionValue builtIn="false" value=""${workspace_loc:/${ProjName}/SDK/components/driver/i2c}""/>
|
||||
</option>
|
||||
<option IS_BUILTIN_EMPTY="false" IS_VALUE_EMPTY="false" id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs.778573213" name="Defined symbols (-D)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.compiler.defs" useByScannerDiscovery="true" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="DEBUG_INFO=0"/>
|
||||
<listOptionValue builtIn="false" value="MTU_SIZE=247"/>
|
||||
<listOptionValue builtIn="false" value="CFG_CP"/>
|
||||
<listOptionValue builtIn="false" value="OSAL_CBTIMER_NUM_TASKS=1"/>
|
||||
<listOptionValue builtIn="false" value="HOST_CONFIG=4"/>
|
||||
<listOptionValue builtIn="false" value="HCI_TL_NONE=1"/>
|
||||
<listOptionValue builtIn="false" value="ENABLE_LOG_ROM_=0"/>
|
||||
<listOptionValue builtIn="false" value="_BUILD_FOR_DTM_=0"/>
|
||||
<listOptionValue builtIn="false" value="DBG_ROM_MAIN=0"/>
|
||||
<listOptionValue builtIn="false" value="APP_CFG=0"/>
|
||||
<listOptionValue builtIn="false" value="OSALMEM_METRICS=0"/>
|
||||
<listOptionValue builtIn="false" value="PHY_MCU_TYPE=MCU_BUMBEE_M0"/>
|
||||
<listOptionValue builtIn="false" value="CFG_SLEEP_MODE=PWR_MODE_SLEEP"/>
|
||||
<listOptionValue builtIn="false" value="DEF_GAPBOND_MGR_ENABLE=0"/>
|
||||
<listOptionValue builtIn="false" value="USE_FS=0"/>
|
||||
<listOptionValue builtIn="false" value="MAX_NUM_LL_CONN=1"/>
|
||||
<listOptionValue builtIn="false" value="ADV_NCONN_CFG=0x01"/>
|
||||
<listOptionValue builtIn="false" value="ADV_CONN_CFG=0x02"/>
|
||||
<listOptionValue builtIn="false" value="SCAN_CFG=0x04"/>
|
||||
<listOptionValue builtIn="false" value="INIT_CFG=0x08"/>
|
||||
<listOptionValue builtIn="false" value="BROADCASTER_CFG=0x01"/>
|
||||
<listOptionValue builtIn="false" value="OBSERVER_CFG=0x02"/>
|
||||
<listOptionValue builtIn="false" value="PERIPHERAL_CFG=0x04"/>
|
||||
<listOptionValue builtIn="false" value="CENTRAL_CFG=0x08"/>
|
||||
</option>
|
||||
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1110288971" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker.1665333717" name="GNU Arm Cross C Linker" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.c.linker">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections.961682337" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.c.linker.gcsections" value="true" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.490257680" name="GNU Arm Cross C++ Linker" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections.1990176696" name="Remove unused sections (-Xlinker --gc-sections)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.cpp.linker.gcsections" value="true" valueType="boolean"/>
|
||||
<inputType id="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input.1948732723" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver.285396154" name="GNU Arm Cross Archiver" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.archiver"/>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash.958875753" name="GNU Arm Cross Create Flash Image" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createflash"/>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting.1075135616" name="GNU Arm Cross Create Listing" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.createlisting">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source.270050209" name="Display source (--source|-S)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.source" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders.1416561000" name="Display all headers (--all-headers|-x)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.allheaders" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle.469460016" name="Demangle names (--demangle|-C)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.demangle" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers.1948857360" name="Display line numbers (--line-numbers|-l)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.linenumbers" value="true" valueType="boolean"/>
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide.1713552124" name="Wide lines (--wide|-w)" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.createlisting.wide" value="true" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize.1238311914" name="GNU Arm Cross Print Size" superClass="ilg.gnuarmeclipse.managedbuild.cross.tool.printsize">
|
||||
<option id="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format.1518345198" name="Size format" superClass="ilg.gnuarmeclipse.managedbuild.cross.option.printsize.format"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
<storageModule moduleId="ilg.gnumcueclipse.managedbuild.packs"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="thb2.null.820537587" name="thb2"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Default">
|
||||
<resource resourceType="PROJECT" workspacePath="/thb2"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871;ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871.266191087;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1990060925;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.382006300">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871;ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871.266191087;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.1120283720;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1110288971">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871;ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871.266191087;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.1177097648;ilg.gnuarmeclipse.managedbuild.cross.tool.cpp.compiler.input.1321694659">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871;ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871.266191087;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.1775991431;ilg.gnuarmeclipse.managedbuild.cross.tool.c.compiler.input.1659095882">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.make.core.buildtargets">
|
||||
<buildTargets>
|
||||
<target name="all" path="" targetID="org.eclipse.cdt.build.MakeTargetBuilder">
|
||||
<buildCommand>${cross_make}</buildCommand>
|
||||
<buildArguments>-j24</buildArguments>
|
||||
<buildTarget>all</buildTarget>
|
||||
<stopOnError>true</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="clean" path="" targetID="org.eclipse.cdt.build.MakeTargetBuilder">
|
||||
<buildCommand>${cross_make}</buildCommand>
|
||||
<buildArguments>-j24</buildArguments>
|
||||
<buildTarget>clean</buildTarget>
|
||||
<stopOnError>true</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
<target name="flash" path="" targetID="org.eclipse.cdt.build.MakeTargetBuilder">
|
||||
<buildCommand>${cross_make}</buildCommand>
|
||||
<buildArguments>-j24</buildArguments>
|
||||
<buildTarget>flash</buildTarget>
|
||||
<stopOnError>true</stopOnError>
|
||||
<useDefaultCommand>true</useDefaultCommand>
|
||||
<runAllBuilders>true</runAllBuilders>
|
||||
</target>
|
||||
</buildTargets>
|
||||
</storageModule>
|
||||
</cproject>
|
||||
|
|
@ -2,5 +2,6 @@ bin
|
|||
Listings
|
||||
Objects
|
||||
TestTHB2.asm
|
||||
TestTHB2.uvguix.pvvx
|
||||
TestTHB2.uvguix.*
|
||||
TestTHB2.uvoptx
|
||||
build
|
||||
28
bthome_phy6222/.project
Normal file
28
bthome_phy6222/.project
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>bthome_phy6222</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.autotools.core.autotoolsNatureV2</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
<nature>org.eclipse.cdt.core.ccnature</nature>
|
||||
</natures>
|
||||
</projectDescription>
|
||||
15
bthome_phy6222/.settings/language.settings.xml
Normal file
15
bthome_phy6222/.settings/language.settings.xml
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<project>
|
||||
<configuration id="ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871" name="Default">
|
||||
<extension point="org.eclipse.cdt.core.LanguageSettingsProvider">
|
||||
<provider copy-of="extension" id="org.eclipse.cdt.ui.UserLanguageSettingsProvider"/>
|
||||
<provider-reference id="org.eclipse.cdt.core.ReferencedProjectsLanguageSettingsProvider" ref="shared-provider"/>
|
||||
<provider class="org.eclipse.cdt.managedbuilder.language.settings.providers.GCCBuildCommandParser" id="org.eclipse.cdt.managedbuilder.core.GCCBuildCommandParser" keep-relative-paths="false" name="CDT GCC Build Output Parser" parameter="([^/\\\\]*)((g?cc)|([gc]\+\+)|(clang))" prefer-non-shared="true"/>
|
||||
<provider class="org.eclipse.cdt.managedbuilder.language.settings.providers.GCCBuiltinSpecsDetector" console="false" env-hash="-940467565923246545" id="org.eclipse.embedcdt.managedbuild.cross.arm.core.GCCBuiltinSpecsDetector" keep-relative-paths="false" name="CDT Arm Cross GCC Built-in Compiler Settings" parameter="${COMMAND} ${FLAGS} ${cross_toolchain_flags} -E -P -v -dD "${INPUTS}"" prefer-non-shared="true">
|
||||
<language-scope id="org.eclipse.cdt.core.gcc"/>
|
||||
<language-scope id="org.eclipse.cdt.core.g++"/>
|
||||
</provider>
|
||||
<provider-reference id="org.eclipse.cdt.managedbuilder.core.MBSLanguageSettingsProvider" ref="shared-provider"/>
|
||||
</extension>
|
||||
</configuration>
|
||||
</project>
|
||||
109
bthome_phy6222/.settings/org.eclipse.cdt.codan.core.prefs
Normal file
109
bthome_phy6222/.settings/org.eclipse.cdt.codan.core.prefs
Normal file
|
|
@ -0,0 +1,109 @@
|
|||
eclipse.preferences.version=1
|
||||
org.eclipse.cdt.codan.checkers.errnoreturn=Warning
|
||||
org.eclipse.cdt.codan.checkers.errnoreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No return\\")",implicit\=>false}
|
||||
org.eclipse.cdt.codan.checkers.errreturnvalue=Error
|
||||
org.eclipse.cdt.codan.checkers.errreturnvalue.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused return value\\")"}
|
||||
org.eclipse.cdt.codan.checkers.localvarreturn=-Warning
|
||||
org.eclipse.cdt.codan.checkers.localvarreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Returning the address of a local variable\\")"}
|
||||
org.eclipse.cdt.codan.checkers.nocommentinside=-Error
|
||||
org.eclipse.cdt.codan.checkers.nocommentinside.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Nesting comments\\")"}
|
||||
org.eclipse.cdt.codan.checkers.nolinecomment=-Error
|
||||
org.eclipse.cdt.codan.checkers.nolinecomment.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Line comments\\")"}
|
||||
org.eclipse.cdt.codan.checkers.noreturn=Error
|
||||
org.eclipse.cdt.codan.checkers.noreturn.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No return value\\")",implicit\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.AbstractClassCreation.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Abstract class cannot be instantiated\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.AmbiguousProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Ambiguous problem\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.AssignmentInConditionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Assignment in condition\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.AssignmentToItselfProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Assignment to itself\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.BlacklistProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.BlacklistProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Function or method is blacklisted\\")",blacklist\=>()}
|
||||
org.eclipse.cdt.codan.internal.checkers.CStyleCastProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.CStyleCastProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"C-Style cast instead of C++ cast\\")",checkMacro\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.CaseBreakProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"No break at end of case\\")",no_break_comment\=>"no break",last_case_param\=>false,empty_case_param\=>false,enable_fallthrough_quickfix_param\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.CatchByReference=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.CatchByReference.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Catching by reference is recommended\\")",unknown\=>false,exceptions\=>()}
|
||||
org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.CircularReferenceProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Circular inheritance\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.ClassMembersInitialization.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Class members should be properly initialized\\")",skip\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.CopyrightProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.CopyrightProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Lack of copyright information\\")",regex\=>".*Copyright.*"}
|
||||
org.eclipse.cdt.codan.internal.checkers.DecltypeAutoProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.DecltypeAutoProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid 'decltype(auto)' specifier\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.FieldResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Field cannot be resolved\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.FloatCompareProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.FloatCompareProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Direct float comparison\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.FunctionResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Function cannot be resolved\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.GotoStatementProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.GotoStatementProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Goto statement used\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.InvalidArguments=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.InvalidArguments.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid arguments\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.InvalidTemplateArgumentsProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid template argument\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.LabelStatementNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Label statement not found\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MagicNumberProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MagicNumberProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Avoid magic numbers\\")",checkArray\=>true,checkOperatorParen\=>true,exceptions\=>(1,0,-1,2,1.0,0.0,-1.0)}
|
||||
org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.MemberDeclarationNotFoundProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Member declaration not found\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.MethodResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Method cannot be resolved\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MissCaseProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MissCaseProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Missing cases in switch\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MissDefaultProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MissDefaultProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Missing default in switch\\")",defaultWithAllEnums\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.MissReferenceProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MissReferenceProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Missing reference return value in assignment operator\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MissSelfCheckProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MissSelfCheckProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Missing self check in assignment operator\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.MultipleDeclarationsProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.MultipleDeclarationsProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Multiple variable declaration\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker=-Info
|
||||
org.eclipse.cdt.codan.internal.checkers.NamingConventionFunctionChecker.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Name convention for function\\")",pattern\=>"^[a-z]",macro\=>true,exceptions\=>()}
|
||||
org.eclipse.cdt.codan.internal.checkers.NoDiscardProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.NoDiscardProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Return value not evaluated\\")",macro\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.NonVirtualDestructorProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Class has a virtual method and non-virtual destructor\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.OverloadProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.OverloadProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid overload\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.RedeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid redeclaration\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.RedefinitionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Invalid redefinition\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.ReturnStyleProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Return with parenthesis\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.ScanfFormatStringSecurityProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Format String Vulnerability\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.ShallowCopyProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.ShallowCopyProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Miss copy constructor or assignment operator\\")",onlynew\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.StatementHasNoEffectProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Statement has no effect\\")",macro\=>true,exceptions\=>()}
|
||||
org.eclipse.cdt.codan.internal.checkers.StaticVariableInHeaderProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.StaticVariableInHeaderProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Static variable in header file\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.SuggestedParenthesisProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Suggested parenthesis around expression\\")",paramNot\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.SuspiciousSemicolonProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Suspicious semicolon\\")",else\=>false,afterelse\=>false}
|
||||
org.eclipse.cdt.codan.internal.checkers.SymbolShadowingProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.SymbolShadowingProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Symbol shadowing\\")",paramFuncParameters\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.TypeResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Type cannot be resolved\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedFunctionDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused function declaration\\")",macro\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedStaticFunctionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused static function\\")",macro\=>true}
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem=Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.UnusedVariableDeclarationProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Unused variable declaration in file scope\\")",macro\=>true,exceptions\=>("@(\#)","$Id")}
|
||||
org.eclipse.cdt.codan.internal.checkers.UsingInHeaderProblem=-Warning
|
||||
org.eclipse.cdt.codan.internal.checkers.UsingInHeaderProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Using directive in header\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem=Error
|
||||
org.eclipse.cdt.codan.internal.checkers.VariableResolutionProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Symbol is not resolved\\")"}
|
||||
org.eclipse.cdt.codan.internal.checkers.VirtualMethodCallProblem=-Error
|
||||
org.eclipse.cdt.codan.internal.checkers.VirtualMethodCallProblem.params={launchModes\=>{RUN_ON_FULL_BUILD\=>true,RUN_ON_INC_BUILD\=>true,RUN_ON_FILE_OPEN\=>false,RUN_ON_FILE_SAVE\=>false,RUN_AS_YOU_TYPE\=>true,RUN_ON_DEMAND\=>true},suppression_comment\=>"@suppress(\\"Virtual method call in constructor/destructor\\")"}
|
||||
6
bthome_phy6222/.settings/org.eclipse.cdt.core.prefs
Normal file
6
bthome_phy6222/.settings/org.eclipse.cdt.core.prefs
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
doxygen/doxygen_new_line_after_brief=true
|
||||
doxygen/doxygen_use_brief_tag=false
|
||||
doxygen/doxygen_use_javadoc_tags=true
|
||||
doxygen/doxygen_use_pre_tag=false
|
||||
doxygen/doxygen_use_structural_commands=false
|
||||
eclipse.preferences.version=1
|
||||
|
|
@ -0,0 +1,13 @@
|
|||
eclipse.preferences.version=1
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/CPATH/delimiter=;
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/CPATH/operation=remove
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/CPLUS_INCLUDE_PATH/delimiter=;
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/CPLUS_INCLUDE_PATH/operation=remove
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/C_INCLUDE_PATH/delimiter=;
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/C_INCLUDE_PATH/operation=remove
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/append=true
|
||||
environment/buildEnvironmentInclude/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/appendContributed=true
|
||||
environment/buildEnvironmentLibrary/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/LIBRARY_PATH/delimiter=;
|
||||
environment/buildEnvironmentLibrary/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/LIBRARY_PATH/operation=remove
|
||||
environment/buildEnvironmentLibrary/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/append=true
|
||||
environment/buildEnvironmentLibrary/ilg.gnuarmeclipse.managedbuild.cross.toolchain.base.28719871/appendContributed=true
|
||||
|
|
@ -0,0 +1,2 @@
|
|||
eclipse.preferences.version=1
|
||||
toolchain.path.1287942917=D\:\\MCU\\GNU_Tools_ARM_Embedded\\13.2.rel1\\bin
|
||||
274
bthome_phy6222/Makefile
Normal file
274
bthome_phy6222/Makefile
Normal file
|
|
@ -0,0 +1,274 @@
|
|||
##############################################################################
|
||||
PROJECT_NAME = bthome_phy6222
|
||||
##############################################################################
|
||||
COM_PORT = COM11
|
||||
|
||||
##############################################################################
|
||||
# Source
|
||||
|
||||
SRC_PATH = ./source
|
||||
|
||||
SRC_PRJ = main.c
|
||||
SRC_PRJ += battery.c
|
||||
SRC_PRJ += battservice.c
|
||||
SRC_PRJ += bthome_beacon.c
|
||||
SRC_PRJ += osal_peripheral.c
|
||||
SRC_PRJ += peripheral_main.c
|
||||
SRC_PRJ += sbp_profile_ota.c
|
||||
SRC_PRJ += sensors.c
|
||||
SRC_PRJ += thb2_main.c
|
||||
SRC_PRJ += thservice.c
|
||||
|
||||
INCLUDES = -I$(SRC_PATH)
|
||||
|
||||
SRCS = $(addprefix $(SRC_PATH)/, $(SRC_PRJ))
|
||||
|
||||
##############################################################################
|
||||
BIN_DIR = ./bin
|
||||
OBJ_DIR = ./build
|
||||
SDK_PATH = ./SDK
|
||||
GCC_PATH =
|
||||
PYTHON = python3
|
||||
|
||||
CC = $(GCC_PATH)arm-none-eabi-gcc
|
||||
OBJCOPY = $(GCC_PATH)arm-none-eabi-objcopy
|
||||
OBJDUMP = $(GCC_PATH)arm-none-eabi-objdump
|
||||
SIZE = $(GCC_PATH)arm-none-eabi-size
|
||||
READELF = $(GCC_PATH)arm-none-eabi-readelf
|
||||
|
||||
CFLAGS = -Os
|
||||
CFLAGS += -W -Wall --std=gnu99
|
||||
CFLAGS += --static -nostartfiles -nostdlib
|
||||
CFLAGS += -mcpu=cortex-m0 -mthumb -mthumb-interwork
|
||||
CFLAGS += -fno-diagnostics-show-caret
|
||||
CFLAGS += -fdata-sections -ffunction-sections
|
||||
CFLAGS += -funsigned-char -funsigned-bitfields
|
||||
CFLAGS += -specs=nosys.specs
|
||||
CFLAGS += -Wl,--gc-sections
|
||||
CFLAGS += -Wl,--start-group -lgcc -lnosys -Wl,--end-group
|
||||
#CFLAGS += -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
||||
|
||||
LDFLAGS += -mcpu=cortex-m0 -mthumb -mthumb-interwork
|
||||
LDFLAGS += -Wl,--gc-sections
|
||||
LDFLAGS += -Wl,--start-group -lgcc -lnosys -Wl,--end-group
|
||||
LDFLAGS += -Wl,--script=$(SDK_PATH)/misc/phy6222.ld
|
||||
LDFLAGS += -Wl,--just-symbols=$(SDK_PATH)/misc/bb_rom_sym_m0.gcc
|
||||
LDFLAGS += -Wl,-Map=$(OBJ_DIR)/$(PROJECT_NAME).map
|
||||
|
||||
INCLUDES += -I$(SDK_PATH)/misc
|
||||
INCLUDES += -I$(SDK_PATH)/misc/CMSIS/include
|
||||
INCLUDES += -I$(SDK_PATH)/components/arch/cm0
|
||||
INCLUDES += -I$(SDK_PATH)/components/ble/controller
|
||||
INCLUDES += -I$(SDK_PATH)/components/ble/include
|
||||
INCLUDES += -I$(SDK_PATH)/components/ble/hci
|
||||
INCLUDES += -I$(SDK_PATH)/components/ble/host
|
||||
INCLUDES += -I$(SDK_PATH)/components/inc
|
||||
INCLUDES += -I$(SDK_PATH)/components/osal/include
|
||||
INCLUDES += -I$(SDK_PATH)/components/common
|
||||
INCLUDES += -I$(SDK_PATH)/components/profiles/ota_app
|
||||
INCLUDES += -I$(SDK_PATH)/components/profiles/DevInfo
|
||||
INCLUDES += -I$(SDK_PATH)/components/profiles/SimpleProfile
|
||||
INCLUDES += -I$(SDK_PATH)/components/profiles/Roles
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/adc
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/bsp_button
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/clock
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/dma
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/flash
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/gpio
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/i2c
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/key
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/kscan
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/led_light
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/log
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/pwm
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/pwrmgr
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/qdec
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/spi
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/spiflash
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/timer
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/uart
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/voice
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/watchdog
|
||||
INCLUDES += -I$(SDK_PATH)/components/libraries/crc16
|
||||
INCLUDES += -I$(SDK_PATH)/components/libraries/cliface
|
||||
INCLUDES += -I$(SDK_PATH)/components/libraries/fs
|
||||
INCLUDES += -I$(SDK_PATH)/components/driver/watchdog
|
||||
|
||||
|
||||
###########################################
|
||||
# LIBs
|
||||
SRCS += $(SDK_PATH)/lib/rf/patch.c
|
||||
SRCS += $(SDK_PATH)/lib/sec/phy_sec_ext.c
|
||||
SRCS += $(SDK_PATH)/lib/sec/aes.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/att_client.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/att_server.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/att_util.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_centdevmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_centlinkmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_configmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_devmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_linkmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_peridevmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_perilinkmgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_simpletask.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gap_task.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gatt_client.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gatt_server.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gatt_task.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/gatt_uuid.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/l2cap_if.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/l2cap_task.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/l2cap_util.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/linkdb.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/sm_intpairing.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/sm_mgr.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/sm_pairing.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/smp.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/sm_rsppairing.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_host/sm_task.c
|
||||
ifdef LIB_BLE_ADD
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_common.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_enc.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_hw_drv.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_hwItf.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_masterEndCauses.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_slaveEndCauses.c
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/ll_sleep.c
|
||||
endif
|
||||
SRCS += $(SDK_PATH)/lib/ble_controller/rf_phy_driver.c
|
||||
|
||||
###########################################
|
||||
# SDK
|
||||
SRCS += $(SDK_PATH)/components/driver/clock/clock.c
|
||||
SRCS += $(SDK_PATH)/components/driver/flash/flash.c
|
||||
SRCS += $(SDK_PATH)/components/driver/gpio/gpio.c
|
||||
#SRCS += $(SDK_PATH)/components/driver/key/key.c
|
||||
#SRCS += $(SDK_PATH)/components/driver/led_light/led_light.c
|
||||
#SRCS += $(SDK_PATH)/components/driver/pwm/pwm.c
|
||||
SRCS += $(SDK_PATH)/components/driver/pwrmgr/pwrmgr.c
|
||||
SRCS += $(SDK_PATH)/components/driver/timer/timer.c
|
||||
SRCS += $(SDK_PATH)/components/driver/uart/uart.c
|
||||
SRCS += $(SDK_PATH)/components/driver/watchdog/watchdog.c
|
||||
SRCS += $(SDK_PATH)/components/driver/log/my_printf.c
|
||||
|
||||
#SRCS += $(SDK_PATH)/components/profiles/Roles/central.c
|
||||
#SRCS += $(SDK_PATH)/components/profiles/ota_app/ota_app_service.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/Roles/peripheral.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/Roles/gapbondmgr.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/Roles/gapgattserver.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/Roles/gap.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/GATT/gattservapp.c
|
||||
SRCS += $(SDK_PATH)/components/profiles/DevInfo/devinfoservice.c
|
||||
|
||||
SRCS += $(SDK_PATH)/components/osal/snv/osal_snv.c
|
||||
SRCS += $(SDK_PATH)/components/libraries/fs/fs.c
|
||||
|
||||
SRCS += $(SDK_PATH)/misc/jump_table.c
|
||||
|
||||
##############################################################################
|
||||
|
||||
INCLUDES += -I$(SDK_PATH)/misc/CMSIS/device/phyplus
|
||||
|
||||
STARTUP_ASM = $(SDK_PATH)/misc/CMSIS/device/phyplus/phy6222_start.s
|
||||
|
||||
SRCS += $(SDK_PATH)/misc/CMSIS/device/phyplus/phy6222_cstart.c
|
||||
SRCS += $(SDK_PATH)/misc/CMSIS/device/phyplus/phy6222_vectors.c
|
||||
|
||||
STARTUP_OBJ =
|
||||
|
||||
##############################################################################
|
||||
|
||||
DEFINES = -D__GCC
|
||||
DEFINES += -DDEBUG_INFO=0
|
||||
DEFINES += -DMTU_SIZE=247
|
||||
DEFINES += -DCFG_SLEEP_MODE=PWR_MODE_SLEEP
|
||||
DEFINES += -DADV_NCONN_CFG=0x01
|
||||
DEFINES += -DADV_CONN_CFG=0x02
|
||||
DEFINES += -DSCAN_CFG=0x04
|
||||
DEFINES += -DINIT_CFG=0x08
|
||||
DEFINES += -DBROADCASTER_CFG=0x01
|
||||
DEFINES += -DOBSERVER_CFG=0x02
|
||||
DEFINES += -DPERIPHERAL_CFG=0x04
|
||||
DEFINES += -DCENTRAL_CFG=0x08
|
||||
DEFINES += -DHOST_CONFIG=0x4
|
||||
DEFINES += -DARMCM0
|
||||
DEFINES += -D_RTE_
|
||||
DEFINES += -DCFG_CP
|
||||
DEFINES += -DOSAL_CBTIMER_NUM_TASKS=1
|
||||
DEFINES += -DHCI_TL_NONE=1
|
||||
DEFINES += -DENABLE_LOG_ROM_=0
|
||||
DEFINES += -D_OBJ_DIR_FOR_DTM_=0
|
||||
DEFINES += -DDBG_ROM_MAIN=0
|
||||
DEFINES += -DAPP_CFG=0
|
||||
DEFINES += -DOSALMEM_METRICS=0
|
||||
DEFINES += -DPHY_MCU_TYPE=MCU_BUMBEE_M0
|
||||
DEFINES += -DDEF_GAPBOND_MGR_ENABLE=0
|
||||
DEFINES += -DUSE_FS=0
|
||||
DEFINES += -DMAX_NUM_LL_CONN=1
|
||||
|
||||
CFLAGS += $(DEFINES) $(INCLUDES)
|
||||
|
||||
#SRC_O = $(patsubst %.c,%.o,$(patsubst sdk/%, $(SDK_PATH)%, $(SRCS)))
|
||||
|
||||
SRC_O = $(SRCS:%.c=%.o) $(STARTUP_ASM:%.s=%.o)
|
||||
OBJS = $(patsubst %, $(OBJ_DIR)/%, $(patsubst ./%, %, $(SRC_O)))
|
||||
|
||||
DEPENDENCY_LIST = $(OBJS:%o=%d)
|
||||
|
||||
##############################################################################
|
||||
.PHONY: all directory clean size flash
|
||||
|
||||
all: directory $(SRC_O) $(OBJ_DIR)/$(PROJECT_NAME).elf $(OBJ_DIR)/$(PROJECT_NAME).hex $(OBJ_DIR)/$(PROJECT_NAME).asm size
|
||||
|
||||
%.elf: $(SRC_O)
|
||||
@echo LD: $@
|
||||
@$(CC) $(LDFLAGS) $(OBJS) $(LIBS) -o $@
|
||||
|
||||
%.hex: %.elf
|
||||
@echo OBJCOPY: $@
|
||||
@$(OBJCOPY) -O ihex $^ $@
|
||||
|
||||
%.bin: %.elf
|
||||
@echo OBJCOPY: $@
|
||||
@$(OBJCOPY) -O binary $^ $@
|
||||
|
||||
%.asm: %.elf
|
||||
@echo OBJDUMP: $@
|
||||
@$(OBJDUMP) -s -S $^ >$@
|
||||
|
||||
|
||||
%.o : %.c
|
||||
@echo CC: $<
|
||||
@mkdir -p $(OBJ_DIR)/$(dir $@)
|
||||
@$(CC) $(CFLAGS) $(INCFLAGS) -c $< -o $(OBJ_DIR)/$@
|
||||
@$(CC) -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
||||
|
||||
%.o : %.s
|
||||
@echo CC: $<
|
||||
@mkdir -p $(OBJ_DIR)/$(dir $@)
|
||||
@$(CC) $(CFLAGS) $(INCFLAGS) -c $< -o $(OBJ_DIR)/$@
|
||||
@$(CC) -MM $(CFLAGS) $(INCFLAGS) $< -MT $@ -MF $(OBJ_DIR)/$(patsubst %.o,%.d,$@)
|
||||
|
||||
flash:
|
||||
@$(PYTHON) ./rdwr_phy6222.py -p$(COM_PORT) -b 1000000 -r wh $(OBJ_DIR)/$(PROJECT_NAME).hex
|
||||
|
||||
erase_and_flash:
|
||||
@$(PYTHON) ./rdwr_phy6222.py -p$(COM_PORT) -b 1000000 -e -r wh $(OBJ_DIR)/$(PROJECT_NAME).hex
|
||||
|
||||
directory:
|
||||
@mkdir -p $(OBJ_DIR)
|
||||
|
||||
size: $(OBJ_DIR)/$(PROJECT_NAME).elf
|
||||
@echo size:
|
||||
#@$(SIZE) -t $^
|
||||
@$(READELF) -l $^
|
||||
@echo
|
||||
|
||||
clean:
|
||||
@echo clean
|
||||
@-rm -rf $(OBJ_DIR)
|
||||
|
||||
-include $(DEPENDENCY_LIST)
|
||||
|
||||
VPATH:=$(OBJ_DIR) $(SDK_PATH)
|
||||
168
bthome_phy6222/RTE/Device/ARMCM0/startup_ARMCM0.s
Normal file
168
bthome_phy6222/RTE/Device/ARMCM0/startup_ARMCM0.s
Normal file
|
|
@ -0,0 +1,168 @@
|
|||
;/**************************************************************************//**
|
||||
; * @file startup_ARMCM0.s
|
||||
; * @brief CMSIS Core Device Startup File for
|
||||
; * ARMCM0 Device
|
||||
; * @version V1.0.1
|
||||
; * @date 23. July 2019
|
||||
; ******************************************************************************/
|
||||
;/*
|
||||
; * Copyright (c) 2009-2019 Arm Limited. All rights reserved.
|
||||
; *
|
||||
; * SPDX-License-Identifier: Apache-2.0
|
||||
; *
|
||||
; * Licensed under the Apache License, Version 2.0 (the License); you may
|
||||
; * not use this file except in compliance with the License.
|
||||
; * You may obtain a copy of the License at
|
||||
; *
|
||||
; * www.apache.org/licenses/LICENSE-2.0
|
||||
; *
|
||||
; * Unless required by applicable law or agreed to in writing, software
|
||||
; * distributed under the License is distributed on an AS IS BASIS, WITHOUT
|
||||
; * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
; * See the License for the specific language governing permissions and
|
||||
; * limitations under the License.
|
||||
; */
|
||||
|
||||
;//-------- <<< Use Configuration Wizard in Context Menu >>> ------------------
|
||||
|
||||
|
||||
;<h> Stack Configuration
|
||||
; <o> Stack Size (in Bytes) <0x0-0xFFFFFFFF:8>
|
||||
;</h>
|
||||
|
||||
Stack_Size EQU 0x00000400
|
||||
|
||||
AREA STACK, NOINIT, READWRITE, ALIGN=3
|
||||
__stack_limit
|
||||
Stack_Mem SPACE Stack_Size
|
||||
__initial_sp
|
||||
|
||||
|
||||
;<h> Heap Configuration
|
||||
; <o> Heap Size (in Bytes) <0x0-0xFFFFFFFF:8>
|
||||
;</h>
|
||||
|
||||
Heap_Size EQU 0x00000C00
|
||||
|
||||
IF Heap_Size != 0 ; Heap is provided
|
||||
AREA HEAP, NOINIT, READWRITE, ALIGN=3
|
||||
__heap_base
|
||||
Heap_Mem SPACE Heap_Size
|
||||
__heap_limit
|
||||
ENDIF
|
||||
|
||||
|
||||
PRESERVE8
|
||||
THUMB
|
||||
|
||||
|
||||
; Vector Table Mapped to Address 0 at Reset
|
||||
|
||||
AREA RESET, DATA, READONLY
|
||||
EXPORT __Vectors
|
||||
EXPORT __Vectors_End
|
||||
EXPORT __Vectors_Size
|
||||
|
||||
__Vectors DCD __initial_sp ; Top of Stack
|
||||
DCD Reset_Handler ; Reset Handler
|
||||
DCD NMI_Handler ; -14 NMI Handler
|
||||
DCD HardFault_Handler ; -13 Hard Fault Handler
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD SVC_Handler ; -5 SVCall Handler
|
||||
DCD 0 ; Reserved
|
||||
DCD 0 ; Reserved
|
||||
DCD PendSV_Handler ; -2 PendSV Handler
|
||||
DCD SysTick_Handler ; -1 SysTick Handler
|
||||
|
||||
; Interrupts
|
||||
DCD Interrupt0_Handler ; 0 Interrupt 0
|
||||
DCD Interrupt1_Handler ; 1 Interrupt 1
|
||||
DCD Interrupt2_Handler ; 2 Interrupt 2
|
||||
DCD Interrupt3_Handler ; 3 Interrupt 3
|
||||
DCD Interrupt4_Handler ; 4 Interrupt 4
|
||||
DCD Interrupt5_Handler ; 5 Interrupt 5
|
||||
DCD Interrupt6_Handler ; 6 Interrupt 6
|
||||
DCD Interrupt7_Handler ; 7 Interrupt 7
|
||||
DCD Interrupt8_Handler ; 8 Interrupt 8
|
||||
DCD Interrupt9_Handler ; 9 Interrupt 9
|
||||
|
||||
SPACE ( 22 * 4) ; Interrupts 10 .. 31 are left out
|
||||
__Vectors_End
|
||||
__Vectors_Size EQU __Vectors_End - __Vectors
|
||||
|
||||
|
||||
AREA |.text|, CODE, READONLY
|
||||
|
||||
; Reset Handler
|
||||
|
||||
Reset_Handler PROC
|
||||
EXPORT Reset_Handler [WEAK]
|
||||
IMPORT SystemInit
|
||||
IMPORT __main
|
||||
|
||||
LDR R0, =SystemInit
|
||||
BLX R0
|
||||
LDR R0, =__main
|
||||
BX R0
|
||||
ENDP
|
||||
|
||||
; The default macro is not used for HardFault_Handler
|
||||
; because this results in a poor debug illusion.
|
||||
HardFault_Handler PROC
|
||||
EXPORT HardFault_Handler [WEAK]
|
||||
B .
|
||||
ENDP
|
||||
|
||||
; Macro to define default exception/interrupt handlers.
|
||||
; Default handler are weak symbols with an endless loop.
|
||||
; They can be overwritten by real handlers.
|
||||
MACRO
|
||||
Set_Default_Handler $Handler_Name
|
||||
$Handler_Name PROC
|
||||
EXPORT $Handler_Name [WEAK]
|
||||
B .
|
||||
ENDP
|
||||
MEND
|
||||
|
||||
|
||||
; Default exception/interrupt handler
|
||||
|
||||
Set_Default_Handler NMI_Handler
|
||||
Set_Default_Handler SVC_Handler
|
||||
Set_Default_Handler PendSV_Handler
|
||||
Set_Default_Handler SysTick_Handler
|
||||
|
||||
Set_Default_Handler Interrupt0_Handler
|
||||
Set_Default_Handler Interrupt1_Handler
|
||||
Set_Default_Handler Interrupt2_Handler
|
||||
Set_Default_Handler Interrupt3_Handler
|
||||
Set_Default_Handler Interrupt4_Handler
|
||||
Set_Default_Handler Interrupt5_Handler
|
||||
Set_Default_Handler Interrupt6_Handler
|
||||
Set_Default_Handler Interrupt7_Handler
|
||||
Set_Default_Handler Interrupt8_Handler
|
||||
Set_Default_Handler Interrupt9_Handler
|
||||
|
||||
ALIGN
|
||||
|
||||
|
||||
; User setup Stack & Heap
|
||||
|
||||
IF :LNOT::DEF:__MICROLIB
|
||||
IMPORT __use_two_region_memory
|
||||
ENDIF
|
||||
|
||||
EXPORT __stack_limit
|
||||
EXPORT __initial_sp
|
||||
IF Heap_Size != 0 ; Heap is provided
|
||||
EXPORT __heap_base
|
||||
EXPORT __heap_limit
|
||||
ENDIF
|
||||
|
||||
END
|
||||
56
bthome_phy6222/RTE/Device/ARMCM0/system_ARMCM0.c
Normal file
56
bthome_phy6222/RTE/Device/ARMCM0/system_ARMCM0.c
Normal file
|
|
@ -0,0 +1,56 @@
|
|||
/**************************************************************************//**
|
||||
* @file system_ARMCM0.c
|
||||
* @brief CMSIS Device System Source File for
|
||||
* ARMCM0 Device
|
||||
* @version V1.0.0
|
||||
* @date 09. July 2018
|
||||
******************************************************************************/
|
||||
/*
|
||||
* Copyright (c) 2009-2018 Arm Limited. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the License); you may
|
||||
* not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an AS IS BASIS, WITHOUT
|
||||
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include "ARMCM0.h"
|
||||
|
||||
/*----------------------------------------------------------------------------
|
||||
Define clocks
|
||||
*----------------------------------------------------------------------------*/
|
||||
#define XTAL (50000000UL) /* Oscillator frequency */
|
||||
|
||||
#define SYSTEM_CLOCK (XTAL / 2U)
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------------
|
||||
System Core Clock Variable
|
||||
*----------------------------------------------------------------------------*/
|
||||
uint32_t SystemCoreClock = SYSTEM_CLOCK; /* System Core Clock Frequency */
|
||||
|
||||
|
||||
/*----------------------------------------------------------------------------
|
||||
System Core Clock update function
|
||||
*----------------------------------------------------------------------------*/
|
||||
void SystemCoreClockUpdate (void)
|
||||
{
|
||||
SystemCoreClock = SYSTEM_CLOCK;
|
||||
}
|
||||
|
||||
/*----------------------------------------------------------------------------
|
||||
System initialization function
|
||||
*----------------------------------------------------------------------------*/
|
||||
void SystemInit (void)
|
||||
{
|
||||
SystemCoreClock = SYSTEM_CLOCK;
|
||||
}
|
||||
|
|
@ -45,7 +45,9 @@ extern "C" {
|
|||
//#define __Vendor_SysTickConfig 0U /* Set to 1 if different SysTick Config is used */
|
||||
|
||||
#include "core_cm0.h" /* Processor and core peripherals */
|
||||
#if defined ( __CC_ARM )
|
||||
#include "system_ARMCM0.h" /* System Header */
|
||||
#endif /*__CC_ARM*/
|
||||
|
||||
#define NVIC_GetPendingIRQs() (NVIC->ISPR[0U])
|
||||
#define NVIC_ClearPendingIRQs(icpr) (NVIC->ICPR[0U] = (unsigned int)icpr)
|
||||
|
|
@ -212,9 +212,11 @@ extern volatile uint8_t g_rc32kCalRes ;
|
|||
#define RF_PHY_TX_POWER_0DBM 0x1f
|
||||
#define RF_PHY_TX_POWER_N2DBM 0x0f
|
||||
#define RF_PHY_TX_POWER_N5DBM 0x0a
|
||||
#define RF_PHY_TX_POWER_N10DBM 0x04
|
||||
#define RF_PHY_TX_POWER_N15DBM 0x02
|
||||
#define RF_PHY_TX_POWER_N20DBM 0x01
|
||||
|
||||
#elif(SDK_VER_CHIP==__DEF_CHIP_TSOP16__)
|
||||
#elif(SDK_VER_CHIP==__DEF_CHIP_TSOP16__)
|
||||
#define RF_PHY_TX_POWER_EXTRA_MAX 0x3f
|
||||
#define RF_PHY_TX_POWER_MAX 0x1f
|
||||
#define RF_PHY_TX_POWER_MIN 0x00
|
||||
|
|
@ -29,6 +29,15 @@ extern "C"
|
|||
/*********************************************************************
|
||||
CONSTANTS
|
||||
*/
|
||||
// Minimum connection interval (units of 1.25ms, 80=100ms) if automatic parameter update request is enabled
|
||||
#define DEFAULT_DESIRED_MIN_CONN_INTERVAL 24 // 12 -> 15 ms
|
||||
// Maximum connection interval (units of 1.25ms, 800=1000ms) if automatic parameter update request is enabled
|
||||
#define DEFAULT_DESIRED_MAX_CONN_INTERVAL 24 // 30 ms
|
||||
// Slave latency to use if automatic parameter update request is enabled
|
||||
#define DEFAULT_DESIRED_SLAVE_LATENCY 29
|
||||
// Supervision timeout value (units of 10ms, 1000=10s) if automatic parameter update request is enabled
|
||||
#define DEFAULT_DESIRED_CONN_TIMEOUT 400 // 4s
|
||||
|
||||
|
||||
#define GAP_DEVICE_NAME_LEN (20+1)
|
||||
|
||||
|
|
@ -220,7 +220,7 @@ __ATTR_SECTION_XIP__ void hal_rfPhyFreqOff_Set(void)
|
|||
int32_t freqPpm=0;
|
||||
freqPpm= *(volatile int32_t*) 0x11004008;
|
||||
|
||||
if((freqPpm!=0xffffffff) && (freqPpm>=-50) && (freqPpm<=50))
|
||||
if((freqPpm!=-1) && (freqPpm>=-50) && (freqPpm<=50))
|
||||
{
|
||||
g_rfPhyFreqOffSet=(int8_t)freqPpm;
|
||||
}
|
||||
463
bthome_phy6222/SDK/components/driver/flash/flash.c
Normal file
463
bthome_phy6222/SDK/components/driver/flash/flash.c
Normal file
|
|
@ -0,0 +1,463 @@
|
|||
/**************************************************************************************************
|
||||
*******
|
||||
**************************************************************************************************/
|
||||
|
||||
/*******************************************************************************
|
||||
@file flash.c
|
||||
@brief Contains all functions support for flash driver
|
||||
@version 0.0
|
||||
@date 27. Nov. 2017
|
||||
@author qing.han
|
||||
|
||||
|
||||
|
||||
*******************************************************************************/
|
||||
#include "rom_sym_def.h"
|
||||
#include <string.h>
|
||||
#include "types.h"
|
||||
#include "flash.h"
|
||||
#include "log.h"
|
||||
#include "pwrmgr.h"
|
||||
#include "error.h"
|
||||
|
||||
#define SPIF_WAIT_IDLE_CYC (32)
|
||||
|
||||
#define SPIF_STATUS_WAIT_IDLE(n) \
|
||||
do \
|
||||
{ \
|
||||
while((AP_SPIF->fcmd & 0x02) == 0x02); \
|
||||
volatile int delay_cycle = n; \
|
||||
while (delay_cycle--){}; \
|
||||
while ((AP_SPIF->config & 0x80000000) == 0);\
|
||||
} while (0);
|
||||
|
||||
#define HAL_CACHE_ENTER_BYPASS_SECTION() do{ \
|
||||
HAL_ENTER_CRITICAL_SECTION();\
|
||||
AP_CACHE->CTRL0 = 0x02; \
|
||||
AP_PCR->CACHE_RST = 0x02;\
|
||||
AP_PCR->CACHE_BYPASS = 1; \
|
||||
HAL_EXIT_CRITICAL_SECTION();\
|
||||
}while(0);
|
||||
|
||||
#define HAL_CACHE_EXIT_BYPASS_SECTION() do{ \
|
||||
HAL_ENTER_CRITICAL_SECTION();\
|
||||
AP_CACHE->CTRL0 = 0x00;\
|
||||
AP_PCR->CACHE_RST = 0x03;\
|
||||
AP_PCR->CACHE_BYPASS = 0;\
|
||||
HAL_EXIT_CRITICAL_SECTION();\
|
||||
}while(0);
|
||||
|
||||
#define spif_wait_nobusy(flg, tout_ns, return_val) {if(_spif_wait_nobusy_x(flg, tout_ns)){if(return_val){ return return_val;}}}
|
||||
|
||||
static xflash_Ctx_t s_xflashCtx = { .spif_ref_clk = SYS_CLK_DLL_64M, .rd_instr =
|
||||
XFRD_FCMD_READ_DUAL };
|
||||
|
||||
chipMAddr_t g_chipMAddr;
|
||||
|
||||
__ATTR_SECTION_SRAM__ static inline uint32_t spif_lock() {
|
||||
HAL_ENTER_CRITICAL_SECTION();
|
||||
uint32_t vic_iser = NVIC->ISER[0];
|
||||
//mask all irq
|
||||
NVIC->ICER[0] = 0xFFFFFFFF;
|
||||
//enable ll irq and tim1 irq
|
||||
NVIC->ISER[0] = 0x100010;
|
||||
HAL_EXIT_CRITICAL_SECTION();
|
||||
return vic_iser;
|
||||
}
|
||||
|
||||
__ATTR_SECTION_SRAM__ static inline void spif_unlock(uint32_t vic_iser) {
|
||||
HAL_ENTER_CRITICAL_SECTION();
|
||||
NVIC->ISER[0] = vic_iser;
|
||||
HAL_EXIT_CRITICAL_SECTION();
|
||||
}
|
||||
|
||||
static void hal_cache_tag_flush(void) {
|
||||
HAL_ENTER_CRITICAL_SECTION();
|
||||
uint32_t cb = AP_PCR->CACHE_BYPASS;
|
||||
volatile int dly = 8;
|
||||
|
||||
if (cb == 0) {
|
||||
AP_PCR->CACHE_BYPASS = 1;
|
||||
}
|
||||
|
||||
AP_CACHE->CTRL0 = 0x02;
|
||||
|
||||
while (dly--) {
|
||||
;
|
||||
};
|
||||
|
||||
AP_CACHE->CTRL0 = 0x03;
|
||||
|
||||
dly = 8;
|
||||
|
||||
while (dly--) {
|
||||
;
|
||||
};
|
||||
|
||||
AP_CACHE->CTRL0 = 0x00;
|
||||
|
||||
if (cb == 0) {
|
||||
AP_PCR->CACHE_BYPASS = 0;
|
||||
}
|
||||
|
||||
HAL_EXIT_CRITICAL_SECTION();
|
||||
}
|
||||
|
||||
static uint8_t _spif_read_status_reg_x(void) {
|
||||
uint8_t status;
|
||||
spif_cmd(FCMD_RDST, 0, 2, 0, 0, 0);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_rddata(&status, 1);
|
||||
return status;
|
||||
}
|
||||
|
||||
static int _spif_wait_nobusy_x(uint8_t flg, uint32_t tout_ns) {
|
||||
uint8_t status;
|
||||
volatile int tout = (int) (tout_ns);
|
||||
|
||||
for (; tout; tout--) {
|
||||
status = _spif_read_status_reg_x();
|
||||
|
||||
if ((status & flg) == 0)
|
||||
return PPlus_SUCCESS;
|
||||
|
||||
//insert polling interval
|
||||
//5*32us
|
||||
WaitRTCCount(5);
|
||||
}
|
||||
|
||||
return PPlus_ERR_BUSY;
|
||||
}
|
||||
|
||||
static void hal_cache_init(void) {
|
||||
volatile int dly = 100;
|
||||
//clock gate
|
||||
hal_clk_gate_enable(MOD_HCLK_CACHE);
|
||||
hal_clk_gate_enable(MOD_PCLK_CACHE);
|
||||
//cache rst ahp
|
||||
AP_PCR->CACHE_RST = 0x02;
|
||||
|
||||
while (dly--) {
|
||||
};
|
||||
|
||||
AP_PCR->CACHE_RST = 0x03;
|
||||
|
||||
hal_cache_tag_flush();
|
||||
|
||||
//cache enable
|
||||
AP_PCR->CACHE_BYPASS = 0;
|
||||
}
|
||||
|
||||
FLASH_CHIP_INFO phy_flash = { .init_flag = FALSE, .IdentificationID = 0x00,
|
||||
.Capacity = 0x80000, };
|
||||
|
||||
int hal_get_flash_info(void) {
|
||||
uint32_t cs;
|
||||
uint8_t data[17];
|
||||
|
||||
if (phy_flash.init_flag == TRUE) {
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
cs = spif_lock();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
spif_cmd(FCMD_RDID, 0, 3, 0, 0, 0);
|
||||
spif_rddata(data, 3);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
spif_unlock(cs);
|
||||
phy_flash.IdentificationID = (data[2] << 16) | (data[1] << 8) | data[0];
|
||||
|
||||
if ((data[2] >= 0x11) && (data[2] <= 0x16)) //most use:256K~2M.reserved:128K,4M
|
||||
{
|
||||
phy_flash.Capacity = (1ul << data[2]);
|
||||
*(volatile int*) 0x1fff0898 = phy_flash.Capacity;
|
||||
} else {
|
||||
phy_flash.Capacity = 512 * 1024;
|
||||
*(volatile int*) 0x1fff0898 = phy_flash.Capacity;
|
||||
}
|
||||
|
||||
phy_flash.init_flag = TRUE;
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
int hal_flash_lock(void)
|
||||
{
|
||||
uint32_t cs = spif_lock();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd = 0x6000001;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd_wrdata[0] = 0x7c;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd = 0x1008001;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
spif_unlock(cs);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
int hal_flash_unlock(void)
|
||||
{
|
||||
uint32_t cs = spif_lock();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd = 0x6000001;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd_wrdata[0] = 0x00;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
AP_SPIF->fcmd = 0x1008001;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
spif_unlock(cs);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
uint8_t hal_flash_get_lock_state(void)
|
||||
{
|
||||
uint32_t cs = spif_lock();
|
||||
uint8_t status;
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
status = _spif_read_status_reg_x();
|
||||
status = (status & 0x7c)>>2;
|
||||
spif_unlock(cs);
|
||||
return status;
|
||||
}
|
||||
#endif
|
||||
|
||||
static void hw_spif_cache_config(void) {
|
||||
spif_config(s_xflashCtx.spif_ref_clk,/*div*/1, s_xflashCtx.rd_instr, 0, 0);
|
||||
AP_SPIF->wr_completion_ctrl = 0xff010005; //set longest polling interval
|
||||
NVIC_DisableIRQ(SPIF_IRQn);
|
||||
NVIC_SetPriority((IRQn_Type) SPIF_IRQn, IRQ_PRIO_HAL);
|
||||
hal_cache_init();
|
||||
hal_get_flash_info();
|
||||
}
|
||||
|
||||
int hal_spif_cache_init(xflash_Ctx_t cfg) {
|
||||
memset(&(s_xflashCtx), 0, sizeof(s_xflashCtx));
|
||||
memcpy(&(s_xflashCtx), &cfg, sizeof(s_xflashCtx));
|
||||
hw_spif_cache_config();
|
||||
hal_pwrmgr_register(MOD_SPIF, NULL, hw_spif_cache_config);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
int hal_flash_read(uint32_t addr, uint8_t *data, uint32_t size) {
|
||||
uint32_t cs = spif_lock();
|
||||
volatile uint8_t *u8_spif_addr = (volatile uint8_t*) ((addr & 0x7ffff)
|
||||
| FLASH_BASE_ADDR);
|
||||
uint32_t cb = AP_PCR->CACHE_BYPASS;
|
||||
uint32_t remap = 0;
|
||||
|
||||
if (phy_flash.Capacity > 0x80000) {
|
||||
remap = addr & 0xf80000;
|
||||
|
||||
if (remap) {
|
||||
AP_SPIF->remap = remap;
|
||||
AP_SPIF->config |= 0x10000;
|
||||
}
|
||||
}
|
||||
|
||||
//read flash addr direct access
|
||||
//bypass cache
|
||||
if (cb == 0) {
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
}
|
||||
|
||||
for (uint32_t i = 0; i < size; i++)
|
||||
data[i] = u8_spif_addr[i];
|
||||
|
||||
//bypass cache
|
||||
if (cb == 0) {
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
}
|
||||
|
||||
if (phy_flash.Capacity > 0x80000) {
|
||||
if (remap) {
|
||||
AP_SPIF->remap = 0;
|
||||
AP_SPIF->config &= ~0x10000ul;
|
||||
}
|
||||
}
|
||||
|
||||
spif_unlock(cs);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
int hal_flash_write(uint32_t addr, uint8_t *data, uint32_t size) {
|
||||
uint8_t retval;
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_unlock();
|
||||
#endif
|
||||
uint32_t cs = spif_lock();
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
retval = spif_write(addr, data, size);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
spif_unlock(cs);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_lock();
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
|
||||
int hal_flash_write_by_dma(uint32_t addr, uint8_t *data, uint32_t size) {
|
||||
uint8_t retval;
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_unlock();
|
||||
#endif
|
||||
uint32_t cs = spif_lock();
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
retval = spif_write_dma(addr, data, size);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
spif_unlock(cs);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_lock();
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
|
||||
int hal_flash_erase_sector(unsigned int addr) {
|
||||
uint8_t retval;
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_unlock();
|
||||
#endif
|
||||
uint32_t cs = spif_lock();
|
||||
uint32_t cb = AP_PCR->CACHE_BYPASS;
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
retval = spif_erase_sector(addr);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WELWIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
|
||||
if (cb == 0) {
|
||||
hal_cache_tag_flush();
|
||||
}
|
||||
|
||||
spif_unlock(cs);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_lock();
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
|
||||
int hal_flash_erase_block64(unsigned int addr) {
|
||||
uint8_t retval;
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_unlock();
|
||||
#endif
|
||||
uint32_t cs = spif_lock();
|
||||
uint32_t cb = AP_PCR->CACHE_BYPASS;
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
retval = spif_erase_block64(addr);
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WELWIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
|
||||
if (cb == 0) {
|
||||
hal_cache_tag_flush();
|
||||
}
|
||||
|
||||
spif_unlock(cs);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_lock();
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
|
||||
int hal_flash_erase_all(void) {
|
||||
uint8_t retval;
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_unlock();
|
||||
#endif
|
||||
uint32_t cs = spif_lock();
|
||||
uint32_t cb = AP_PCR->CACHE_BYPASS;
|
||||
HAL_CACHE_ENTER_BYPASS_SECTION();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
retval = spif_erase_all();
|
||||
SPIF_STATUS_WAIT_IDLE(SPIF_WAIT_IDLE_CYC);
|
||||
spif_wait_nobusy(SFLG_WELWIP, SPIF_TIMEOUT, PPlus_ERR_BUSY);
|
||||
HAL_CACHE_EXIT_BYPASS_SECTION();
|
||||
|
||||
if (cb == 0) {
|
||||
hal_cache_tag_flush();
|
||||
}
|
||||
|
||||
spif_unlock(cs);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
hal_flash_lock();
|
||||
#endif
|
||||
return retval;
|
||||
}
|
||||
|
||||
int flash_write_word(unsigned int offset, uint32_t value) {
|
||||
uint32_t temp = value;
|
||||
offset &= 0x00ffffff;
|
||||
return (hal_flash_write(offset, (uint8_t*) &temp, 4));
|
||||
}
|
||||
|
||||
CHIP_ID_STATUS_e read_chip_mAddr(void) {
|
||||
CHIP_ID_STATUS_e ret = CHIP_ID_UNCHECK;
|
||||
uint8_t b;
|
||||
for (int i = 0; i < CHIP_MADDR_LEN; i++) {
|
||||
ret = chip_id_one_bit_hot_convter(&b,
|
||||
read_reg(CHIP_MADDR_FLASH_ADDRESS+(i<<2)));
|
||||
|
||||
if (ret == CHIP_ID_VALID) {
|
||||
g_chipMAddr.mAddr[CHIP_MADDR_LEN - 1 - i] = b;
|
||||
} else {
|
||||
if (i > 0 && ret == CHIP_ID_EMPTY) {
|
||||
ret = CHIP_ID_INVALID;
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
void check_chip_mAddr(void) {
|
||||
//chip id check
|
||||
for (int i = 0; i < CHIP_MADDR_LEN; i++) {
|
||||
g_chipMAddr.mAddr[i] = 0xff;
|
||||
}
|
||||
g_chipMAddr.chipMAddrStatus = read_chip_mAddr();
|
||||
}
|
||||
|
||||
void LOG_CHIP_MADDR(void) {
|
||||
|
||||
LOG("\n");
|
||||
if (g_chipMAddr.chipMAddrStatus == CHIP_ID_EMPTY) {
|
||||
LOG("[CHIP_MADDR EMPTY]\n");
|
||||
} else if (g_chipMAddr.chipMAddrStatus == CHIP_ID_INVALID) {
|
||||
LOG("[CHIP_MADDR INVALID]\n");
|
||||
} else if (g_chipMAddr.chipMAddrStatus == CHIP_ID_VALID) {
|
||||
|
||||
LOG("[CHIP_MADDR VALID]\n");
|
||||
for (int i = 0; i < CHIP_MADDR_LEN; i++) {
|
||||
LOG("%02x",g_chipMAddr.mAddr[i]);
|
||||
} LOG("\n");
|
||||
|
||||
} else {
|
||||
LOG("[CHIP_MADDR UNCHECKED]\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -125,7 +125,7 @@ extern void spif_cmd(uint8_t op, uint8_t addrlen, uint8_t rdlen, uint8_t wrlen,
|
|||
extern void spif_rddata(uint8_t* data, uint8_t len);
|
||||
extern int spif_config(sysclk_t ref_clk, uint8_t div, uint32_t rd_instr, uint8_t mode_bit, uint8_t QE);
|
||||
int hal_spif_cache_init(xflash_Ctx_t cfg);
|
||||
static void hal_cache_tag_flush(void);
|
||||
//static void hal_cache_tag_flush(void);
|
||||
#if(FLASH_PROTECT_FEATURE == 1)
|
||||
int hal_flash_lock(void);
|
||||
int hal_flash_unlock(void);
|
||||
|
|
@ -1,5 +1,33 @@
|
|||
/**************************************************************************************************
|
||||
*******
|
||||
|
||||
Phyplus Microelectronics Limited confidential and proprietary.
|
||||
All rights reserved.
|
||||
|
||||
IMPORTANT: All rights of this software belong to Phyplus Microelectronics
|
||||
Limited ("Phyplus"). Your use of this Software is limited to those
|
||||
specific rights granted under the terms of the business contract, the
|
||||
confidential agreement, the non-disclosure agreement and any other forms
|
||||
of agreements as a customer or a partner of Phyplus. You may not use this
|
||||
Software unless you agree to abide by the terms of these agreements.
|
||||
You acknowledge that the Software may not be modified, copied,
|
||||
distributed or disclosed unless embedded on a Phyplus Bluetooth Low Energy
|
||||
(BLE) integrated circuit, either as a product or is integrated into your
|
||||
products. Other than for the aforementioned purposes, you may not use,
|
||||
reproduce, copy, prepare derivative works of, modify, distribute, perform,
|
||||
display or sell this Software and/or its documentation for any purposes.
|
||||
|
||||
YOU FURTHER ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE
|
||||
PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED,
|
||||
INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE,
|
||||
NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
|
||||
PHYPLUS OR ITS SUBSIDIARIES BE LIABLE OR OBLIGATED UNDER CONTRACT,
|
||||
NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER
|
||||
LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
|
||||
INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE
|
||||
OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT
|
||||
OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
|
||||
(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
|
||||
|
||||
**************************************************************************************************/
|
||||
|
||||
/*******************************************************************************
|
||||
|
|
@ -21,6 +49,7 @@
|
|||
#include "error.h"
|
||||
#include "jump_function.h"
|
||||
#include "log.h"
|
||||
#include "global_config.h"
|
||||
|
||||
|
||||
extern uint32_t s_gpio_wakeup_src_group1,s_gpio_wakeup_src_group2;
|
||||
|
|
@ -46,6 +75,7 @@ typedef struct
|
|||
{
|
||||
bool state;
|
||||
uint8_t pin_assignments[NUMBER_OF_PINS];
|
||||
uint32_t pin_retention_status;
|
||||
gpioin_Ctx_t irq_ctx[NUMBER_OF_PINS];
|
||||
|
||||
} gpio_Ctx_t;
|
||||
|
|
@ -62,6 +92,7 @@ static gpio_Ctx_t m_gpioCtx =
|
|||
{
|
||||
.state = FALSE,
|
||||
.pin_assignments = {0,},
|
||||
.pin_retention_status = 0
|
||||
};
|
||||
|
||||
const uint8_t c_gpio_index[GPIO_NUM] = {0,1,2,3,7,9,10,11,14,15,16,17,18,20,23,24,25,26,27,31,32,33,34};
|
||||
|
|
@ -130,6 +161,9 @@ static int hal_gpio_interrupt_disable(gpio_pin_e pin)
|
|||
void hal_gpio_write(gpio_pin_e pin, uint8_t en)
|
||||
{
|
||||
// hal_gpio_pin_init(pin,GPIO_OUTPUT);
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if(en)
|
||||
AP_GPIO->swporta_dr |= BIT(pin);
|
||||
else
|
||||
|
|
@ -140,6 +174,9 @@ void hal_gpio_write(gpio_pin_e pin, uint8_t en)
|
|||
|
||||
void hal_gpio_fast_write(gpio_pin_e pin, uint8_t en)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if(en)
|
||||
AP_GPIO->swporta_dr |= BIT(pin);
|
||||
else
|
||||
|
|
@ -150,6 +187,9 @@ bool hal_gpio_read(gpio_pin_e pin)
|
|||
{
|
||||
uint32_t r;
|
||||
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
if(AP_GPIO->swporta_ddr & BIT(pin))
|
||||
r = AP_GPIO->swporta_dr;
|
||||
else
|
||||
|
|
@ -160,6 +200,9 @@ bool hal_gpio_read(gpio_pin_e pin)
|
|||
|
||||
void hal_gpio_fmux(gpio_pin_e pin, bit_action_e value)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if(value)
|
||||
{
|
||||
// if((pin == P2) || (pin == P3))
|
||||
|
|
@ -170,7 +213,7 @@ void hal_gpio_fmux(gpio_pin_e pin, bit_action_e value)
|
|||
AP_IOMUX->full_mux0_en &= ~BIT(pin);
|
||||
}
|
||||
|
||||
void hal_gpio_fmux_set(gpio_pin_e pin,gpio_fmux_e type)
|
||||
void hal_gpio_fmux_set(gpio_pin_e pin, gpio_fmux_e type)
|
||||
{
|
||||
uint8_t h = 0,l = 0;
|
||||
uint32_t reg_index;
|
||||
|
|
@ -178,21 +221,24 @@ void hal_gpio_fmux_set(gpio_pin_e pin,gpio_fmux_e type)
|
|||
|
||||
if(pin != GPIO_DUMMY)
|
||||
{
|
||||
reg_index = pin / 4;
|
||||
bit_index = pin % 4;
|
||||
reg_index = pin >> 2;
|
||||
bit_index = pin & 0x03;
|
||||
l = 8 * bit_index;
|
||||
h = l + 5;
|
||||
hal_gpioin_disable(pin);
|
||||
subWriteReg(&(AP_IOMUX->gpio_sel[reg_index]),h,l,type);
|
||||
hal_gpio_fmux(pin, Bit_ENABLE);
|
||||
}
|
||||
}
|
||||
|
||||
int hal_gpio_pin_init(gpio_pin_e pin,gpio_dir_t type)
|
||||
int hal_gpio_pin_init(gpio_pin_e pin, gpio_dir_t type)
|
||||
{
|
||||
if((type == GPIO_INPUT)&&(m_gpioCtx.pin_assignments[pin] == GPIO_PIN_ASSI_OUT))
|
||||
{
|
||||
return PPlus_ERR_INVALID_STATE;
|
||||
}
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
// if((m_gpioCtx.pin_assignments[pin] == GPIO_PIN_ASSI_OUT) &&
|
||||
// (m_gpioCtx.pin_retention_status & BIT(pin)) && (type == GPIO_INPUT))
|
||||
// return PPlus_ERR_INVALID_PARAM;
|
||||
|
||||
hal_gpio_fmux(pin,Bit_DISABLE);
|
||||
|
||||
|
|
@ -210,6 +256,7 @@ int hal_gpio_pin_init(gpio_pin_e pin,gpio_dir_t type)
|
|||
{
|
||||
AP_GPIO->swporta_ddr &= ~BIT(pin);
|
||||
m_gpioCtx.pin_assignments[pin] = GPIO_PIN_ASSI_IN;
|
||||
m_gpioCtx.pin_retention_status &= ~BIT(pin);
|
||||
}
|
||||
|
||||
return PPlus_SUCCESS;
|
||||
|
|
@ -235,6 +282,9 @@ static void hal_gpio_wakeup_control(gpio_pin_e pin, bit_action_e value)
|
|||
|
||||
void hal_gpio_ds_control(gpio_pin_e pin, bit_action_e value)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if(value)
|
||||
AP_IOMUX->pad_ps0 |= BIT(pin);
|
||||
else
|
||||
|
|
@ -243,11 +293,13 @@ void hal_gpio_ds_control(gpio_pin_e pin, bit_action_e value)
|
|||
|
||||
int hal_gpioretention_unregister(gpio_pin_e pin)
|
||||
{
|
||||
if(m_gpioCtx.pin_assignments[pin] == GPIO_PIN_ASSI_IN)
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
if(m_gpioCtx.pin_assignments[pin] != GPIO_PIN_ASSI_OUT)
|
||||
return PPlus_ERR_INVALID_PARAM;
|
||||
|
||||
m_gpioCtx.pin_assignments[pin] = GPIO_PIN_ASSI_NONE;
|
||||
hal_gpio_pin_init(pin,GPIO_INPUT);
|
||||
m_gpioCtx.pin_retention_status &= ~BIT(pin);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
|
|
@ -270,6 +322,9 @@ int hal_gpio_cfg_analog_io(gpio_pin_e pin, bit_action_e value)
|
|||
if((pin < P11) || (pin > P25))
|
||||
return PPlus_ERR_INVALID_PARAM;
|
||||
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
if(value)
|
||||
{
|
||||
hal_gpio_pull_set(pin,GPIO_FLOATING);
|
||||
|
|
@ -286,6 +341,9 @@ int hal_gpio_cfg_analog_io(gpio_pin_e pin, bit_action_e value)
|
|||
|
||||
void hal_gpio_pull_set(gpio_pin_e pin, gpio_pupd_e type)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
uint8_t i = c_gpio_pull[pin].reg_i;
|
||||
uint8_t h = c_gpio_pull[pin].bit_h;
|
||||
uint8_t l = c_gpio_pull[pin].bit_l;
|
||||
|
|
@ -298,6 +356,9 @@ void hal_gpio_pull_set(gpio_pin_e pin, gpio_pupd_e type)
|
|||
|
||||
void hal_gpio_wakeup_set(gpio_pin_e pin, gpio_polarity_e type)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
uint8_t i = c_gpio_pull[pin].reg_i;
|
||||
uint8_t p = c_gpio_pull[pin].bit_l-1;
|
||||
|
||||
|
|
@ -332,9 +393,12 @@ void hal_gpio_pin2pin3_control(gpio_pin_e pin, uint8_t en)//0:sw,1:other func
|
|||
AP_IOMUX->gpio_pad_en &= ~BIT(pin-2);
|
||||
}
|
||||
|
||||
|
||||
#if(CFG_SLEEP_MODE == PWR_MODE_SLEEP)
|
||||
static void hal_gpio_retention_enable(gpio_pin_e pin,uint8_t en)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if(en)
|
||||
{
|
||||
if((pin == P32)||(pin == P33)||(pin == P34))
|
||||
|
|
@ -358,6 +422,7 @@ static void hal_gpio_retention_enable(gpio_pin_e pin,uint8_t en)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
int hal_gpioin_disable(gpio_pin_e pin)
|
||||
{
|
||||
|
|
@ -376,7 +441,7 @@ static int hal_gpio_interrupt_enable(gpio_pin_e pin, gpio_polarity_e type)
|
|||
{
|
||||
uint32_t gpio_tmp;
|
||||
|
||||
if (pin >= NUMBER_OF_PINS)
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
gpio_tmp = AP_GPIO->inttype_level;
|
||||
|
|
@ -403,6 +468,9 @@ static void hal_gpioin_event_pin(gpio_pin_e pin, gpio_polarity_e type)
|
|||
{
|
||||
gpioin_Ctx_t* p_irq_ctx = &(m_gpioCtx.irq_ctx[0]);
|
||||
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
if (p_irq_ctx[pin].posedgeHdl && (type == POL_RISING ))
|
||||
{
|
||||
p_irq_ctx[pin].posedgeHdl(pin,POL_RISING );//LOG("POS\n");
|
||||
|
|
@ -413,14 +481,19 @@ static void hal_gpioin_event_pin(gpio_pin_e pin, gpio_polarity_e type)
|
|||
}
|
||||
}
|
||||
|
||||
#if(CFG_SLEEP_MODE == PWR_MODE_SLEEP)
|
||||
static void hal_gpioin_wakeup_trigger(gpio_pin_e pin)
|
||||
{
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return;
|
||||
|
||||
uint8_t pin_state = (uint8_t)hal_gpio_read(pin);
|
||||
gpio_polarity_e type = pin_state ? POL_RISING : POL_FALLING;
|
||||
|
||||
if (m_gpioCtx.irq_ctx[pin].pin_state != pin_state)
|
||||
hal_gpioin_event_pin(pin, type);
|
||||
}
|
||||
#endif
|
||||
|
||||
static void hal_gpioin_event(uint32 int_status, uint32 polarity)
|
||||
{
|
||||
|
|
@ -452,7 +525,7 @@ static void hal_gpioin_event(uint32 int_status, uint32 polarity)
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
#if(CFG_SLEEP_MODE == PWR_MODE_SLEEP)
|
||||
static void hal_gpio_sleep_handler(void)
|
||||
{
|
||||
int i;
|
||||
|
|
@ -461,14 +534,29 @@ static void hal_gpio_sleep_handler(void)
|
|||
for (i = 0; i < NUMBER_OF_PINS; i++)
|
||||
{
|
||||
//config wakeup
|
||||
if (m_gpioCtx.pin_assignments[i] == GPIO_PIN_ASSI_OUT)
|
||||
if ((m_gpioCtx.pin_assignments[i] == GPIO_PIN_ASSI_OUT) && (m_gpioCtx.pin_retention_status & BIT(i)))
|
||||
{
|
||||
hal_gpio_retention_enable((gpio_pin_e)i,Bit_ENABLE);
|
||||
}
|
||||
|
||||
if (m_gpioCtx.pin_assignments[i] == GPIO_PIN_ASSI_IN)
|
||||
{
|
||||
pol = hal_gpio_read((gpio_pin_e)i) ? POL_FALLING : POL_RISING ;
|
||||
#ifdef XOSC_PIN_ALLOW
|
||||
|
||||
if((i==P16)||(i==P17))
|
||||
{
|
||||
hal_gpio_cfg_analog_io((gpio_pin_e)i,Bit_DISABLE);
|
||||
subWriteReg(&(AP_AON->PMCTL2_0),6,6,0x01);
|
||||
WaitUs(50);
|
||||
pol = hal_gpio_read((gpio_pin_e)i) ? POL_FALLING : POL_RISING ;
|
||||
subWriteReg(&(AP_AON->PMCTL2_0),6,6,0x00);
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
pol = hal_gpio_read((gpio_pin_e)i) ? POL_FALLING : POL_RISING ;
|
||||
}
|
||||
|
||||
hal_gpio_wakeup_set((gpio_pin_e)i, pol);
|
||||
m_gpioCtx.irq_ctx[i].pin_state = hal_gpio_read((gpio_pin_e)i);
|
||||
}
|
||||
|
|
@ -480,13 +568,37 @@ static void hal_gpio_wakeup_handler(void)
|
|||
int i;
|
||||
NVIC_SetPriority(GPIO_IRQn, IRQ_PRIO_HAL);
|
||||
NVIC_EnableIRQ(GPIO_IRQn);
|
||||
#ifdef XOSC_PIN_ALLOW
|
||||
|
||||
if (pGlobal_config[LL_SWITCH] & LL_RC32K_SEL)
|
||||
{
|
||||
subWriteReg(0x4000f01c,16,7,0x3fb); //software control 32k_clk
|
||||
subWriteReg(0x4000f01c,6,6,0x01); //enable software control
|
||||
}
|
||||
else
|
||||
{
|
||||
subWriteReg(0x4000f01c,9,8,0x03); //software control 32k_clk
|
||||
subWriteReg(0x4000f01c,6,6,0x00); //disable software control
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
for (i = 0; i < NUMBER_OF_PINS; i++)
|
||||
{
|
||||
if((i == 2) || (i == 3))
|
||||
hal_gpio_pin2pin3_control((gpio_pin_e)i,1);
|
||||
if(m_gpioCtx.pin_assignments[i] != GPIO_PIN_ASSI_NONE)
|
||||
{
|
||||
if((i == P2) || (i == P3))
|
||||
hal_gpio_pin2pin3_control((gpio_pin_e)i,1);
|
||||
|
||||
if (m_gpioCtx.pin_assignments[i] == GPIO_PIN_ASSI_OUT)
|
||||
#ifdef XOSC_PIN_ALLOW
|
||||
|
||||
if((i == P16) ||(i == P17))
|
||||
hal_gpio_cfg_analog_io((gpio_pin_e)i, Bit_DISABLE);
|
||||
|
||||
#endif
|
||||
}
|
||||
|
||||
if ((m_gpioCtx.pin_assignments[i] == GPIO_PIN_ASSI_OUT) && (m_gpioCtx.pin_retention_status & BIT(i)))
|
||||
{
|
||||
bool pol = hal_gpio_read((gpio_pin_e)i);
|
||||
hal_gpio_write((gpio_pin_e)i,pol);
|
||||
|
|
@ -500,6 +612,8 @@ static void hal_gpio_wakeup_handler(void)
|
|||
}
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
void __attribute__((used)) hal_GPIO_IRQHandler(void)
|
||||
{
|
||||
|
|
@ -515,6 +629,9 @@ int hal_gpioin_enable(gpio_pin_e pin)
|
|||
gpio_polarity_e type = POL_FALLING;
|
||||
uint32 pinVal = 0;
|
||||
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
if (p_irq_ctx[pin].posedgeHdl == NULL && p_irq_ctx[pin].negedgeHdl == NULL)
|
||||
return PPlus_ERR_NOT_REGISTED;
|
||||
|
||||
|
|
@ -543,11 +660,13 @@ int hal_gpioin_enable(gpio_pin_e pin)
|
|||
|
||||
int hal_gpioretention_register(gpio_pin_e pin)
|
||||
{
|
||||
if(m_gpioCtx.pin_assignments[pin] == GPIO_PIN_ASSI_IN)
|
||||
return PPlus_ERR_INVALID_PARAM;
|
||||
if (pin > (NUMBER_OF_PINS - 1))
|
||||
return PPlus_ERR_NOT_SUPPORTED;
|
||||
|
||||
m_gpioCtx.pin_assignments[pin] = GPIO_PIN_ASSI_OUT;
|
||||
hal_gpio_pin_init(pin,GPIO_OUTPUT);
|
||||
hal_gpio_pin_init(pin, GPIO_OUTPUT);
|
||||
m_gpioCtx.pin_assignments[pin] = GPIO_PIN_ASSI_OUT;
|
||||
|
||||
m_gpioCtx.pin_retention_status |= BIT(pin);
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
|
|
@ -583,7 +702,9 @@ int hal_gpio_init(void)
|
|||
AP_WAKEUP->io_wu_mask_34_32 = 0;
|
||||
NVIC_SetPriority(GPIO_IRQn, IRQ_PRIO_HAL);
|
||||
NVIC_EnableIRQ(GPIO_IRQn);
|
||||
#if(CFG_SLEEP_MODE == PWR_MODE_SLEEP)
|
||||
hal_pwrmgr_register(MOD_GPIO, hal_gpio_sleep_handler, hal_gpio_wakeup_handler);
|
||||
#endif
|
||||
return PPlus_SUCCESS;
|
||||
}
|
||||
|
||||
|
|
@ -594,8 +715,3 @@ void hal_gpio_debug_mux(Freq_Type_e fre,bool en)
|
|||
else
|
||||
AP_IOMUX->debug_mux_en &= ~BIT(fre);
|
||||
}
|
||||
|
||||
void hal_gpioin_set_flag(gpio_pin_e pin)
|
||||
{
|
||||
m_gpioCtx.pin_assignments[pin] = GPIO_PIN_ASSI_IN;
|
||||
}
|
||||
|
|
@ -1,5 +1,33 @@
|
|||
/**************************************************************************************************
|
||||
*******
|
||||
|
||||
Phyplus Microelectronics Limited confidential and proprietary.
|
||||
All rights reserved.
|
||||
|
||||
IMPORTANT: All rights of this software belong to Phyplus Microelectronics
|
||||
Limited ("Phyplus"). Your use of this Software is limited to those
|
||||
specific rights granted under the terms of the business contract, the
|
||||
confidential agreement, the non-disclosure agreement and any other forms
|
||||
of agreements as a customer or a partner of Phyplus. You may not use this
|
||||
Software unless you agree to abide by the terms of these agreements.
|
||||
You acknowledge that the Software may not be modified, copied,
|
||||
distributed or disclosed unless embedded on a Phyplus Bluetooth Low Energy
|
||||
(BLE) integrated circuit, either as a product or is integrated into your
|
||||
products. Other than for the aforementioned purposes, you may not use,
|
||||
reproduce, copy, prepare derivative works of, modify, distribute, perform,
|
||||
display or sell this Software and/or its documentation for any purposes.
|
||||
|
||||
YOU FURTHER ACKNOWLEDGE AND AGREE THAT THE SOFTWARE AND DOCUMENTATION ARE
|
||||
PROVIDED AS IS WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED,
|
||||
INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY, TITLE,
|
||||
NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL
|
||||
PHYPLUS OR ITS SUBSIDIARIES BE LIABLE OR OBLIGATED UNDER CONTRACT,
|
||||
NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR OTHER
|
||||
LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
|
||||
INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE
|
||||
OR CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT
|
||||
OF SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
|
||||
(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
|
||||
|
||||
**************************************************************************************************/
|
||||
|
||||
/*******************************************************************************
|
||||
|
|
@ -180,10 +208,9 @@ int hal_gpioin_unregister(gpio_pin_e pin);
|
|||
int hal_gpio_init(void);
|
||||
void hal_gpio_debug_mux(Freq_Type_e fre,bool en);
|
||||
|
||||
|
||||
//rom api
|
||||
extern int gpio_write(gpio_pin_e pin, uint8_t en);
|
||||
|
||||
extern bool gpio_read(gpio_pin_e pin);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
@ -123,7 +123,7 @@ void light_pwm_init(void)
|
|||
{
|
||||
hal_pwm_module_init();
|
||||
|
||||
for(int i = 0; i < sizeof(pwm_ch)/sizeof(pwm_ch[0]); i++)
|
||||
for(unsigned int i = 0; i < sizeof(pwm_ch)/sizeof(pwm_ch[0]); i++)
|
||||
{
|
||||
pwm_ch[i].pwmN = (PWMN_e)(PWM_CH0 + (PWMN_e)i);
|
||||
pwm_ch[i].pwmPin = GPIO_DUMMY;
|
||||
|
|
@ -49,7 +49,7 @@ static uint32_t sramRet_config;
|
|||
static uint32_t s_config_swClk0 = DEF_CLKG_CONFIG_0;
|
||||
|
||||
uint32_t s_config_swClk1 = DEF_CLKG_CONFIG_1;
|
||||
uint32_t s_gpio_wakeup_src_group1,s_gpio_wakeup_src_group2;
|
||||
uint32_t s_gpio_wakeup_src_group1, s_gpio_wakeup_src_group2;
|
||||
|
||||
/*
|
||||
osal_idle_task will be call
|
||||
|
|
@ -262,7 +262,7 @@ int __attribute__((used)) hal_pwrmgr_wakeup_process(void)
|
|||
WaitRTCCount(8); // 8*32us
|
||||
#endif
|
||||
AP_PCR->SW_CLK = s_config_swClk0;
|
||||
AP_PCR->SW_CLK1 = s_config_swClk1|0x01;//force set M0 CPU
|
||||
AP_PCR->SW_CLK1 = s_config_swClk1 | 0x01; //force set M0 CPU
|
||||
s_gpio_wakeup_src_group1 = AP_AON->GPIO_WAKEUP_SRC[0];
|
||||
s_gpio_wakeup_src_group2 = AP_AON->GPIO_WAKEUP_SRC[1];
|
||||
//restore BB TIMER IRQ_PRIO
|
||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue