Simulation Results
Vivado behavioral simulation에서 확인한 기능별 결과입니다.
전체 파형

전체 testbench 구간에서 reset, normal cycle, green_count, emergency, night_mode와 두 신호등 출력을 함께 확인했습니다.
Green Time Limit

Country Road Green 상태인 S3에서만 green_count가 증가하고, GREEN_LIMIT에 도달하면 차량 감지가 유지되어도 S4로 이동했습니다.
Vehicle Removed Before Limit

S3에서 car_country = 0이 되면 제한값에 도달하지 않았더라도 S4로 이동했습니다.
Emergency Priority

일반 상태 S0–S4에서 emergency 입력이 들어오면 다음 clock edge에서 S5로 이동했습니다.
Night OFF Mode

night_mode = 1일 때 S6로 이동하고 Main Highway와 Country Road가 모두 OFF = 2'b11로 출력되었습니다.
Night Mode with Emergency

Night Mode 중 emergency 입력에 따라 S6 → S5로 이동하고, emergency가 종료된 뒤 night_mode가 유지되면 S5 → S6로 복귀했습니다.
Verification Summary
| Function | Expected Behavior | Result |
|---|---|---|
| Reset | S0 and default outputs | Pass |
| Normal Cycle | S0 → S1 → S2 → S3 → S4 → S0 | Pass |
| Green Limit | S3 exits at GREEN_LIMIT | Pass |
| Car Removed | S3 exits before limit | Pass |
| Emergency | Any normal state → S5 | Pass |
| Night OFF | S6 outputs OFF/OFF | Pass |
| Night + Emergency | S6 → S5 → S6 | Pass |