can_api

1.13.10 • Public • Published

First Use Need

(Install serialport first and version must be the same with can_api)

  1. npm install --save-dev electron-rebuild

  2. sudo npm install serialport@(version) --unsafe-perm --build-from-source

  3. ("rebuild": "electron-rebuild -f -w serialport") in package.json => scripts

  4. create vue.config.js in package

  5. write code in vue.config.js const { IgnorePlugin } = require('webpack')

    module.exports = { pluginOptions: { moment: { locales: ['cn'] }, electronBuilder: { // experimentalNativeDepCheck: true, nodeIntegration: true, // List native deps here if they don't work externals: ['serialport'] } } }

  6. in background.js before createView write this code app.allowRendererProcessReuse = false

  7. in background.js createView write this code const win = new BrowserWindow({ width: 1280, height: 720, webPreferences: { nodeIntegration: true, contextIsolation: false } })

  8. npm install

  9. use this code to check is install success import SerialPort from 'serialport'

    SerialPort.list().then(function(ports){ console.log(ports) })

Getting Started

(please check node.js and serialport version is same)

  1. npm install can_api
  2. Example:
import { pool } from "can_api"
var portList = pool.getPortList();
pool.connectSeriPort(
        portList[0]
        , function(arr){
            //connect
            if(arr['connect']){

                //receiver all data
                pool.setDataListener(function(output){
                    console.log(output);
                });

                //get hmi version. No.19~No.118 function like this
                pool.getHmiVer(function(output:){
                    console.log(output);

                    //觸發斷線
                    pool.disconnected();
                    //取消listener
                    pool.clearDataListener()();
                })
            }else{
                //connect fail
            }
        }
        , function(){
            //disconnect
        }
    );

Tools

  1. setMaxListeners(n) 設定 event Linstener 數量,預設10個 n:數量
    pool.setMaxListeners(20);
    
  2. setIsDebug(isDebug) 自動回覆模擬cmd, 預設關閉 isDebug: true:啟動, false:關閉
    pool.setIsDebug(true);
    
  3. getWalkAssist() 取得 Walk Assist List [ { 'id': 0 , 'name': 'Inactivated' } , { 'id': 1 , 'name': 'Activated' } ]
    var list = pool.getWalkAssist();
    
  4. getWritUnit() 取得 Writ Unit List [ { 'id': 0 , 'name': 'km' } , { 'id': 1 , 'name': 'mile' } ]
    var list = pool.getWritUnit();
    
  5. clearData() 清除收集數據
    pool.clearData();
    
  6. setNoShowArr(arr) 設定特殊處理ID列表 arr: ['123', '456', '789']
    pool.setNoShowArr(['123', '345']);
    
  7. setNoShowFilter(type) 設定特殊處理類別 type: 0:not select, 1:accept, 2:denied
    pool.setNoShowFilter(0);
    
  8. getSettings() 取得目前設定清單
    output: { autoOpen: autoOpen , baudRate: baudRate , dataBits: dataBits , stopBits: stopBits , parity: parity , rtscts: rtscts , xon: xon , xoff: xoff , xany: xany , lock: lock , highWaterMark: highWaterMark }
    var settings = pool.getSettings();
    
  9. setSettings(arr) 設定port arr: { autoOpen: autoOpen , baudRate: baudRate , dataBits: dataBits , stopBits: stopBits , parity: parity , rtscts: rtscts , xon: xon , xoff: xoff , xany: xany , lock: lock , highWaterMark: highWaterMark }
    pool.setSettings({
            autoOpen: autoOpen
            , baudRate: baudRate
            , dataBits: dataBits
            , stopBits: stopBits
            , parity: parity
            , rtscts: rtscts
            , xon: xon
            , xoff: xoff
            , xany: xany
            , lock: lock
            , highWaterMark: highWaterMark
        });
    
  10. getAllSetList() 取得全部設定列表
    output: { 'baudRate': baudRateList , 'dataBits': dataBitsList , 'stopBits': stopBitsList , 'parity': parityList , 'rtscts': rtsctsList , 'xon': xonList , 'xoff': xoffList , 'xany': xanyList , 'lock': lockList , 'highWaterMark': highWaterMarkList , 'autoOpen': autoOpenList }
    var list = pool.getAllSetList();
    
  11. getPortList() 取得目前port清單
    output: [ { path: '/dev/tty.usbmodem1421', manufacturer: 'Arduino (www.arduino.cc)', serialNumber: '752303138333518011C1', pnpId: undefined, locationId: '14500000', productId: '0043', vendorId: '2341' } ]
    var list = pool.getPortList();
    
  12. connectSeriPort(port, connectCallBack, disconnectCallBack) 連線指定port port: { path: '/dev/tty.usbmodem1421', manufacturer: 'Arduino (www.arduino.cc)', serialNumber: '752303138333518011C1', pnpId: undefined, locationId: '14500000', productId: '0043', vendorId: '2341' } connectCallBack: 連線狀態回復 { "connect": false } disconnectCallBack: 斷線狀態回復
    pool.connectSeriPort(
        portList[0]
        , function(arr){
            //connect
            if(arr['connect']){
    
            }else{
                //connect fail
            }
        }
        , function(){
            //disconnect
        }
    );
    
  13. disconnected() 手動出發斷線
    pool.disconnected();
    
  14. setSizeListener(outCallback, writeCallback) 取得cmd數量 outCallback(size): 取得 receiver cmd 數量 writeCallback(size): 取得 write cmd 數量
    pool.setSizeListener(
        function(size){
            console.log(size);
        },
        function(size){
            console.log(size);
        }
    )
    
  15. clearSizeListener() 清除Size Listener
    pool.clearSizeListener();
    
  16. setDataListener(callback(output)) 取得全部 receiver write cmd output: { 'directionStatus': 0(Read), 1(Write) , 'time': 取得時間 , 'type': 0(Data), 1(Remote) , 'format': 0(standard), 1(extend) , 'id': Send id , 'length': cmd length , 'data': cmd data }
    pool.setDataListener(
        function(output){
            console.log(output);
        }
    );
    
  17. clearDataListener() 清除 data Listener
    pool.clearDataListener();
    
  18. write(arr) 發送命令 arr:{ "id": "123" "type": 0(Data), 1(Remote) "format": 0(standard), 1(extend) "data": "12 34 56 78" }
    pool.write({
        "id": "123"
        "type": 0(Data), 1(Remote)
        "format": 0(standard), 1(extend)
        "data": "12 34 56 78"
    });
    
  19. getHmiVer(callback(output:)) 取得 Hmi version
    output:: {"status":true,"data":{"fwVer":"01.23","hwVer":"4.AB","brand":"C"}}
  20. getHmiSerial(callback(output:)) 取得 Hmi Serial
    output: {"status":true,"data":{"serial":305419896,"serial_hex":"12345678","manu":255,"manu_hex":"ff","date":"2021/12/2"}}
  21. getDriverVer(callback(output)) 取得 driver version
    output: {"status":true,"data":{"hw_type":"01","fw_ver":"23.4A","client":"B","model":"C"}}
  22. getDriverSerial1(callback(output)) 取得 driver serial 1
    output: {"status":true,"data":{"serial":"01234567"}}
  23. getDriverSerial2(callback(output)) 取得 driver serial 2
    output: {"status":true,"data":{"serial":"ABCDEFGH"}}
  24. getDriverProd(callback(output)) 取得 driver prod
    output: {"status":true,"data":{"manu":90,"manu_hex":"5a","date":"2021/12/02"}}
  25. getBmsFwVer(callback(output)) 取得 Bms Fw Version
    output: {"status":true,"data":{"fw_ver":"01.23","debug_serial":"45","client_number":"6","brand":"7"}}
  26. getBmsHwVer(callback(output)) 取得 Bms Hw Version
    output: {"status":true,"data":{"hw_ver":"48.49","fw_ver":"50.51","pn":875902519,"pn_16":"34353637"}}
  27. getBmsProd(callback(output)) 取得 Bms Prod
    output: {"status":true,"data":{"serial":"30313233","manu":52,"manu_hex":"34","date":"2021-12-2"}}
  28. getDriverNumberAssist(callback(output)) 取得 driver number of assist
    output: {"status":true,"data":{"numberOfAssist":3}}
  29. writeDriverNumberOfAssist(value) 寫入 driver number of assist value: number of assist
  30. getDriverWheelDiameter(callback(output)) 取得 driver wheel diameter
    output: {"status":true,"data":{"wheel_diameter":2854}}
  31. writeDriverWheelDiameter(value) 寫入 driver wheelDiameter value: wheelDiameter
  32. getDriverSpeed(callback(output)) 取得 driver speed
    output: {"status":true,"data":{"speed":450}}
  33. writeDriverSpeed(value) 寫入 driver speed value: speed
  34. getDriverCurrent(callback(output)) 取得 driver current
    output: {"status":true,"data":{"input_current":15000,"phase_current":25000}}
  35. writeDriverCurrent(input, phase) 寫入 driver current input: Input current limit phase: Phase current limit
  36. getDriverOverVoltage(callback(output)) 取得 driver over voltage
    output: {"status":true,"data":{"over_voltage":52000,"voltage_recovery":51000}}
  37. writeDriverOverVoltage(voltage, recovery) 寫入 driver over voltage voltage: DC bus over voltage recovery: Over voltage recovery
  38. getDriverUnderVoltage(callback(output)) 取得 driver under voltage
    output: {"status":true,"data":{"over_voltage":42000,"voltage_recovery":43000,"delay_time":1000}}
  39. writeDriverUnderVoltage(voltage, recovery, delayTime) 寫入 driver under voltage voltage: DC bus under voltage recovery: under voltage recovery delayTime: Under voltage delay time
  40. getDriverDivisor(callback(output)) 取得 driver divisor
    output: {"status":true,"data":{"divisor":13330,"holding_time":30806,"switch_time":22291}}
  41. writeDriverDivisor(divisor, holding_time, switch_time) 寫入 driver divisor divisor: Fade out divisor holding_time: Fade holding time switch_time: Fade out switch time limit
  42. getDriverOverTemp(callback(output)) 取得 driver over temp
    output: {"status":true,"data":{"motor_temp":48,"motor_derating_temp":49,"motor_derating_percentage":50,"controller_temp":51,"controller_derating_temp":52,"controller_derating_percentage":53}}
  43. writeMotorTemp(motor_temp, motor_derating_temp, motor_derating_percentage) 寫入 motor temp motor_temp: Motor over temperature limit motor_derating_temp: Motor derating temperature motor_derating_percentage: Motor derating percentage
  44. writeControllerTemp(controller_temp, controller_derating_temp, controller_derating_percentage) 寫入 controller temp controller_temp: Controller over temperature limit controller_derating_temp: Controller derating temperature controller_derating_percentage: Controller derating percentage
  45. getDriverTS(callback(output)) 取得 driver ts
    output: {"status":true,"data":{"ts_over":2000,"ts_under":800,"ts_offset":400,"ts_effective":3000}}
  46. getDriverTS2() 取得 driver ts 2
    output: {"status":true,"data":{"ts_adc_value":1024,"ts_effective_value":2048,"ts_percentage":48,"ts_radio":96,"ts_rpm":80}}
  47. writeTSOver(ts_over, ts_under) 寫入 ts over ts_over: TS over limit ts_under: TS under limit
  48. writeTSOffset(ts_offset, ts_effective, ts_radio) 寫入 ts offset ts_offset: TS offset ts_effective: TS effective range ts_radio: TS ratio
  49. getDriverTorqueTune(callback(output)) 取得 driver torque tune
    output: {"status":true,"data":{"tune_pont1":16,"tune_pont2":32,"tune_area0":48,"tune_area1":64,"tune_area2":80}}
  50. writeTorquePoint(tune_pont1, tune_pont2) 寫入 torque point tune_point1: Torque tune point 1 tune_point2: Torque tune point 2
  51. writeTorqueArea(tune_area0, tune_area1, tune_area2) 寫入 torque area tune_area0: Torque tune area 0 tune_area1: Torque tune area 1 tune_area2: Torque tune area 2
  52. getDriverTorqueInputTime(callback(output)) 取得 driver torque input time
    output: {"status":true,"data":{"delay_time":500}}
  53. writeTorqueInputTime(delay_time) 寫入 torque input time delay_time: Torque input delay time
  54. getDriverTorqueModel1(callback(output)) 取得 driver torque mode 1
    output: {"status":true,"data":{"point1":17,"point2":33,"radio1":3,"radio2":4,"radio3":5}}
  55. getDriverTorqueModel2(callback(output)) 取得 driver torque mode 2
    output: {"status":true,"data":{"point1":17,"point2":33,"radio1":3,"radio2":4,"radio3":5}}
  56. getDriverTorqueModel3(callback(output)) 取得 driver torque mode 3
    output: {"status":true,"data":{"point1":17,"point2":33,"radio1":3,"radio2":4,"radio3":5}}
  57. getDriverTorqueModel4(callback(output)) 取得 driver torque mode 4
    output: {"status":true,"data":{"point1":17,"point2":33,"radio1":3,"radio2":4,"radio3":5}}
  58. getDriverTorqueModel5(callback(output)) 取得 driver torque mode 5
    output: {"status":true,"data":{"point1":17,"point2":33,"radio1":3,"radio2":4,"radio3":5}}
  59. writeTorqueModel(choose, point1, point2, radio1, radio2, radio3) 寫入 torque model choose: Basic mode choose point1: Basic mode n point 1 pount2: Basic mode n point 2 radio1: Basic mode n point 3 radio2: Basic mode n point 4 radio3: Basic mode n point 5
  60. getDriverStatusMotorTemp(callback(output)) 取得 driver status motor temp
    output: {"status":true,"data":{"actual_motor_temp":-10,"actual_mosfet_temp_u":16,"actual_mosfet_temp_v":32,"actual_mosfet_temp_w":48}}
  61. getDriverStatusMcuTemp(callback(output)) 取得 driver status mcu temp
    output: {"status":true,"data":{"actual_mcu_temp":-20}}
  62. getDriverStatusInputVoltage(callback(output)) 取得 driver status input voltage
    output: {"status":true,"data":{"actual_controller_input_voltage":48000,"actual_mcu_input_controller":15000,"human_power_output:":48,"crank_rpm":64,"human_torque":16}}
  63. getDriverStatusRemainingDistance(callback(output)) 取得 driver status remaining distance
    output: {"status":true,"data":{"remaining_distance":3000,"remaining_time":40000}}
  64. getDriverStatusMotorTorqueOutput:(callback(output)) 取得 driver status motor torque output:
    output: "status":true,"data":{"motor_torque_output:":40,"motor_rpm":300,"motor_power_percentage":48,"motor_power_output:":750}}
  65. getDriverStatusTSValue(callback(output)) 取得 driver status ts value
    output: {"status":true,"data":{"ts_adc_value":1024,"ts_effective_value":2048,"ts_percentage":48,"ts_radio":96,"ts_rpm":80}}
  66. getDriverStatusTSHi(callback(output))
    取得 driver status ts hi

    output: {"status":true,"data":{"ts_hi_point":2048,"ts_low_point":1024}}
  67. getBMSStateOfHealth(callback(output)) 取得 bms state of health
    output: {"status":true,"data":{"state_of_health":100,"min":36,"hour":15,"day":31,"month":12,"year":2020}}
  68. getBMSTotalDischargeCapacity(callback(output)) 取得 bms total discharge capacity
    output: {"status":true,"data":{"total_discharge_capacity":13400,"cycle_count":300,"full_chagrged_capacity":13400}}
  69. getBMSUnderVoltageLimit(callback(output)) 取得 bms under voltage limit
    output: {"status":true,"data":{"total_discharge_capacity":13400,"cycle_count":300,"full_chagrged_capacity":13400}}
  70. getBMSIdleCurrentLimit(callback(output)) 取得 bms idle current limit
    output: {"status":true,"data":{"idel_current_limit":160,"idel_timeout":1024000}}
  71. getBMSRestMah(callback(output)) 取得 bms rest mah
    output: {"status":true,"data":{"rest_mah":100000}}
  72. getBMSDischargeCurrentCounter(callback(output)) 取得 bms discharge current counter
    output: {"status":true,"data":{"discharge_current_count":4,"charge_current_count":8,"discharge_temp_count":16,"charge_temp_count":1024}}
  73. getBMSShortCircuitCounter(callback(output)) 取得 bms short circuit counter
    output: {"status":true,"data":{"short_curcuit_count":2048,"regeneration_error_count":4096,"over_voltage_count":8192}}
  74. getBMSMaxDischargeCurrent(callback(output)) 取得 bms max discharge current
    output: {"status":true,"data":{"max_discharge_current":15000,"max_charge_current":3000,"max_voltage":52000,"max_discharge_temp":-10,"max_charge_temp":40}}
  75. getBMSCellVoltage1(callback(output)) 取得 bms cell voltage 1-4
    output: {"status":true,"data":{"cell_voltage_1":48000,"cell_voltage_2":48001,"cell_voltage_3":48002,"cell_voltage_4":48003}}
  76. getBMSCellVoltage2(callback(output)) 取得 bms cell voltage 5-8
    output: {"status":true,"data":{"cell_voltage_5":48004,"cell_voltage_6":48005,"cell_voltage_7":48006,"cell_voltage_8":48007}}
  77. getBMSCellVoltage3(callback(output)) 取得 bms cell voltage 9-12
    output: {"status":true,"data":{"cell_voltage_9":48008,"cell_voltage_10":48009,"cell_voltage_11":48010,"cell_voltage_12":48011}}
  78. getBMSCellVoltage4(callback(output)) 取得 bms cell voltage 13
    output: {"status":true,"data":{"cell_voltage_13":48012}}
  79. writeBmsClearError() 寫入 bms clear error
  80. writeBmsClearMax 寫入 bms clear max
  81. getMCPeriodicalFrame(callback(output)) 取得 mc periodical frame
    output: {"status":true,"data":{"speed":6.4,"trip":300,"odo":400,"current_mode_level":4,"lock":"1","brake":"1","light":"1","error":"1","unit_mile":"1","derating":"1","walking":"1"}}
  82. clearMCPeriodicalFrame() 清除 mac periodical frame listener
  83. writeMCClearTrip() 寫入 mc clear trip
  84. writeMCWritUnit(data) 寫入 mc writ unit data: WritUnitList data
  85. writeMCAssistLevel(level) 寫入 mc assist level level: level 0-8
  86. writeMCWalkAssist(data) 寫入 mc walk assist data: WalkAssistList data
  87. getBMSPeriodicalFrame(callback(output)) 取得 bms periodical frame
    output: {"status":true,"data":{"total_battery_voltage":48000,"charge_discharge_current":-200,"discharge":"1","dcmos_on":"1","have_error":"0","cell_temp":-10,"state_of_charge":100}}
  88. clearBMSPeriodicalFrame() 清除 bms periodical frame listener
  89. getBMSEXPeriodicalFrame(callback(output)) 取得 bms-ex periodical frame
    output: {"status":true,"data":{"total_battery_voltage":48001,"charge_discharge_current":-200.1,"discharge":"0","dcmos_on":"1","have_error":"1","cell_temp":-11,"state_of_charge":99.5}}
  90. clearBMSEXPeriodicalFrame() 清除 bms-ex periodical frame listener
  91. getBMSEXVersion(callback(output)) 取得 bms-ex version
    output: {"status":true,"data":{"main_ver":"01","sec_ver":"23","debug_serial":"45","client_number":"6","brand":"7"}}
  92. getBMSEXDPVersion(callback(output)) 取得 bms-ex dp version
    output: {"status":true,"data":{"hw_reversion":48,"hw_version":49,"fw_reversion":50,"fw_version":51,"pn":875902519,"pn_hex":"34353637"}}
  93. getBMSEXSerialProd(callback(output)) 取得 bms-ex serial prod
    output: {"status":true,"data":{"serial_number":"30313233","code":52,"code_hex":"34","day":2,"month":12,"year":2021}}
  94. getBMSEXStateOfHealth(callback(output)) 取得 bms-ex state of health
    output: {"status":true,"data":{"state_of_health":100,"min":36,"hour":15,"day":31,"month":12,"year":2020}}
  95. getBMSEXDischargeCapacity(callback(output)) 取得 bms-ex discharge capacity
    output: {"status":true,"data":{"total_discharge_capacity":13400,"cycle_count":300,"full_chagrged_capacity":13400}}
  96. getBMSEXUnderVoltage(callback(output)) 取得 bms-ex under voltage
    output: {"status":true,"data":{"under_voltage_limit":42000,"under_voltage_delay_time":1000,"under_voltage_recovery_limit":43000}}
  97. getBMSEXIdleCurrent(callback(output)) 取得 bms-ex idle current
    output: {"status":true,"data":{"idle_current_limit":160,"idle_timeout":1024000}}
  98. getBMSEXRestMah(callback(output)) 取得 bms-ex rest mah
    output: {"status":true,"data":{"idle_current_limit":160,"idle_timeout":1024000}}
  99. getBMSEXDischargeCurrentCounter(callback(output)) 取得 bms-ex discharge current counter
    output: {"status":true,"data":{"discharge_current_count":4,"charge_current_count":8,"discharge_temp_count":16,"charge_temp_count":1024}}
  100. getBMSEXShortCircuitCounter(callback(output)) 取得 bms-ex short circuit counter
    output: {"status":true,"data":{"short_curcuit_count":2048,"regeneration_error_count":4096,"over_voltage_count":8192}}
  101. getBMSEXMaxDischargeCurrent(callback(output)) 取得 bms-ex max discharge current
    output: {"status":true,"data":{"max_discharge_current":15000,"max_charge_current":3000,"max_voltage":52000,"max_discharge_temp":-10,"max_charge_temp":40}}
  102. getBMSEXCellVoltage1(callback(output)) 取得 bms-ex cellVoltage 1-4
    output: {"status":true,"data":{"cell_voltage_1":48000,"cell_voltage_2":48001,"cell_voltage_3":48002,"cell_voltage_4":48003}}
  103. getBMSEXCellVoltage2(callback(output)) 取得 bms-ex cellVoltage 5-8
    output: {"status":true,"data":{"cell_voltage_5":48004,"cell_voltage_6":48005,"cell_voltage_7":48006,"cell_voltage_8":48007}}
  104. getBMSEXCellVoltage3(callback(output)) 取得 bms-ex cellVoltage 9-12
    output: {"status":true,"data":{"cell_voltage_9":48008,"cell_voltage_10":48009,"cell_voltage_11":48010,"cell_voltage_12":48011}}
  105. getBMSEXCellVoltage4(callback(output)) 取得 bms-ex cellVoltage 13
    output: {"status":true,"data":{"cell_voltage_13":48012}}
  106. writeBmsEXClearError() 寫入 bms-ex clear error
  107. writeBmsEXClearMax() 寫入 bms-ex clear max
  108. getHmiPeriodicalFrame(callback(output)) 取得 hmi periodical frame
    output: {"status":true,"data":{"mode":0,"error_status":1}}
  109. clearHmiPeriodicalFrame() 清除 hmi periodical frame listener
  110. getBmsWarningAlarm(callback(output)) 取得 bms warning alarm
    output: {"status":true,"data":[{"dateTime":"2021-12-14 07:23:01","error_code":"UT"},{"dateTime":"2021-12-14 07:23:01","error_code":"OT"},{"dateTime":"2021-12-14 07:23:01","error_code":"OCC"},{"dateTime":"2021-12-14 07:23:01","error_code":"UV"},{"dateTime":"2021-12-14 07:23:01","error_code":"OV"},{"dateTime":"2021-12-14 07:23:01","error_code":"DSC"},{"dateTime":"2021-12-14 07:23:01","error_code":"ODC"},{"dateTime":"2021-12-14 07:23:01","error_code":"COUT"}]}
  111. clearHmiPeriodicalFrame() 清除 hmi periodical frame listener
  112. getBmsEXWarningAlarm(callback(output)) 取得 bms-ex warning alarm
    output: {"status":true,"data":[{"dateTime":"2021-12-14 07:24:33","error_code":"UT"},{"dateTime":"2021-12-14 07:24:33","error_code":"OT"},{"dateTime":"2021-12-14 07:24:33","error_code":"OCC"},{"dateTime":"2021-12-14 07:24:33","error_code":"UV"},{"dateTime":"2021-12-14 07:24:33","error_code":"OV"},{"dateTime":"2021-12-14 07:24:33","error_code":"DSC"},{"dateTime":"2021-12-14 07:24:33","error_code":"ODC"},{"dateTime":"2021-12-14 07:24:33","error_code":"COUT"}]}
  113. clearBmsEXWarningAlarmListener() 清除 bms-ex warning alarm
  114. getMcWarningAlarm(callback(output)) 取得 mc warning alarm
    output: {"status":true,"data":[{"dateTime":"2021-12-14 07:25:40","error_code":"Torque Over Limit"},{"dateTime":"2021-12-14 07:25:40","error_code":"Hall Sensor"},{"dateTime":"2021-12-14 07:25:40","error_code":"Bettery Over Voltage"},{"dateTime":"2021-12-14 07:25:40","error_code":"DRV Over Phase Current"},{"dateTime":"2021-12-14 07:25:40","error_code":"Battery Over Current"},{"dateTime":"2021-12-14 07:25:40","error_code":"Turn On While Drive"},{"dateTime":"2021-12-14 07:25:40","error_code":"Battery Under Voltage"},{"dateTime":"2021-12-14 07:25:40","error_code":"Motor Over Temperature"},{"dateTime":"2021-12-14 07:25:40","error_code":"MOSFET Over Temprature"},{"dateTime":"2021-12-14 07:25:40","error_code":"Throttle Under Limit"},{"dateTime":"2021-12-14 07:25:40","error_code":"Throttle Over Limit"},{"dateTime":"2021-12-14 07:25:40","error_code":"Torque Under Limit"},{"dateTime":"2021-12-14 07:25:40","error_code":"EEPROM Error"},{"dateTime":"2021-12-14 07:25:40","error_code":"Constant Voltage Error"},{"dateTime":"2021-12-14 07:25:40","error_code":"HC Time"},{"dateTime":"2021-12-14 07:25:40","error_code":"Bettery SOC Full"},{"dateTime":"2021-12-14 07:25:40","error_code":"Found BMS"},{"dateTime":"2021-12-14 07:25:40","error_code":"BMS Time Out"},{"dateTime":"2021-12-14 07:25:40","error_code":"Crank Over Speed"},{"dateTime":"2021-12-14 07:25:40","error_code":"Update FW Error"}]}
  115. clearMcWarningAlarmListener() 清除 mc warning alarm listener
  116. writeMcShutdown() 寫入 mc shutdown
  117. writeBmsEnterSpecialMode(type) 寫入 bms enter special mode type: 'SHIP', 'BPIN', 'BPOU'
  118. writeMcHeadLight(flag, reserved) 寫入 mc head light flag: 0: Inactivated/1: Activated reserved:

Readme

Keywords

none

Package Sidebar

Install

npm i can_api

Weekly Downloads

15

Version

1.13.10

License

ISC

Unpacked Size

911 kB

Total Files

35

Last publish

Collaborators

  • bep.mis