public
Description: Ruby Arduino Development: a framework for programming the Arduino physcial computing platform using Ruby
Home | Edit | New

Serial Communication

A Guide to Serial Communication with RAD

What It Is

rs-232, usb, etc.

What It’s Good For

computer-to-arduino communication
lots of other devices

How to Use It – General

available
read
print
type issues on read

debugging with screen

How to Use It – RAD


class Basic < ArduinoSketch
  serial_begin
  
  def loop
    serial_println "hello"
  end    
end

How it Works

How to Use It – Advanced


class SerialTerm < ArduinoSketch
  serial_begin
  
  def loop
    if serial_available
      serial_print serial_read
      toggle 13
    end
  end    
end

Where to Get It

all you need is a serial cable: usb device cable or ttl-232

Read More

Igoe

Last edited by atduskgreg, Sun Aug 31 15:04:41 -0700 2008
Home | Edit | New
Versions: