Skip to content

Commit 2171d4c

Browse files
committed
example F429 updated
1 parent b2e6aa9 commit 2171d4c

File tree

1 file changed

+1
-2
lines changed
  • ModbusSTM32F4-discovery/ModbusSTM32F4-Discovery/Core/Src

1 file changed

+1
-2
lines changed

ModbusSTM32F4-discovery/ModbusSTM32F4-Discovery/Core/Src/main.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -202,13 +202,12 @@ int main(void)
202202
//ModbusH2.EN_Pin = LD2_Pin; // RS485 Enable
203203
ModbusH.u32overTime = 0;
204204
ModbusH.au16regs = ModbusDATARX;
205-
ModbusH.u8regsize= sizeof(ModbusDATARX)/sizeof(ModbusDATARX[0]);
205+
ModbusH.u16regsize= sizeof(ModbusDATARX)/sizeof(ModbusDATARX[0]);
206206
//Initialize Modbus library
207207
ModbusInit(&ModbusH);
208208
//Start capturing traffic on serial Port
209209
ModbusStart(&ModbusH);
210210

211-
212211
/* USER CODE END 2 */
213212

214213
/* Init scheduler */

0 commit comments

Comments
 (0)