Skip to content

Commit

Permalink
deploy: ca5a411
Browse files Browse the repository at this point in the history
  • Loading branch information
greg-norris committed Oct 27, 2023
1 parent be63c8c commit 587e61d
Showing 1 changed file with 19 additions and 1 deletion.
20 changes: 19 additions & 1 deletion demos.json
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,22 @@
"Goto Loop"
]
},
{
"label": "Touch Screen",
"code": [
"# This sample reads the x & y position on a touch screen.",
"# Touch screen with finger to read",
"# BrainPad already has the required R/C",
"# Other pins need R/C to work",
"@Loop",
" x = TouchRead('x')",
" y = TouchRead('y')",
" LogLn(x)",
" LogLn(y)",
" Wait(100)",
"Goto Loop"
]
},
{
"label": "For Loop",
"code": [
Expand Down Expand Up @@ -276,7 +292,9 @@
"# TickUs()",
"# Read system ticks in microseconds",
"# TouchRead(pin) ",
"# pin: pin number - Returns: 0 = not touched or 1 = touched",
"# pin: pin number, 'x' or 'y'",
"# Pin Returns: 0 = pin not touched or pin 1 = touched ",
"# Touch Screen Returns: -1 = not touched or x and y position",
"# Trunc(number)",
"# Returns the truncated value of it's argument",
"# Version",
Expand Down

0 comments on commit 587e61d

Please sign in to comment.