mirror of
https://github.com/ArteryTek/AT32F415_Firmware_Library.git
synced 2026-05-21 09:22:11 +00:00
update version to v2.1.2
This commit is contained in:
@@ -145,7 +145,7 @@ void SysTick_Handler(void)
|
||||
*/
|
||||
void SPI1_IRQHandler(void)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI1, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI1, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
{
|
||||
spi_i2s_data_transmit(SPI1, spi1_tx_buffer[tx_index++]);
|
||||
if(tx_index == BUFFERSIZE)
|
||||
@@ -162,7 +162,7 @@ void SysTick_Handler(void)
|
||||
*/
|
||||
void SPI2_IRQHandler(void)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI2, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI2, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
{
|
||||
spi2_rx_buffer[rx_index++] = spi_i2s_data_receive(SPI2);
|
||||
}
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
<TargetName>halfduplex_transceiver_switch</TargetName>
|
||||
<ToolsetNumber>0x4</ToolsetNumber>
|
||||
<ToolsetName>ARM-ADS</ToolsetName>
|
||||
<pCCUsed>5060750::V5.06 update 6 (build 750)::ARMCC</pCCUsed>
|
||||
<pCCUsed>5060750::V5.06 update 6 (build 750)::.\ARMCC</pCCUsed>
|
||||
<uAC6>0</uAC6>
|
||||
<TargetOption>
|
||||
<TargetCommonOption>
|
||||
|
||||
@@ -13,4 +13,5 @@
|
||||
pb13(sck) <---> pa5(sck)
|
||||
pb14(miso) <---> pa7(mosi)
|
||||
|
||||
for more detailed information. please refer to the application note document AN0102.
|
||||
for more detailed information. please refer to the application note document AN0102.
|
||||
|
||||
|
||||
@@ -147,28 +147,22 @@ void SysTick_Handler(void)
|
||||
*/
|
||||
void SPI1_IRQHandler(void)
|
||||
{
|
||||
if(SPI1->ctrl2_bit.tdbeie != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI1, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI1, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
spi_i2s_data_transmit(SPI1, spi1_tx_buffer[tx_index++]);
|
||||
if(tx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_i2s_data_transmit(SPI1, spi1_tx_buffer[tx_index++]);
|
||||
if(tx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_i2s_interrupt_enable(SPI1, SPI_I2S_TDBE_INT, FALSE);
|
||||
}
|
||||
spi_i2s_interrupt_enable(SPI1, SPI_I2S_TDBE_INT, FALSE);
|
||||
}
|
||||
}
|
||||
if(SPI1->ctrl2_bit.rdbfie != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI1, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI1, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
spi_enable(SPI1, FALSE);
|
||||
spi1_rx_buffer[rx_index++] = spi_i2s_data_receive(SPI1);
|
||||
spi_enable(SPI1, TRUE);
|
||||
if(rx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_enable(SPI1, FALSE);
|
||||
spi1_rx_buffer[rx_index++] = spi_i2s_data_receive(SPI1);
|
||||
spi_enable(SPI1, TRUE);
|
||||
if(rx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_i2s_interrupt_enable(SPI1, SPI_I2S_RDBF_INT, FALSE);
|
||||
}
|
||||
spi_i2s_interrupt_enable(SPI1, SPI_I2S_RDBF_INT, FALSE);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -180,23 +174,17 @@ void SysTick_Handler(void)
|
||||
*/
|
||||
void SPI2_IRQHandler(void)
|
||||
{
|
||||
if(SPI2->ctrl2_bit.tdbeie != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI2, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI2, SPI_I2S_TDBE_FLAG) != RESET)
|
||||
spi_i2s_data_transmit(SPI2, spi2_tx_buffer[tx_index++]);
|
||||
if(tx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_i2s_data_transmit(SPI2, spi2_tx_buffer[tx_index++]);
|
||||
if(tx_index == BUFFERSIZE)
|
||||
{
|
||||
spi_i2s_interrupt_enable(SPI2, SPI_I2S_TDBE_INT, FALSE);
|
||||
}
|
||||
spi_i2s_interrupt_enable(SPI2, SPI_I2S_TDBE_INT, FALSE);
|
||||
}
|
||||
}
|
||||
if(SPI2->ctrl2_bit.rdbfie != RESET)
|
||||
if(spi_i2s_interrupt_flag_get(SPI2, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
{
|
||||
if(spi_i2s_flag_get(SPI2, SPI_I2S_RDBF_FLAG) != RESET)
|
||||
{
|
||||
spi2_rx_buffer[rx_index++] = spi_i2s_data_receive(SPI2);
|
||||
}
|
||||
spi2_rx_buffer[rx_index++] = spi_i2s_data_receive(SPI2);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user