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

Added fix for calibration 5 #559

Merged
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
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ namespace embot { namespace app { namespace eth {
{
Process::eApplication,
{2, 14},
{2025, Month::Jan, Day::sixteen, 11, 17}
{2025, Month::Jan, Day::twentytwo, 16, 00}
},
.OStick = 1000*embot::core::time1microsec,
.OSstacksizeinit = 10*1024,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,20 +81,20 @@ extern "C" {
#define EOMTHEEMSAPPLCFG_VERSION_MAJOR (VERSION_MAJOR_OFFSET+3)
// <o> minor <0-255>
// <o> minor <0-255>
#define EOMTHEEMSAPPLCFG_VERSION_MINOR 98
#define EOMTHEEMSAPPLCFG_VERSION_MINOR 99
// </h>version

// <h> build date
// <o> year <2010-2030>
#define EOMTHEEMSAPPLCFG_BUILDDATE_YEAR 2024
#define EOMTHEEMSAPPLCFG_BUILDDATE_YEAR 2025
// <o> month <1-12>
#define EOMTHEEMSAPPLCFG_BUILDDATE_MONTH 12
#define EOMTHEEMSAPPLCFG_BUILDDATE_MONTH 1
// <o> day <1-31>
#define EOMTHEEMSAPPLCFG_BUILDDATE_DAY 24
#define EOMTHEEMSAPPLCFG_BUILDDATE_DAY 14
// <o> hour <0-23>
#define EOMTHEEMSAPPLCFG_BUILDDATE_HOUR 18
#define EOMTHEEMSAPPLCFG_BUILDDATE_HOUR 16
// <o> minute <0-59>
#define EOMTHEEMSAPPLCFG_BUILDDATE_MIN 00
#define EOMTHEEMSAPPLCFG_BUILDDATE_MIN 0
// </h>build date
// </h>Info

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ extern "C" {
#define EOMTHEEMSAPPLCFG_VERSION_MAJOR 3
// <o> minor <0-255>
// <o> minor <0-255>
#define EOMTHEEMSAPPLCFG_VERSION_MINOR 77
#define EOMTHEEMSAPPLCFG_VERSION_MINOR 78

// </h>version

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ extern "C" {
#define EOMTHEEMSAPPLCFG_VERSION_MAJOR (VERSION_MAJOR_OFFSET+3)
// <o> minor <0-255>

#define EOMTHEEMSAPPLCFG_VERSION_MINOR 98
#define EOMTHEEMSAPPLCFG_VERSION_MINOR 99

// </h>version

Expand Down
2 changes: 1 addition & 1 deletion emBODY/eBcode/arch-arm/embobj/plus/mc/Calibrators.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ BOOL JointSet_do_wait_calibration_5(JointSet* o)

for (int ms=0; ms<*(o->pN); ++ms)
{
if (!Motor_is_calibrated(o->motor+o->motors_of_set[ms]))
if(Calibration_check(o->motor+o->motors_of_set[ms]))
{
calibrated = FALSE;

Expand Down
4 changes: 4 additions & 0 deletions emBODY/eBcode/arch-arm/embobj/plus/mc/Motor.c
Original file line number Diff line number Diff line change
Expand Up @@ -990,6 +990,10 @@ BOOL Motor_is_calibrated(Motor* o) //
return !(o->not_calibrated);
}

BOOL Calibration_check(Motor* o)
{
return (o->hardstop_calibdata.u.bits.iscalibrating && !(o->hardstop_calibdata.u.bits.hwlimitreached));
}

CTRL_UNITS Motor_do_trq_control_EXPERIMENTAL(Motor* o, CTRL_UNITS trq_ref, CTRL_UNITS trq_fbk, CTRL_UNITS motor_vel_icubdeg_sec) //
{
Expand Down
1 change: 1 addition & 0 deletions emBODY/eBcode/arch-arm/embobj/plus/mc/Motor.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ extern void Motor_force_idle(Motor* o); //

extern void Motor_motion_reset(Motor *o); //
extern BOOL Motor_is_calibrated(Motor* o); //
extern BOOL Calibration_check(Motor* o); //
extern BOOL Motor_check_faults(Motor* o); //
extern void Motor_reset(Motor *o);//

Expand Down