ICOc
Channel Selection
- ICOc now supports more sensor channels. You can now select one of up to 255 (instead of 8) hardware channels for each of the three measurement channels.
- The CLI interface now uses three options (`-1`, `-2`, `-3`), instead of one option (`-p`), to specify the channel number of each of the three measurement channels.
Logging
We replaced our custom logging class in the ICOc command line interface with logging code from the Python standard library. This logging code stores data in the following files:
- `cli.log`: Log messages of ICOc
- `network.log`: Log messages of CAN network class
- `plotter.log`: Log messages of plotter (window process)
By default ICOc only write log messages of level `ERROR` or higher into theses files. To print more detailed output you can use the option `--log` to change the log level. For example, to change the log level to `DEBUG` (or higher) you can use the the following command:
sh
icoc --log debug
The other parts of the code, which use the old `Network` class (e.g. the verification test) do not store the log output in files, but instead use the standard error output (`stdout`). This change should hopefully improve the visibility of important log messages.
Tests
- The production tests for the hardware (STH, SMH and STU) should now also work on macOS, after you installed the [PCBUSB](https://github.com/mac-can/PCBUSB-Library) library.
- The STH tests now use the correct ADC reference voltage for the ± 40 g acceleration sensor [ADXL356](https://www.analog.com/en/products/adxl356.html?doc=ADXL356-357.pdf).
Internal
Measurement
- Renamed the method `convert_voltage_adc_to_volts` to `convert_to_supply_voltage`
- The method `convert_to_supply_voltage` now supports different reference voltages
Network
- The methods to
- activate (`activate_acceleration_self_test`) and
- deactivate (`deactivate_acceleration_self_test`)
the self test of the accelerometer now have a parameter to specify the dimension (`x`, `y` or `z`) for the self test.
- The method to read the acceleration voltage (`read_acceleration_voltage`) now supports two additional parameters to
- specify the dimension (`x`, `y` or `z`) and
- the ADC reference voltage.
- The method to read the supply voltage (`read_supply_voltage`) now takes the current reference voltage into consideration
- The new method `read_sensor_configuration` can be used to read the current sensor configuration (i.e. the mapping from hardware/sensor channel to measurement channel).