element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Arduino
  • Products
  • More
Arduino
Arduino Forum <STX> <ETX> character in Serial Arduino Communication
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Arduino to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 3 replies
  • Subscribers 391 subscribers
  • Views 3425 views
  • Users 0 members are here
  • ttl
  • ascii
  • serial
  • etx
  • stx
  • arduino
  • module
Related

<STX> <ETX> character in Serial Arduino Communication

Former Member
Former Member over 10 years ago

Hi to everyone,

 

I'm implementing a serial communication between Arduino Uno and a Non Invasive Blood Pressure Model (NIBScan NIBP OEM module). This module has a RS232 port and I've used a RS232 to TTL converter to wire the module to Arduino.

I must send serial commands to the Module this way:

      <STX>01;;D7<EXT>    => Start measuring

      <STX>18;;DF<EXT>  => Read status from slave.

 

The problem is that I don't know how to correctly send the "<STX>" (0x02)  and "<ETX>" (0x03) chars. I've tried this way:

     blood_pressure_board.print("\u000218;;DF\u0003");

    blood_pressure_board.print("<STX>18;;DF<ETX>");

but it doesn't work.

 

Besides, after booting, the module  has to send a message like this:

    <STX>S1;A0;C00;M00;P135345234;R087;T6890;;D9<ETX><CR>

but what I get into serial monitor of Arduino (setting 4800 baud rate how indicated into the guide) is:

Ë–X`1ƒ¶  fÌ;Mƒ¶µeË–µkÖ¬egÔ-k¶   È�  Û  Í´`Ã�9  Ö˜°jÌ�Á¶  3Ì�Mƒ¶ZgË–-k  Ë–X`˜;ÁMÁk˵j£    9Ë6¬˜°˜;ƒ¶ 3Ì�MÁ¶ YË–-«Ö¬Ù3Ë–íF    dÈ ;  fÚ°á

 

What am I getting wrong?

  • Sign in to reply
  • Cancel

Top Replies

  • gadget.iom
    gadget.iom over 10 years ago +1
    Try Serial.write(0x02);
  • clem57
    clem57 over 10 years ago +1
    void WriteDummyWeatherData(){ #define STX Serial.print(STX); Serial.print( " 11 06 2013 12:00=11.78" ); Serial.print(RS); Serial.print( " 11 06 2013 23:00=8.9" ); Serial.print(RS); Serial.print( " 11 07…
Parents
  • clem57
    0 clem57 over 10 years ago

    void WriteDummyWeatherData(){

    #define STX

      Serial.print(STX);

      Serial.print("11 06 2013 12:00=11.78");

      Serial.print(RS);

      Serial.print("11 06 2013 23:00=8.9");

      Serial.print(RS);

      Serial.print("11 07 2013 06:00=4.54");

      Serial.print(RS);

      Serial.print("11 07 2013 12:00=15.3");

      Serial.print(RS);

      Serial.print("11 07 2013 23:00=10.3");

      Serial.print(RS);

      Serial.print("11 21 2013 06:00=-2.33");

      Serial.print(ETX);

    }    replace blood_pressure_board for serial.

     

    From Arduino, C#, and Serial Interface - CodeProject

     

    Clem

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Reply
  • clem57
    0 clem57 over 10 years ago

    void WriteDummyWeatherData(){

    #define STX

      Serial.print(STX);

      Serial.print("11 06 2013 12:00=11.78");

      Serial.print(RS);

      Serial.print("11 06 2013 23:00=8.9");

      Serial.print(RS);

      Serial.print("11 07 2013 06:00=4.54");

      Serial.print(RS);

      Serial.print("11 07 2013 12:00=15.3");

      Serial.print(RS);

      Serial.print("11 07 2013 23:00=10.3");

      Serial.print(RS);

      Serial.print("11 21 2013 06:00=-2.33");

      Serial.print(ETX);

    }    replace blood_pressure_board for serial.

     

    From Arduino, C#, and Serial Interface - CodeProject

     

    Clem

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube