19.11.2013 Views

Spirometer Demo with Freescale Microcontrollers

Spirometer Demo with Freescale Microcontrollers

Spirometer Demo with Freescale Microcontrollers

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Software architecture<br />

Figure 19. State Measuring exhalation flow chart<br />

4.5.6 State—Sending results<br />

Once the end of exhalation is detected, the next state is the sending results state. It consists of filling the results buffer <strong>with</strong><br />

the final results obtained <strong>with</strong> the calculation routines, and generates an event to send that information to the computer.<br />

Afterwards, the measurement is aborted by stopping the timer, changing the state to idle, and turning the MED-SPI board off.<br />

Figure 20 shows the flow chart.<br />

<strong>Spirometer</strong> <strong>Demo</strong> <strong>with</strong> <strong>Freescale</strong> <strong>Microcontrollers</strong>, Rev. 1, 12/2012<br />

<strong>Freescale</strong> Semiconductor, Inc. 19

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!