mirror of
https://github.com/DashyFox/StackSport.git
synced 2025-05-04 07:10:17 +00:00
test
This commit is contained in:
parent
ff754d60a6
commit
b962cbb419
@ -100,7 +100,7 @@
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release" cleanCommand="rm -rf" description="" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.config.exe.release.301353199" name="Release" parent="com.st.stm32cube.ide.mcu.gnu.managedbuild.config.exe.release">
|
||||
<configuration artifactExtension="elf" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe,org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release" cleanCommand="rm -rf" description="" id="com.st.stm32cube.ide.mcu.gnu.managedbuild.config.exe.release.301353199" name="Release" parent="com.st.stm32cube.ide.mcu.gnu.managedbuild.config.exe.release" postbuildStep="STM32_Programmer_CLI -c port=SWD -w "${ProjName}.hex" -v -rst">
|
||||
<folderInfo id="com.st.stm32cube.ide.mcu.gnu.managedbuild.config.exe.release.301353199." name="/" resourcePath="">
|
||||
<toolChain id="com.st.stm32cube.ide.mcu.gnu.managedbuild.toolchain.exe.release.1942176349" name="MCU ARM GCC" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.toolchain.exe.release">
|
||||
<option id="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.target_mcu.855111063" name="MCU" superClass="com.st.stm32cube.ide.mcu.gnu.managedbuild.option.target_mcu" useByScannerDiscovery="true" value="STM32F103C8Tx" valueType="string"/>
|
||||
|
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,4 +1,4 @@
|
||||
|
||||
Release/*
|
||||
Debug/*
|
||||
Drivers/*
|
||||
Middlewares/*
|
@ -1,6 +1,7 @@
|
||||
#include "EEPROM.h"
|
||||
#include "pca9685.h"
|
||||
#include "usbd_cdc_if.h"
|
||||
#include "Print.h"
|
||||
|
||||
|
||||
void SaveShot(unsigned char number, struct Shot* shot)
|
||||
|
@ -23,6 +23,7 @@ enum IR_MENU {
|
||||
|
||||
// <<
|
||||
extern void (*InputHandler)(void); // ProcessFunc
|
||||
extern void (*onHoldRepeat)(void);
|
||||
extern uint16_t inputParam; // current input parameter
|
||||
|
||||
// >>
|
||||
@ -46,10 +47,14 @@ void onSelectShot(){
|
||||
|
||||
|
||||
|
||||
|
||||
unsigned char b1 = 1;
|
||||
unsigned char b2 = 1;
|
||||
unsigned char b3 = 1;
|
||||
|
||||
uint8_t screwSpeed;
|
||||
uint8_t speedUP = 100;
|
||||
uint8_t speedDown = 100;
|
||||
|
||||
void IR_Home_Process() {
|
||||
InputHandler = IR_Home_Process;
|
||||
SetShiftReg_inline(0xff, 0, 0);
|
||||
@ -59,115 +64,120 @@ void IR_Home_Process() {
|
||||
paramEnter(onSelectShot);
|
||||
break;
|
||||
|
||||
case IR_PROG:
|
||||
// paramEnter(onSelectShot);
|
||||
break;
|
||||
|
||||
case IR_FRONT_MID:
|
||||
SetShiftReg_inline(0, 0, 0);
|
||||
b1 = b2 = b3 = 0;
|
||||
break;
|
||||
// case IR_PROG:
|
||||
//// paramEnter(onSelectShot);
|
||||
// break;
|
||||
//
|
||||
// case IR_FRONT_MID:
|
||||
// SetShiftReg_inline(0, 0, 0);
|
||||
// b1 = b2 = b3 = 0;
|
||||
// break;
|
||||
case IR_FRONT_LEFT:
|
||||
SetShiftReg_inline(++b1, ++b2, ++b3);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
|
||||
case IR_F_BTN:
|
||||
{
|
||||
Shot testShot = GetShot(3);
|
||||
if(!testShot.isExist){
|
||||
testShot.countRepeatShot = 1;
|
||||
testShot.speedRollerTop = 200;
|
||||
testShot.speedRollerBottom = 200;
|
||||
testShot.speedScrew = 100;
|
||||
testShot.rotationAxial = 90;
|
||||
testShot.rotationHorizontal = 90;
|
||||
testShot.rotationVertical = 90;
|
||||
|
||||
SaveShot(3, &testShot);
|
||||
doShot(&testShot);
|
||||
}
|
||||
}
|
||||
// {
|
||||
// Shot testShot = GetShot(3);
|
||||
// if(!testShot.isExist){
|
||||
// testShot.countRepeatShot = 1;
|
||||
// testShot.speedRollerTop = 200;
|
||||
// testShot.speedRollerBottom = 200;
|
||||
// testShot.speedScrew = 100;
|
||||
// testShot.rotationAxial = 90;
|
||||
// testShot.rotationHorizontal = 90;
|
||||
// testShot.rotationVertical = 90;
|
||||
//
|
||||
// SaveShot(3, &testShot);
|
||||
// doShot(&testShot);
|
||||
// }
|
||||
// }
|
||||
break;
|
||||
|
||||
case IR_PAUSE:
|
||||
{
|
||||
uint8_t buf[256];
|
||||
uint8_t buf[32];
|
||||
|
||||
uint16_t blockAddr16 = 0;
|
||||
uint8_t blockAddr[2] = {HIBYTE(blockAddr16), LOBYTE(blockAddr16)};
|
||||
uint16_t blockAddr16 = 0; // Начальный адрес блока в EEPROM
|
||||
uint8_t blockAddr[2] = {HIBYTE(blockAddr16), LOBYTE(blockAddr16)}; // Адрес в формате 2 байта
|
||||
|
||||
HAL_I2C_Master_Transmit(&hi2c1, (AT24C_ADRESS << 1), blockAddr, 2, 10);
|
||||
HAL_Delay(1);
|
||||
HAL_I2C_Master_Receive(&hi2c1, (AT24C_ADRESS << 1), buf, sizeof(buf), 10);
|
||||
HAL_Delay(1);
|
||||
// Отправляем адрес в EEPROM
|
||||
if (HAL_I2C_Master_Transmit(&hi2c1, (AT24C_ADRESS << 1), blockAddr, 2, 1000) == HAL_OK) {
|
||||
HAL_Delay(1); // Небольшая задержка
|
||||
|
||||
// Читаем данные из EEPROM
|
||||
if (HAL_I2C_Master_Receive(&hi2c1, (AT24C_ADRESS << 1), buf, sizeof(buf), 1000) == HAL_OK) {
|
||||
// Выводим считанные данные
|
||||
for (int i = 0; i < sizeof(buf); ++i) {
|
||||
if (!(i % 8)) print(" ");
|
||||
if (!(i % 32)) print("\n");
|
||||
char buffer[BUFFER_SIZE];
|
||||
int_to_str(buf[i], buffer, 16);
|
||||
|
||||
char buffer[16];
|
||||
snprintf(buffer, sizeof(buffer), "%02X ", buf[i]); // Преобразуем байт в шестнадцатеричную строку
|
||||
CDC_Transmit_FS((uint8_t*)buffer, strlen(buffer));
|
||||
HAL_Delay(1);
|
||||
print(" ");
|
||||
}
|
||||
} else {
|
||||
print("Read Error EEPROM\n");
|
||||
}
|
||||
} else {
|
||||
print("Address TX Error EEPROM\n");
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
case IR_DEBUG:
|
||||
{
|
||||
uint8_t i2c_address;
|
||||
HAL_StatusTypeDef result;
|
||||
|
||||
print("Scan\n");
|
||||
|
||||
// Перебираем все возможные адреса на шине I2C (7 бит, от 0x08 до 0x77)
|
||||
for (i2c_address = 0x08; i2c_address <= 0x77; i2c_address++) {
|
||||
// Отправляем запрос на указанный адрес (HAL_I2C_Master_Transmit без данных)
|
||||
result = HAL_I2C_IsDeviceReady(&hi2c1, (i2c_address << 1), 1, 100);
|
||||
|
||||
if (result == HAL_OK) {
|
||||
// Если устройство отвечает, выводим его адрес
|
||||
print("Found I2C at: ");
|
||||
printNumber(i2c_address);
|
||||
print("\n");
|
||||
} else {
|
||||
// Если устройство не отвечает, продолжаем сканирование
|
||||
print(".");
|
||||
}
|
||||
HAL_Delay(10); // Задержка для стабильности сканирования
|
||||
}
|
||||
|
||||
print("\nScanning completed.\n");
|
||||
}
|
||||
break;
|
||||
|
||||
case IR_NUM_1:
|
||||
// SetServo(0, 90+25);
|
||||
setRollersSpeed(200,200);
|
||||
setRollersSpeed(speedUP+=1, speedDown);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
case IR_NUM_2:
|
||||
setRollersSpeed(0,0);
|
||||
// SetServo(1, 90+25);
|
||||
setScrewkSpeed(screwSpeed+=1);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
case IR_NUM_3:
|
||||
setScrewkSpeed(100);
|
||||
// SetServo(3, 90+25);
|
||||
setRollersSpeed(speedUP, speedDown+=1);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
|
||||
case IR_NUM_7:
|
||||
// SetServo(0, 90-25);
|
||||
|
||||
{
|
||||
uint16_t blockAddr16 = 0;
|
||||
uint8_t blockAddr[2] = {HIBYTE(blockAddr16), LOBYTE(blockAddr16)};
|
||||
|
||||
unsigned char Buf[2+2];
|
||||
memset(Buf, 0x00, sizeof(Buf));
|
||||
Buf[0] = blockAddr[0];
|
||||
Buf[1] = blockAddr[1];
|
||||
|
||||
uint8_t data[2] = {0xAB,0xCD};
|
||||
|
||||
for( unsigned char i = 0; i < (sizeof(data)); i++ ) Buf[i+2] = (data)[i];
|
||||
|
||||
HAL_I2C_Master_Transmit(&hi2c1, (AT24C_ADRESS << 1), Buf, (sizeof(data) + 2), 10);
|
||||
HAL_Delay(1);
|
||||
}
|
||||
setRollersSpeed(speedUP-=1, speedDown);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
case IR_NUM_8:
|
||||
// SetServo(1, 90-25);
|
||||
{
|
||||
|
||||
uint16_t blockAddr16 = 0;
|
||||
uint8_t blockAddr[2] = {HIBYTE(blockAddr16), LOBYTE(blockAddr16)};
|
||||
|
||||
unsigned char Buf[2+2];
|
||||
memset(Buf, 0x00, sizeof(Buf));
|
||||
Buf[0] = blockAddr[0];
|
||||
Buf[1] = blockAddr[1];
|
||||
|
||||
uint16_t data = 0;
|
||||
|
||||
for( unsigned char i = 0; i < (sizeof(data)); i++ ) Buf[i+2] = (&data)[i];
|
||||
|
||||
HAL_I2C_Master_Transmit(&hi2c1, (AT24C_ADRESS << 1), Buf, (sizeof(data) + 2), 10);
|
||||
HAL_Delay(1);
|
||||
}
|
||||
setScrewkSpeed(screwSpeed-=1);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
case IR_NUM_9:
|
||||
// SetServo(3, 90-25);
|
||||
setRollersSpeed(speedUP, speedDown-=1);
|
||||
onHoldRepeat = IR_Home_Process;
|
||||
break;
|
||||
|
||||
case IR_NUM_5:
|
||||
|
@ -1,19 +1,16 @@
|
||||
/*
|
||||
* IR_CMD_Handler.c
|
||||
*
|
||||
* Created on: Aug 25, 2024
|
||||
* Author: DashyFox
|
||||
*/
|
||||
|
||||
#include "IR_CMD_Handler.h"
|
||||
#include "IR.h"
|
||||
#include "SimpleTimer.h"
|
||||
#include "ShiftReg.h"
|
||||
#include "Print.h"
|
||||
|
||||
|
||||
#define IR_Timeout 137
|
||||
#define ResetInputProgerss_Timeout 2500
|
||||
#define InitialRepeatTime 100 // Начальный интервал времени между вызовами функции при удержании
|
||||
#define MinRepeatTime 30 // Минимально допустимый интервал времени между вызовами функции при удержании
|
||||
#define HoldTime 500 // Время, необходимое для определения удержания
|
||||
#define RepeatDecay 10 // Шаг уменьшения времени между вызовами функции при удержании
|
||||
|
||||
#define NULL_NumberParam 0xFFFF
|
||||
|
||||
//extern unsigned char IR_Command;
|
||||
@ -34,18 +31,27 @@ uint8_t inputDigit = 0; // left = 0 to right
|
||||
|
||||
uint16_t inputParam = NULL_NumberParam;
|
||||
|
||||
void IR_Home_Process();
|
||||
uint32_t holdStartTime = 0; // Время начала удержания
|
||||
uint32_t lastRepeatTime = 0; // Последнее время повторного вызова функции
|
||||
uint32_t currentRepeatTime = InitialRepeatTime; // Текущее значение интервала между вызовами функции
|
||||
|
||||
void IR_Home_Process();
|
||||
|
||||
void IR_ParamEnter();
|
||||
void IR_CMD_Clear();
|
||||
void (*InputHandler)(void) = IR_Home_Process;
|
||||
void NullFunc(){};
|
||||
void (*onParamEnter)() = NullFunc;
|
||||
void (*onHoldRepeat)() = NullFunc; // Указатель на функцию, вызываемую при удержании
|
||||
|
||||
void paramEnter(void(*onEnter_)()){
|
||||
InputHandler = IR_ParamEnter;
|
||||
onParamEnter = onEnter_;
|
||||
}
|
||||
|
||||
// Установка функции для вызова при удержании
|
||||
void setHoldRepeatHandler(void (*handler)()) {
|
||||
onHoldRepeat = handler;
|
||||
}
|
||||
|
||||
void IR_CMD_Handler() {
|
||||
@ -54,8 +60,7 @@ void IR_CMD_Handler() {
|
||||
if (dataHandled_flag && (millis() - IR_Timeout_timer > IR_Timeout)) {
|
||||
dataHandled_flag = 0;
|
||||
}
|
||||
if (inputInProgerss
|
||||
&& (millis() - inputInProgerss_timer > ResetInputProgerss_Timeout)) {
|
||||
if (inputInProgerss && (millis() - inputInProgerss_timer > ResetInputProgerss_Timeout)) {
|
||||
IR_CMD_Clear();
|
||||
}
|
||||
|
||||
@ -65,15 +70,34 @@ void IR_CMD_Handler() {
|
||||
|
||||
IR_Timeout_timer = millis();
|
||||
// works once per button press
|
||||
if (memcmp(&data, &old_data, sizeof(IRData)) != 0
|
||||
|| !dataHandled_flag) {
|
||||
if (memcmp(&data, &old_data, sizeof(IRData)) != 0 || !dataHandled_flag) {
|
||||
dataHandled_flag = 1;
|
||||
if (IR_Address == 0x01) {
|
||||
onHoldRepeat = NullFunc;
|
||||
InputHandler();
|
||||
inputInProgerss = 1;
|
||||
inputInProgerss_timer = millis();
|
||||
holdStartTime = millis(); // Запоминаем время начала удержания
|
||||
lastRepeatTime = holdStartTime; // Инициализируем таймер повторного вызова
|
||||
currentRepeatTime = InitialRepeatTime; // Сбрасываем интервал повторного вызова
|
||||
}
|
||||
memcpy(&old_data, &data, sizeof(IRData));
|
||||
} else {
|
||||
// Проверка на удержание кнопки
|
||||
if (millis() - holdStartTime > HoldTime) { // Если кнопка удерживается дольше HoldTime
|
||||
if (millis() - lastRepeatTime > currentRepeatTime) { // Если прошло достаточно времени для повторного вызова
|
||||
lastRepeatTime = millis(); // Обновляем время последнего вызова
|
||||
onHoldRepeat(); // Вызываем функцию при удержании
|
||||
|
||||
// Уменьшаем интервал до минимального значения
|
||||
if (currentRepeatTime > MinRepeatTime) {
|
||||
currentRepeatTime -= RepeatDecay;
|
||||
if (currentRepeatTime < MinRepeatTime) {
|
||||
currentRepeatTime = MinRepeatTime;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
IR_Timeout_timer = millis();
|
||||
ClearIRStatus();
|
||||
@ -81,7 +105,6 @@ void IR_CMD_Handler() {
|
||||
}
|
||||
|
||||
void IR_CMD_Clear() {
|
||||
|
||||
InputHandler = IR_Home_Process;
|
||||
inputDigit = 0;
|
||||
inputInProgerss = 0;
|
||||
@ -122,6 +145,3 @@ void IR_ParamEnter() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
@ -40,8 +40,8 @@ typedef struct Current {
|
||||
Current current;
|
||||
|
||||
|
||||
extern uint8_t Vz1;
|
||||
extern uint8_t Vz2;
|
||||
extern int16_t Vz1;
|
||||
extern int16_t Vz2;
|
||||
void doShot(Shot* shot){
|
||||
SetServo(0, shot->rotationHorizontal);
|
||||
SetServo(1, shot->rotationVertical);
|
||||
@ -89,7 +89,8 @@ void startShooting(){
|
||||
void stopShooting(){
|
||||
isShooting = 0;
|
||||
isPause = 0;
|
||||
|
||||
setScrewkSpeed(0);
|
||||
setRollersSpeed(100,100);
|
||||
setPosDefault();
|
||||
Vz1 = 100;
|
||||
Vz2 = 100;
|
||||
|
@ -76,8 +76,8 @@ uint8_t rejim[60]; // 0 - chislo rejimov, 1-6 - rejim1, 7-12 - rejim2...
|
||||
uint8_t avto = 0; // vkl/otkl avtomaticheskoi raboti
|
||||
uint8_t rejim_number = 1; // nomer tekyshego rejima
|
||||
|
||||
uint8_t Vz1 = 100;
|
||||
uint8_t Vz2 = 100;
|
||||
int16_t Vz1 = 100;
|
||||
int16_t Vz2 = 100;
|
||||
|
||||
uint16_t vi = 0;
|
||||
|
||||
@ -201,7 +201,18 @@ initcomlete = 1;
|
||||
/* Infinite loop */
|
||||
/* USER CODE BEGIN WHILE */
|
||||
|
||||
Shot testShot = GetShot(3);
|
||||
if(!testShot.isExist){
|
||||
testShot.countRepeatShot = 1;
|
||||
testShot.speedRollerTop = 200;
|
||||
testShot.speedRollerBottom = 200;
|
||||
testShot.speedScrew = 100;
|
||||
testShot.rotationAxial = 90;
|
||||
testShot.rotationHorizontal = 90;
|
||||
testShot.rotationVertical = 90;
|
||||
|
||||
SaveShot(3, &testShot);
|
||||
}
|
||||
|
||||
while (1)
|
||||
{
|
||||
|
@ -254,7 +254,7 @@ void HAL_TIM_MspPostInit(TIM_HandleTypeDef* htim)
|
||||
*/
|
||||
GPIO_InitStruct.Pin = RPWM_UP_Pin|LPWM_UP_Pin|RPWM_DOWN_Pin|LPWM_DOWN_Pin;
|
||||
GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
|
||||
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
|
||||
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_HIGH;
|
||||
HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);
|
||||
|
||||
/* USER CODE BEGIN TIM2_MspPostInit 1 */
|
||||
|
@ -79,8 +79,8 @@ extern uint16_t timing1; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD>
|
||||
extern uint16_t timing2; // <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
extern uint8_t velosety[600]; // <20><><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><>
|
||||
|
||||
extern uint8_t Vz1;
|
||||
extern uint8_t Vz2;
|
||||
extern int16_t Vz1;
|
||||
extern int16_t Vz2;
|
||||
|
||||
/* USER CODE END PV */
|
||||
|
||||
@ -403,6 +403,11 @@ void SysTick_Handler(void)
|
||||
vsk2 = 0;
|
||||
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 0 - 200 <20> -8000 ... 8000 <20><>./<2F><><EFBFBD>.
|
||||
if (Vz1 < 0) {Vz1 = 0;}
|
||||
if (Vz1 > 200) {Vz1 = 200;}
|
||||
if (Vz2 < 0) {Vz2 = 0;}
|
||||
if (Vz2 > 200) {Vz2 = 200;}
|
||||
|
||||
if (Vz1 > 100)
|
||||
{
|
||||
Vzad1 = (Vz1 - 100) * 80;
|
||||
@ -446,6 +451,7 @@ void SysTick_Handler(void)
|
||||
TIM2->CCR3 = Vupr2;
|
||||
}
|
||||
|
||||
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> <20><><EFBFBD><EFBFBD><EFBFBD> <20><><EFBFBD> <20><>
|
||||
if (vi < 600)
|
||||
{
|
||||
|
@ -72,11 +72,13 @@ NVIC.TIM3_IRQn=true\:0\:0\:false\:false\:true\:true\:true\:true
|
||||
NVIC.USART3_IRQn=true\:0\:0\:false\:false\:true\:true\:true\:true
|
||||
NVIC.USB_LP_CAN1_RX0_IRQn=true\:0\:0\:false\:false\:true\:false\:true\:true
|
||||
NVIC.UsageFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false\:false
|
||||
PA0-WKUP.GPIOParameters=GPIO_Label
|
||||
PA0-WKUP.GPIOParameters=GPIO_Speed,GPIO_Label
|
||||
PA0-WKUP.GPIO_Label=RPWM_UP
|
||||
PA0-WKUP.GPIO_Speed=GPIO_SPEED_FREQ_HIGH
|
||||
PA0-WKUP.Signal=S_TIM2_CH1_ETR
|
||||
PA1.GPIOParameters=GPIO_Label
|
||||
PA1.GPIOParameters=GPIO_Speed,GPIO_Label
|
||||
PA1.GPIO_Label=LPWM_UP
|
||||
PA1.GPIO_Speed=GPIO_SPEED_FREQ_HIGH
|
||||
PA1.Signal=S_TIM2_CH2
|
||||
PA11.Mode=Device
|
||||
PA11.Signal=USB_DM
|
||||
@ -86,11 +88,14 @@ PA13.Mode=Serial_Wire
|
||||
PA13.Signal=SYS_JTMS-SWDIO
|
||||
PA14.Mode=Serial_Wire
|
||||
PA14.Signal=SYS_JTCK-SWCLK
|
||||
PA2.GPIOParameters=GPIO_Label
|
||||
PA2.GPIOParameters=GPIO_Speed,GPIO_Label
|
||||
PA2.GPIO_Label=RPWM_DOWN
|
||||
PA2.GPIO_Speed=GPIO_SPEED_FREQ_HIGH
|
||||
PA2.Locked=true
|
||||
PA2.Signal=S_TIM2_CH3
|
||||
PA3.GPIOParameters=GPIO_Label
|
||||
PA3.GPIOParameters=GPIO_Speed,GPIO_Label
|
||||
PA3.GPIO_Label=LPWM_DOWN
|
||||
PA3.GPIO_Speed=GPIO_SPEED_FREQ_HIGH
|
||||
PA3.Signal=S_TIM2_CH4
|
||||
PA4.GPIOParameters=GPIO_Label
|
||||
PA4.GPIO_Label=LED_DATA
|
||||
@ -131,8 +136,9 @@ PB11.GPIOParameters=GPIO_Label
|
||||
PB11.GPIO_Label=RX
|
||||
PB11.Mode=Asynchronous
|
||||
PB11.Signal=USART3_RX
|
||||
PB6.GPIOParameters=GPIO_Label
|
||||
PB6.GPIOParameters=GPIO_Label,GPIO_Mode
|
||||
PB6.GPIO_Label=SCL
|
||||
PB6.GPIO_Mode=GPIO_MODE_AF_OD
|
||||
PB6.Mode=I2C
|
||||
PB6.Signal=I2C1_SCL
|
||||
PB7.GPIOParameters=GPIO_Label
|
||||
@ -228,7 +234,7 @@ TIM2.Channel-PWM\ Generation1\ CH1=TIM_CHANNEL_1
|
||||
TIM2.Channel-PWM\ Generation2\ CH2=TIM_CHANNEL_2
|
||||
TIM2.Channel-PWM\ Generation3\ CH3=TIM_CHANNEL_3
|
||||
TIM2.Channel-PWM\ Generation4\ CH4=TIM_CHANNEL_4
|
||||
TIM2.IPParameters=Channel-PWM Generation1 CH1,Channel-PWM Generation2 CH2,Channel-PWM Generation3 CH3,Channel-PWM Generation4 CH4,Period
|
||||
TIM2.IPParameters=Channel-PWM Generation1 CH1,Channel-PWM Generation2 CH2,Channel-PWM Generation4 CH4,Period,Channel-PWM Generation3 CH3
|
||||
TIM2.Period=4000
|
||||
TIM3.Channel-Input_Capture1_from_TI1=TIM_CHANNEL_1
|
||||
TIM3.Channel-Input_Capture2_from_TI2=TIM_CHANNEL_2
|
||||
|
Loading…
x
Reference in New Issue
Block a user