Posts

Showing posts from February, 2012

Ayuda con multi interruptores

estimados amigos, les comento que estoy realizando un proyecto en arduino mega. me quedado detenido tratando de resolver un problema que no podido solucionar, quizas su experiencias o ideas puedan encaminarmesucede que quiero encender y apagar un pequeño motor eléctrico con un interruptor. hasta ahí todo bien. pero además estoy mandando caracteres desde una aplicación que hice para android con bluetooth y la idea también es controlar el motor desde ahí, también lo logrado. pero el problema está que cuando enciendo el motor desde la aplicación, no puedo apagar el motor desde el interruptor. y cuando enciendo el motor desde el interruptor no puedo apagar el motor desde la app. obviamente eso debería funcionar. tengo algo así: if(digitalread(interruptor)==0 || serial.read()=='a')            digitalwrite(motor, low); if(digitalread(interruptor)==1 || serial.read()=='b')          digitalwrite(motor,high); atento sus comentarios y o sugerencias.

Speed of event_detected()? - Raspberry Pi Forums

hello, trying build animatronic shooting gallery using rpi b+ , arduino mega, having trouble keeping motors in sync sound. using python 2.7, , attempting measure time using time.clock(), seem have slippage of little on half second per second, sends animatronic routines out of sync pretty quickly. have been told on other boards rpi bad @ time, whereas arduinos handle time accurately. thinking send timed square wave arduino 1 of rpi's pins, , use ticking clock keep in sync. think 30ms tick work enough speed @ sending position commands motors, need know if event_detected() count every 1 of these ticks reliably. if so, approximately how fast make clock tick should want higher precision? raspberrypi

Mini Ethernet SPI Reset

hello, i better understand how reset spi works. have mini ethernet spi on arduino nano, , connected reset spi pin. but how can reset ethernet mini without resetting arduino board? the board after long time reason hangs , works fine after reset. thanks connect ethernet reset separately board reset. Arduino Forum > Using Arduino > Networking, Protocols, and Devices (Moderator: fabioc84) > Mini Ethernet SPI Reset arduino

Solid state relay trouble?? [SOLVED]

