Skip to content

Instantly share code, notes, and snippets.

Board 4.2.2 chip STM32F103
Install debian 13 with xfce desktop
sudo apt-get update && sudo apt-get install git -y
cd ~ && git clone https://github.com/dw-0/kiauh.git
./kiauh/kiauh.sh
Using menù install:
1. Klipper
strict digraph {
#rankdir="LR"
subgraph cluster_CA1B {
label="CA";
subgraph cluster_CA1B {
label="CA1B";
/interface wireless
set [ find default-name=wlan1 ] antenna-gain=3 country=italy disabled=no \
installation=indoor mode=ap-bridge ssid=zen.myssid.2g
/interface wireless security-profiles
set [ find default=yes ] authentication-types=wpa2-psk eap-methods="" mode=\
dynamic-keys supplicant-identity=MikroTik wpa2-pre-shared-key=aSuperPASS
<?php
$campanelli=[];
for($i=1;$i<=1024;$i++){
$campanelli[$i]=$i;
}
$verso=1;
$i=1;
while (daSuonare($campanelli)>1) {
$campanelli[$i]='*';
echo "\r\n";
<?php
namespace MyBundle\Admin;
use Sonata\AdminBundle\Admin\Admin;
use Sonata\AdminBundle\Datagrid\ListMapper;
use Sonata\AdminBundle\Datagrid\DatagridMapper;
use Sonata\AdminBundle\Form\FormMapper;
use Sonata\AdminBundle\Show\ShowMapper;
use FOS\UserBundle\Model\UserManagerInterface;
<?php
namespace MyBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Knp\DoctrineBehaviors\Model as ORMBehaviors;
use Symfony\Component\HttpFoundation\File\File;
use Symfony\Component\Validator\Constraints as Assert;
use Vich\UploaderBundle\Mapping\Annotation as Vich;
vich_uploader:
db_driver: orm
mappings:
event_logo:
uri_prefix: /images/events
upload_destination: %kernel.root_dir%/../web/images/events
namer: vich_uploader.namer_uniqid
delete_on_update: false
delete_on_remove: true
---- download action -----
$session = new Session();
$session->set('downloadPercent',0);
$filesize = filesize($filePath);
$handle = fopen($filePath, 'rb');
header( 'Content-Disposition: attachment; filename="' .$fallbackFilename . '"' );
header( 'Pragma: no-cache' );
@vittore
vittore / 0_reuse_code.js
Last active August 29, 2015 14:06
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
<?php
use Idephix\Idephix;
use Idephix\Extension\Deploy\Deploy;
use Idephix\Extension\PHPUnit\PHPUnit;
use Idephix\SSH\SshClient;
$localBaseDir = __DIR__;
$sshParams = array(