Commit Graph

7312 Commits

Author SHA1 Message Date
Léa Saviot
834568d08e [usb] Missing return statement.
Change-Id: I25cfaa2e1f75b9d9922ef7b3a82322f9077ca06f
2018-04-06 14:31:46 +02:00
Léa Saviot
c518d89ca0 [usb] Remove debug blue screen code.
Change-Id: I46c6b5027a5074adb0ec195d5125832ea5fce456
2018-04-06 14:31:45 +02:00
Léa Saviot
3e5173b4f0 [usb] Remove old code.
Change-Id: I1b06c138c1c2277d3ec2284164b959056c020903
2018-04-06 14:31:45 +02:00
Léa Saviot
9c98d90975 [usb] Malloc not needed to copy DFU code from flash to RAM.
Change-Id: I62f10b26766703affc5a1b75da98d1a8149e1367
2018-04-06 14:31:45 +02:00
Léa Saviot
0503adaa17 [usb] Remove the data section of dfu.elf.
Change-Id: Idcbef385f4703b6f9a2d14d3b5c1d7bcbc5213a0
2018-04-06 14:31:45 +02:00
Léa Saviot
e0e26a3607 [usb] Separate bin file for DFU code, copied in RAM for execution.
Change-Id: I1b2147ecd2f3d4a5c3d7db5e7a07b66258666fca
2018-04-06 14:31:45 +02:00
Léa Saviot
4b4a8307e1 [usb] Write on memory when usb download.
Change-Id: If68885619639581bcfa0ba38986bdae85e459e20
2018-04-06 14:31:45 +02:00
Léa Saviot
b7829a0937 [usb] Change apps and relocate usb stack on ram.
When the device is plugged to a USB host.

Change-Id: I5d7ae3c86cacce509b6ccca2746984f7e806cb49
2018-04-06 14:31:45 +02:00
Léa Saviot
4368989611 [usb] Handle upload requests.
Change-Id: Ia4cbf2db5e519c62642458e38efd8adc93936edd
2018-04-06 14:31:45 +02:00
Léa Saviot
54dab9bad3 [usb] Handle download requests (but do not actually write).
Change-Id: Id07422b2cab044bf70fcf839bc2e0ce6b7be664f
2018-04-06 14:31:45 +02:00
Léa Saviot
8fc6c9b9b7 [usb] Fixed the getStatus and getState requests, at interface level.
Change-Id: I009a33880921f394ba47db1670ab5fb7d2c7030b
2018-04-06 14:31:45 +02:00
Léa Saviot
4f59cbe0e4 [usb] An interface handles standard requests.
Change-Id: I290aa5c1f0cae7c18c3a2852bc354d7ad4583f17
2018-04-06 14:31:45 +02:00
Léa Saviot
1a5544a0b0 [usb] First dfu code. The device receives dfu commands.
Change-Id: Ibae00051f171f341f9cfc725e4054b4ceb0c966e
2018-04-06 14:31:45 +02:00
Léa Saviot
94e1e2cff5 [usb] Cleaned the way descriptors are copied on the transfer buffer.
Change-Id: Ia6a6372340300d4144fd699f3d318c8d22a49492
2018-04-06 14:31:45 +02:00
Léa Saviot
3979a5c307 [usb] Handle setup packets depending on its recipient.
The recipient can be the device, the interface or the endpoint.

Change-Id: Icc6b6179956d403df2a6fc0cdb6525306af17b51
2018-04-06 14:31:45 +02:00
Léa Saviot
6f17cf6a58 [usb] Remove dead code.
Change-Id: I5c295f5e4e9c84c5877e5a46c33b1dccf553595f
2018-04-06 14:31:45 +02:00
Léa Saviot
88cbe8d560 [usb] Clean enumeration code.
Change-Id: Ie82f5d6585735708a75fd7c0121b19ef19e40374
2018-04-06 14:31:45 +02:00
Léa Saviot
90a57ccf38 WIP
Change-Id: Icbcde58e5857c224ceebce4234db8fc9ef7631e4
2018-04-06 14:31:45 +02:00
Léa Saviot
bd6802a56c [WIP] Cleaning
Change-Id: If174298202b8b53e1cbdc306d16886e100961c41
2018-04-06 14:31:45 +02:00
Léa Saviot
b67f889a40 [WIP] dfu
Change-Id: I8a30380f393a073320843ad94b7938d1f510377a
2018-04-06 14:31:45 +02:00
Léa Saviot
a1b6dacdbe [usb] Code re-organization.
Change-Id: I62be87ea2b8baf419c8e8dc43fa06faa9c290961
2018-04-06 14:31:45 +02:00
Léa Saviot
851d927235 [usb] Open a web page when the calculator is plugged.
Add WebUSB descriptors.

Change-Id: I0bb8bedc93b64ca8b420fb938b379676a2014690
2018-04-06 14:31:44 +02:00
Léa Saviot
78f56d9ada [usb] Reset endpoints before setting them up.
This fixes an enumaration bug when plugging, un-plugging and re-plugging
the calculator.

