Quick-Event / quickbox

Quick Event - Orienteering Software
GNU General Public License v2.0
52 stars 41 forks source link

Print SIAC battery status on receipt #363

Open fvacek opened 5 years ago

fvacek commented 5 years ago

SI_cards_data_structure_developer.zip

according to this document, there are fields MVBAT, RBAT and LBAT in BLOCK_03, however functionality is not clear so far.

fvacek commented 2 years ago
02 E8 06 00 01 0F 81 F5 30 FC F7 03 /* E8 - SI-Card8/9/p/SIAC Detected */
02 EF 01 00 E2 09 03 /* EF - Get SI-Card data block 00 */
02 EF 83 00 01 00 ED FF 10 9E EA EA EA EA 0C 06 A7 D2 EE EE EE EE 8D 57 18 18 14 7D 15 60 0F 81 F5 30 08 13 09 20 4B 61 6D 69 6C 3B 50 69 70 65 6B 3B 4D 3B 31 39 37 33 30 38 33 31 3B 4F 4B 20 4C 6F 6B 6F 6D 6F 74 69 76 61 20 50 61 72 64 75 62 69 63 65 3B 6B 61 6D 69 6C 2E 70 69 70 65 6B 40 67 6D 61 69 6C 2E 63 6F 6D 3B 2B 34 32 30 36 30 35 32 30 35 35 32 32 3B 4C 61 7A 6E 65 20 42 6F 68 64 61 6E 65 15 8B 03 /* EF - SI-Card data block 0, if ((SI card ID > 8000000)&& (SI card ID < 9000000)) {SI card is SIAC} */
02 EA 05 7E 05 05 05 05 B2 31 03 /* EA - PROBABLY SIAC battery measurement request */
02 EA 03 00 01 7E F6 17 03 /* EA - PROBABLY the SIAC battery maeasurement response */
02 EF 01 03 E1 09 03 /* EF - Get SI-Card data block 03 */
02 EF 83 00 01 03 EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE EE 31 53 EE EE EE EE EE EE 10 07 03 84 0C 7C A8 0E 0C 03 A7 A0 13 08 10 01 01 06 04 03 02 20 00 0C 00 1A 00 00 30 00 05 4A 08 00 05 0A 06 AA 01 F6 EE EE EE EE 8D 57 18 18 CC AA CC CC AA AA CA CA AC CC CC CA CC CC AA AA 73 69 61 63 FF FF FF FF 03 84 00 7E 06 D1 00 00 22 D9 03 /*  EF - SI-Card data block 3, 1B at position 78 of data block (in this case 0x0C) is the BATT_VOLTAGE value, there is no separate checksum for that */

Real battery voltage calculation: 1.9 + (BATT_VOLTAGE * 0.09) /* 1.9V is offset and 0.09 V LSB */
BATT_VOLTAGE
0x06 ~ 2.44V /* ERROR - under this voltage SIAC does not work as contactless */
0x09 ~ 2.71V /* WARNING - under this voltageit it is time to think about battery exchange */
...
0x0B ~ 2.89V
0x0C ~ 2.98V
0x0D ~ 3.07V /* the value should not exceed this value */
paukert commented 2 years ago

Dear Sir or Madam,

I am writting to you due to problem which we faced during developing our open source application written in C++ for organizing orienteering events (https://github.com/Quick-Event/quickbox).

There is a future request to print SIAC battery status on receipts (https://github.com/Quick-Event/quickbox/issues/363), but we are not sure about SIAC data structure. I would be grateful if you could send me PC Programmer's Guide mentioned on your website or provide any additional information which could be helpful for our case.

I look forward to hearing from you.

Best regards

Lukáš Paukert

Dear Lukas,

Thank you for your request and your patience. We have not yet been able to offer you a solution because the topic of SIAC batteries is currently in a state of flux. You may be aware that the routine currently implemented in the battery test station does not sufficiently assess what is currently happening. I ask for a little more patience.

Best Regards,

Ute Schönfeld SPORTident Support

fvacek commented 1 year ago

https://github.com/Quick-Event/quickbox/issues/909#issuecomment-1540519595 should work according this