Rik's Ramblings

Tuesday, August 23, 2016

mars lagrange point L2

it occurs to me that the Mars L2 Lagrange is the ideal spot to stick a manned mission to mars while they're preparing to descend to the surface.

  • http://www.marspedia.org/index.php?title=Lagrangian_point

It's not a geosynchronous location, but what it does provide is a spot in the 'shadow' of Mars, so should be protected from solar winds and flares.

not sure why I've never heard this mentioned.

of course, i'm assuming the Mars L2 doesn't lag behind mars too far


Sunday, August 21, 2016

Gas station fail

My teens first attempt at filling the car with gas today.

It was a bit like this:



Play on YouTube

   

Saturday, August 20, 2016

Nasty 'Crypto' Outbreak Infects More Than 100 in Arizona

In case anyone is still under the impression that hand sanitizer is a good idea.  Another example of how you're better off with soap and water.


The highly contagious parasite is difficult to get rid of because chlorine doesn't always kill it, according to the Mayo Clinic. Alcohol-based hand sanitizer isn't effective against it, so washing hands with soap and water is considered the best prevention.

And note, there's no need for "anti-microbial" soap. We don't need to be doing selective breeding of our microbes.


They are a cute looking little blighter though ain't they!


Tuesday, August 16, 2016

Pentagon cracks down on Pokémon Go

No such thing as new news!  Pretty similar to the story in the 1990's when they banned Furby's!


... a Pentagon source said that the Defense Department has banned the playing of the mobile game app in its facilities as it is feared it could help foreign spying





Monday, August 08, 2016

Tessel coding

Like I said, I have been playing with my Tessel. Here's some code I wrote to mess with the GPIO port that sits atop the Tessel.

Here's what the GPIO connector looks like.



Click for fullsize image.

The pins labels can be seen in the silkscreen: GPIO - G3, G2, and G1 from the bottom right. Power - GND and 3.3V at the bottom left.


Note in the code below that there is a special tessel module, included via node (require("tessel")). Thisallows you to interact with the GPIO on the Tessel.

Here I use the GPIO property (tessel.port['GPIO']) to access G1, G2 and G3.

(function(){
 "use strict";


 var tessel = require("tessel");
 var gpio = tessel.port['GPIO'];


 var Button = require("../tessel/button");
 var Led = require("../tessel/led");


 var led = Led.create(gpio.pin['G2']);
 var flasher = Led.createFlasher(led);

 var leftBtn = Button.create(gpio.pin['G1'], ["down", "up"]);
 var rightBtn = Button.create(gpio.pin['G3'], ["up", "down"]);

 leftBtn.onChange = function(evt){
  console.log("left button: ", evt.detail);
  if ("down" === evt.detail) {
   console.log("Do something with left button...");
  }
 };

 leftBtn.listen();


 rightBtn.onChange = function(evt){
  console.log("right button: ", evt.detail);
  if ("down" === evt.detail){
   flasher.fast();
  }
  else {
   flasher.slow();
  }
 };

 rightBtn.listen();


})();




I built a daughter board to plug into the GPIO connector. The board contains two buttons, one of the buttons has an LED built into it.





Here are the two other modules I that this one includes, just for reference. They are actually the ones that do all the real work.


Look at all that beautiful Javascript, being used to control a microcontroller. All is well with the world! Of course, I'm not sure how long the code will execute before it generates some kind of memory fault!


Labels: ,

Saturday, August 06, 2016

Finally, fun with my Tessel!

I think it's about two years since I bought these Tessel boards.
- https://tessel.io

If you're not familiar, Tessel are microcontroller boards. They're similar in size to an Arduino, and have the GPIO connectivity you'd expect from a micro.

In addition to the generic GPIO connector, the Tessel has four ports that take the Tessel "Modules" - equivalent to an Arduino "shield". Because there are 4 ports, you can plug-and-play multiple Modules without issues of IO conflict (which is a problem with Arduino on occasion).

Also, USB and Wi-Fi are built in. Some peripherals connect to the Tessel via USB.


But I saved the best part until last! The Tessel is programmed in JavaScript.

After sitting in my box of microcontrollers for all that time, I finally pulled one out last week and got around to programming it.

It's such a pleasure to write code for embedded in JavaScript, though I'm sure there are Arduino lovers out there who just got a shiver down their spine :-)



Labels: , ,

Thursday, August 04, 2016

Time to rethink mandatory password changes | Federal Trade Commission

https://www.ftc.gov/news-events/blogs/techftc/2016/03/time-rethink-mandatory-password-changes

--