hello! i'm trying troubleshoot project , i'm stuck.. this post follows thread opened (http://forum.arduino.cc/index.php?topic=246837.0) , many tries working brought me seek electronic help! i thought sw problem wondering... can solid sate relay piloted arduino turning on , off 12v switching power supply cause software crash??? how driving relay? have datasheet or link it? Arduino Forum > Using Arduino > General Electronics > Solid state relay trouble?? [SOLVED] arduino

Joomla! Forum - community, help and support - Login

the board requires registered , logged in view forum. username: password: i forgot password resend activation email remember me hide online status session   register in order login must registered. registering takes few moments gives increased capabilities. board administrator may grant additional permissions registered users. before register please ensure familiar our terms of use , related policies. please ensure read forum rules navigate around board. terms of use | privacy policy register Board index

type mismatch problem

i show form allow visitors view information regarding person, each person has id number, problem first time visitor views person works fine, if try , view different person following message microsoft ole db provider odbc drivers error '80040e07' [microsoft][odbc microsoft access driver] data type mismatch in criteria expression. i've been fighting quite time , can't find problem. out there can point me in right direction. thanks is there possibly being passed query string incorrectly. this can happen when going master detail page , back, if parameters not cleared. can give url , underlying code? More discussions in Dreamweaver support forum adobe

Joystick Error - Raspberry Pi Forums

Image
this common type of post in forum joystick not working. have isolated code quite long , software error instead of hardware. have read guides posted on rpi website , believe i'm doing right. here isolated version of code: code: select all from astro_pi import astropi #importing astropi python library. ap = astropi() temp = ap.get_temperature() z = [255, 0, 0] redhigh = [ z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, #setting individual neopixels create high red equilizer when values above safe values z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z, z ] event.type = input(ap.show_message("select variable screen")) while event.type == keyleft: while temp < 30: ap.set_pixels(redhigh) huge in advance i've spent 3 hours trying fix it! hi, can ask, know how make temperature displayed on 1 page, , when move joystick right, shows humidity... please @ post see me

RN-42-HID Bluetooth Breakout PCB Design Assistance

i new pcb design , wanted try out. created simple breakout board rn-42-hid (former) roving networks. have recent datasheet, gerber files, , pictures of schematic , board design included. can't thing work. led's don't light up, doesn't respond serial commands, nothing. i have checked , rechecked, far can tell not missing anything. here see issues pcb designed? this logic problem, have isolate error is. software error, hardware error or what? since hardware can easier test definitely, check hardware first. first thing check make sure ground , power connections working properly. it's quickest , easiest thing check first. after have ensured working, using multimeter work backwards led device. 1) check continuity between ground of r2 , ground pin. if there not continuity, problem obvious. 2) check resistance between  across resistor (measuring led ground pin). rule out mislabeled resistor. check mislabeled resistors, happen time time. 3) ch

singing animatronic - Raspberry Pi Forums

so far basic script makes servo move left middle right need way setup timing bare in mind im python newb. (something wait 1.5 move left, wait 2.0 move right) code: select all import rpi.gpio gpio import time gpio.setmode(gpio.board) gpio.setup (11, gpio.out) frequencyhertz = 50 pwm = gpio.pwm(11, frequencyhertz) leftposition = 0.75 rightposition = 2.5 middleposition = (rightposition - leftposition) / 2 + leftposition positionlist = [leftposition, middleposition, rightposition, middleposition] mspercycle = 1000 / frequencyhertz in range(3): position in positionlist: dutycyclepercentage = position * 100 / mspercycle print "position: " + str(position) print "duty cycle: " + str(dutycyclepercentage) + "%" print "" pwm.start(dutycyclepercentage) time.sleep(.5) pwm.stop() gpio.cleanup() need little need change . raspberrypi

Roundtrip issue

this may have been covered not find in forums. i have bunch of pages created in fireworks , exported dreamweaver. if needed change graphics click on fw edit button in dw. so far good. opens original source file in fireworks can make updates. the problem 1 of pages open image element in fw, not fw source png. i've no idea what's causing works other pages. anybody know solution this? many time, trev More discussions in Dreamweaver support forum adobe

urm37 ultrasonic serial reading problem

hello i trying distance reading urm37 ultrasonic sensor. here code: code: [select] #include <urmserial.h> /* distancebysoftwareserial.pde - urm 37 control library version 2.0.0 author: miles burton, miles@mnetcs.com copyright (c) 2009 miles burton rights reserved this library free software; can redistribute and/or modify under terms of gnu lesser general public license published free software foundation; either version 2.1 of license, or (at option) later version. this library distributed in hope useful, but without warranty; without implied warranty of merchantability or fitness particular purpose.  see gnu lesser general public license more details. you should have received copy of gnu lesser general public license along library; if not, write free software foundation, inc., 51 franklin st, fifth floor, boston, ma  02110-1301  usa */ #include <softwareserial.h> #include "urmserial.h" // measurement we'r

Fermare servomotori ed iniziare un altro ciclo

salve gente! vi scrivo perché ho un problema e spero possiate aiutarmi risolverlo. allora io sto facendo il progetto di un robot (non se avete visto un mio post precedente). comunque riepilogando è uno scarafaggio che cammina, quando incontra un ostacolo torna indietro e si gira. io sono riuscito farlo camminare e farlo andare indietro. adesso devo farlo girare, come deve muoversi, ma non come scriverlo nel programma. per capirci meglio, inserisco l'ultima parte del programma che serve farlo indietreggiare e vi mostro dov'è il mio problema: code: [select] #include <servo.h> servo motore1; servo motore2; servo motore3; int pos1 = 75; int pos2 = 75; int pos3 = 0; void setup () { motore1.attach(2); motore2.attach(3);                                                  motore3.attach(4); pinmode(8,input); } void loop() { if (digitalread(8)== high) {                        // se viene pressato il pulsante    motore3.write(140);                               // si al

Joomla! Forum - community, help and support - Login

the board requires registered , logged in view forum. username: password: i forgot password resend activation email remember me hide online status session   register in order login must registered. registering takes few moments gives increased capabilities. board administrator may grant additional permissions registered users. before register please ensure familiar our terms of use , related policies. please ensure read forum rules navigate around board. terms of use | privacy policy register Board index

Bluetooth and SD Card Shield

i working on project need store amount of data (too store on arduino) controllable via bluetooth.  sd card shield have uses spi pins of arduino uno (10-13) , ble shield have been looking @ uses these pins.  will both of these shields work @ same time? if not there way around doing or sd card or bluetooth shields not use spi pins stack bluetooth , sd card shield? thanks! pretty bluetooth modules ive seen use serial, sure you're reading correctly? in addition hc-05/06 series extremely cheap , popular bluetooth solution there many how-tos it.. uses serial, , depending on board have can use 'soft serial' library use 2 pins feel choosing.  also check out: http://www.gammon.com.au/forum/?id=10918 summary of protocos. Arduino Forum > Using Arduino > Storage > Bluetooth and SD Card Shield arduino

Can't select newly created css styles

help! after have created new css style, there no way can apply it. the new style appears on right-hand-side under design - css styles, can't select in properties - styles drop box neither if select text - right click - css styles. it's not there...... what doing wrong? can show code? do have style sheet attached page: <link href="css/screenindex.css" rel="stylesheet" type="text/css" media="all" /> shane More discussions in Dreamweaver support forum adobe

Errore Codice controllo motori

vi posto il codice che utilizzo per il controllo dei motori code: [select] int velmot1 =9; int velmot2 =10; int motore1pos =4; int motore1neg =5; int motore2pos =6; int motore2neg =7; int enable= 2; int echopin = 12;       // echo (digital 2) int initpin = 13; int sensibilita =10; unsigned long pulsetime = 0;                     unsigned long distanza = 0;   void setup() {  pinmode( enable,output );  pinmode( velmot1,output );  pinmode( velmot2,output );  pinmode( motore1pos,output );  pinmode( motore1neg,output );  pinmode( motore2pos,output );  pinmode( motore2neg,output );     pinmode(initpin, output);                       pinmode(echopin, input);     unsigned long pulsetime = 0;                       unsigned long distanza = 0;                     // distanza in cm    digitalwrite( enable,high );       serial.begin(9600);  //inizializza la seriale } void loop() {   //manda un impulso di ampiezza 10 us   digitalwrite(initpin, high);                    

Joomla! Forum - community, help and support - Login

the board requires registered , logged in view forum. username: password: i forgot password resend activation email remember me hide online status session   register in order login must registered. registering takes few moments gives increased capabilities. board administrator may grant additional permissions registered users. before register please ensure familiar our terms of use , related policies. please ensure read forum rules navigate around board. terms of use | privacy policy register Board index

AYUDA control de luces y ventilación con Raspberry y arduino.

Image
buenas caballeros y caballeras, caballeros más que nada porque dudo que haya por aquí muchas mujeres   . ante todo me presento, soy nuevo en el foro me llamo tony, soy español y estoy terminando un ciclo superior de informática, ahora mismo estoy con el proyecto final que consiste en controlar ciertos componentes eléctricos de una casa con la ayuda de la arduino uno y la raspberry pi model b. la finalidad del proyecto es montar un servidor web, un ap (hostapd), y diversas herramientas en la raspberry pi y mediante un interfaz web controlar el encendido y apagado de 3 habitaciones (realmente son leds de 3.3v en una maqueta), 1 ventilador(pequeño de los que utiliza los disipadores de pc) y una puerta de garaje (en maqueta también).  para dotar de mayor complejidad al proyecto quiero que la encargada de gestionar el encendido de los pines necesarios sea la arduino. para ello conectado la arduino mediante serial (usb) la raspberry, y gracias un script en python le mando una serie

FUZE BASIC V3 FREE for all Pi Users - Raspberry Pi Forums

Image
it's official! fuze basic free download pi community. we've been working hard , fuze basic vastly improved new editor , lots of new commands including advanced sprite handling. go to: http://lair.fuze.co.uk please spread word! & tell think thanks this. installed described not start program menu. when selected mouse icon spins few seconds nothing happens. hovever seem start ok terminal typing 'fuze'. doing wrong? raspberrypi

Thread: Linux DNA

i have heard linux dna project. custom kernal cpu , it's supposed make computer run lot faster. on site gives instructions gentoo , general instructions other distros. wondering if has tried , maybe can give better ubuntu instructions. i used run gentoo , spent lot of time tweaking every little kernel module , compile parameter squeeze out % of performance. unless have lots of free time , no other interests hacking, it's lot more efficient/effective buy faster hardware. Forum The Ubuntu Forum Community Ubuntu Official Flavours Support General Help [ubuntu] Linux DNA Ubuntu

[lain-lain] upgrade joomla 10.0.10 to joomla 10.0.11 - Joomla! Forum - community, help and support

lagi 1 soklan..jangan mare yer... macam mana nak upgrade joomla 10.0.10 ke joomla 10.0.11.. kita install biasa juga ker... mula2 orkid kene download package file untuk version 1.0.10 - v1.0.11. orkid bleh download kat sini: http://developer.joomla.org/sf/frs/do/v ... 2f850992ab just extract, copy ,paste , overwrite file. (attention, please make backup first before u try). untuk joomla v1.0.11 ni, global_configuration(dalam php.ini) dan rg_emulator(global.php) diorg off kan.so, ada beberapa komponent yg x bleh jalan, dan terdapat beberapa masalah lain. orkid bleh rujuk kat sini : http://forum.joomlamalaysia.org/index.php?topic=31.0 cadangan saya, better guna v 1.0.10 buat sementara waktu. Board index Joomla! International Language Support International Zone Malaysian Forum

Trying To Optimize Images To Work With BerryBoot - Raspberry Pi Forums

so picked first raspberry pi 2 , installed retropie onto it. i've decided dualboot retropi , osmc using berryboot can use gaming , htpc. downloaded: 1. berryboot build 20150401 rp2 2. osmc build20150412 rp2 3. retropie version 3.0 beta2 rp2 placed osmc , retropi images onto usb drive after renaming them osmc.img , retropi.img respectively. booted retropie image installed on sd card, exited command line , installed kpartx , squashfs. ran ' 'sudo kpartx -av osmc.img '' , according tutorial should have gotten outcome similar this: add map loop0p1 (252:5): 0 117187 linear /dev/loop0 1 add map loop0p2 (252:6): 0 3493888 linear /dev/loop0 118784 ended this: add map loop0p1 (254:0): 0 497664 linear /dev/loop0 2048 done improperly or should proceed , use information ended next step? i'm pretty green when comes linux , have figured few things out need guidance haven't used command line os since dos when kid. in advance! anybody? raspberrypi

DCF77 Modul with Arduino UNO and Micro

Image
hi guys, i'm testing these dcf77 modul 1 1/2 days. following diagram: now on arduino uno diagram , sketch working, fine, arduino micro nothing working, cant find signal. i tried other resistor , add capacitor , on nothing working. do has idea? thank in advance philipp did change code work micro? don't think have same pinout. uno has mega328 , micro has mega32u4. Arduino Forum > Using Arduino > General Electronics > DCF77 Modul with Arduino UNO and Micro arduino

Trouble creating custom AreaRenderer for AreaChart

quick first question: if purchase charting package, source code? solve problems. ok real question: have quick example class custom arearenderer areachart? i'm trying create custom arearenderer implementation. according docs, need implement "arearenderer" interface (not iarearenderer (?)) supposedly lives in mx.charts.renderers.interfaces flex builder complains interface not found. link docs: http://livedocs.macromedia.com/flex/15/asdocs_en/mx/charts/renderers/interfaces/arearender er.html alternatively i've tried extending arearenderer methods: begindraw, draw , enddraw don't seem there or not overridable? ok first mistake... looking @ flex 1.5 docs. must have come search :s anyone have more clues? More discussions in Flex (Read Only) adobe

Thread: Comprehensive Ubuntu Book : recommendations ?

i'm beginning third week ubuntu. downloaded kier thomas's excellent ubuntu pocket guide . now looking comprehensive, yet reasonably up-to-date ( @ least version 8.04 ). of course text should have lot command line. recommendations. hi dave wb3dwe. practical guide ubuntu linux mark g. sobell book information. Forum The Ubuntu Forum Community Ubuntu Official Flavours Support New to Ubuntu [ubuntu] Comprehensive Ubuntu Book : recommendations ? Ubuntu

Validating Dates

i've 'written' simple function validate date; see below .... function valid_date($date) // validate date in dd/mm/yyyy format { $date_element = split("/",$date); // split input date down constituent parts $dd = $date_element[0]; // first element of array day $mm = $date_element[1]; // second element month $yyyy = $date_element[2]; // third element year if(!checkdate($mm,$dd,$yyyy)) { return false; } else { return true; } } // end of date validation function this partially works returns true if enter before 1901 , e.g. 01/01/1881 thought wouldn't. if enter date alph characters (e.g. i/2/1982) ... "warning: checkdate() expects parameter 1 long, string given in .... " appears on screen out side of control @ least says date false. i know you're going roll eyes swear routine validated both of these scenarios correctly before today ... unlikey sounds? have manually code these scenarios in 'long hand'? all best. patrick. .oo(pat

AccellStepper help

total nooby here go easy on ego. question 1) steppers start out acceleration specified every time called don't stall. they way have , have acceleration rate first time called. after first call start out full speed every time. have tried moving following commands on place doesn't seem matter. verticalstepper.setmaxspeed(3000); // set verticalstepper max speed verticalstepper.setacceleration(50.0); // set stepper accelleration lower # + slower ramp   question 2) have taken following command out of code since didn't anything: stepper.stop(); // stop fast possible: sets new target it seems if meet condition , no longer call stepper.run() stops motor? please enlighten me on correct usage or suggest else accelerate top speed every time called. as can see i'm not programmer working me far. thanks help. ferny code: [select]   //april 2014 big dipper state machine ferny // state machine lcd outputs case when changed #include <accelstepper.h> #include <liquidc

