Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
micropython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
xpstem
micropython
Commits
c13b2f2d
Commit
c13b2f2d
authored
Jan 11, 2016
by
Peter Hinch
Committed by
Damien George
Jan 13, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
docs: Several minor changes: network, pyb, ADCAll and inline asm.
parent
22d85ec5
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
6 deletions
+24
-6
docs/library/network.rst
docs/library/network.rst
+2
-1
docs/library/pyb.ADC.rst
docs/library/pyb.ADC.rst
+6
-0
docs/library/pyb.rst
docs/library/pyb.rst
+8
-0
docs/reference/asm_thumb2_hints_tips.rst
docs/reference/asm_thumb2_hints_tips.rst
+5
-5
docs/reference/asm_thumb2_misc.rst
docs/reference/asm_thumb2_misc.rst
+3
-0
No files found.
docs/library/network.rst
View file @
c13b2f2d
...
...
@@ -8,7 +8,8 @@
This module provides network drivers and routing configuration. Network
drivers for specific hardware are available within this module and are
used to configure a hardware network interface. Configured interfaces
are then available for use via the :mod:`socket` module.
are then available for use via the :mod:`socket` module. To use this module
the network build of firmware must be installed.
For example::
...
...
docs/library/pyb.ADC.rst
View file @
c13b2f2d
...
...
@@ -74,3 +74,9 @@ Methods
This function does not allocate any memory.
The ADCAll Object
-----------------
Instantiating this changes all ADC pins to analog inputs. It is possible to read the
MCU temperature, VREF and VBAT without using ADCAll. The raw data can be accessed on
ADC channels 16, 17 and 18 respectively. However appropriate scaling will need to be applied.
docs/library/pyb.rst
View file @
c13b2f2d
...
...
@@ -25,6 +25,10 @@ Time related functions
after 2^30 milliseconds (about 12.4 days) this will start to return
negative numbers.
Note that if :meth:`pyb.stop()` is issued the hardware counter supporting this
function will pause for the duration of the "sleeping" state. This
will affect the outcome of :meth:`pyb.elapsed_millis()`.
.. function:: micros()
Returns the number of microseconds since the board was last reset.
...
...
@@ -33,6 +37,10 @@ Time related functions
after 2^30 microseconds (about 17.8 minutes) this will start to return
negative numbers.
Note that if :meth:`pyb.stop()` is issued the hardware counter supporting this
function will pause for the duration of the "sleeping" state. This
will affect the outcome of :meth:`pyb.elapsed_micros()`.
.. function:: elapsed_millis(start)
Returns the number of milliseconds which have elapsed since ``start``.
...
...
docs/reference/asm_thumb2_hints_tips.rst
View file @
c13b2f2d
...
...
@@ -78,11 +78,11 @@ three arguments, which must (if used) be named ``r0``, ``r1`` and ``r2``. When
the code executes the registers will be initialised to those values.
The data types which can be passed in this way are integers and memory
addresses.
Further, integers are restricted in that the top two bits
must be identical, limiting the range to -2**30 to 2**30 -1. Return
values are similarly limited. These limitations can be overcome by mean
s
of the ``array`` module to allow any number of values of any type to
be accessed.
addresses.
With current firmware all possible 32 bit values may be passed.
Returned integers are restricted in that the top two bits must be identical,
limiting the range to -2**30 to 2**30 -1. The limitations on number of argument
s
and return values can be overcome by means of the ``array`` module which enables
any number of values of any type to
be accessed.
Multiple arguments
~~~~~~~~~~~~~~~~~~
...
...
docs/reference/asm_thumb2_misc.rst
View file @
c13b2f2d
...
...
@@ -5,6 +5,9 @@ Miscellaneous instructions
* wfi() Suspend execution in a low power state until an interrupt occurs.
* cpsid(flags) set the Priority Mask Register - disable interrupts.
* cpsie(flags) clear the Priority Mask Register - enable interrupts.
* mrs(Rd, special_reg) ``Rd = special_reg`` copy a special register to a general register. The special register
may be IPSR (Interrupt Status Register) or BASEPRI (Base Priority Register). The IPSR provides a means of determining
the exception number of an interrupt being processed. It contains zero if no interrupt is being processed.
Currently the ``cpsie()`` and ``cpsid()`` functions are partially implemented.
They require but ignore the flags argument and serve as a means of enabling and disabling interrupts.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment