File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -370,10 +370,12 @@ impl Hardware {
370370 /// MCP23S17 CS pin disable time (between transactions). At least 50ns, we give 100ns.
371371 const CS_IO_DISABLE_CPU_CLOCKS : u32 = 100 / Self :: NS_PER_CLOCK_CYCLE ;
372372
373- /// Give the device 2us (2 clocks @ 1 MHz) to get ready.
374- const CS_BUS_SETUP_CPU_CLOCKS : u32 = 2000 / Self :: NS_PER_CLOCK_CYCLE ;
373+ /// Give the device 10us to get ready.
374+ ///
375+ /// This seems to reduce the error rate on the BMC link to an acceptable level.
376+ const CS_BUS_SETUP_CPU_CLOCKS : u32 = 10_000 / Self :: NS_PER_CLOCK_CYCLE ;
375377
376- /// Give the device 2us (2 clocks @ 1 MHz) before we take away CS.
378+ /// Give the device 2000ns before we take away CS.
377379 const CS_BUS_HOLD_CPU_CLOCKS : u32 = 2000 / Self :: NS_PER_CLOCK_CYCLE ;
378380
379381 /// Give the device 10us when we do a retry.
@@ -1554,7 +1556,7 @@ extern "C" fn block_dev_eject(dev_id: u8) -> common::Result<()> {
15541556/// Sleep the CPU until the next interrupt.
15551557extern "C" fn power_idle ( ) {
15561558 // cortex_m::asm::wfe();
1557- // cortex_m::asm::delay(20_000_000 );
1559+ cortex_m:: asm:: delay ( 1_000_000 ) ;
15581560}
15591561
15601562/// TODO: Get the monotonic run-time of the system from SysTick.
You can’t perform that action at this time.
0 commit comments