Integrating weather, camera, xbee, and SD shields together fails, works seperate

i'm building remote environment monitor can take measurements , photos on demand. i tested each shield itself, modified each shield avoid conflicts - had cut , re-route 1 trace.  pin 8 sd chip select sd shield, , status indicator output on weather shield.  cut , jumped on pin 9. when integrated parts 1 file (below) log data , photos sd card.  problem seemed have getting photos on xbee link - , seemed fault.   as in not splitting out data status messages properly.  so focused on that, , when thought had working surprised find image viewer (irfanview) still said dct 11 (or 10) bogus. i powered off uno r3 , pulled out u-sd chip, put usb adapter, , jpg files zero-bytes!  then noticed data logger command getting error too. this when loaded sd data logger itself, worked fine.  photo taker itself, fine. so commented out line(s) echo data on serial link.  still zero-byte photos.  put code had removed (sending periodic dots during save) in case weird timing issue.   no change. i&#

Joomla! News question - Joomla! Forum - community, help and support

hello, i trying make site rape survivers, make section allows users submit recovery story , allow users browse stories in alphabetical order. (kind of postnukes article section). wondering mod or content manager out there can me? or can use core news system this. know news system allows me have users submit news me not see option allows users browse in alphabetical order. thank you andyac wrote: hello, i trying make site rape survivers, make section allows users submit recovery story , allow users browse stories in alphabetical order. (kind of postnukes article section). wondering mod or content manager out there can me? or can use core news system this. know news system allows me have users submit news me not see option allows users browse in alphabetical order. thank you as far know, should 1.) make users authors - going difficult there no way globally allow new users automatically become authors 2.) create section , category , menu link read articles. 3.) add menu link submit new

U8glib and SSD1306 I2C

Image
so here's problem i have v2.1 adafruit 128x64 ssd1306 oled , can not life of me work u8glib library. i'm using arduino uno r2, arduino ide 1.5.6 r2, , u8glib 1.16pre-release.  trying use i2c setup, have sda pin set a4 , scl pin set a5.  5v  , gnd in right place well.  know wiring right , display functional because can run display adafruit library.   i have tried every u8glib constructor involving ssd1306 , i2c, still darkness.  have adafruit 128x32 i2c oled, hooked up, same 128x64, change constructor , works instantly.  don't understand why can't work.  any appreciated!! can provide exact constructor calls? maybe repeat test arduino ide 1.0.5. oliver Arduino Forum > Using Arduino > Displays > U8glib and SSD1306 I2C arduino

Problem interfacing ArduinoMega-2560 with laptop

im using arduino mega 2560 , working fine. tried energize relay coil of 5v using digital output pin of arduino , ground pin, worked , after minute disconnected arduino. later when tried upload new matlab model, laptop not recognise board..i not see in device manager. but power on led , led near 13th pin working when connect board using usb , last program burnt on board still there , running fine. what problem? operating system windows7. unless relay small , has snubbing diode may have fried pin.  pin did use?  if 0 or 1 may have damaged 1 of 2 pins used serial i/o. Arduino Forum > Using Arduino > Installation & Troubleshooting > Problem interfacing ArduinoMega-2560 with laptop arduino

