Skip to content

Antdigapony/SPI_STC

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

SPI_STC

Basically the same as Arduino, just view http://arduino.cc/en/Reference/SPI for reference. Add function: SPI_pin for SPI pin to switch. Diff function: 1. SPI_begin need a parameter for master and slave(I use 15L CPU so slave fuction was not complete right now)

  1. SPI_setClockDivider only has four input choices because of hardware limitation: SPI_CLOCK_DIV4 SPI_CLOCK_DIV16 SPI_CLOCK_DIV64 SPI_CLOCK_DIV128

ATTENTION: 1. according to offical document, when CPHA=0, SSIG should be 0 too. Which is not solved yet.

  1. When using interrupt, you should first enable the interrupt in CPU by yourself.

About

Arduino-like SPI library for STC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published