User Tools

Site Tools

한국어

logicpython:cubloc_api:output

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
logicpython:cubloc_api:output [2026/04/10 02:06] – created - external edit 127.0.0.1logicpython:cubloc_api:output [2026/04/14 04:15] (current) – [Related APIs] mfranklin
Line 18: Line 18:
  
 <code python> <code python>
-from cubloc import Output+from time import sleep 
 +from cubloc import Output, High, Low
  
-Example usage +LED on GP25, configured as an output 
-Output(0)+LED = 25 
 +Output(LED) 
 + 
 +while True: 
 +    # Turn LED on for 500ms 
 +    High(LED) 
 +    print("LED ON") 
 +    sleep(0.5) 
 + 
 +    # Turn LED off for 500ms 
 +    Low(LED) 
 +    print("LED OFF"
 +    sleep(0.5)
 </code> </code>
  
Line 31: Line 44:
   * [[logicpython:cubloc_api:low|Low]]   * [[logicpython:cubloc_api:low|Low]]
   * [[logicpython:cubloc_api:out|Out]]   * [[logicpython:cubloc_api:out|Out]]
 +  * [[logicpython:cubloc_api:reverse|Reverse]]
  
logicpython/cubloc_api/output.1775786798.txt.gz · Last modified: by 127.0.0.1