This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
* Configuration | |
*/ | |
// Le nom de ce fichier | |
$filename = "updater.php"; | |
// Le repertoire ou extraire la nouvelle version | |
$extractdir= "./"; | |
// Le repertoire ou sauvegarder l'ancienne version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd /tmp | |
wget https://dl.google.com/dl/android/studio/ide-zips/0.8.14/android-studio-ide-135.1538390-linux.zip | |
zip -r android-studio-ide-135.1538390-linux.zip . | |
idea-IC-135.1230/bin/idea.sh | |
rm -rf idea-IC-135.1230 | |
rm -f android-studio-ide-135.1538390-linux.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use Symfony\Component\Console\Output\BufferedOutput; | |
class InstallController extends BaseController { | |
public function index($user, $pass) | |
{ | |
//check trivial pour éviter les reset intenpestifs | |
//a vous d'implemnter votre propre méthode de verrification | |
if ($user != "MonUser" || $pass != "MonPass") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
deploy: | |
steps: | |
# Add SSH-Key to current box | |
# You have to generate an ssh key in wercker, add it to your github/bitbucket accoung | |
# Then you have to add the ssh key to your env vars in wercker | |
- leipert/add-ssh-key-gh-bb: | |
keyname: deploy_ssh | |
# Add bitbucket to known hosts, so they won't ask us whether we trust bitbucket (change this if using github) | |
# on your local machine use ssh-keyscan github.com >> thefingerprint to get it | |
- add-to-known_hosts: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Variables d'env (paths divers) | |
export APPPATH=$(pwd)/data # Le chemin vers votre module java a convertir | |
export J2OBJC=~/utils/j2objc-0.9.7 # Le chemin vers votre install de j2ObjC | |
# Convert tous les fichiers dans src/main/java | |
# Place l'export dans build/objc | |
# Ignore les fichiers commençant pas Android | |
# Cela permet de prefixer par Android/IOS les codes propres aux deux plateformes | |
cd $APPPATH | |
$J2OBJC/j2objc -use-arc -d build/objc -sourcepath src/main/java \ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php namespace Atrakeur\EnhancedModels; | |
use \stdClass; | |
abstract class EnhancedModel extends \Eloquent { | |
/***************************************** | |
* Act like toArray but generate stdClass objects on the current object. | |
*****************************************/ | |
public function toObject() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function multiply(int a, int b) : float { | |
return a * b; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Define the echo pin (receive the echo from the ultrasound) | |
#define SENSOR_ECHO_PIN 7 | |
//Define the trig pin (trigger the ultrasonic emitter) | |
#define SENSOR_TRIG_PIN 8 | |
//On some sort of sensors, echo and trig can be on the same pin | |
//Precalculate some values | |
const float SpeedOfSound = 343.2; // ~speed of sound (m/s) in air, at 20°C | |
const float MicrosecondsPerMillimetre = 1000.0 / SpeedOfSound; // microseconds per millimetre | |
const float MicrosecondsToMillimetres = (1.0 / MicrosecondsPerMillimetre); //distance by time elapsed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "Origo.h" | |
#include "Brain.h" | |
int Brain::addModule(AbstractBrain * module) | |
{ | |
DEBUG_PRINT("Brain: Adding module "); | |
DEBUG_PRINT(module->getName()); | |
DEBUG_PRINT("\n"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define RST_PIN 8 //Reset pin | |
#define CHPD_PIN 9 //CHPD pin | |
#define GPIO_PIN 10 //Flashmode pin | |
void setup() { | |
//Open serial | |
Serial.begin(115200); | |
Serial1.begin(115200); | |
//Set pin modes on arduino |
OlderNewer