Mercurial > louis > kiibohd-controller
comparison Output/pjrcUSB/arm/usb_serial.c @ 334:9ac304aa1ab5
Adding initial dfu-upload code and debugging for Bootloader.
author | Jacob Alexander <haata@kiibohd.com> |
---|---|
date | Mon, 27 Apr 2015 00:57:34 -0700 |
parents | ab4515606277 |
children | 45feb80a2ad1 |
comparison
equal
deleted
inserted
replaced
333:772f9bea482b | 334:9ac304aa1ab5 |
---|---|
1 /* Teensyduino Core Library | 1 /* Teensyduino Core Library |
2 * http://www.pjrc.com/teensy/ | 2 * http://www.pjrc.com/teensy/ |
3 * Copyright (c) 2013 PJRC.COM, LLC. | 3 * Copyright (c) 2013 PJRC.COM, LLC. |
4 * Modified by Jacob Alexander 2013-2014 | 4 * Modified by Jacob Alexander 2013-2015 |
5 * | 5 * |
6 * Permission is hereby granted, free of charge, to any person obtaining | 6 * Permission is hereby granted, free of charge, to any person obtaining |
7 * a copy of this software and associated documentation files (the | 7 * a copy of this software and associated documentation files (the |
8 * "Software"), to deal in the Software without restriction, including | 8 * "Software"), to deal in the Software without restriction, including |
9 * without limitation the rights to use, copy, modify, merge, publish, | 9 * without limitation the rights to use, copy, modify, merge, publish, |
54 // too short, we risk losing data during the stalls that are common with ordinary desktop | 54 // too short, we risk losing data during the stalls that are common with ordinary desktop |
55 // software. If it's too long, we stall the user's program when no software is running. | 55 // software. If it's too long, we stall the user's program when no software is running. |
56 #define TX_TIMEOUT_MSEC 70 | 56 #define TX_TIMEOUT_MSEC 70 |
57 | 57 |
58 #if F_CPU == 96000000 | 58 #if F_CPU == 96000000 |
59 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 596) | 59 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 596) |
60 #elif F_CPU == 72000000 | |
61 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 512) // XXX Correct? | |
60 #elif F_CPU == 48000000 | 62 #elif F_CPU == 48000000 |
61 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 428) | 63 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 428) |
62 #elif F_CPU == 24000000 | 64 #elif F_CPU == 24000000 |
63 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 262) | 65 #define TX_TIMEOUT (TX_TIMEOUT_MSEC * 262) |
64 #endif | 66 #endif |
65 | 67 |
66 | 68 |
67 | 69 |
68 // ----- Variables ----- | 70 // ----- Variables ----- |