[91] Flipper Zero - Understand SPI Protocol

Published: 18 November 2023
on channel: Derek Jamison
2,306
75

In this multi-part video series we learn about SPI. Serial Peripheral Interface, created by Motorola in the 80s, is used to interface the Flipper Zero with devices such as SD cards, temperature sensors and flash memory. This video takes a look at flash memory. We use the "SPI Mem Manager" app, which is used to read/write to flash memory. We learn how to wire up devices to the Flipper Zero. We learn what each wire actually does. We look at the signals on the CS, SCK, MOSI and MISO wires and hand-decode some Flipper Zero interactions. Finally, we write some Flipper Zero code to read a message from the flash memory.

In future videos, we will be looking at how the external CC1101 works and how to control WS2812B LEDs using SPI.


Join the discord server (conversations and giveaways):
  / discord  

Support the channel:
Option 1. Like, Subscribe and click the Bell (to get notified)
Option 2. https://ko-fi.com/codeallnight (donate $3 via PayPal or Venmo)
Option 3. Click the "Thanks" button on YouTube.

Lesson summary:
SPI is used it interface with various devices, like flash memory, temp sensors, SD cards, etc.
CS (Chip Select) is used to signal to sensor that communication is for it.
SCK (Serial Clock) is controlled by the Flipper Zero. Each cycle a bit is read & written.
MOSI (Main Out/Sub In) is output from Flipper Zero. Data in on sensor.
MISO (Main In/Sub Out) is input to Flipper Zero. Data out on sensor.
TRX needs more memory
TX, RX commands make code more readable.

Timeline:
0:00 - Introduction
0:27 - SPI 4-wire implementation
0:52 - Chip Select (CS)
1:06 - Serial Clock (SCK)
1:22 - Main Out/Sub In (MOSI)
1:52 - Main In/Sub Out (MISO)
2:13 - Power
2:36 - Decoding Chip Id message
4:08 - SPI Memory Manager
4:25 - Flipper Zero communication
5:30 - Flipper Zero code (TRX)
6:54 - Flipper Zero code (TX, RX)
8:12 - Summary


Video for setting up Windows Development Environment:
   • [51] Flipper Zero - Windows developme...  

SPI Mem Manager project (not my project):
https://github.com/flipperdevices/fli...


Watch video [91] Flipper Zero - Understand SPI Protocol online, duration hours minute second in high quality that is uploaded to the channel Derek Jamison 18 November 2023. Share the link to the video on social media so that your subscribers and friends will also watch this video. This video clip has been viewed 2,306 times and liked it 75 visitors.