Saturday, September 19, 2015
Simplified command line formats
The command line formats for launching Systems and Devices have been simplified by taking advantage of the new system.jar and device.jar files, respectively. See http://www.holobloc.com/doc/fbdk2/systest.htm#Remote and http://www.holobloc.com/doc/fbdk2/systest.htm#System for details.
FBDK 2.3 Release
A new release (FBDK 2.3, version 20150919) is now available. To facilitate reuse of the codebase on multiple platforms, this release encapsulates platform dependencies in "manifest" files contained in the corresponding
*.jar files, which now include fbrt.jar, editor.jar, system.jar and device.jar.
In order to obtain proper launching of this new configuration, you will need to replace your existing fbdk2.jar with the new version available at http://www.holobloc.com/fbdk2/. Updates of the other files will then occur upon launching the fbdk2.jar file.
Descriptions of the new features will be posted to this blog with links to corresponding pages of the online documentation.
Friday, June 5, 2015
Drag and Drop (DnD) Tagging
The latest (20150602) FBDK2 self-update now supports DnD tagging of FB instances in the Tagged Data Design Pattern. See the documentation at http://www.holobloc.com/doc/despats/tags/tags.htm#Tools for details.
Previous versions of the FBDK tried to support automatic application of tags under certain conditions, but this turned out to result in unanticipated and sometimes undesirable results.
Monday, June 1, 2015
RPi Test #6: Bit Toggling
In this example (GPIO_TEST6), at each press of a pushbutton the state of an LED is toggled from OFF to ON or vice versa.

xxx
- The Tagged Data and Local Multicast design patterns are reused from the previous example to simplify the system configuration.
- An instance of the E_F_TRIG function block (FB) type is used to detect the keypress by issuing an EO event when a falling edge of the button state (BUTTON.RD_1) occurs.
- The TRIGGER.EO event fires the OUTPUT.REQ event block to toggle the OUTPUT.OUT value, which is then passed to the LED.

xxx
Tuesday, May 26, 2015
RPi Test #5: Separation of Concerns
In the previous example, you may have noticed the beginning of "diagram clutter", where the I/O interface blocks were taking up significantly more space than the actual program logic. This problem can become severe with more complicated logic and a greater amount of I/O, such that it can become extremely difficult to even figure out what the logic is supposed to be doing.

As shown in the current example (GPIO_TEST5), we can solve this problem by applying the principle of Separation of Concerns:
- First, as shown below, we move all the I/O interface blocks into one or more Resources separate from the program logic (here the resource is named IO for obvious reasons).
- Then we add Local Multicast blocks to transmit inputs to and receive outputs from other Resources.
- The Tagged Data design pattern support in the FBDK helps to keep the use of Local Multicast channels consistent among Resources.

Now we add Local Multicast blocks to the LOGIC resource to receive data from inputs and transmit the results of the control logic to outputs. Notice the reduction of diagram clutter:
In the next example, we'll take advantage of this reduced clutter to make room for more complicated control logic.
Monday, May 25, 2015
RPi GPIO Test #4: Signal Inversion
In the previous example, a pushbutton was "soft wired" to an LED in such a way that the LED was ON when the pushbutton was up, and OFF when the pushbutton was down. This is the reverse of what you would usually expect, so in the present system configuration (GPIO_TEST4.sys), the signal is inverted using an instance of the FB_NOT function block type so that the LED is ON when the pushbutton is down.
RPi GPIO Test #3 : Soft Wiring
In this system configuration (
GPIO_TEST3), the GPIO "loopback" connection of the previous example is replaced with connections to real devices, which replace the Graphical User Interface (GUI) elements:- Pin 3 is configured as an output connected to an LED (the yellow button) in series with a 100 Ohm resistor to ground.
- Pin 5 is configured as an input with an internal pull-up resistor, connected to a normally open pushbutton (the green button) to ground.
- The value of the pushbutton input (
BUTTON.X) is passed to the LED output (LED.X) via the graphical connection, and theLEDblock is notified of the current pushbutton status by theBUTTON.CNF => LED.REQevent connection.
- When the button is up (open), the state of pin 5 is HIGH due to the internal pullup resistor on the input pin, and this is passed to the LED on pin 3 as an ON condition, as shown in the picture on the left below.
- When the button is down (closed), it pulls pin 5 LOW and this is passed to the LED on pin 3 as an OFF condition, as shown in the picture on the right below (the green button is held down with transparent tape in order to take the picture).
Subscribe to:
Posts (Atom)

