General UNIHIKERMind+

Issue with the DFR1216_1 Expansion Board with a micro under Mind+

userHead Patrick.Gelinaud 2026-09-15 17:54:08 7 Views0 Replies

Problem Description

When a DFR1216_1 expansion board is used with a micro and programmed with Mind+, we have observed a motor control issue when a servo motor control instruction is placed before a motor control instruction.

Example

 

The following program does not work correctly:

 

Servo motor command → M1 motor command

In this case, motor M1 receives the command correctly, but it operates without sufficient power.

 

However, when the order of the instructions is reversed:

M1 motor command → Servo motor command

the motor operates normally.

 

Observation Regarding the Generated Code

An analysis of the Arduino code automatically generated by Mind+ suggests that the problem may be related to the initialization of the motor control.

When the motor instruction is used alone, Mind+ generates the following motor period initialization instructions:

eunihiker.setMotorPeriod(eMotor1_2, 255); eunihiker.setMotorPeriod(eMotor3_4, 255);

However, when the servo motor block is placed before the motor block, these initialization instructions may no longer appear in the setup() function of the generated program.

The behavior therefore appears to depend on the order in which the blocks are placed in the Mind+ program.

 

Proposed Workaround

To avoid this issue, we currently recommend placing a motor initialization instruction with a speed of zero at the beginning of the program.

This instruction forces the motor control to be initialized before any servo motor is used.

 

Request to DFRobot

We would like to know whether this behavior is a known issue with the DFR1216_1, and whether it would be possible to fix the library or the Mind+ extension so that the motor initialization is always performed, regardless of the order of the servo motor and motor blocks.

icon Capture 01.zip 497KB Download(0)