Microposts

  • Light wall panel prototype

    prototype led lit acrylic panel

    Prototype almost assembled! Need to add the touch sensors and work on a better way to secure it– I’m considering just welding the pieces since that seems to work well enough.

  • The newest Known release had a series of database upgrade SQL files, and these apparently had syntax errors! I was able to fix these and use them to “repair” my database. I finally got my entries recovered!

    …export/import failed, but that’s a new problem I can tackle ;]

    Going to make a PR, but also had my confidence shaken a little bit… wanted this to be a hands off blog, but maybe I should use something a bit more “known” :P

  • Still can’t seem to recover my old Known database. I either get schema errors or Known thinks it’s an un-setup instance (depending on version I try to use). My guess is that it was somehow corrupted during my last 0.9.1->0.9.2 upgrade… I had a backup of the db pre-upgrade, but cannot seem to locate it (and may have been on a harddrive I re-purposed…).

    Need to decide how much I want those posts in this new Known instance. The posts themselves are intact, and I’ve already extracted them as JSON (for potential use in anther webapp I was working on). Or, I can try and figure out what is wrong in my database, and how to fix the entries to have Known startup correctly.

  • Third times the charm for known??? However! I finally figured out my problems last time (and likely my irrecoverable database of old entries) was from too small buffers for fastcgi. Will need to see if I can recover them!

  • I’ve been trying to do some WebGL programming in Clojurescript. Decided to use three.js, but didn’t want to use the slightly outdated CLJSJS package. Luckily, after that release three.js implemented ES6 modules, allowing me to add it directly as an external lib.

    Downside: not compatible with “advanced” compile mode currently :/

    Hint: grab “three.module.js” from the tagged release archive

  • Just learned the Pixel allows one to flash their own keys, and do verified boot with own images. That is what I’ve wanted all along!

  • Using Enlive: trying to “change” a tag was giving me a headache: (do -> unwrap (wrap :newtag)) would then wrap any whitespace around the child tags.

    Finally bruteforced it by making a new transformation:

    (defn replace-tag
      ([tag] (replace-tag tag nil))
      ([tag attrs]
       #(map (fn [node] (array-map :tag tag :attrs attrs :content (:content node))) (html/as-nodes %))))
    

  • I had never heard of Zeppelin until the last interview I went to, and I have to say I’m impressed.

    While the focus is more on the Spark backend and “big data” applications, the notebook is very impressive and well done as well. I absolutely love the NVD3 integration with automatic plotting from SQL statements, and the dynamic input form generation.

    I think I will be very happy using it :3

  • I’ve also been reading up on AWS and have been wanting to give it a try, but I’m not happy with the billing situation: even for the the free tier they require a billing address and credit card number. The free tier only lasts a year, and [from what I can find] you are only able to setup a “warning” if you are exceeding the free tier usage..

    I would be more comfortable giving them billing info if I could setup hard cutoffs: eg “stop service if it exceeds the free tier” or even just “issue warning at x$, but cutoff service at y$”

    The reason being: I’ve read horror stories over the years of config errors or (even worse) an API key leaking out resulting in 100s or even 1000s of dollars of AWS service being billed. While I’ve also read the AWS team is very helpful to work through problems like this, I still find it unacceptable, especially in my hobbyist situation.

    That being said: my typical usage would likely be pennies a month, and it would be nice to have a more resilient mirror for my personal sites…

    “Don’t worry! For this tutorial we guide you through setup of a free tier account for you to try it out!” -> “please enter your credit card info” … nope. Luckily the tutorial and documentation is still good enough I can learn about it without an account, but damn Amazon…

    Apparently, this has been an open request since 2011? https://forums.aws.amazon.com/thread.jspa?threadID=58127&start=50&tstart=75

    However, I did find this: http://docs.aws.amazon.com/awsaccountbilling/latest/aboutv2/detailed-billing-reports.html

    So, ideally, I could setup an monitor instance that will do this for me.

    The more and more I read about this, the more I see the dichotomy evolving: hobbyists or personal or non-revenue generating tasks where the person doesn’t care if their service gets cutoff, and the infrastructure/revenue/business cases where costs can be absorbed, but uptime and availability is absolutely vital. The former would benefit from a cutoff, the later needs to adapt best practices, and a cutoff switch could absolutely cripple them.

    AWS seems to favor the latter, for lack of a nice solution.

  • So! My advisor wants all my slides (written in HTML with deck.js) as powerpoint (so he can use them in his presentations)…

    I could convince him to “screenshot and paste”, or meticulously recreate them as PPT… or! I can lookup the ODP format and write a conversion utility!

    …Whoo!

    clojure.xml uses the java SAXparser which is proving too brittle for my HTML files… However! Enlive/tagsoup appear to be popular and usable libraries. In particular, Enlive also functions as a templating engine: aside from being great for regurgitating another XML format, it also will be useful for my web applications! My pages have become complicated enough that embedding all those HTML snippets is becoming verbose, and I am NOT a fan of the JSP style pages… Templating means I could possibly dual purpose my “mockups”

    …and sadly further contemplation reminds me of layout. I can make assumptions about layout and make this a “one-off” tool, or perhaps I can use clojurescript, DOM selection in the browser, and info about the object (position, height/width) to make a more general tool?

  • For a reason I haven’t determined yet: Clojure java interop uses different syntax for static methods…

    (.member Instance args) ;; Normal object access
    (Classname/StaticMember args*) ;;static class access
    

    Both expand to the same form -> (. instance/class member [args]), so my guess would be the (.member ...) shorthand does some runtime reflection checking that is not possible with static methods? Hmmm…. will have check the source soon :P

  • One route to SQL injection is allowing arbitrary parameters that can end up in a request string. Proper parameter checking can help prevent this.

    Interestingly, compojure allows regex expressions when defining routes with parameters: (GET "/root/:id{[0-9]+}" [id] ...) will only match this route if the parameter matches the regular expression: in this case only numbers.

    However, clojure’s jdbc interface uses java.sql “PreparedStatement”s with their set{type}() methods for parameter filling, and the setString() method will escape any SQL characters in the string. Neat!

  • I found a reddit thread this morning that talked about doing non-profit web development in order to build a portfolio.

    Aside from a very important comment on not devaluing one’s work (something I’ve seen tweeted often from the web cartoonists I follow), there was also a fairly strong endorsement of freecodecamp.

    I decided to check it out as it is free, open source, and emphasizes doing practical work for non-profits.

    So far I’ve blown through the first 5-10 “hours” of the map, and I’m optimistic it will get better, but it’s not even “review” at this point.

    However! I did learn 2 new things!

    1. !important is the ultimate CSS override
    2. Bootstrap is almost entirely CSS based (I would have checked it out much earlier had I realized that).

    Hopefully this early stuff will make a good time-sink during down-time/breaks at work

  • I’ve known about it for a while (and cloned the repo for my system fonts), but fonts.google.com is just amazing!

    The web interface for it is fun as well! Playing around with font combos and weights. Then looking at the popularity broken down by region ;D

  • On my Chromebook: 4.8-rc1 doesn’t crash wifi, has audio over HDMI and USB3, and fixed USB with LPAE! YAY!.

    …and ac adapter module (bq24735) is not loading when not plugged in, again (which causes sbs-battery to not load, and battery monitors to not work). UGH!

    The patch I submitted should still be working… It’s reaching the initialization code that it shouldn’t touch le-sigh…

    In other news, removing the bq24725-charger as a power-supply in the DT for sbs-battery (sludge hammer attempt to get it to load w/o bq24735 module present) now makes it visible to the Cinnamon power applet? This was something I figured was a Cinnamon problem (as xfce4-power-manager would detect the battery properly), but maybe it’s a combination?

    Also this makes me happy: mount my external USB3 SSD, hdpartm -Tt yieldes 203 Mb/s read time!!! Whoo!

    Actually, I now think Cinnamon doesn’t sanitize or handle the ‘@’ in bq24735-charger’s path name (funny enough, this was also true in udev originally), as the power-manager doesn’t show the battery info when the bq24735 module is loaded at all (even when sbs-battery doesn’t have it listed as a dependent power-supply).

    Also, wifi does crash on my home network… There are bug reports that mwifiex is unstable in high throughput 5GHz (which would match my experience). However, exposing a 2.4 GHz AP and using that still results in crashes… grumble…

    Also, I’ve noticed weird behavior in my USB3 drive: when I was at work letting things compile, I would come back to the filesystem being marked read-only, and apparent communication errors. I’m using dm-crypt so the read-only and communication errors may be misleading, but appears the USB loses connection briefly and reassigns the drive as a new dummy drive under sdb (and hence why dm-crypt may freak out). I think this is power-saving related somehow? If I sit actively working I never witness this problem (and had it running much longer last night while I was actively using my chromebook).

    I think the WiFi problem may be related to MMC/SDHCI… The errors are related to timeouts waiting for interrupts, then an interrupt occurring when not waiting. I can’t seem to pin down the errors to anything mwifiex related (well, aside from not getting an interrupt through causing the firmware to get into an irrecoverable state…) 4.6 is when the problem started, and that is when they disabled UHS tuning for tegra124. There are a handful of commits related to timing as well… I’m patching to reenable UHS for tegra124 and seeing if it mitigates the problem (the Chromebook has become almost unusable at home…).

  • I’m continually and pleasantly surprised by how much a break/sleep and fresh eyes can help when trying to solve a problem!

  • My ODroid U3 has become my defacto build server: made a separate “debug” makepkg.conf for OpenJDK8. Easy enough to use for Firefox to figure out what’s segfaulting

    I can’t pinpoint exactly what is wrong with OpenJDK8, but it seems to be pthread and/or ld related. My previous lazy debugging attempt on Firefox/Thunderbird seemed to be a pthread problem as well. My suspicion is there’s an annoying bug in the newest glibc for ARM.

    And right after that: an update pushed that fixed Firefox!

  • Finally got motivated/irritated enough to change this theme’s font from a serif to sans-serif font. PHEW! (next up, actually making my own ;D)

  • Reversible Debugging Tools for C/C++ on Linux and Android

    Learned some new tricks!

  • cp -ax apparently doesn’t copy filesystem capabilities… evidenced by gnome-keyring-daemon not being able to set its IPC/”do not swap” permission on the process… (fixed by reinstalling the package).

  • Finally moved ALARM from the SD card to the eMMC on my Chromebook. It works! Now have 2x the read speed (with 8GB less space…)

    I resized the stateful filesystem from 25 GB to under 1GB, resized the partition, moved and resized the Kern/root-C partitions, set flags, then cp -ax‘d the root filesystem from the SD card.

    I had done a backup of the eMMC before doing any of this, and hopefully I can use that to boot ChromeOS if anything goes wrong (as it looks like I have some new bugs to play with on the 4.6/4.7 kernels…)

  • sketches from D&D

    Sketches from the last session of D&D

  • Upside, LWJGL2 works with OpenJDK7 and was easy to build on ARM. The migration guide to LWJGL3 looks simple enough, time to just get my hands dirty!

  • With Java being a possible “not quite” on my ARM machine, decided to go for SDL in the meantime. Initially thinking “time to hone those C++ skills” but then noticed Lua and Rust bindings exist for SDL. Hmmm, decisions decisions…

    Lua is a fun interpreted language with strong gaming ties, and has the venerable LuaJIT implementation. I’ve used it a little bit for configuring Awesome (my longtime tiling WM of choice), but not much else. The indexing scheme is weird, but interesting syntax nonetheless.

    Rust is something I’ve lazily followed but haven’t tried out yet. I love the idea of a memory safe concurrent compiled language, and I was mostly waiting for it to stabilize (apparently it had a major release sometime last year?). This would be a great chance to learn it! …but it’s not in the ALARM repos? Trying to compile the upstream Arch PKGBUILD, but I imagine I’m gonna hit some errors soon :c

    Rust fails because there are no arm snapshots to download and bootstrap with. There is a --enable-local-rust option, and armv7l rustc nightlies available through rustup, but this is beyond what I was willing to do at the moment :P

  • The Descent: “I wanna program games again! -> lwjgl looks awesome! -> ugh no ARM support, will have to compile myself and possibly patch -> ugh it only works on JRE 8 or newer (and OpenJDK 8 is segfaulting in ALARM) -> let’s try recompiling! -> Ugh, there’s a ton of new errors from using GCC 6.1.1 -> …okay, let’s edit and patch all these string literals… yay…”

    I started in a “compile -> edit errored files -> recompile” cycle, and finally am giving up and resorting to grep’ing and sed’ing it to death (and hoping I don’t break anything)

    Successfully built! …still segfaults. Added the PKGBUILD option to include debug symbols and narrowed it down to the function that is segfaults in (CppInterpreter::main_loop), but had to suspend debugging to work on more pressing matters.

    This https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=210024 prompted me to try the newest tagged jdk8u (112-b01). The good news, a recursive patch from the edits I made mostly applied, and running “java” with no args no longer segfaults!!

    …the bad news is anything else still segfaults :/ applying some other patches that might address it

    Debug symbols and gdb stacktraces, and log files place it as a GC allocation failure… fudge, I am probably out of my depth here. Gonna try one last thing (full debug build, hopefully with the full symbols, and valgrind can help me trace down what is going wrong).

    Also just noticed configure complaining about ignoring environmental CFLAGS and friends!! (and probably why my last debug build didn’t work, I was worried it was because I didn’t make clean first… grumble). Might have to patch upstream to use --with-extra-{c,cxx,ld}flags?

  • Ugh, Known is not sanitizing encoded tags (even with CMark using a code block). Renders on own, but in a post, interprets them as tags…

    Yay! Go bug reports! https://github.com/idno/Known/issues/1024

  • Grrr, trying to build libchromiumcontent or even Chromium gets stuck on building webrtc (python script failing, no good error messages…)

    Not sure what the specific error was, but adding use_system_protoc fixed the problem (after making sure to install python2-protobuf).

    WHOOPS! I had my CFLAGS set with -mfpu=neon-vfpv4 for my cortex-a15 systems when the U3 is a cortex-a9 (only vfpv3).

    This caused a binary that was built to fail, but may have been a reason why the stock protobuf was failing…

  • Become a Peer Reviewer for Citizen Scientist - Hackaday

    This popped up in my RSS feed, and sounds like a lot of fun! There are a good handful of projects I think are interesting and/or I’m actually qualified to review.

    There is even a project to create an Open-Access publishing platform (replacement for SSRN, which I never heard of, but I like this idea).

  • Trying to build Chromium, my RPi3 proved insufficient (out of memory and freezing). My old Odroid U3 is blowing it away!! (want XU4 now)

    Even the external USB drive seems faster and bogging the system down less!

  • Firefox/Thunderbird crashing (weird pthread error in libxul…). No time for debug builds to figure it out, so switching to chromium atm…

    And ugh! Evolution is better looking and supports my two-factor authentication (no more app passwords). I wasn’t really attached to Thunderbird though–just wanted to avoid as many Gnome dependencies as I could.

    But, Chromium is so much snappier! This is what I didn’t want to find out… I used Firefox mainly for idealistic reasons (non-profit Mozilla who fights for open web and against DRM and open codecs, etc versus Google, who “does no evil” but is just so Google focused)… but they also have Zotero which I used extensively…

    We’ll see if I get the time to build a debug version of Firefox to trace the segfault down, but will be interesting to see if I stick with Chromium even after that…

    …here’s hoping for Servo sometime soon?

    First Chromium annoyance though: “file://” urls are automatically blocked in XMLHttpRequests, which breaks my citeproc-js script when viewing slides locally! UGH!

  • Netflix on my Raspberry Pi!!! …sortof

    Netflix running on a Raspberry Pi3

    By “…sortof” I mean it’s super choppy and sound doesn’t work :P

    I just grabbed the full chrome dir from my ChromeBook. However, I needed to compile their sound server (which is probably why audio doesn’t work…), and the libdbus version it wanted was old and not included in the system libdbus… So I just grabbed theirs! Yay for LD_LIBRARY_PATH!!!

    Hulu doesn’t work, complains flash version is too old (but honestly don’t care too much, and if I wanted Hulu I’m sure pepperflash from AUR would work…)

    Just realized this was from my Tegra based Chromebook (full OpenGL, which were the errors from terminal).

    Maybe if I find an image from a Samsung or other OpenGLES based Chromebook, that version might work better…

  • LiFePO4wered/Pi • Hackaday.io

    Definitely important to my project, where I want to power a RPi 3 by Li-polymer, but the adafruit boost converter I grabbed is rated for 1A@5V, but can handle 2A.

    What I love about the adafruit boost board is it has a 3/5V pin! This is [supposed] to use the 5V from USB when plugged in/charging, but 3.7V direct from battery when not.

    Hopefully the 3.7V from battery will be enough, and the battery will provide the current needed.

    I mean… It should right? If the battery can provide a lower voltage and be boosted to higher voltage with “enough” current, the current straight from the battery should be higher… Will have to check the datasheet :P

  • aivi & surasshu - Lonely Rolling Star (Missing You) by Aivi Tran

    This has been my new “writing song” lately.

    This is a cover of one of my favorite Katamari Damacy songs, and by one of my new favorite artists, Aivi and Surasshu (they do Steven Universe stuff!).

    …it makes me so happy :3

    Sidenote: they sell the rest of the album on bandcamp! I’ll definitely be purchasing it (DRM free copy I buy directly from an artist who gets to name their [minimum] price? What’s not to love!).

  • Yay! Newest DAVdroid fixed http/2 support! Finally can use my DAV server for contacts/calendars on my phone!

  • DIY Bluetooth Gamepad Mod (Arduino PS2 Controller Hack Part 2) - YouTube

    I have been trying to get my DualShock 3 to work over bluetooth for years. It works great over USB, but bluetooth always required a special patched bluetooth stack, a dedicated bluetooth dongle, etc… I was excited to see they recently released a new version of bluez with a plugin for the SixAxis advertising “out of box” compatability! But, I still cannot get it to work… Le sigh.

    I contemplated ripping it apart and sticking my own bluetooth module in place. However, the DS3 is a densely populated PCB… Le sigh again.

    However… I have all the pieces to do this to one of my old PS2 controllers… muahaha.

    Lastly! Super intrigued by the guy using an x-acto blade screwed to his soldering iron to cut away plastic. Just the tip I needed for my next project I’ve been planning ;D

    (Also, I usually HATE watching videos and get frustrated when people don’t release a write-up for me to read instead, but this one was fast, to the point, and amusing!).

  • Sigh, grabbing the ARM version of libwidevine.so from my Chromebook did not get me Netflix on my rpi :c no handy error messages either

  • There has to be a document authoring approach that everyone is able to use, but not a giant monolithic beast like Word/LibreOffice, right?

  • Desoldered a Raspberry Pi

    desoldered raspberry pi

    Used a canned air method to desolder some of the bulkier components off of the Pi. Solder wick and solder suckers only seem to work for me when fixing soldering mistakes. This worked much better (even though it sprayed flux and solder everywhere).

  • Finally tried Clojure … it is such a fun language! Reading the reference (esp transients) is giving me chills. Avoided for so long due to it being a JVM language, but love it!

  • Plexitube Owl Clock - Retro Tech Journal

    I love the look of Nixie tubes, and this looks like an awesome way to fake it!

    …I may have to see about getting access to a laser cutter myself…

  • Having trouble with DAVdroid and Baikal… 499 error, so not authenticating? No idea what is going wrong

  • Setup a known instance and added a new domain name! Very exciting. Just need to setup syndication and I’ll be all set :D

subscribe via RSS