Monday, September 24, 2018

Lenovo Yoga

When the touch screen cracks the pointer goes nuts.

xinput disable device

Wednesday, September 12, 2018

Current Sensor

30A New Range Current Sensor Module Board For ACS712

Descrition:

The current sensor chips: ACS712ELC-30A
The module can measure the positive and negative 30 amps, corresponding to the analog output 66mV / A
Pin 5V power supply, on-board power indicator
Using gold plated circuit boards
No test current through the output voltage is VCC / 2
Size: 31 x 13mm


This will hook straight to the ADC GPIOs in the ESP32. 

ESP8266 220V 10A Network Relay WIFI Module.
I have two of these. 

https://ucexperiment.wordpress.com/2016/12/18/yunshan-esp8266-250v-15a-acdc-network-wifi-relay-module/ 

Leveling up with openHAB

The level sensor project has worked and is connected (USB) to a Raspberry Pi which will form the hub.

I need to work out how serial communicate with the Pi so as to be able to hand data traffic to the Pi.

I am using Android devices to get access to the www. This means that I cant get the Pi to access the intranet and apt-get simultaneously. The simplest way to solve this seems to be to use a USB Internet dongle plugged into the router.

The Raspberry Pi in the lighting / power control role is overkill for the job. It needs to be replaced by a ESP32 wirelessly controlled by the single Raspberry Pi.

It would probably be handy to have a monitor to hook directly to the Pi but I havent tried the full range of headless operation. I have a laptop which has a good screen but a knackered keyboard. It might work well to buy a driver board for it and set it up as a low profile monitor.

Display B156XTN02.0 - Ordered. Fleabay.

Thursday, September 6, 2018

Arduino "Hello World"

Well not quite. I did a Morse Code snippet instead.


[code]
/*
SOS

Blinks the On Board LED
Prints out the "Word" on the Serial Port

  modified 6 September 2018
  by Mark Bolton

*/

int var = 0;

void setup() {
  
 Serial.begin(9600);                                         // initialize BAUD 9600 bits per second:
 pinMode(LED_BUILTIN, OUTPUT);          // initialize digital pin LED_BUILTIN as an output.
}

void loop() {

  var = 0;                                                           // loop 3 times
  while(var < 3){

  digitalWrite(LED_BUILTIN, HIGH);           // turn the LED on "DIT")
  delay(100);                        // wait
  digitalWrite(LED_BUILTIN, LOW);           // turn the LED off "SPACE"
  delay(200);
  Serial.print("DIT  ");                                     //Print the Character
  var++;
  }
    var = 0;                                                        // loop 3 times
  while(var < 3){
  var++;
  digitalWrite(LED_BUILTIN, HIGH);           // turn the LED on "DAH")
  delay(400);                                                     // wait
  digitalWrite(LED_BUILTIN, LOW);            // turn the LED off "SPACE"
  delay(200);                                                     // wait
  Serial.print("DAH  ");
  }
    var = 0;                                                        // loop 3 times
  while(var < 3){
  var++;
  digitalWrite(LED_BUILTIN, HIGH);            // turn the LED on "DIT")
  delay(100);                                                     // wait
  digitalWrite(LED_BUILTIN, LOW);            // turn the LED off "SPACE"
  delay(200);                                                     // wait
  Serial.print("DIT  ");
  }

  {
  digitalWrite(LED_BUILTIN, LOW);           // turn the LED off "END WORD"
  delay(600);                                                   // wait
  Serial.println("");
  }
}
[/code]