HAL_Linux: don't panic on runtime failures

This commit is contained in:
Andrew Tridgell 2015-08-19 19:19:09 +10:00
parent 582318448f
commit bf001f19ff
2 changed files with 0 additions and 2 deletions

View File

@ -174,7 +174,6 @@ void LinuxGPIO_RPI::setPWM0Period(uint32_t time_us)
// 320 bits for one cycle of 20 milliseconds = 62.5 us per bit = 16 kHz
int idiv = (int) (19200000.0f / (320000000.0f / time_us));
if (idiv < 1 || idiv > 0x1000) {
hal.scheduler->panic("idiv out of range.");
return;
}
*(clk + PWMCLK_DIV) = 0x5A000000 | (idiv<<12);

View File

@ -161,7 +161,6 @@ void LinuxRPIOUARTDriver::_timer_tick(void)
if (_baudrate != 0) {
if (!_spi_sem->take_nonblocking()) {
hal.scheduler->panic("SPIDevice_RASPIO cannot take semaphore!");
return;
}