<feed xmlns='http://www.w3.org/2005/Atom'>
<title>suspect-devices/circuitpython/stmhal/usbd_cdc_interface.c, branch v1.5.1</title>
<subtitle>CircuitPython - a Python implementation for teaching coding with microcontrollers</subtitle>
<id>https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.5.1</id>
<link rel='self' href='https://git.suspectdevices.com/suspect-devices/circuitpython/atom?h=v1.5.1'/>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/'/>
<updated>2015-10-24T18:58:58+00:00</updated>
<entry>
<title>stmhal: Typo fix in comment.</title>
<updated>2015-10-24T18:58:58+00:00</updated>
<author>
<name>Paul Sokolovsky</name>
<email>pfalcon@users.sourceforge.net</email>
</author>
<published>2015-10-24T18:58:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=4a9c60cdfb509b61dd71dbaec36293239e6e53cc'/>
<id>urn:sha1:4a9c60cdfb509b61dd71dbaec36293239e6e53cc</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Break immediately from USB CDC busy wait loop if IRQs disabled.</title>
<updated>2015-06-07T22:48:07+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-06-07T22:48:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=0aa5e7500047d869cc78e8914fc08b5d6a3f5994'/>
<id>urn:sha1:0aa5e7500047d869cc78e8914fc08b5d6a3f5994</id>
<content type='text'>
If IRQs are disabled then the USB CDC buffer will never be
drained/filled and the sys-tick timer will never increase, so we should
not busy wait in this case.
</content>
</entry>
<entry>
<title>stmhal: Remove some unnecessary declarations, purely for cleanup.</title>
<updated>2015-03-20T22:27:34+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2015-03-20T22:27:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=7674da8057b5236373345350acd2a7513377d393'/>
<id>urn:sha1:7674da8057b5236373345350acd2a7513377d393</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Add Python-configurable USB HID mode.</title>
<updated>2015-02-13T14:02:51+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-11-01T21:26:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=d39c7aa517b722161a7dd792fafc5096d58beec8'/>
<id>urn:sha1:d39c7aa517b722161a7dd792fafc5096d58beec8</id>
<content type='text'>
Different HID modes can be configured in Python.  You can either use
predefined mouse or keyboard, or write your own report descriptor.
</content>
</entry>
<entry>
<title>stmhal: Add USB_VCP.setinterrupt method, to disable CTRL-C.</title>
<updated>2014-11-29T15:23:21+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-11-29T15:23:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=19fb1b4dd7173ad2cf4b2bb1b0f0c06498499bd2'/>
<id>urn:sha1:19fb1b4dd7173ad2cf4b2bb1b0f0c06498499bd2</id>
<content type='text'>
</content>
</entry>
<entry>
<title>stmhal: Reduce coupling between USB driver and readline.</title>
<updated>2014-11-27T16:58:31+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-11-27T16:58:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=5cbc9e0db0f01e1e643e8c091a536b54372df5bd'/>
<id>urn:sha1:5cbc9e0db0f01e1e643e8c091a536b54372df5bd</id>
<content type='text'>
This makes it easier to re-use readline.c and pyexec.c from stmhal in
other ports.
</content>
</entry>
<entry>
<title>stmhal: Add ioctl to USB_VCP object, so it works with select.</title>
<updated>2014-10-31T00:12:02+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-31T00:12:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=9a41b32b3f58246cbe69db237877775b4d2fe920'/>
<id>urn:sha1:9a41b32b3f58246cbe69db237877775b4d2fe920</id>
<content type='text'>
This patch also enables non-blocking streams on stmhal port.

One can now make a USB-UART pass-through function:

def pass_through(usb, uart):
    while True:
        select.select([usb, uart], [], [])
        if usb.any():
            uart.write(usb.read(256))
        if uart.any():
            usb.write(uart.read(256))

pass_through(pyb.USB_VCP(), pyb.UART(1, 9600))
</content>
</entry>
<entry>
<title>stmhal: Improve REPL control codes; improve pyboard.py script.</title>
<updated>2014-10-26T15:39:22+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-26T15:39:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=bc1488a05f509cd5be8bfab9574babfcb993806f'/>
<id>urn:sha1:bc1488a05f509cd5be8bfab9574babfcb993806f</id>
<content type='text'>
Improvements are:

2 ctrl-C's are now needed to truly kill running script on pyboard, so
make CDC interface allow multiple ctrl-C's through at once (ie sending
b'\x03\x03' to pyboard now counts as 2 ctrl-C's).

ctrl-C in friendly-repl can now stop multi-line input.

In raw-repl mode, use ctrl-D to indicate end of running script, and also
end of any error message.  Thus, output of raw-repl is always at least 2
ctrl-D's and it's much easier to parse.

pyboard.py is now a bit faster, handles exceptions from pyboard better
(prints them and exits with exit code 1), prints out the pyboard output
while the script is running (instead of waiting till the end), and
allows to follow the output of a previous script when run with no
arguments.
</content>
</entry>
<entry>
<title>py: Add mp_pending_exception global variable, for VM soft interrupt.</title>
<updated>2014-10-25T22:37:57+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-10-25T17:19:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=124df6f8d07b53542b6960dbeea9b63bff469a67'/>
<id>urn:sha1:124df6f8d07b53542b6960dbeea9b63bff469a67</id>
<content type='text'>
This allows to implement KeyboardInterrupt on unix, and a much safer
ctrl-C in stmhal port.  First ctrl-C is a soft one, with hope that VM
will notice it; second ctrl-C is a hard one that kills anything (for
both unix and stmhal).

One needs to check for a pending exception in the VM only for jump
opcodes.  Others can't produce an infinite loop (infinite recursion is
caught by stack check).
</content>
</entry>
<entry>
<title>stmhal: Add USB_VCP class/object, for direct USB VCP control.</title>
<updated>2014-07-31T09:30:42+00:00</updated>
<author>
<name>Damien George</name>
<email>damien.p.george@gmail.com</email>
</author>
<published>2014-07-31T09:30:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.suspectdevices.com/suspect-devices/circuitpython/commit/?id=3c4db9f91c01211aed47afe3efdd11477badc0bc'/>
<id>urn:sha1:3c4db9f91c01211aed47afe3efdd11477badc0bc</id>
<content type='text'>
Before, pyb.stdin/pyb.stdout allowed some kind of access to the USB VCP
device, but it was basic access.

This patch adds a proper USB_VCP class and object with much more control
over the USB VCP device.  Create an object with pyb.USB_VCP(), then use
this object as if it were a UART object.  It has send, recv, read,
write, and other methods.  send and recv allow a timeout to be specified.

Addresses issue 774.
</content>
</entry>
</feed>
