uCOS-ii cmd제어 관련 질문있습니다.

Hyeon9mak의 이미지

안녕하세요, 컴퓨터공학과 재학중인 학부생입니다.
임베디드 과목에서 uCOS-ii를 이용한 프로젝트를 진행중에 궁금한 점이 2가지 있습니다.

1. cmd 종료
cmd를 마우스 클릭으로 직접 종료시키는게 아니라면 정상적인 종료가 불가능한 상태인데
정확한 종료 코드가 궁금합니다. exit()를 이용하라는 이야기를 본 것 같은데, 실제 적용해보았으나
exit()로 제대로 종료되지 않았던 것 같습니다...

2. 2회 입력
cmd 창에서 테스트를 진행할 때, 간혹 Task간의 statement 이동에서 2회씩 입력을 해야
다음 Task로 이동하는 문제를 겪고 있습니다.
(e.g. priority 4 task OSTaskSuspend(OS_PRIO_SELF)를 시켰으나 바로 priority 5 task로 못넘어가고
다른 입력을 1회 더 진행해야 priority 5 task로 넘어감)
혹시 확실하게 1회 입력으로 바로 넘어갈 수 있도록 하는 방법이 있을까요?
(2회 입력이 발생하는 근본적 원인이 무엇인지..)
어느 때는 즉각적으로 잘, 어느 때는 2회입력으로 이동되다보니 나중에 일이 커질까봐 불안불안합니다..

uCOS-ii에 대해 잘 알지 못하니 제대로 질문을 한 것인지도 모르겠습니다 ㅎㅎ;
귀엽게 봐주시고 도움 주시면 감사하겠습니다...

라스코니의 이미지

아주 옛날에 책에 붙어 있는 플로피 디스크에 들어 있던 uCos 코드 돌려보고 분석해 보았던 기억이 나네요. 그때 저자하고도 이메일로 물어보고 했었는데...

1. 'cmd 종료'는 잘 모르겠습니다. embedded 특징상 종료 자체에 대해서 고민을 안해봤어요.

2. task 간 statement가 뭔지 잘 모르겠지만 설계하신 코드 구조를 모르니 답변 드리기 곤란하네요. 간단하게는 아마 2회 입력해야 넘어가도록 코드 설계가 되어 있을 거라 생각됩니다.

댓글 달기

Filtered HTML

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

BBCode

  • 텍스트에 BBCode 태그를 사용할 수 있습니다. URL은 자동으로 링크 됩니다.
  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param>
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.

Textile

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • You can use Textile markup to format text.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Markdown

  • 다음 태그를 이용하여 소스 코드 구문 강조를 할 수 있습니다: <code>, <blockcode>, <apache>, <applescript>, <autoconf>, <awk>, <bash>, <c>, <cpp>, <css>, <diff>, <drupal5>, <drupal6>, <gdb>, <html>, <html5>, <java>, <javascript>, <ldif>, <lua>, <make>, <mysql>, <perl>, <perl6>, <php>, <pgsql>, <proftpd>, <python>, <reg>, <spec>, <ruby>. 지원하는 태그 형식: <foo>, [foo].
  • Quick Tips:
    • Two or more spaces at a line's end = Line break
    • Double returns = Paragraph
    • *Single asterisks* or _single underscores_ = Emphasis
    • **Double** or __double__ = Strong
    • This is [a link](http://the.link.example.com "The optional title text")
    For complete details on the Markdown syntax, see the Markdown documentation and Markdown Extra documentation for tables, footnotes, and more.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 사용할 수 있는 HTML 태그: <p><div><span><br><a><em><strong><del><ins><b><i><u><s><pre><code><cite><blockquote><ul><ol><li><dl><dt><dd><table><tr><td><th><thead><tbody><h1><h2><h3><h4><h5><h6><img><embed><object><param><hr>

Plain text

  • HTML 태그를 사용할 수 없습니다.
  • web 주소와/이메일 주소를 클릭할 수 있는 링크로 자동으로 바꿉니다.
  • 줄과 단락은 자동으로 분리됩니다.
댓글 첨부 파일
이 댓글에 이미지나 파일을 업로드 합니다.
파일 크기는 8 MB보다 작아야 합니다.
허용할 파일 형식: txt pdf doc xls gif jpg jpeg mp3 png rar zip.
CAPTCHA
이것은 자동으로 스팸을 올리는 것을 막기 위해서 제공됩니다.