Class: MSR::MSR206
- Inherits:
-
Object
- Object
- MSR::MSR206
- Defined in:
- lib/msr/msr206.rb,
ext/msr/msr206.c
Overview
Represents a connection to an MSR206 (or MSR206-compatible device).
Instance Method Summary collapse
-
#bpc= ⇒ Object
Set the bits-per-character on each track.
-
#bpi= ⇒ Object
Set the bits-per-inch on the second track.
-
#coercivity ⇒ Symbol
Get the device's current coercivity level.
-
#coercivity= ⇒ Object
Set the device's coercivity level.
-
#comm_test! ⇒ Symbol
Run a communications test between the system and the device.
-
#firmware ⇒ String
Get the device's firmware version.
-
#initialize ⇒ Object
constructor
Create a new MSR206 instance for a serial device.
-
#iso_read ⇒ MSR::Tracks
Read ISO-formatted data from a card.
-
#iso_write ⇒ Object
Write ISO-formatted data to a card.
-
#led= ⇒ Object
Control the LEDs on the device.
-
#linked? ⇒ Boolean
Whether or not the device is currently linked.
-
#model ⇒ String
Get the device's model.
-
#ram_test! ⇒ Symbol
Run a test of the device's internal RAM.
-
#raw_read ⇒ MSR::Tracks
Read raw data from a card.
-
#raw_write ⇒ Object
Write raw data to a card.
-
#reset! ⇒ Object
Reset the device to a ready state.
-
#sensor_test! ⇒ Symbol
Run a test of the device's magnetic sensor.
Constructor Details
#initialize ⇒ Object
Create a new MSR::MSR206 instance for a serial device.
15 |
# File 'ext/msr/msr206.c', line 15
static VALUE initialize(VALUE self, VALUE rb_string);
|
Instance Method Details
#bpc= ⇒ Object
Set the bits-per-character on each track.
84 |
# File 'ext/msr/msr206.c', line 84
static VALUE set_bpc(VALUE self, VALUE bpc_ary);
|
#bpi= ⇒ Object
This only applies to the second track.
Set the bits-per-inch on the second track.
77 |
# File 'ext/msr/msr206.c', line 77
static VALUE set_bpi(VALUE self, VALUE bpi);
|
#coercivity ⇒ Symbol
Get the device's current coercivity level.
61 |
# File 'ext/msr/msr206.c', line 61 static VALUE get_coercivity(VALUE self); |
#coercivity= ⇒ Object
Set the device's coercivity level.
69 |
# File 'ext/msr/msr206.c', line 69
static VALUE set_coercivity(VALUE self, VALUE co_sym);
|
#comm_test! ⇒ Symbol
Run a communications test between the system and the device.
21 |
# File 'ext/msr/msr206.c', line 21 static VALUE comm_test(VALUE self); |
#firmware ⇒ String
Get the device's firmware version.
47 |
# File 'ext/msr/msr206.c', line 47 static VALUE firmware(VALUE self); |
#iso_read ⇒ MSR::Tracks
This method is interactive.
Read ISO-formatted data from a card.
106 |
# File 'ext/msr/msr206.c', line 106 static VALUE iso_read(VALUE self); |
#iso_write ⇒ Object
This method is interactive.
Write ISO-formatted data to a card.
120 |
# File 'ext/msr/msr206.c', line 120
static VALUE iso_write(VALUE self, VALUE tks_obj);
|
#led= ⇒ Object
Control the LEDs on the device.
92 |
# File 'ext/msr/msr206.c', line 92
static VALUE set_led(VALUE self, VALUE led_sym);
|
#linked? ⇒ Boolean
Whether or not the device is currently linked. Corresponds to #comm_test! being passed.
9 10 11 |
# File 'lib/msr/msr206.rb', line 9 def linked? comm_test! == :pass end |
#model ⇒ String
Get the device's model.
54 |
# File 'ext/msr/msr206.c', line 54 static VALUE model(VALUE self); |
#ram_test! ⇒ Symbol
Run a test of the device's internal RAM.
34 |
# File 'ext/msr/msr206.c', line 34 static VALUE ram_test(VALUE self); |
#raw_read ⇒ MSR::Tracks
This method is interactive.
Read raw data from a card.
99 |
# File 'ext/msr/msr206.c', line 99 static VALUE raw_read(VALUE self); |
#raw_write ⇒ Object
This method is interactive.
Write raw data to a card.
113 |
# File 'ext/msr/msr206.c', line 113
static VALUE raw_write(VALUE self, VALUE tks_obj);
|
#reset! ⇒ Object
This method pauses for 100ms.
Reset the device to a ready state.
40 |
# File 'ext/msr/msr206.c', line 40 static VALUE reset(VALUE self); |
#sensor_test! ⇒ Symbol
This method is interactive.
Run a test of the device's magnetic sensor.
28 |
# File 'ext/msr/msr206.c', line 28 static VALUE sensor_test(VALUE self); |