team project #1 digital watch sadslab.konkuk.ac.kr/class/2019/19se/team_b/p1/[t7]sra_ppt.pdfsystem...

19
Team 7 Software Engineering team project #1 Digital Watch – SA 김소영 (201511248) 지우영 (201511299) 문승훈 (201714284) 김현재 (201812308)

Upload: others

Post on 28-Dec-2019

33 views

Category:

Documents


0 download

TRANSCRIPT

Team 7

Software Engineering

team project #1

Digital Watch – SA

김소영 (201511248) 지우영 (201511299)

문승훈 (201714284) 김현재 (201812308)

Index

• Statement Of Purpose

• Basic Idea

• System Context Diagram with Event List

• DFD 0~3 with Data Dictionary

• DFD Level 4 : State Transition Diagram

Digital Watch (DW)

- Digital Watch has three modes. (Time Keeping, Alarm , Stopwatch)

- It displays time and user can modify time

- User can set Alarm time and If it’s time to alarm sound user set before, alarm

speaker ring the sound

- It can check Lap time while in stopwatch mode

- It can light on backlight when user wants to see screen brightly

Statement Of Purpose

Basic Idea

Main Control

BacklightControl

SpeakerControl

Processed Data

Processed Data

Data

System Context Diagram

Button DW

Control

Backlight

Screen

Speaker

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

Button A inputButton B inputButton C inputButton D input

Light

Display

Sound

System Context Diagram – Event List

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

Input/Output Event Description

Button A input 디지털 시계에 A 버튼을 입력 받습니다.

Button B input 디지털 시계에 B 버튼을 입력 받습니다.

Button C input 디지털 시계에 C 버튼을 입력 받습니다.

Button D input 디지털 시계에 D 버튼을 입력 받습니다.

Light 디지털 시계의 Backlight를 작동시킵니다.

Display 디지털 시계의 화면을 표시합니다.

Sound 디지털 시계의 알람을 울립니다.

Button A

Button B

Button C

Button D

DWControl

0

Light

Sound

Backlight

Screen

Speaker

Display

Digital Clock

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 0

Button A input

Button C input

Button D input

Button B input

Tick

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 0 – Data Dictionary

Input/Output Event Description Format / Type

Button A input 디지털 시계에 A 버튼을 입력 받습니다. True / False , Interrupt

Button B input 디지털 시계에 B 버튼을 입력 받습니다. True / False , Interrupt

Button C input 디지털 시계에 C 버튼을 입력 받습니다. True / False , Interrupt

Button D input 디지털 시계에 D 버튼을 입력 받습니다. True / False , Interrupt

Light 디지털 시계의 Backlight를 작동시킵니다. On/Off

Display 디지털 시계의 화면을 표시합니다.Timekeeping /

Alarm / Stopwatch

Sound 디지털 시계의 알람을 울립니다. On/Off

Tick

Button B Input

Button C Input

Button D Input

Display

Sound

Button Data

Update Alarm Data Get

StateData

LightButton A Input

Backlight & Screen & SpeakerControl

2

ButtonControl

1

Alarm Data Storage State Data Storage

GetAlarm Data

Update State Data

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 1

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 1 – Data Dictionary

Input/Output Event Description Format / Type

Alarm Data(Storage)

1.알람 indicator 정보(On/Off)2.설정된 알람 시간(char* ”hh.mm”)

3.알람 소리 작동 정보(On/Off)Structure / Periodic

State Data(Storage)

1.현재 동작중인 모드 정보2.Stop Watch 데이터

Structure / Periodic

Button Data 입력된 버튼 데이터 저장 Char * / Interrupt

Update Alarm Data 알람 데이터 업데이트 Event / Interrupt

Get Alarm Data 알람 데이터 저장소에서 데이터를 가져옴 Event / Periodic

Update State Data 스테이트 데이터 업데이트 Event / Interrupt

Get State Data 스테이트 데이터 저장소에서 데이터를 가져옴 Event / Periodic

Button B Input

Button C Input

Button D Input

Button Data

Button A Input

ButtonControl

1

Button AInterface

Button BInterface

Button CInterface

Button DInterface

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 2

Tick

Sound

Main Control

2.2Button Data

BacklightControl

2.1

SpeakerControl

2.3

UpdateAlarm data

GetStatedata

Alarm Data Storage

State Data Storage

GetAlarmdata

UpdateState data

BacklightInterface

2.4

SpeakerInterface

2.6

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 2

Tick

Light

Display command

Light Command

Sound Command

ScreenInterface

2.5

Display

Button DataAlarm Data

Button DataAlarm Data

Tick

Tick

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 3 Backlight Controller

BacklightController

2.1.1

Tick

Backlight On2.1.3

Idle2.1.2

Button DataAlarm Data

LightCommand

LightCommand

Enable

Disable

Enable

Disable

Tick

Mode Change2.2.13

AlarmIndicator2.2.12

Time Keeping

Unit Change2.2.4

Add Value2.2.14

StopWatchRun2.2.6

Button Data

Alarm Data Storage

State Data Storage

Tick

Trigger

Trigger

Trigger

Trigger

TriggerTrigger

MainController

2.2.1

EnableSystem Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 3 Main ControllerTime

Keeping Mode2.2.2

Display Command

Display Command

Time Keeping

Set 2.2.3

Display Command

Display Command

StopWatchPause2.2.8

StopWatch

Laptime2.2.7

StopWatch

Initialize2.2.5

