Wednesday, September 22, 2010

Limited resources devices become not!!!

Break the phenomena... I am always hearing about the mobile devices or in general the devices that is used for embedded systems are all have the constraint "Limited resources". I believe this is not true any more. I can say that there is some mobile devices have a better resources than ordinary computing devices like PC.

Nvidia releases Tigra2: More than 1GHz Dual Core Processor "general purpose", Video decode/encode processors "viewing and capturing", Audio Processor "based on PortalPlayer which is existed in iPod", Image processor "stand-still capturing up to 12MP sensor", 2D/3D GPU, ARM-7 processor "for Chip Management", 32-bit 333MHz datarate LPDDR1 memory bus "resulting in 1.33GB/s of memory bandwidth"... some news tell: it is used in LG Optimus "Cheap phone around 1000LE"...WoW

Another competing alternative is POWERVR

Ref:
http://www.anandtech.com/show/2911
http://www.imgtec.com/powervr/powervr-graphics.asp

Saturday, September 18, 2010

DASH7

What is DASH7 Technology?


The DASH7 protocol is redefining wireless sensor networking and the internet of things with:

  • Multi-kilometer range and excellent penetration of walls, floors, and things made of water.
  • Extremely low power draw (measured in microwatts) and multi-year battery life
  • A maximum bitrate of 200kbps
  • Supports tag-to-tag or “multi-hop” communications, sensors, and public key encryption
  • Multi-channel architecture for real-time locating capability
  • Extremely low latency for tracking moving objects
  • Operation in the license-free and globally available 433 MHz spectrum
  • “Out of the box” interoperability using a single global frequency
  • The brand given to the ISO 18000-7 standard for active RFID
Will this Communication technology beat others? ZigBee and WiMax... who knows?

Wednesday, September 15, 2010

QA & QC

QA: is involved in the whole process and discusses improvement and development of the whole cycle to provide a product.
QC: is the process of detecting defects for the final products.

Wednesday, September 1, 2010

Mutex & Semaphore

Both are used for controlling the use of a shared resource.
- Mutex: is like a binary flag in the fashion of use and release.
- Semaphore: is a signaling counter, when finish using a resource, signal (increment) the semaphore so the resource can be used by the next task.

A problem can be happen when using Mutices, Priority Inversion, which is when a higher priority ready task cant run because a lower priority task is restricting using a resource usually by a mutex. which will lead to missing a deadline and the system to fail. A developer should consider this when using mutex. A solution to this problem is by using Priority Ceiling, that each resource has its own priority, when a task uses this resource, it is associated with the resource priority till it finishes. The priority of the resource equals the highest priority user plus one.

void TaskA(void)
{
...
SetTaskPriority(RES_X_PRIO);
// Access shared resource X.
SetTaskPriority(TASK_A_PRIO);
...
}

Ref:

Memory characteristics [1]

Type
Volatile?
Writeable?
Erase Size
Max Erase Cycles
Cost (per Byte)
Speed
SRAM
Yes
Yes
Byte
Unlimited
Expensive
Fast
DRAM
Yes
Yes
Byte
Unlimited
Moderate
Moderate
Masked ROM
No
No
n/a
n/a
Inexpensive
Fast
PROM
No
Once, with a device programmer
n/a
n/a
Moderate
Fast
EPROM
No
Yes, with a device programmer
Entire Chip
Limited (consult datasheet)
Moderate
Fast
EEPROM
No
Yes
Byte
Limited (consult datasheet)
Expensive
Fast to read, slow to erase/write
Flash
No
Yes
Sector
Limited (consult datasheet)
Moderate
(Cheap by Z)
Fast to read, slow to erase/write
NVRAM
No
Yes
Byte
Unlimited
Expensive (SRAM + battery)
Fast

[1] Barr, Michael. "Memory Types," Embedded Systems Programming, May 2001, pp. 103-104.

Volatile in C

When you declare a variable as a volatile, then you are telling the compiler that this variable may be changed by some external factor and do not optimize the code related to this variable.
Example:
int foo=0;
while (foo != 10)
//do sth

if this code is optimized, the compiler will make the loop always true because it seems it would not be changed through the code (while (true)).

Cases you need to declare a variable as Volatile:
  • Memory-mapped peripheral registers
  • Global variables modified by an interrupt service routine
  • Global variables accessed by multiple tasks within a multi-threaded application
More info at http://www.netrino.com/node/80