Created
July 8, 2020 10:36
-
-
Save agent3bood/63357a79c733014adf3c862c1d27513e to your computer and use it in GitHub Desktop.
example logger
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import 'dart:convert'; | |
| import 'dart:typed_data'; | |
| void main() { | |
| Map<String, dynamic> outMap = { | |
| 'wheelSpeed': 3, | |
| 'tempFet': 4.4, | |
| 'tempMotor': 5.5, | |
| 'motorCurr': 6.6, | |
| 'inputCurr': 7, | |
| 'tachometer': 8, | |
| 'faultCode': 9, | |
| 'K_assist': 31.0, | |
| 'min_driving_torque': 32.32, | |
| 'max_chain_tension_curr': 33, | |
| 'version': 19, | |
| }; | |
| String outStr = jsonEncode(outMap); | |
| print(outStr); | |
| List<int> outUnit8 = outStr.codeUnits; | |
| print(outUnit8); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment