-
Notifications
You must be signed in to change notification settings - Fork 5
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
error when configuring fieldfriend #59
Comments
When the fieldfriend config is overwritten, the new configuration works on the rb32. But when configuring the fieldfriend configuration the bug occurs again. The fieldfriend configuration looks like this:rdyp = Output(15)
en3 = Output(12)
bluetooth = Bluetooth("fieldfriend-ff12")
can = Can(32, 33, 1000000)
l0 = ODriveMotor(can, 0)
r0 = ODriveMotor(can, 512)
l1 = ODriveMotor(can, 256)
r1 = ODriveMotor(can, 768)
l0.m_per_tick = 0.05567092651757189
r0.m_per_tick = 0.05567092651757189
l1.m_per_tick = 0.05567092651757189
r1.m_per_tick = 0.05567092651757189
l0.reversed = true
r0.reversed = false
l1.reversed = true
r1.reversed = false
wheels = ODriveWheels(l0, r0)
wheels_front = ODriveWheels(l1, r1)
wheels.width = 0.47
wheels_front.width = 0.47
wheels.shadow(wheels_front)
serial = Serial(26, 27, 115200, 1)
p0 = Expander(serial, 25, 14)
master = CanOpenMaster(can)
master.sync_interval = 5
yaxis_motor = CanOpenMotor(can, 96)
yaxis_end_l = p0.Input(21)
yaxis_end_l.inverted = true
yaxis_end_r = p0.Input(19)
yaxis_end_r.inverted = true
yaxis = MotorAxis(yaxis_motor, yaxis_end_r, yaxis_end_l)
tornado_motor_z = ODriveMotor(can, 1280)
tornado_motor_turn = ODriveMotor(can, 1024)
tornado_motor_z.m_per_tick = 0.0019968051118210866
tornado_motor_turn.m_per_tick = 0.07987220447284345
tornado_motor_z.limits(1.5, 30)
tornado_motor_turn.limits(1.5, 30)
tornado_motor_z.reversed = true
tornado_motor_turn.reversed = true
tornado_end_top = p0.Input(32)
tornado_end_top.inverted = true;
tornado_end_bottom = p0.Input(5)
tornado_end_bottom.inverted = true;
tornado_ref_motor = p0.Input(35)
tornado_ref_motor.inverted = true;
tornado_ref_gear = p0.Input(18)
tornado_ref_gear.inverted = false;
tornado_ref_knife_stop = p0.Input(4)
tornado_ref_knife_stop.inverted = false;
tornado_ref_knife_ground = p0.Input(33)
tornado_ref_knife_ground.inverted = true;
tornado_z = MotorAxis(tornado_motor_z, tornado_end_bottom, tornado_end_top)
bool tornado_is_referencing = false;
bool tornado_ref_motor_enabled = false;
bool tornado_ref_gear_enabled = false;
when tornado_ref_motor_enabled and tornado_is_referencing and tornado_ref_motor.level == 0 then
tornado_motor_turn.speed(0);
end
when tornado_ref_gear_enabled and tornado_is_referencing and tornado_ref_gear.level == 1 then
tornado_motor_turn.speed(0);
end
bool tornado_knife_ground_enabled = false;
bool tornado_knife_stop_enabled = false;
when tornado_knife_ground_enabled and tornado_ref_knife_ground.level == 1 then
tornado_motor_z.off();
end
when tornado_knife_stop_enabled and tornado_ref_knife_stop.level == 1 then
en3.off();
tornado_knife_stop_enabled = false;
end
flashlight = PwmOutput(5)
flashlight.duty = 255
flashlight_back = PwmOutput(4)
flashlight_back.duty = 255
flashlight.shadow(flashlight_back)
bms = p0.Serial(26, 27, 9600, 2)
bms.unmute()
estop_1 = Input(34)
estop_2 = Input(35)
battery_control_reset = p0.Output(15)
battery_control_status = p0.Input(13)
bumper_front_top = p0.Input(22)
bumper_front_bottom = p0.Input(12)
bumper_back = p0.Input(25)
rdyp_status = Input(39)
vdp_status = p0.Input(39)
let stop do wheels.speed(0, 0); yaxis.stop();tornado_z.stop();tornado_motor_turn.speed(0);end
when estop_1.level == 0 then stop(); end
when estop_2.level == 0 then stop(); end
when bumper_front_top.level == 1 or bumper_front_bottom.level == 1 or bumper_back.level == 1 then wheels.off(); end
when tornado_ref_knife_ground.active == false then wheels.speed(0, 0); yaxis.stop(); end
when core.last_message_age > 1000 then wheels.speed(0, 0); end
when core.last_message_age > 20000 then stop(); end
core.output("core.millis wheels.linear_speed:3 wheels.angular_speed:3 yaxis_end_l.active yaxis_end_r.active yaxis_motor.actual_position yaxis_motor.status_target_reached yaxis_motor.status_fault yaxis_motor.ctrl_enable tornado_end_top.active tornado_end_bottom.active tornado_ref_motor.active tornado_ref_gear.active tornado_ref_knife_stop.active tornado_ref_knife_ground.active tornado_motor_z.position:3 tornado_motor_turn.position:3 estop_1.level estop_2.level battery_control_status.level bumper_front_top.level bumper_front_bottom.level bumper_back.level rdyp_status.level vdp_status.level core.heap")
rdyp.on()
en3.on() the same behaviour is observed on the z34 robot brain. when configuring the fieldfriend first it works. when it is configured later the bug occurs again.
and the configuration is not succsessful. |
This issue is also occuring on the U4 with following startuprdyp = Output(15)
en3 = Output(12)
bluetooth = Bluetooth("uckerbot-u4")
can = Can(32, 33, 1000000)
l0 = ODriveMotor(can, 0, 6)
r0 = ODriveMotor(can, 512, 6)
l1 = ODriveMotor(can, 256, 6)
r1 = ODriveMotor(can, 768, 6)
l0.m_per_tick = 0.05567092651757189
r0.m_per_tick = 0.05567092651757189
l1.m_per_tick = 0.05567092651757189
r1.m_per_tick = 0.05567092651757189
l0.reversed = false
r0.reversed = true
l1.reversed = false
r1.reversed = true
wheels = ODriveWheels(l0, r0)
wheels_front = ODriveWheels(l1, r1)
wheels.width = 0.47
wheels_front.width = 0.47
wheels.shadow(wheels_front)
serial = Serial(26, 27, 115200, 1)
p0 = Expander(serial, 25, 14)
y_axis_motor = StepperMotor(5, 4)
y_axis_alarm = Input(13)
y_axis_alarm.inverted = true
y_axis_end_l = p0.Input(21)
y_axis_end_l.inverted = true
y_axis_end_r = p0.Input(19)
y_axis_end_r.inverted = true
y_axis = MotorAxis(y_axis_motor, y_axis_end_r, y_axis_end_l)
tornado_motor_z = ODriveMotor(can, 1280, 6)
tornado_motor_turn = ODriveMotor(can, 1024, 6)
tornado_motor_z.m_per_tick = 0.0019968051118210866
tornado_motor_turn.m_per_tick = 0.07987220447284345
tornado_motor_z.limits(1.5, 30)
tornado_motor_turn.limits(1.3, 30)
tornado_motor_z.reversed = true
tornado_motor_turn.reversed = true
tornado_end_top = p0.Input(32)
tornado_end_top.inverted = true;
tornado_end_bottom = p0.Input(5)
tornado_end_bottom.inverted = true;
tornado_ref_motor = p0.Input(33)
tornado_ref_motor.inverted = true;
tornado_ref_gear = p0.Input(4)
tornado_ref_gear.inverted = false;
tornado_ref_knife_stop = p0.Input(35)
tornado_ref_knife_stop.inverted = false;
tornado_ref_knife_ground = p0.Input(18)
tornado_ref_knife_ground.inverted = true;
tornado_z = MotorAxis(tornado_motor_z, tornado_end_bottom, tornado_end_top)
bool tornado_is_referencing = false;
bool tornado_ref_motor_enabled = false;
bool tornado_ref_gear_enabled = false;
when tornado_ref_motor_enabled and tornado_is_referencing and tornado_ref_motor.level == 0 then
tornado_motor_turn.speed(0);
end
when tornado_ref_gear_enabled and tornado_is_referencing and tornado_ref_gear.level == 1 then
tornado_motor_turn.speed(0);
end
bool tornado_knife_ground_enabled = false;
bool tornado_knife_stop_enabled = false;
when tornado_knife_ground_enabled and tornado_ref_knife_ground.level == 1 then
tornado_motor_z.off();
end
when tornado_knife_stop_enabled and tornado_ref_knife_stop.level == 1 then
en3.off();
tornado_knife_stop_enabled = false;
end
flashlight = p0.PwmOutput(2)
flashlight.duty = 204
bms = p0.Serial(26, 27, 9600, 2)
bms.unmute()
estop_1 = Input(34)
estop_2 = Input(35)
battery_control_reset = p0.Output(15)
battery_control_status = p0.Input(13)
bumper_front_top = p0.Input(12)
bumper_front_bottom = p0.Input(22)
bumper_back = p0.Input(25)
rdyp_status = Input(39)
vdp_status = p0.Input(39)
let stop do wheels.speed(0, 0); y_axis.stop();tornado_z.stop();tornado_motor_turn.speed(0);end
when estop_1.level == 0 then stop(); end
when estop_2.level == 0 then stop(); end
when bumper_front_top.level == 1 or bumper_front_bottom.level == 1 or bumper_back.level == 1 then wheels.off(); end
when tornado_ref_knife_ground.active == false then wheels.speed(0, 0); y_axis.stop(); end
when core.last_message_age > 1000 then wheels.speed(0, 0); end
when core.last_message_age > 20000 then stop(); end
core.output("core.millis wheels.linear_speed:3 wheels.angular_speed:3 l0.motor_error_flag r0.motor_error_flag l1.motor_error_flag r1.motor_error_flag y_axis_end_l.active y_axis_end_r.active y_axis_motor.idle y_axis_motor.position y_axis_alarm.active tornado_end_top.active tornado_end_bottom.active tornado_ref_motor.active tornado_ref_gear.active tornado_ref_knife_stop.active tornado_ref_knife_ground.active tornado_motor_z.position:3 tornado_motor_turn.position:3 tornado_motor_z.motor_error_flag tornado_motor_turn.motor_error_flag estop_1.level estop_2.level battery_control_status.level bumper_front_top.level bumper_front_bottom.level bumper_back.level rdyp_status.level vdp_status.level core.heap")
rdyp.on()
en3.on() @JensOgorek and I found a startup that worksrdyp = Output(15)
en3 = Output(12)
bluetooth = Bluetooth("uckerbot-u4")
can = Can(32, 33, 1000000)
l0 = ODriveMotor(can, 0, 6)
r0 = ODriveMotor(can, 512, 6)
l1 = ODriveMotor(can, 256, 6)
r1 = ODriveMotor(can, 768, 6)
l0.m_per_tick = 0.05567092651757189
r0.m_per_tick = 0.05567092651757189
l1.m_per_tick = 0.05567092651757189
r1.m_per_tick = 0.05567092651757189
l0.reversed = false
r0.reversed = true
l1.reversed = false
r1.reversed = true
wheels = ODriveWheels(l0, r0)
wheels_front = ODriveWheels(l1, r1)
wheels.width = 0.47
wheels_front.width = 0.47
wheels.shadow(wheels_front)
serial = Serial(26, 27, 115200, 1)
p0 = Expander(serial, 25, 14)
y_axis_motor = StepperMotor(5, 4)
y_axis_alarm = Input(13)
y_axis_alarm.inverted = true
y_axis_end_l = p0.Input(21)
y_axis_end_l.inverted = true
y_axis_end_r = p0.Input(19)
y_axis_end_r.inverted = true
y_axis = MotorAxis(y_axis_motor, y_axis_end_r, y_axis_end_l)
tornado_motor_z = ODriveMotor(can, 1280, 6)
tornado_motor_turn = ODriveMotor(can, 1024, 6)
tornado_motor_z.m_per_tick = 0.0019968051118210866
tornado_motor_turn.m_per_tick = 0.07987220447284345
tornado_motor_z.limits(1.5, 30)
tornado_motor_turn.limits(1.3, 30)
tornado_motor_z.reversed = true
tornado_motor_turn.reversed = true
tornado_end_top = p0.Input(32)
tornado_end_top.inverted = true;
tornado_end_bottom = p0.Input(5)
tornado_end_bottom.inverted = true;
tornado_ref_motor = p0.Input(33)
tornado_ref_motor.inverted = true;
tornado_ref_gear = p0.Input(4)
tornado_ref_gear.inverted = false;
tornado_ref_knife_stop = p0.Input(35)
tornado_ref_knife_stop.inverted = false;
tornado_ref_knife_ground = p0.Input(18)
tornado_ref_knife_ground.inverted = true;
tornado_z = MotorAxis(tornado_motor_z, tornado_end_bottom, tornado_end_top)
bool tornado_is_referencing = false;
bool tornado_ref_motor_enabled = false;
bool tornado_ref_gear_enabled = false;
when tornado_ref_motor_enabled and tornado_is_referencing and tornado_ref_motor.level == 0 then
tornado_motor_turn.speed(0);
end
when tornado_ref_gear_enabled and tornado_is_referencing and tornado_ref_gear.level == 1 then
tornado_motor_turn.speed(0);
end
bool tornado_knife_ground_enabled = false;
bool tornado_knife_stop_enabled = false;
when tornado_knife_ground_enabled and tornado_ref_knife_ground.level == 1 then
tornado_motor_z.off();
end
when tornado_knife_stop_enabled and tornado_ref_knife_stop.level == 1 then
en3.off();
tornado_knife_stop_enabled = false;
end
flashlight = p0.PwmOutput(2)
flashlight.duty = 204
bms = p0.Serial(26, 27, 9600, 2)
bms.unmute()
estop_1 = Input(34)
estop_2 = Input(35)
battery_control_reset = p0.Output(15)
battery_control_status = p0.Input(13)
bumper_front_top = p0.Input(12)
bumper_front_bottom = p0.Input(22)
bumper_back = p0.Input(25)
rdyp_status = Input(39)
vdp_status = p0.Input(39)
let stop do wheels.speed(0, 0); y_axis.stop();tornado_z.stop();tornado_motor_turn.speed(0);end
when estop_1.level == 0 then stop(); end
when estop_2.level == 0 then stop(); end
when bumper_front_top.level == 1 or bumper_front_bottom.level == 1 or bumper_back.level == 1 then wheels.off(); end
when tornado_ref_knife_ground.active == false then wheels.speed(0, 0); y_axis.stop(); end
when core.last_message_age > 1000 then wheels.speed(0, 0); end
when core.last_message_age > 20000 then stop(); end
core.print("................................................................tornado_ref_motor.active")
core.output("core.millis tornado_ref_gear.active tornado_ref_knife_stop.active tornado_ref_knife_ground.active tornado_motor_z.position:3 tornado_motor_turn.position:3 tornado_motor_z.motor_error_flag tornado_motor_turn.motor_error_flag estop_1.level estop_2.level battery_control_status.level bumper_front_top.level bumper_front_bottom.level bumper_back.level rdyp_status.level vdp_status.level core.heap")
rdyp.on()
en3.on() but if one Point is added to the When the first startup is configured as the first startup after the new Lizard is flashed the startup will configure. But when the esp is enabled again(happens in |
When the ESP is configured before configuring the ESp with a the startup, follwing error will occure:
This makes it impossible to comunicate with the core. It can be fixed by eraesing the flash and reflashing the ESP. When the configuration is the first configured it works.
I tried configuring a empty configuration beforehand but it still didn't work.
The text was updated successfully, but these errors were encountered: