<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/stmhal/irq.h, branch esp-extra-scripts</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=esp-extra-scripts</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=esp-extra-scripts'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2015-12-22T21:00:20+00:00</updated>
<entry>
<title>stmhal: Add pyb.irq_stats() to get statistics about IRQ calls.</title>
<updated>2015-12-22T21:00:20+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-06-10T13:25:54+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=401af50dc081faa421e7caef18fde2beb15632e4'/>
<id>urn:sha1:401af50dc081faa421e7caef18fde2beb15632e4</id>
<content type='text'>
Adds a lot of code, makes IRQs a bit less efficient, but is very useful
for debugging.  Usage: pyb.irq_stats() returns a memory view that can be
read and written, eg:

    list(pyb.irq_stats())
    pyb.irq_stats()[0]
    pyb.irq_stats()[0] = 0

The patch provides general IRQ_ENTER() and IRQ_EXIT() macros that can be
modified to provide further IRQ statistics if desired.
</content>
</entry>
<entry>
<title>stmhal: Only use BASEPRI irq stuff if Cortex is M3 or higher.</title>
<updated>2015-12-04T12:13:12+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-12-04T12:13:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=dd7d2e0810b6835d4798c315fb53d2f552a07e9d'/>
<id>urn:sha1:dd7d2e0810b6835d4798c315fb53d2f552a07e9d</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Add raise_irq_pri and restore_irq_pri functions.</title>
<updated>2015-12-04T11:38:23+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-12-04T11:38:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=95c9cc8114a7dd2bc73dc820d45ba8a97f16a60a'/>
<id>urn:sha1:95c9cc8114a7dd2bc73dc820d45ba8a97f16a60a</id>
<content type='text'>
These can be used to disable only certain interrupts, ones at or above
the given priority value.
</content>
</entry>
<entry>
<title>stmhal: Increase the priority of UART IRQ.</title>
<updated>2015-11-25T08:03:44+00:00</updated>
<author>
<name>Dave Hylands</name>
<email>dhylands@gmail.com</email>
</author>
<published>2015-11-24T18:22:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=c8437f97ae1b9849bbb8e3abbf82a832cc901622'/>
<id>urn:sha1:c8437f97ae1b9849bbb8e3abbf82a832cc901622</id>
<content type='text'>
The UARTs have no FIFOs, so if interrupts are disabled
for more than a character time (10 usec at 1 Mbit/sec)
then characters get dropped.

The overhead for handling a UART ISR is about 0.5 usec,
so even at baud rates of 1 Mbit/sec this only corresponds
to about 5% of the CPU. Lower baud rates will have less
of an impact.
</content>
</entry>
<entry>
<title>stmhal/irq: Set all IRQ subpriorities to 0, since they aren't used.</title>
<updated>2015-11-24T15:56:33+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-11-24T15:56:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=3cfb02f1663fbf3a6d7ae367974d0984d3424806'/>
<id>urn:sha1:3cfb02f1663fbf3a6d7ae367974d0984d3424806</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal/irq: Add comment about SDIO priority being higher than DMA.</title>
<updated>2015-11-24T15:51:07+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-11-24T15:51:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=18820471ae1b8c3977ed453da2d8f1fcfabda963'/>
<id>urn:sha1:18820471ae1b8c3977ed453da2d8f1fcfabda963</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Put IRQs into priority order.</title>
<updated>2015-11-24T09:37:25+00:00</updated>
<author>
<name>Dave Hylands</name>
<email>dhylands@gmail.com</email>
</author>
<published>2015-11-15T22:23:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=9f5486c7e2928435362b7ae06f0d678a4798693a'/>
<id>urn:sha1:9f5486c7e2928435362b7ae06f0d678a4798693a</id>
<content type='text'>
- added some comments to explain the priority/sub-priority.
- adds an entry for SDIO (to be used in a later patch)
- increases DMA priority above USB so that DMA can be used
  for sdcard I/O when using USB Mass Storage.
</content>
</entry>
<entry>
<title>stmhal: Add symbolic #defines for interrupt levels in irq.h.</title>
<updated>2015-11-01T23:23:39+00:00</updated>
<author>
<name>Dave Curtis</name>
<email>davecurtis@sonic.net</email>
</author>
<published>2015-10-31T17:44:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=32b3549cce7a965d92a81db02c7adc973f08d74c'/>
<id>urn:sha1:32b3549cce7a965d92a81db02c7adc973f08d74c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Make pyb.[u]delay use systick with IRQs, busy loop otherwise.</title>
<updated>2014-11-30T21:23:25+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-11-30T21:23:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=1960475ed7e190bcf537f8f7714a543b7513e2d5'/>
<id>urn:sha1:1960475ed7e190bcf537f8f7714a543b7513e2d5</id>
<content type='text'>
pyb.delay and pyb.udelay now use systick if IRQs are enabled, otherwise
they use a busy loop.  Thus they work correctly when IRQs are disabled.
The busy loop is computed from the current CPU frequency, so works no
matter the CPU frequency.
</content>
</entry>
<entry>
<title>stmhal: Make enable_irq and disable_irq inline functions.</title>
<updated>2014-08-25T12:24:33+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-08-25T12:24:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=e5cbb70328239e58c820938eccd51f3c735fc312'/>
<id>urn:sha1:e5cbb70328239e58c820938eccd51f3c735fc312</id>
<content type='text'>
These functions are generally 1 machine instruction, and are used in
critical code, so makes sense to have them inline.

Also leave these functions uninverted (ie 0 means enable, 1 means
disable) and provide macro constants if you really need to distinguish
the states.  This makes for smaller code as well (combined with
inlining).

Applied to teensy port as well.
</content>
</entry>
</feed>
