Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.0.3 release PR #11

Merged
merged 2 commits into from
Jul 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
![Release](https://www.ardu-badge.com/badge/SimpleDCMotor.svg?)


Release 1.0.2 for SimpleFOC 2.3.1 or later
Release 1.0.3 for SimpleFOC 2.3.4 or later

:warning: code in development! Please help us test it!

Expand Down
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=SimpleDCMotor
version=1.0.2
version=1.0.3
author=Simplefoc <[email protected]>
maintainer=Simplefoc <[email protected]>
sentence=A library enabling DC motor control with SimpleFOC.
Expand Down
7 changes: 4 additions & 3 deletions src/DCMotor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,16 @@ void DCMotor::linkDriver(DCDriver* driver) {
};


void DCMotor::init() {
int DCMotor::init() {
if (!driver || !driver->initialized) {
motor_status = FOCMotorStatus::motor_init_failed;
SIMPLEFOC_DEBUG("MOT: Init not possible, driver not initialized");
return;
return 0;
}
if (!sensor) {
motor_status = FOCMotorStatus::motor_init_failed;
SIMPLEFOC_DEBUG("MOT: Init not possible, sensor not initialized");
return;
return 0;
}

motor_status = FOCMotorStatus::motor_initializing;
Expand Down Expand Up @@ -62,6 +62,7 @@ void DCMotor::init() {
}

motor_status = FOCMotorStatus::motor_ready;
return 1;
};


Expand Down
2 changes: 1 addition & 1 deletion src/DCMotor.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class DCMotor : public FOCMotor {
DCDriver* driver;

/** Motor hardware init function */
void init() override;
int init() override;
/** Motor disable function */
void disable() override;
/** Motor enable function */
Expand Down
Loading