Effectuer une action qu'une seule fois dans le loop() ?

Image
bonjour et bonne fête  , après moult recherche, j'en arrive la conclusion que c'est la jungle dans l'information, et que par conséquent je n'ai pas réussi trouver ce que je cherchais... donc pour faire claire et ne pas trop vous faire perdre du temps, voilà ce que je veut : lecture de la valeur de ma photorésistance si elle dépasse 500 alors actionner le moteur dans le sens horaire, une seul fois pendant x secondes puis le moteur stop jusqu'à au prochain changement d'état. sinon si elle ne dépasse pas 500 alors actionner le moteur dans le sens anti-horaire une seule fois pendant x secondes puis le moteur stop jusqu'à au prochain changement d'état. le étant de contrôler le moteur avec une lampe si ça reste allumé le moteur ouvre une trappe. si ça s'éteint il la ferme. j'ai donc réussis pwm le moteur pour avoir la longueur d'action que je souhaitais, malheureusement le moteur tourne en boucle... code: [select] const int monter = 2; //

CS3, Spry insertion

i upgraded design premium studio , first foray spry. i have inserted collapsable panel, works fine in preview, not work when put. the link http://www.coolshapes.net/, panel @ bottom, "contact" tab, address supposed appear when clicked. any ideas? thanks gary More discussions in Dreamweaver support forum adobe

