Yahoo Groups archive

AVR-Chat

Index last updated: 2026-04-28 22:41 UTC

Message

Simple Embedded Expression Evaluation

2012-11-25 by Chuck Hackett

I am looking for a simple expression evaluation routine for use in an AVR
embedded system.  My needs are simple:

- Binary logical operators: logical AND (&) and OR(|)
- Unary operator NOT(!)
- Parentheses
- Known (system) variables (T1, S1, etc.)

Expressions such as:
(T1 | S1) & (T2 | S2)

All values are logical (i.e.: True/False).

Later I might add logical functions but that's down the road.

Anyone have a favorite?
 
Cheers,

Chuck Hackett
"Good judgment comes from experience, experience comes from bad judgment"
7.5" gauge Union Pacific Northern (4-8-4) 844
http://www.whitetrout.net/Chuck

Attachments

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.