Skip to content

Instantly share code, notes, and snippets.

import Data.List
lineBreak :: String -> String
lineBreak = joinBrokenLines . joinWordsInBrokenLines . brokenLines . words
brokenLines :: [String] -> [[String]]
brokenLines [] = []
brokenLines wordList = brokenLine : brokenLines remainingWords
where (brokenLine, remainingWords) = splitAt (brokenLineWordCount wordList) wordList
@infinity0
infinity0 / ambient.c
Created August 25, 2017 18:43
Set ambient capabilities
/*
* Test program for the ambient capabilities
*
* You need to install libcap-ng-dev first, then compile using:
* $ gcc -lcap-ng -o ambient ambient.c && sudo setcap cap_setpcap,cap_net_raw,cap_net_admin,cap_sys_nice+eip ambient
*
* To get a shell with additional caps that can be inherited do:
*
* ./ambient /bin/bash
*/
module corescore_emitter_uart
#(
parameter clk_freq_hz = 0,
parameter baud_rate = 57600)
(
input wire i_clk,
input wire i_rst,
input wire [7:0] i_data,
input wire i_valid,
output reg o_ready,