Odrive S1 configuration error: struct size prolem

I am trying to configure a odrive s1 over can from a raspberry pi using the can_restore.py file, I am using firmware version 6.11, but when it tries to write and verify i get the error:
opening CAN bus…
/home/dev/ODrive_config/ODriveResources/examples/can_restore_config.py:114: DeprecationWarning: The ‘bustype’ argument is deprecated since python-can v4.2.0, and scheduled for removal in python-can v5.0.0. Use ‘interface’ instead.
with can.interface.Bus(args.channel, bustype=args.interface, bitrate=args.bitrate) as bus:
checking version…
writing 36 variables…
config.dc_bus_overvoltage_trip_level = 50
Traceback (most recent call last):
File “/home/dev/ODrive_config/ODriveResources/examples/can_restore_config.py”, line 131, in
asyncio.run(main())
File “/usr/lib/python3.10/asyncio/runners.py”, line 44, in run
return loop.run_until_complete(main)
File “/usr/lib/python3.10/asyncio/base_events.py”, line 649, in run_until_complete
return future.result()
File “/home/dev/ODrive_config/ODriveResources/examples/can_restore_config.py”, line 122, in main
await restore_config(odrv, config_list)
File “/home/dev/ODrive_config/ODriveResources/examples/can_restore_config.py”, line 94, in restore_config
await odrv.write_and_verify(k, v)
File “/home/dev/ODrive_config/ODriveResources/examples/can_restore_config.py”, line 83, in write_and_verify
_, _, _, return_value = struct.unpack_from(‘<BHB’ + endpoint_fmt, msg.data)
struct.error: unpack_from requires a buffer of at least 8 bytes for unpacking 8 bytes at offset 0 (actual buffer size is 4)

I am using this config file:
{
“config.dc_bus_overvoltage_trip_level”: 50,
“config.dc_bus_undervoltage_trip_level”: 10.5,
“config.dc_max_positive_current”: 6,
“config.dc_max_negative_current”: -3,
“config.brake_resistor0.enable”: false,
“axis0.config.motor.motor_type”: 0,
“axis0.config.motor.pole_pairs”: 5,
“axis0.config.motor.torque_constant”: 0.07552511415525114,
“axis0.config.motor.current_soft_max”: 10,
“axis0.config.motor.current_hard_max”: 23,
“axis0.config.motor.calibration_current”: 10,
“axis0.config.motor.resistance_calib_max_voltage”: 3,
“axis0.config.calibration_lockin.current”: 10,
“axis0.motor.motor_thermistor.config.enabled” : false,
“axis0.controller.config.control_mode”: 2,
“axis0.controller.config.input_mode”: 1,
“axis0.controller.config.vel_limit”: 45,
“axis0.controller.config.vel_limit_tolerance” : 1.1111111111111112,
“axis0.config.torque_soft_min”: -0.345,
“axis0.config.torque_soft_max”: 0.345,
“can.config.protocol”: 1,
“can.config.baud_rate”: 250000,
“axis0.config.can.node_id”: 2,
“axis0.config.can.heartbeat_msg_rate_ms”: 1000,
“axis0.config.can.encoder_msg_rate_ms”: 0,
“axis0.config.can.iq_msg_rate_ms”: 0,
“axis0.config.can.torques_msg_rate_ms”: 0,
“axis0.config.can.error_msg_rate_ms”: 0,
“axis0.config.can.temperature_msg_rate_ms”: 0,
“axis0.config.can.bus_voltage_msg_rate_ms”: 0,
“axis0.config.enable_watchdog”: false,
“axis0.config.encoder_bandwidth”: 100,
“hall_encoder0.config.enabled”: true,
“axis0.config.load_encoder”: 8,
“axis0.config.commutation_encoder”: 8,
“config.enable_uart_a” : false
}

Can you show the whole command you’re using to run can_restore_config.py? Have you verified you’re using the correct flat_endpoints.json file?

I am using the command python3 can_restore_config.py --interface socketcan --channel can0 --node-id 2 --endpoints-json flat_endpoints_6_11.json --config config_s1_2.json --save-config, where flat_end_points_6_11.json is the flat_end_points.json file for firmware version 6.11 downloaded from: ODrive Releases and config_s1_2.json is the config file for the odrive s1, which is based on the one from the odrive GUI.