Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] M-2000C: PCN outputs not working #717

Closed
charliefoxtwo opened this issue Jun 26, 2024 · 3 comments
Closed

[BUG] M-2000C: PCN outputs not working #717

charliefoxtwo opened this issue Jun 26, 2024 · 3 comments
Assignees
Labels
bug A bug affecting dcs-bios help wanted

Comments

@charliefoxtwo
Copy link
Member

Seems like device 10 was modified at some point

@charliefoxtwo charliefoxtwo added the bug A bug affecting dcs-bios label Jun 26, 2024
@charliefoxtwo charliefoxtwo self-assigned this Jun 26, 2024
@charliefoxtwo
Copy link
Member Author

charliefoxtwo commented Jun 27, 2024

Both devices 9 and 10 were modified in 2.9.2.49940, and I'm a bit stumped as to how they're encoding data now. e.g. for 42.54.5 we used to be able to read a variable that had the value 42545. Now we get this:

PCN_UL_SEG0:  i   
PCN_UL_SEG1: j jjb
PCN_UL_SEG2:  kk k
PCN_UL_SEG3: ld l 
PCN_UL_SEG4: m mmm
PCN_UL_SEG5:  nn n
PCN_UL_SEG6: goooo
PCN_UL_SEG7:   p p 

@charliefoxtwo
Copy link
Member Author

Upon further investigation, it seems each SEG# corresponds to a segment on a 7-segment display (0-6, +7 for the decimal).

Lowercase letters map left-to-right, top-to-bottom on the image below.
image

this maps roughly like so (with the top row being a-h and the bottom row being q-x)

 k     2
j l   1 3
 o     6 
i m   0 4
pn    75

It appears different characters are used for different brightness levels. This would be fine, however it also appears sometimes segments are intentionally missing from the display. In these cases, it could be virtually impossible to use any heuristic to determine what number something should be (e.g. consider a 9, which may be a 9 or may also be an 8 missing the 0/i bar).

charliefoxtwo added a commit to charliefoxtwo/dcs-bios that referenced this issue Jun 29, 2024
github-merge-queue bot pushed a commit that referenced this issue Jun 29, 2024
* M-2000C: Add alternate PCN output

#717

* Fix swapped brightness values

* Fix missing decimals in top displays

* Right-align pcn segments

* Fix decimals in wrong position
@charliefoxtwo
Copy link
Member Author

Individual segments of the PCN displays are now exported - this is the only data we get from the module. As mentioned in the PR:

Output values are 0-3 depending on brightness.

Digits are left to right.

Output segment indices follow this chart (7 is the decimal, which is on the left):

 2
1 3
 6
0 4
75

The outputs are formatted as:

PCN_DISP_<DISPLAY>_<DIGIT>_<SEGMENT>

e.g. PCN_DISP_L_4_7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug A bug affecting dcs-bios help wanted
Projects
None yet
Development

No branches or pull requests

1 participant