SPI setup/hold time units

Can someone please confirm what time units the setup and hold time values in the SPI.Configuration call are in: milliseconds, microseconds, nanoseconds? I’m guessing milliseconds but would like to be sure.

The .netMicro doc is here

and this is all it says about the setup and hold time
* ChipSelect_SetupTime
Type: System. . :: . .UInt32
The setup time for the chip select port. In other words, this parameter specifies the amount of time that will elapse between the time at which the device is selected and the time at which the clock and the clock data transmission will start.

* ChipSelect_HoldTime
Type: System. . :: . .UInt32
The hold time for the chip select port. In other words, this parameter specifies the amount of time that the chip select port must remain in the active state before the device is unselected, or the amount of time that the chip select will remain in the active state after the data read/write transaction has been completed.

Thanks

In .NETMF the units is miliseconds. Typically we use zero anyways. In tinyclr the values are in microseconds.

1 Like

Thanks, I’m working with someone else’s code and they had the setup time set to 200 which seemed odd because the setup time on the part’s data sheet was 200 nanoseconds.

NETMF is is microseconds.

Oh then TinyClr is nano seconds? Oops.