Change-Id: Ifbb4386b46b7492ce2b833e9e4755fd3cfefc708
2018-04-06 14:31:44 +02:00
Léa Saviot
3583ea3ade [usb] Fix bug that prevented to handle SET_CONFIGURATION requests.
Change-Id: Iff00be2f77fc49b0ed9d9d1f1c6e8d214cbc2043
2018-04-06 14:31:44 +02:00
Léa Saviot
59f4fee05b [usb] Handle GET_STATUS request.
Change-Id: I4c9d8cbe7241dfd6fbb986253122a74d0ddb0e2c
2018-04-06 14:31:44 +02:00
Léa Saviot
10f7e222f0 [usb] Fix comment.
Change-Id: I98466810e00d42b140178fd93b69f05c836d3631
2018-04-06 14:31:44 +02:00
Léa Saviot
954c24bf9c [usb] Windows Device Descriptor
Change-Id: Ibaa37ce94b17ea3a5313f690cfb4b74f93bae899
2018-04-06 14:31:44 +02:00
Léa Saviot
11630f8f62 [usb] Fix buildConfigDescriptor.
Change-Id: Ia837141ceec95fbc5d56f78d7fe2ad31682620d2
2018-04-06 14:31:44 +02:00
Léa Saviot
1b865106e4 [usb] The device can now change its address and completes enumeration.
Change-Id: Ia0a602b108d29349291293d0a57a88d14fc283fa
2018-04-06 14:31:44 +02:00
Léa Saviot
f8f944b449 [usb] Some cleaning.
Change-Id: I576ce8bdb1436f246e01a1928d3892893c8b46b9
2018-04-06 14:31:44 +02:00
Léa Saviot
1a8062e365 [usb] Handle Setup and in packets from host.
Change-Id: I9ffc2705af3c30389b30fdcac34e9e3a1a97a3d7
2018-04-06 14:31:44 +02:00
Léa Saviot
46eaac5054 [usb] Fixed usb initialization.
Change-Id: I614d873f9423844a353ef41d6421ce107f6f8094
2018-04-06 14:31:44 +02:00
Romain Goyet
c89055d4ad Preliminary work on the OTG registers
Change-Id: I39e9c79538d17ea76d5484083d87a52b9bdc34e0
2018-04-06 14:31:44 +02:00
Romain Goyet
e8c61324a6 Configure the USB GPIO's alternate functions
Change-Id: Iee2c685645778accad88cd2008c4faac0f119224
2018-04-06 14:31:44 +02:00
Romain Goyet
d4d4cd359b Use the high-speed external oscillator
This is required to feed the USB controller an accurate 48 MHz clock.

Change-Id: If3b4490c931c18e1b917b3569ece1adec870477a
2018-04-06 14:31:44 +02:00
Léa Saviot
704e02f765 [python] Add qstrdefs.generated.h to generated_headers in Makefile.
This fixes a compilation bug when building without "-j8".

Change-Id: Ic30d379837ab685843f011c3dba01e3d38d2402a
2018-04-06 14:31:44 +02:00
Émilie Feral
9289928fff [apps] Code: abort script name editing if MenuController exits responder
chain
2018-04-06 10:14:13 +02:00
Émilie Feral
4312df1bf1 [ion] Enable to call updateModifiersFromEvent on Special events
(Termination event on emscripten platform for instance)
2018-04-05 15:13:33 +02:00
Zhaofeng Li
6679cb0a20 [apps] Fix exam mode 2018-04-04 13:42:00 +02:00
Romain Goyet
38bf626c19 Make clena 2018-04-04 10:53:56 +02:00
LeaNumworks
fbdff797d8 Merge pull request #387 from Ecco/jump-reset
[ion] Add the ability to perform a jump-reset
2018-04-04 10:49:34 +02:00
Romain Goyet
5c86a07481 [ion] Add the ability to perform a jump-reset 2018-04-04 10:38:52 +02:00
Émilie Feral
9cadc49264 [apps] Code: Fix autoImportScript to avoid corrupting stack 2018-03-28 10:03:36 +02:00
Émilie Feral
f1ddf1dbf4 Valgrind: uninitialized value, memory leak 2018-03-28 10:02:09 +02:00
Émilie Feral
06ace4369c Clean warnings (comparison signed and unsigned) 2018-03-28 10:01:21 +02:00
Émilie Feral
ae086adfcf Clean 2018-03-22 14:01:38 +01:00
Émilie Feral
75292ed749 [ion] Storage: change tags around storage 2018-03-22 14:01:38 +01:00
Émilie Feral
3bc16637a0 [ion] Storage: add comment on Record 2018-03-22 14:01:38 +01:00
Émilie Feral
845fc7c979 [ion] Typo: NoEnough -> NotEnough 2018-03-22 14:01:38 +01:00
Émilie Feral
36e6851c21 [ion] Storage: change rule on record name compliance 2018-03-22 14:01:38 +01:00