User Tools

Site Tools

한국어

logicpython:index

This is an old revision of the document!


LogicPython User Documentation

LogicPython is a browser-based Python development environment for RP2350 hardware. The target device must be an RP2350-based device with LogicPython firmware installed. You can edit code, deploy to the device, run programs, monitor output, and use AI-assisted editing.

User Guide

CUBLOC API Reference

The CUBLOC API pages are grouped by category. Each entry links to a dedicated page and includes a short description.

Analog Input

  • ADIn - Read the full MicroPython ADC value from the specified ADC channel.

Digital I/O

  • High - Set a digital output pin high.
  • In - Read a digital input value from a pin.
  • Input - Configure a pin as digital input.
  • Low - Set a digital output pin low.
  • Out - Write a digital output value to a pin.
  • Output - Configure a pin as digital output.
  • Reverse - Toggle the output state of the specified pin.

Memory and Storage

  • EERead - Read bytes from per-address backing files named like _ee_0000.
  • EEWrite - Write bytes into per-address backing files named like _ee_0000.

PWM and Counters

  • Pwm - Output a PWM waveform on the specified channel.
  • PwmOff - Stop PWM output on the specified channel.

MDOBUS RTU Communication

  • OpenCom - Enable serial communication on a CUBLOC-style channel.
  • SetModbus - Start the LogicPython Modbus RTU slave worker using a pre-opened UART channel.

Stepper and Pulse Motion

  • StepAccel - Output an accelerated pulse train on step channel 0 using a PIO state machine.
  • StepPulse - Output a finite pulse train on the specified pin using a PIO state machine.
  • StepStat - Return how many pulses have been generated by the most recent StepPulse or StepAccel command on the channel.
  • StepStop - Immediately stop pulse output on the specified step channel.

System and Debug

  • Debug - Print debug values, interpreting CUBLOC debug control codes.
  • SetDebug - Enable or disable Debug output.
  • SetOnGlobal - Enable or disable CUBLOC-style global interrupt handling.
  • Sys - Return a supported CUBLOC system status value.
  • Time - Read system RTC values for addresses 10 through 13.

Timing and Delays

  • Delay - Delay execution for the given number of milliseconds.
  • OnTimer - Register a periodic timer callback using CUBLOC OnTimer semantics.
  • Pause - Pause execution for the given interval in milliseconds.
  • SetOnTimer - Enable or disable execution of callbacks registered with OnTimer.
  • UDelay - Delay execution for the given number of microseconds.
  • Wait - Delay execution for the given interval in milliseconds.
logicpython/index.1775789653.txt.gz · Last modified: by admin