- "using.html" converted to AsciiDoc mode
- the shell documentation was split in a separate file and divided into
two parts: docs for the simple shell and for the advanced shell
(yet to be written)
Methods: mizar32.rtc.get() returns a table like Lua's os.date()
and os.time() with fields year, monthm day, wday, hour min, sec
and mizar32.rtc.set() takes a similar table, only changing the
fields that are present in the table.
Works with DS1337 and PCF8563 clock chips.
This patch undoes the change in the order of timer parameters for:
net.accept() net.recv() tmr.delay() tmr.setclock() tmr.set_match_int()
tmr.gettimediff() and also changes the new tmr.getdiffnow() to have the
same parameter ordering as the others.
The default timer ID (the systimer), which previously was obtained with an
optional last parameter, is now obtained by supplying nil as the timer ID.
The new LCD PIC firmware has the ability to return the cursor position
in the LCD character RAM and the state of the buttons. This commit
implements eLua module functions to make these available to users.
platform_pwm_op( id, op, data ) did four unrelated tasks, switching on the
"op" parameter:
op==PLATFORM_PWM_OP_SET_CLOCK took a frequency and returned a frequency
op==PLATFORM_PWM_OP_GET_CLOCK took nothing returned a frequency
op==PLATFORM_PWM_OP_START and _STOP both took nothing and returned nothing
this patch replaces it with:
clock = platform_pwm_set_clock( id, clock)
clock = platform_pwm_get_clock( id )
platform_pwm_start( id ) and
platform_pwm_stop( id )
with resulting clarity in the documentation and smaller, faster code.
This does not affect the Lau interface.
Previously, you called platform_adc_op(id, OPERATION, u32 arg) to achieve
six unrelated functions with different arg types and return values:
GET_MAXVAL takes nothing and returns an ADC conversion value
SET_SMOOTHING takes a power-of-two filter length and returns nothing
SET_BLOCKING takes a boolean and returns nothing
IS_DONE takes nothing and returns a boolean
SET_TIMER takes a timer ID and returns nothing
SET_CLOCK takes a frequency in Hz and returns a frequency in Hz.
This changes these to six independent functions, each with the right
parameters and return values.
This also makes the documentation more comprehensible, saves 26 bytes of
executable code and should be very slightly faster.