MS12 -> MS14 MCI
High level (MSXII)
- The MCI is connected to both the main CAN bus and an isolated motor controller CAN bus which contains the two WaveSculptors and the MCI board.
- The MCI reads DRIVE_OUTPUT CAN messages from driver controls and caches the desired settings (pedal, direction, cruise, mech_brake). The settings are periodically transmitted to both WaveSculptors.
- The user manual can be found at WaveSculptor 22 Motor Drive User's Manual
DRIVE_OUTPUT message (MSXII)
- The DRIVE_OUTPUT message contains parameters, handled currently as:
- Pedal: the throttle value (can be for both accelerating and braking)
- Direction: Neutral, forward, or reverse
- Cruise: if 0 update speed; if > 0, get pedal value and set a target speed
- Mech_brake: force coast/neutral if mech_brake is on (0 throttle)
How it currently (MSXII) works (starting at main)
- Set settings
- motor_controller_init
- setup handlers for velocity and bus measurement readings from wavesculptor
- Init periodic transmission of controller settings
- Periodically (200 ms, motor_controller.h) send a CAN message to both wave sculptors with the current controller settings
- drive_can_init
- Set callback function pointers for speed and bus measurements
- Register a handler for receiving DRIVE_OUTPUT messages from driver controls
- set relay init settings (order, delays)
- Sequenced_relay_init (handled by relay sequencer)
- Precharge handled here by hardware
- register powertrain heartbeat handler
- Loop
- We currently listen for velocity and bus measurements (voltage, current) and transmits them back to driver controls
- We don’t currently send the reset message ever
- We don’t currently have any precharge checks, we just wait for it in the relay sequencer
Things we can send WaveSculptor (section 18 of manual)
- Motor Drive (required every 250 ms)
- Set motor current (%), motor velocity (rpm)
- Motor Power
- Set bus current (% of absolute bus current limit)
- “...setting it to less than 100%...may compromise your vehicle performance”
- Reset
- “Reset the software in the WaveSculptor”
Things we can listen for from WaveSculptor (section 18 of manual)
Note: any of these can be requested at any time with an immediate response (manual pg. 30)
- ID info (1 second)
- Serial number and identifier
- Status info (200 ms)
- Receive and transmit error count, active motor index, error flags, limit flags
- Bus measurement (200 ms)
- Bus current and voltage
- Velocity measurement (200 ms)
- Vehicle velocity (m/s) and motor velocity (rpm)
- Phase current measurement (200 ms)
- Motor voltage vector measurement (200 ms)
- Motor current vector measurement (200 ms)
- Motor BackEMF measurement / prediction (200 ms)
- 15V voltage rail measurement (1 second)
- 3.3V and 1.9V voltage rail measurements
- Heat-sink and motor temperature measurement (1 second)
- DSP board temperature measurement (1 second)
- Odometer and Bus AmpHours measurement (1 second)
Faults
18.4.2 in manual