cannot reorder mj frontpage - Joomla! Forum - community, help and support

Image
my mj frontpage won' t reorder when click on arrow go or down item, page refreshes, stays in place. i tried reinstalling component, didnt work. any idea? thanks j which joomla version? which browser use? how access back-end? http://www.yoursite.com/administrator or http://yoursite.com/administrator ? and how live-site configurated in configuration.php ? do other ordering buttons (e.g. in het category manager) work ok? Board index Joomla! Older Version Support Joomla! 1.0 Administration - 1.0.x

Data Logging Sketch Locking Up (Arduino MEGA1280 w/Official Ethernet Shield)

hi guys, i've quite literally spent day going through code cannot life of me figure out what's going on. seems lock up, i've tried multiple arduino's , ethernet shields i'm code issue. the idea 1 arduino logs sensors , transmits data second arduino via twi logging sd card , live (give or take few seconds) submission php server via ethernet. however, reason second sketch keeps locking up. can shed light on me, can't seem find reason nor pattern it. seems main loop stops running, when happens wire interrupt still work , log data sd, other times nothing happens @ all. code: [select] #include <wire.h> #include <sd.h> #include <spi.h> #include <ethernet.h> #include <avr/wdt.h> #include <memoryfree.h> byte mac[] = {    0x00, 0xaa, 0xbb, 0xcc, 0xde, 0x02 }; char server[] = "my.web.server"; // self explanatory! char siteid[] = "1"; // arduino identifier, if decide have several. char sitepw[] = "passw

Running small (2.5v) light bulbs through arduino?

i'm trying build looks little older, using leds doesn't work well, , figured low voltage light bulbs work great. grabbed 2.5v bulbs , little mounts them. lighting them 2.5-5v worked great (a bit bright @ 5v, understandable). my problem getting them light arduino (uno, if matters). have basic sketch (starting "blink" example in core example set) , doesn't light up. put in led , lights great. put bulb either 3.3v or 5v pin directly , bulb comes up, not @ of regular pins (i've tried both pwm , regular pins,with both analogwrite , digitalwrite). any thoughts? assume i'm missing simple-but-clever piece this, it's eluding me , there isn't on driving small light bulbs searching i've done (or volume on leds , driving full size light bulbs has buried it). thanks! bulbs need more current i/o pin can provide you need transistor, google "arduino lamp transistor" or "arduino bulb transistor" examples

Thread: scripting help

note running script thru terminal. line add have minimize (the terminal) after executed. tks not sure understand , can run script in ground & option code: ./script & or if want notfied once script done add within script code: notify-send "the script has finished" or play around code: gnome-terminal --zoom=.5 not in gnome envirorment , not sure if want Forum The Ubuntu Forum Community Ubuntu Official Flavours Support New to Ubuntu [ubuntu] scripting help Ubuntu

Stuck with a loop

hi just wondering whether piece of code writting. meant game using lasers , ldrs receiver.  when try out seems run void loop until enters "playgame" not seem able exit "lose" function , return "options" function @ start of void loop. second question within "playgame" function, unsure how add amount of time system has wait right input before exiting lose function. code: [select] #include <softwareserial.h> softwareserial myserial(-1, 2); // rx9 disabled, tx on d2 // pins shift registers conected: int latchpin = 5; int clockpin = 6; int datapin = 4; // pins ldrs connected: const int ldr1 = 13; const int ldr2 = 12; const int ldr3 = 11; const int ldr4 = 10; const int ldr5 = 9; const int ldr6 = 8; const int ldr7 = 7; const int speaker = 3; int ldr1state = 0; int ldr2state = 0; int ldr3state = 0; int ldr4state = 0; int ldr5state = 0; int ldr6state = 0; int ldr7state = 0; int x=0; // initial output shift registers: unsigned char reg1 = 0