Arduino syntaxe highlight


I try to enable the «Arduino» syntax highlighting for Geshi module in this blog (drupal 7) for at least 1 hour!

I don't get to bring up the «Arduino» check box in the available languages pages!

After some tests with no success, i finally found a piece of code, which, after only one modification, permit to bring up this f....... check box.

To do this, i force the to update the mysql field 'geshifilter_available_languages_cache' anyway by disabling an «if» statment. It's not very clean but it works!

function _geshifilter_get_available_languages() {
  // try to get it from cache (database actually)
  $available_languages = variable_get('geshifilter_available_languages_cache', NULL);
  if ($available_languages === NULL /* adding or condition to disable the if statment --> */ or $available_languages !== NULL) {

After this modification, i found Arduino in available languages geshi settings.

To finalize, i try this piece of arduino code

#define LED 13

unsigned long elapsed_time;
byte state = LOW;

void setup() {
pinMode(LED, OUTPUT);
digitalWrite(LED, state);
elapsed_time = millis();

void loop() {

if(millis() >= elapsed_time + 500) {

elapsed_time = millis();
state = !state;
digitalWrite(LED, state);

Tags: Arduino highlight drupal 7

  • 8 years 7 months before
  • |