Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Commit

Permalink
liveDataViewer: updated tickerYValue not shown distance, sensorSelect…
Browse files Browse the repository at this point in the history
…: got rid of title, added bumped all buttons up a bit.
  • Loading branch information
KierPalin committed Nov 7, 2024
1 parent b8b9aa0 commit d821e4e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion liveDataViewer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ namespace microcode {
const y = Math.round(Screen.HEIGHT - ((((reading - sensor.getMinimum()) / range) * (BUFFERED_SCREEN_HEIGHT - fromY)))) - fromY

// Make sure the ticker won't be cut-off by other UI elements
if (!tickerYValues.some(v => Math.abs(v - y) <= 5) && (y < sensor.getMaximum() - 5 && y > sensor.getMinimum() + 5)) {
if (!tickerYValues.some(v => Math.abs(v - y) <= 4) && (y < sensor.getMaximum() - 5 && y > sensor.getMinimum() + 5)) {
screen().print(
sensor.getNthReading(sensor.getBufferLength() - 1).toString().slice(0, 5),
this.windowLeftBuffer + sensor.getBufferLength() + 4,
Expand Down
4 changes: 1 addition & 3 deletions sensorSelect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ namespace microcode {
//-----------------------------------------------------

let x: number = -60;
let y: number = Screen.HEIGHT * -0.3125 // y = -40 on an Arcade Shield of height 128 pixels
let y: number = -41
for (let i = 0; i < icons.length; i++) {
this.btns.push(new Button({
parent: null,
Expand Down Expand Up @@ -173,8 +173,6 @@ namespace microcode {
0xc
)

screen().printCenter("Sensor Selection", 2)

for (let i = 0; i < this.btns.length; i++)
this.btns[i].draw()

Expand Down

0 comments on commit d821e4e

Please sign in to comment.