-
Notifications
You must be signed in to change notification settings - Fork 356
IOIO FW and Theory of operation.
mark97229 edited this page Aug 22, 2011
·
4 revisions
Its a PIC24 with a usb host stack implementing the ADB server on the PIC side.
It listens to port 4545 for IOIO messages and sends data back and forth to the android target over the same port.
- boot loader tasts
- application protocol tasks
- interrupts / timers
Comments:
- the buffer processing is hard for me to tell if its right or not from the code. Its hard to read for me.
- there are a only a few extra layers in the code.
-
main
- init
- while 1
-
BootloaderTasks() : bootloader/bootloader.c
- ADBTasks()
- ADBPacketTasks()
- ADBPacketSendTasks()
- ADBPacketRecvTasks()
- ADBPacketTasks()
- ADBHandlePacket
- recv_func callback called on ADB protocol state change to
- AppProtocaleHandleIncoming
- MessageDone() implements some of the protocol commands switched on rx_msg.type (the immediate ones) looks like additional queues are populated for ICSP, SPI, UART and I2c processing
- AppProtocaleHandleIncoming
- recv_func callback called on ADB protocol state change to
- ADBFileTasks(): <-- not sure what this is about
- ADBTasks()
-
AppProtocalTasks() <-- non immediate processing (reads from spi or something and queues up usb transfers)
- UARTTasks();
- SPITasks();
- I2CTasks();
- ICSPTasks();
-
-
timers and interrupts:
- ADC transfers are on timer. What else is going on in the ISRs?
- uarts, spi, i2c, (not ICSP though but ICSP processing has a lot of buffer processing so perhaps its best to queue that shit up...)