ICI Techno

ICI TechnoICI TechnoICI Techno

ICI Techno

ICI TechnoICI TechnoICI Techno
  • Home
  • psC Language
    • Sequential Execution
  • More
    • Home
    • psC Language
      • Sequential Execution
  • Sign In

  • My Account
  • Signed in as:

  • filler@godaddy.com


  • My Account
  • Sign out


Signed in as:

filler@godaddy.com

  • Home
  • psC Language
    • Sequential Execution

Account

  • My Account
  • Sign out

  • Sign In
  • My Account

Sequential Execution

All instructions execute in one-step

All instructions execute in one-step

All instructions execute in one-step

All instructions execute in one-step

All instructions execute in one-step

All instructions execute in one-step

The setup() and loop() function

Arduino setup() and loop() functions are supported. Here is a very simple example:

Control instructions

 As in C++, psC control instructions include if, switch, while, do...while, for, break, continue, call and return. Here is a counter:

Parallel integration

For added performance, you can take many instructions and execute them parallel in a single step. Instructions can be made parallel by simply by enclosing them in parentheses or braces. Here is an example:

Single step loop

In previous examples, the single-step loop was used to wait for events. Combined with parallel execution, it can be a powerful tool for implementing efficient sequential code. The next example computes the square root; it is a direct implementation of the C++ algorithm. Using parallel assignments and single-step loops makes the code as efficient as hand-coded VHDL code.

Functions

Obviously one cannot imagine sequential programming without functions.  The psC functions are like C++ functions, except they are declared using the keyword function and called using the keyword call. Execution is as in C++. Functions can also reference arrays (&). Here is an example.

Copyright © 2019-26 ICI Techno - All right reserved.

  • Home
  • Privacy polilcy

Powered by