Examples of PlatformFactory


Examples of avrora.sim.platform.PlatformFactory

   * @throws Exception
   */
  protected void prepareMote(File file) throws Exception {
    program = new LoadableProgram(file);
    program.load();
    PlatformFactory factory = new MicaZ.Factory();
    micaZ = (MicaZ) factory.newPlatform(1, program.getProgram());
    myCpu = (AtmelMicrocontroller) micaZ.getMicrocontroller();
    eeprom = (EEPROM) myCpu.getDevice("eeprom");
   
    avrProperties = (AVRProperties) myCpu.getProperties();
    Simulator sim = myCpu.getSimulator();
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

        processMonitorList();

        if ( args.length == 0 )
            Avrora.userError("Simulation error", "No program specified");
        Main.checkFilesExist(args);
        PlatformFactory pf = getPlatform();

        // get the radio air model
        air = getRadioAir();
        synchronizer = air.getSynchronizer();
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

            Avrora.userError("Simulation error", "Single node simulation accepts only one program");
        Main.checkFilesExist(args);

        LoadableProgram p = new LoadableProgram(args[0]);
        p.load();
        PlatformFactory pf = getPlatform();
        createNode(pf, p);

    }
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

            if ( exthz > hz )
                Avrora.userError("External clock is greater than main clock speed", exthz+"hz");
            MicrocontrollerFactory mcf = Defaults.getMicrocontroller(MCU.get());
            return new DefaultPlatform.Factory(hz, exthz, mcf);
        } else {
            PlatformFactory pff = Defaults.getPlatform(pfs);
            return pff;
        }
    }
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

    processMonitorList();

    // Eigene Option einbauen, um zu sagen, dass Eingabe von Extern kommt
    // An dieser Stelle nicht nur auf args.length pruefen, sondern auch auf diese Option
    Main.checkFilesExist(args);
    PlatformFactory pf = getPlatform();

    synchronizer = new ExternalSync();

    Utils.debugMsg("Send-Handle: " + SEND_HANDLE.get(), this);
    Utils.debugMsg("Receive-Handle: " + REC_HANDLE.get(), this);
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

            pp.load();
        } catch ( Exception e ) {
            // TODO: display exception loading file
            throw Avrora.failure(e.toString());
        }
        PlatformFactory pf = Defaults.getPlatform("mica2");
        Simulation s = AvroraGui.instance.getSimulation();

        int max = ((Integer) numOfNodesSpinner.getValue()).intValue();
        for (int i = 0; i < max; i++) {
            //add the stuff to the sim
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

   * @throws Exception
   */
  protected void prepareMote(File file) throws Exception {
    program = new LoadableProgram(file);
    program.load();
    PlatformFactory factory = new MicaZ.Factory();
    micaZ = (MicaZ) factory.newPlatform(1, program.getProgram());
    myCpu = (AtmelMicrocontroller) micaZ.getMicrocontroller();
    eeprom = (EEPROM) myCpu.getDevice("eeprom");
   
    avrProperties = (AVRProperties) myCpu.getProperties();
    Simulator sim = myCpu.getSimulator();
View Full Code Here

Examples of avrora.sim.platform.PlatformFactory

   * @throws Exception
   */
  protected void prepareMote(File file) throws Exception {
    program = new LoadableProgram(file);
    program.load();
    PlatformFactory factory = new MicaZ.Factory();
    micaZ = (MicaZ) factory.newPlatform(1, program.getProgram());
    myCpu = (AtmelMicrocontroller) micaZ.getMicrocontroller();
    eeprom = (EEPROM) myCpu.getDevice("eeprom");
   
    avrProperties = (AVRProperties) myCpu.getProperties();
    Simulator sim = myCpu.getSimulator();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.