Tuesday, June 09, 2015

ZedBoard button bit assignments

Future self,

Here are the bit assignments for the five momentary switches on the ZedBoard, as found by experimentation, for your future reference should you ever wish to use them w/GPIO again:

#define BUTTON_CENTER 0x01
#define BUTTON_DOWN   0x02
#define BUTTON_LEFT   0x04
#define BUTTON_RIGHT  0x08
#define BUTTON_UP     0x10

How to undo (almost) anything with Git

via GitHub.com:

https://github.com/blog/2019-how-to-undo-almost-anything-with-git

Sunday, May 31, 2015

Detours

This evening I put together an app using an Adafruit PIR (motion) sensor on Win10 for IoT on Raspberry Pi 2. It almost worked the first time, but edge detection in the ValueChanged event on GpioPin gets its value inverted at times. Turns out it's a known issue. My workaround: in the event handler use sender.Read() to get the pin value.

I'll be glad to see this fixed.

Oh, also--the motion sensor prefers 5V over 3.3V. Just sayin'.

Sunday, May 03, 2015

Enable "Developer Mode" on Windows 10 build 10074

Here's the trick as currently documented here, as the method to do so through the settings window do not work (for me, Settings, For Developers crashes the settings application):


For Windows 10 desktop
Use gpedit.msc to set the group policies to enable your device, unless you have Windows 10 Insider Preview Home Edition. If you do have Home Edition, you need to use regedit or PowerShell commands to set the registry keys directly to enable your device.
Dn706236.wedge(en-us,WIN.10).gifUse gpedit to enable your device
  1. Open a cmd prompt with administrator privileges.
  2. Run Gpedit.msc.
  3. Go to Local Computer Policy > Computer Configuration > Administrative Templates > Windows Components > App Package Deployment
  4. Edit the policies to enable the following:
    • Allow all trusted apps to install (Enables your device for sideloading apps)
    • Allows development of Windows Store apps and installing them from an integrated development environment (IDE) (Enables your device for development from Visual Studio)
  5. Reboot your machine.


Other methods to do so using regedit and PowerShell are found at the same link.

Monday, April 06, 2015

Upping Raspberry Pi 2's power to the USB ports

Interesting post on upping the Raspberry Pi 2's power to the USB ports. Out of the box the USB peripherals are limited to 600mA.

http://hackaday.com/2015/04/06/more-power-for-raspberry-pi-usb-ports/

Friday, April 03, 2015

Raspberry Pi, Quite Exciting

As I write this i am installing an operating system image on the microSD card of a Raspberry Pi that just arrived. I'm rather surprised at the level of excitement that I feel waiting for it to complete.

Unpacking the Pi reminds me of days long ago when our Atari 800 arrived and shortly thereafter came BASIC, PEEK, POKE, and some 6502 assembler. Yes, 8 KB of RAM, that was living high on the hog. I later parlayed my meager 6502 experience into building a graphical supply-side economics demonstration on the Apple II in high school. Those were the days. (Today, my work machine has 16 GB of RAM--2 million times as much--mostly taken up by web browser programs....)

I expect in coming weeks, as I find time, I'll perform amazing feats such as making an LED light up (no code!) and making an LED flash (a little Python code!) and then doing the same in C++ (okay, where is the right header file?!).

How far will this go? Multiple LEDs of different colors? Multiple concurrent LEDs flash patterns? Wait, can I use the Boost libraries? I bet I can. :) Only time will tell.