Commit Graph

153 Commits

Author SHA1 Message Date
qiuyiuestc e822f87b1a Merge pull request #90 from heyuanjie87/ForPullRequest
For pull request
2013-05-17 06:39:05 -07:00
aozima c77c69c46e fix spelling error. 2013-05-17 20:59:38 +08:00
aozima 9a671a5002 move initial alarm event & mutex in system init. 2013-05-17 20:58:40 +08:00
aozima 36fc5520cb format code by Astyle. 2013-05-17 20:57:05 +08:00
heyuanjie87 8b4aadb4db add usb state 2013-05-17 20:53:05 +08:00
Grissiom b3e38f53b4 usbdevice/core: use static message queue
Although currently the only message send to the queue is struct
udev_msg, in order to keep backward compacity and for extention in the
future, we set the size of message to 32.
2013-05-12 15:43:30 +08:00
Grissiom f0d50a7b36 usbdevice/core: use static thread instead of dynamic thread
It also add two configurations for the USB device even loop thread:

    RT_USBD_THREAD_STACK_SZ to set the stack size, default to 2048
    RT_USBD_THREAD_PRIO     to set the priority, default to 8

You can overwrite the default values in rtconfig.h
2013-05-12 15:43:29 +08:00
Bernard Xiong f1e34eef11 Merge pull request #86 from grissiom/serial-rb-size
serial: use RT_SERIAL_RB_BUFSZ to define the size of ring buffer.
2013-05-11 23:18:18 -07:00
Bernard Xiong 8e9e7f3e7c serial: use RT_SERIAL_RB_BUFSZ to define the size of ring buffer. 2013-05-12 14:03:11 +08:00
Grissiom aa179e4438 cdc_vcom: not to start sending data when the data is already sending
We start the sending transaction in SOF handler. But if the data is
already sending, start an other transaction will cause data lose.
Implement a state machine is cdc_vcom and avoid that.
2013-05-12 13:27:13 +08:00
Grissiom 157af94af9 usbdevice/core: small optimization on the event loop
Sort the switch cases by the frequency of the events.
2013-05-12 13:07:03 +08:00
Grissiom d23ee75d2e cdc_vcom: send data as many as possible
The data filled into dcd_ep_write does not to be limited by
MaxPacketSize.
2013-05-10 17:50:07 +08:00
Grissiom 5de59429fe usbdevice/core: misc cleanup 2013-05-10 17:35:33 +08:00
Grissiom ffb1e62020 cdc_vcom: send a zero-length-packet at the end is transaction 2013-05-10 15:17:59 +08:00
Grissiom 778c4239b1 cdc_vcom: fix the bug that use ringbuffer pool as usb packet buffer
This commit set the buffer for packet to CDC_MaxPacketSize which is a
reasonable value for it. However, maybe we should make
CDC_{RX,TX}_BUFSIZE configurable as well.
2013-05-09 23:18:58 +08:00
Grissiom 952bc0d4ef ringbuffer: format the code to a more symmetric structure 2013-05-08 15:54:30 +08:00
Grissiom 639bd30321 reimplement ringbuffer
The new implementation use the mirroring method to distinguish full
buffer and the empty buffer. It also support buffers of arbitrary size.
2013-05-08 15:45:31 +08:00
Grissiom d196a75a41 usbdevice/core/core.c: fix garbage value bug
This could crash the program with -O1 and -O2 in MDK.
2013-05-04 18:34:13 +08:00
heyuanjie87 34d531578e class driver can custom string description 2013-01-24 20:59:43 +08:00
heyuanjie87 7ce0547575 fixed the string descriptor send to host more than actual 2013-01-17 14:03:45 +08:00
heyuanjie87 a3bde3c4a3 handle standard request to interface that defined in class 2013-01-17 12:23:06 +08:00
Bernard Xiong 9721603b72 Add RT_MTD_ESRC definitions.
Add RT_MTD_ESRC definitions. If the source page has issue when copying a page, the low level can return this error code.
2013-01-17 10:06:01 +08:00
heyuanjie87 1cb356c9df Correct macro definition 2013-01-11 00:03:46 +08:00
heyuanjie87 7b2929303e revert some define to usb_common.h 2013-01-11 00:02:40 +08:00
heyuanjie87 d84fde4e54 revert the define 2013-01-09 18:56:31 +08:00
heyuanjie87 928cabff50 allows the user custom PID and VID 2013-01-09 18:07:59 +08:00
heyuanjie87 58317f5bd2 use new interface to send status in control transfer 2013-01-09 17:55:46 +08:00
heyuanjie87 96f5a6dcec move the define related to Mass to here;
remove product ID
2013-01-09 12:20:15 +08:00
heyuanjie87 d20974b9d2 allows the user custom PID and VID 2013-01-09 12:18:13 +08:00
heyuanjie87 6119136596 remove product ID 2013-01-09 12:15:09 +08:00
heyuanjie87 6b0b2d51e3 move the define related to Mass to mstorage.h 2013-01-09 12:12:25 +08:00
heyuanjie87 22786f8817 allows the user to custom PID and VID;
add a dcd operation to send status in control transfer
2013-01-09 12:04:01 +08:00
Ming, Bai b4de7cce57 Re-normalizing the repo 2013-01-08 22:40:58 +08:00
sc943313837@gmail.com deef5db546 添加RNDIS
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2580 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-31 15:40:31 +00:00
sc943313837@gmail.com b1fa07f392 添加RNDIS
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2579 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-31 15:39:52 +00:00
sc943313837@gmail.com 2a6ffa0ccd 添加RNDIS定义
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2578 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-31 15:38:35 +00:00
sc943313837@gmail.com 6374d20fad change inferface handler parameter
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2565 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-30 09:49:31 +00:00
sc943313837@gmail.com aa49ca9db3 change inferface handler parameter; add a protocol define
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2564 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-30 09:43:19 +00:00
sc943313837@gmail.com 454455e858 change inferface handler parameter
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2563 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-30 09:41:55 +00:00
bernard.xiong@gmail.com 1c56553b04 Add BAUD_RATE_4800 definition.
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2538 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-28 08:50:17 +00:00
dzzxzz@gmail.com ef5c47e684 fixed the coding style in components/drivers/src
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2529 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-26 00:29:42 +00:00
dzzxzz@gmail.com 0e40d55d9f fixed the coding style of RT_DEBUG_LOG
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2500 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-20 07:25:19 +00:00
sc943313837@gmail.com b82d5744b6 remove iad form uclass structure
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2491 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-17 09:37:39 +00:00
sc943313837@gmail.com ebe3e461f6 add a new fuction to config the desc in altsetting
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2490 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-17 09:35:15 +00:00
sc943313837@gmail.com c7e5cc311f Descriptor is no longer using the global variable
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2489 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-17 09:31:57 +00:00
sc943313837@gmail.com bc02dbc501 fixed a warning
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2486 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-16 05:17:21 +00:00
sc943313837@gmail.com 5927bf0ac1 set endpoint buffer to RT_NULL
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2480 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-14 03:08:05 +00:00
sc943313837@gmail.com d8796d9639 change endpoint and class handler
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2477 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-12 16:37:38 +00:00
sc943313837@gmail.com 53efe928d6 change endpoint and class handler
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2476 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-12 16:37:10 +00:00
sc943313837@gmail.com 834355c76b change endpoint and class handler
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@2475 bbd45198-f89e-11dd-88c7-29a3b14d5316
2012-12-12 16:36:23 +00:00