Alarm Set

2.2.10

Alarm Mode2.2.9

Alarm Unit

Change2.2.11

Trigger

Display Command

Display Command

Display Command

Display Command

Display Command

Display Command

Display Command

Display Command

Display Command

Trigger

Trigger

Trigger

Trigger

Trigger

Alarm Data

Button Data

Disable

UpdateAlarm data

GetAlarmdata

GetStatedata

UpdateStatedata

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 3 Speaker Controller

SpeakerController

2.3.1

Tick

Alarm Off2.3.2

Alarm Ringing2.3.4

Alarm Ready2.3.3

Enable

Disable

Disable

Disable

Enable

Enable

Sound Command

Sound Command

Sound Command

Button DataAlarm Data

Tick

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 4 – Backlight State Transition Diagram

Tick[Button ‘D’] && !AS /Enable ‘BackLight On’Disable ‘Idle’

Tick (2 seconds)/Enable ‘Idle’Disable ‘BackLight On’

/Enable ‘Idle’

Idle

BacklightOn

AS : Alarm State (On/Off)

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 4 – Main State Transition Diagram

Stop Watch Mode

Time Keeping Mode

/Enable “Time Keeping Mode”

AlarmMode

Stop Watch Run

Stop Watch Pause

Tick [Button ‘A’] && !AS &&mode == timekeep &&timekeepmode == default/Disable “Time Keeping Mode”,Trigger “Time Keeping Set”

Tick [Button ‘C’] && !AS &&mode == timekeep &&timekeepmode == default /Disable “Time Keeping Mode”Trigger “Mode Change”

Tick [Button ‘C’] && !AS &&mode == stopwatch &&stopwatchmode == default /Trigger “Mode Change”

Tick[Button ‘C’] && !AS &&mode == alarm &&alarmmode == default/Enable “Time Keeping Mode”

Tick [Button ‘C’] && !AS && mode == timekeep &&timekeepmode == set &&/Trigger “Time Keeping Unit Change”

Time Keeping

unit change

Time Keeping Set mode

Tick [Button ‘A’] && !AS &&mode == timekeep &&timekeepmode == set/Enable “Time Keeping Mode”

mode == timekeep && !AS &&timekeepmode == set &&/Trigger “Time Keeping Set”

Tick [Button ‘B’] && !AS &&mode == timekeep &&timekeepmode == set &&timekeepunit != none/Trigger “Add Value”

mode == timekeep && !AS &&timekeepmode == set &&timekeepunit != none/Trigger “Time Keeping Set”

Tick [Button ‘B’] && !AS &&mode == stopwatch &&stopwatchmode == default/Trigger “Stop Watch Run”

Tick [Button ‘B’] && !AS &&mode == stopwatch &&stopwatchmode == run/Trigger “Stop Watch Pause”

Tick [Button ‘B’] && !AS && mode == stopwatch &&stopwatchmode == pause/Trigger “Stop Watch Run”

Tick [Button ‘A’] && !AS && mode == stopwatch &&stopwatchmode == pause/Trigger “Stop Watch Initialize”

Stop Watch

Laptime

Tick [Button ‘A’] && !AS &&mode == stopwatch &&stopwatchmode == run/Trigger “Stop Watch Laptime”

Tick [Button ‘B’] && !AS && mode == stopwatch &&stopwatchmode == laptime/Trigger “Stop Watch Run”

Tick [Button ‘A’] && !AS &&mode == stopwatch &&stopwatchmode == laptime/Trigger “Stop Watch Laptime Renew”

AlarmSet Mode

Add Value

AlarmUnit

ChangeAlarm

Indicator

Tick [Button ‘A’] && !AS &&mode == alarm &&alarmmode == default/Trigger “Alarm Set”

Tick [Button ‘A’] && !AS && mode == alarm &&alarmmode == set/Trigger “Alarm Mode”

Tick [Button ‘B’] && !AS &&mode == alarm &&alarmmode == set &&alarmkeepunit != none/Trigger “Add Value”

mode == alarm && !AS &&alarmmode == set &&alarmkeepunit != none/Trigger “Alarm Set”

Tick [Button ‘B’] && !AS &&mode == alarm &&alarmmode == default /Trigger “Alarm Indicator”

mode == alarm && !AS &&alarmmode == default /Trigger “Alarm Mode”

Tick [Button ‘C’] && !AS && mode == alarm &&alarmmode == set &&/Trigger “Alarm Unit Change”

mode == alarm && !AS &&alarmmode == unitchange/Trigger “Alarm Set Mode”

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD Level 4 – Speaker State Transition Diagram

Alarm Off

AlarmRinging

/Enable ‘Alarm Off’

CT== AT/Disable ‘Alarm Ready’Enable ‘Alarm Ringing’

Tick [(5 seconds) || Button (‘A’ || ‘B’ || ‘C’ || ‘D’)]/Disable ‘Alarm Ringing’Enable ‘Alarm Ready’

AlarmReady

AI (ON/OFF) : Alarm Indicator CT : Current TimeAT : Alarm time

Tick [AI == ON]/Disable ‘Alarm Off’Enable ‘Alarm Ready’

Tick [AI == OFF]/Disable ‘Alarm Ready’Enable ‘Alarm Off’

System Context Diagram

DFD Level 0

DFD Level 1

DFD Level 2

DFD Level 3

DFD Level 4

DFD

DFD

Alarm DataButton Data

Alarm DataButton Data