B4R Tutorials

B4R PIR (Passive Infrared Sensor) Example

Thanks to Erel for this great product !! (again)

Here's a PIR example (presence detection) with Arduino and B4R; the PIR sensor is the PIR HC-SR501...
 

BLE (HM-10 module) - Broadcasting a single byte



In this example I'm using a BLE shield to broadcast the state of a connected button.

The byte is sent as part of...
 

Attachments

  • B4A_BLE_ButtonState.zip
    7.9 KB · Views: 1,612
  • B4i_BLE_ButtonState.zip
    2.9 KB · Views: 1,103

Analog Read Example using XBee Mesh Network

Attachments

  • B4RHowToTMP36XBee.zip
    4 KB · Views: 689

Arduino + Raspberry Pi



In this tutorial we will create a currency converter solution that shows the conversion from USD to other currencies on...
 

Attachments

  • B4J_CurrencyConverter.zip
    1.5 KB · Views: 1,190
Last edited:

B4RHelp program

I've hacked my already hacky B4AHelp program to give tidier results when looking at B4R Xml files.

EDIT: Updated to v1.1 to overcome a change in the Xml format that I just noticed.
 

Attachments

  • B4RHelp1.1.zip
    75.8 KB · Views: 809
Last edited:

Analog Read Example using MQTT

Attachments

  • B4RHowToTMP36MQTT.zip
    4.5 KB · Views: 907
Last edited:

Analog Read Example using Ethernet

Hi,

based on previous Analog Read Example extended the solution by using the Arduino Ethernet Shield to send temperature data to B4J server and receive confirmation.
Full project (with...
 

Attachments

  • B4RHowToTMP36Ethernet.zip
    4.6 KB · Views: 897

Data types

The following data types are available in B4R:

Numeric types:

Byte: 0 - 255
Int (2 bytes): -32768 - 32768. Similar to Short type in other B4X tools.
UInt (2 bytes): 0 - 65535.
Long (4 bytes)...
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…