This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "hardware/flash.h" | |
// The two primary functions that you would use are: | |
// bool read(uint8_t *output, uint8_t size); | |
// void write(uint8_t *data, uint8_t size); | |
// The read(...) function will either fill the *output buffer | |
// with size bytes (and return true), or will return false if | |
// there is no saved data available to be read. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import socket, threading, select | |
def _forwardBetween(*sockets, endOnAnySocketClose=True, daemonize=True): | |
def _handler(sockets): | |
sockets = list(sockets) | |
print(sockets) | |
# Set all sockets to nonblocking so we don't have to wait for them | |
[socket.setblocking(False) for socket in sockets] | |
while True: | |
socks = select.select(sockets, [], sockets)[0] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-------------Camera fields--------------- | |
Enable: | |
WRITE 06 02 00 00 00 00 => 0af6 | |
Disable: | |
WRITE 06 02 01 00 00 00 => 0af6 | |
Shutter pressed: | |
READ 07 01 06 00 00 00 <= 0af7 |