Result:
found more than 656 distributions - search limited to the first 2001 files matching your query ( run in 1.330 )


Date-Holidays-TW

 view release on metacpan or  search on metacpan

lib/Date/Holidays/TW.pm  view on Meta::CPAN

    my $lunar_mmdd = sprintf('%02d%02d', $lunar_date->month, $lunar_date->day);
    return $FOLK_LUNAR{$lunar_mmdd};
}

sub __is_qingming {
    # Thanks Wei-Hon Chen for the formula.
    my $dt = $_[0];
    return undef unless $dt->month == 4 && 3 < $dt->day && $dt->day < 6;
    my $year = $dt->year;
    die "Unsupported" if $year < 1901 || 2100 < $year;
    my $Y = ($year % 100);

 view all matches for this distribution


Date-Indiction

 view release on metacpan or  search on metacpan

lib/Date/Indiction.pm  view on Meta::CPAN


Indiction (called I<indict> in Russian chronicles) is the number of
the year in a 15-year cycle, starting from September 1, 312 AD. It can
be calculated for either Byzantine year (Anno Mundi, AM, old Russian
style with the epoch on March 1, 5508 BCE) or Christian year (Anno
Domini, AD). The formulae are, respectively,

    I = AM % 15

    I = (AD + 3) % 15

 view all matches for this distribution


Date-Pcalc

 view release on metacpan or  search on metacpan

lib/Date/Pcalendar/Profiles.pm  view on Meta::CPAN

{
    my($year,$label) = @_;
    return( &Next_Monday($year,1,1) );
}
#
# The following formula (also from Jonathan Stowe <gellyfish@gellyfish.com>)
# also contradicts my pocket calendar, but for lack of a better guess I
# left it as it is. Please tell me the correct formula in case this one
# is wrong! Thank you!
#
sub GB_Early_May # May bank holiday is the first Monday after May 1st
{
    my($year,$label) = @_;

lib/Date/Pcalendar/Profiles.pm  view on Meta::CPAN

    %{$Profiles->{'AU'}},
    "New Year's Day"            => "01.01.",
    "Regatta Day"               => "2/Tue/Feb",
    "Lauceston Cup Day"         => \&AU_Lauceston,
    "King Island Show Day"      => "1/Tue/Mar", # uncertain! (maybe Tuesday after 1/Sun/Mar?)
    "Eight Hour Day"            => "2/Mon/Mar", # dubious, formula probably wrong!
    "Easter Saturday"           => "-1",
    "Queen's Birthday"          => "2/Mon/Jun",
    "Recreation Day"            => "1/Mon/Nov"  # only North Tasmania - date not confirmed!
};
$Profiles->{'AU-SA'} =  # South Australia

lib/Date/Pcalendar/Profiles.pm  view on Meta::CPAN

};
$Profiles->{'AU-ACT'} = # Australian Capital Territory
{
    %{$Profiles->{'AU'}},
    "New Year's Day"            => "01.01.",
    "Canberra Day"              => "2/Mon/Mar", # dubious, formula probably wrong!
    "Easter Saturday"           => "-1",
    "Queen's Birthday"          => "2/Mon/Jun",
    "Labour Day"                => "1/Mon/Oct"
};
$Profiles->{'AU-NSW'} = # New South Wales

 view all matches for this distribution


Date-Pregnancy

 view release on metacpan or  search on metacpan

lib/Date/Pregnancy.pm  view on Meta::CPAN

=back

=head1 DISCLAIMER

The method of calculating day of birth and week numbers implemented in
this module is based on simple formulas.

The ultrasound scan is a much more accurate method and finally babies
seem to have a will of their own, so please do only use the results of
this module as a guideline, the author of this module cannot be held
responsible for the results of calculations based on use of this module.

 view all matches for this distribution


Date-Roman

 view release on metacpan or  search on metacpan

lib/Date/Roman.pm  view on Meta::CPAN

value of the B<num> parameter below if given, to B<Roman> otherwise.


=item B<auc>

Controls how the "ab Urbe condita" formula is written. Possible values
are: B<abbrev>, which writes it as "AUC", and B<complete> which writes
it in full. This parameter defaults to the value of the B<words>
parameter below if given, and to B<abbrev> otherwise.


lib/Date/Roman.pm  view on Meta::CPAN

used an inclusive counting. That way, for instance,
the 2 Jan was the 4th day before the nones of January (the nones of
January being the 5th of January).

The day before a fixed day was designed by "pridie", abbreviated as
"p.d.". The other days was designed using the formula "ante diem",
abbreviated as "a.d.". For instance, the 16th of April was 
I<ante diem XVI Kalendas Maias>, abbreviated as I<a.d. Kal. Mai.>

In leap years, the supplemental day was obtained by counting two times
the 6th day before the Kalendae of March.

 view all matches for this distribution


Date-SundayLetter

 view release on metacpan or  search on metacpan

lib/Date/SundayLetter.pm  view on Meta::CPAN

 Thursday       4 January       D
 Friday         3 January       C
 Saturday       2 January       B

In leap years, you have two Sunday Letters. After leap day, you have a
Sunday Letter calculated with the usual formulae. Before leap day, the
Sunday Letter is one place ahead of that (with A being considered one
latter after G).

Given the Sunday Letter and the Golden Number (see
Date::GoldenNumber), you can immediately look up the dates for Easter

 view all matches for this distribution


Date-Vruceleto

 view release on metacpan or  search on metacpan

lib/Date/Vruceleto.pm  view on Meta::CPAN

chronology as "solar cycle". The count of solar cycles in this
calendar system starts from March 1, 5508 BCE (called Constantinople
World Aera).

I.A.Klimishin in his book "Calendar and Chronology" (Moscow, Nauka,
1985, pp. 66-70) gives the following formulae to calculate solar
cycles and vruceletos ([] meaning the integer part of the quotient and
|| the remainder):

- First get the solar cycle (Q) of the year of Constantinople aera (B):

 view all matches for this distribution


DateTime-Calendar-FrenchRevolutionary

 view release on metacpan or  search on metacpan

eg/g2r_table  view on Meta::CPAN

      $end_of_interval{$current_start} = $year;
  }
}

#
# Compute the formulas for a sample year and for a month.
# 1st January 1796 is 11 Nivôse IV, and 31 January 1796 is 11 Pluviôse IV.
# Therefore, for January 1796, we have two formulas : "+10 Niv" and "-20 Plu".
# Since all French Revolutionary months have 30 days, only one computation is necessary.
# Exception: the additional days are grouped in a notional 13th month, which lasts
# either 5 or 6 days. In this case, we have 3 formulas for September, at the cost of 2 conversions.
#
sub formulas {
  my ($year, $month) = @_;
  my @formulas = ();
  my @month = qw(Niv Plu Vnt Ger Flo Pra Mes The Fru S-C Vnd Bru Fri Niv);
  #my $date = new Date::Convert::Gregorian $year, $month, 1;
  #convert Date::Convert::FrenchRevolutionary $date;
  my $dg = DateTime->new(year => $year, month => $month);
  my $dr = DateTime::Calendar::FrenchRevolutionary->from_object(object => $dg);
  my $offset = $dr->day() - 1;
  if ($month <= 9) # Have to split in two, because of the additional days within @month
    {
      push @formulas, "+$offset $month[$month - 1]";
      $offset = 30 - $offset;
      push @formulas, "-$offset $month[$month]";
    }
  else
    {
      push @formulas, "+$offset $month[$month]";
      $offset = 30 - $offset;
      push @formulas, "-$offset $month[$month + 1]";
    }
  if ($month == 9)
    {
      #$date  = new Date::Convert::FrenchRevolutionary $year - 1791, 1, 1;
      #convert Date::Convert::Gregorian $date;
      $dr = DateTime::Calendar::FrenchRevolutionary->new(year => $year - 1791);
      $dg = DateTime->from_object(object => $dr);
      $offset = $dg->day() - 1;
      push @formulas, "-$offset Vnd";
    }

  @formulas;
}

sub html_0 {
  my ($title) = @_;
  print <<"EOF";

eg/g2r_table  view on Meta::CPAN

  # the part of September in the end of the year
  if ($part eq 'e') {
    print "<tr align='center'><td>$labels{month}[8]</td>";
    foreach (@days) {
      my $year = $year_of_partday{$part}{$_};
      my @formulas = formulas($year, 9);
      print "<td>$formulas[2]</td>\n";
    }
    print "</tr>\n";
  }
  # The regular months of the part of the year
  my @month_list = $part eq 'b' ? (1..2) : $part eq 'm' ? (3..9) : (10..12);
  foreach my $month (@month_list) {
    print "<tr align='center'><td>$labels{month}[$month - 1]</td>";
    foreach (@days) {
      my $year = $year_of_partday{$part}{$_};
      my @formulas = formulas($year, $month);
      print "<td>$formulas[0]<br>$formulas[1]</td>\n";
    }
    print "</tr>\n";
  }

  print "</table>\n";

eg/g2r_table  view on Meta::CPAN

  my $y2       = sprintf "%02d", $y % 100;
  my $part     = $m <= 2 ? 'b' : $m < 9 ? 'm' : 'e';
  my $offset   = $part eq 'e' ? 1791 : 1792;
  my $letter   = letter_of_yearpart($y, $part);
  my $word     = word_for_year($y);
  my @formulas = formulas($y, $m);
  my $limit    = $1 if $formulas[1] =~ /(\d+)/;
  my $formula  = $formulas[$d <= $limit ? 0 : 1];
  my $ryear    = $date->year();
  my $begint; # Beginning of the interval
  foreach (sort { $a <=> $b } keys %end_of_interval)
    {
      last if $y < $_;

eg/g2r_table  view on Meta::CPAN

  # $m = 9;
  $gr_date  = &{$labels{format}}($y, 9, $d, $lang);
  #$date = new Date::Convert::Gregorian $y, 9, $d;
  #convert Date::Convert::FrenchRevolutionary $date;
  $date = DateTime::Calendar::FrenchRevolutionary->from_object(object => DateTime->new(year => $y, month => 9, day => $d));
  @formulas   = formulas($y, 9);
  my $mletter = letter_of_yearpart($y, 'm');
  my $eletter = letter_of_yearpart($y, 'e');
  $abridged   = $date->strftime("%e %b %Y");
  $rev_date   = $date->strftime("%A %e %B %EY");
  $limit = $1 if $formulas[1] =~ /(\d+)/;
  if ($d <= $limit)
    { $formula = $formulas[0]; $offset = 1792 }
  else
    {
      $limit = $1 if $formulas[2] =~ /(\d+)/;
      if ($d <= $limit)
        { $formula = $formulas[1]; $offset = 1792 }
      else
        { $formula = $formulas[2]; $offset = 1791 }
    }
  $_ = eval "qq($labels{usage2})";
  print;
}

 view all matches for this distribution


DateTime-Event-Easter

 view release on metacpan or  search on metacpan

lib/DateTime/Event/Easter.pm  view on Meta::CPAN

=item * western_epact($year)

In the  Gregorian comput, the epact  is the age of  the ecclesiastical
Moon on the 1st January of the  given year. The C<western> part of the
subroutine  name  accounts for  the  fact  that Gregorian  and  Julian
calendars do not use the same formula.

The epact  is a 0..29 number.  The "0" value  is shown as "*"  in some
sources. This  subroutine does not convert  "0" to "*", the  result is
always a pure number.

lib/DateTime/Event/Easter.pm  view on Meta::CPAN

=item * eastern_epact($year)

In the Julian comput, the epact  is the age of the ecclesiastical Moon
on 22nd March. The C<eastern> part of the subroutine name accounts for
the  fact that  Gregorian and  Julian calendars  do not  use the  same
formula.

The epact  is a 0..29 number.  The "0" value  is shown as "*"  in some
sources. This  subroutine does not convert  "0" to "*", the  result is
always a pure  number. There is no  other special case, for  25 as for
any other number.

The formula given by Reingold and  Dershowitz is a "shifted epact" and
gives  different  results from  the  values  printed in  Lefort's  and
Couderc's books. The module follows Couderc and Lefort.

=item * western_sunday_letter($year), eastern_sunday_letter($year)

 view all matches for this distribution


DateTime-Event-Jewish

 view release on metacpan or  search on metacpan

lib/DateTime/Event/Jewish/Haversine.pm  view on Meta::CPAN

@EXPORT_OK = qw(recalculate_coordinate azimuth elevation point2distance);
use Math::Trig;
our $VERSION = '0.01';


#  Python implementation of Haversine formula
#  Copyright (C) <2009>  Bartek Garny <bartek at gorny.edu.pl>
#  Converted to Perl by Raphael Mankin <rapmankin at cpan.org> Feb 2010
#
#  This program is free software: you can redistribute it and/or modify
#  it under the terms of the GNU General Public License as published by

lib/DateTime/Event/Jewish/Haversine.pm  view on Meta::CPAN

#  Sun: 31.6' - 32.7'
#  Moon: 29.3' - 34.1'

=head1 NAME

Haversine.pm - Calculations using haversine formula

=head1 SYNOPSIS

  use Haversine;
  my $degrees	= recalculate_coordinate([51, 12, 0], 'deg');

lib/DateTime/Event/Jewish/Haversine.pm  view on Meta::CPAN

      

=head3 points2distance($start, $end)

Calculate distance (in kilometers) between two points
given as (lat, long) pairs based on Haversine formula
(http://en.wikipedia.org/wiki/Haversine_formula).
Implementation inspired by JavaScript implementation from http://www.movable-type.co.uk/scripts/latlong.html

Accepts coordinates as tuples (deg, min, sec), but coordinates can be given in any form - e.g.
can specify only minutes:
(0, 3133.9333, 0) 

lib/DateTime/Event/Jewish/Haversine.pm  view on Meta::CPAN

}

=head3 azimuth($start, $end)

Calculate azimuth (bearing) of one point from another
given as (lat, long) pairs based on Haversine formula

=cut

sub azimuth {
    my ($start, $end)	= @_;

 view all matches for this distribution


DateTime-Event-Random

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

0.03     2004-03-17
0.02_02  2004-03-15
- update to new DateTime::Set specs
- more tests, revised README and TODO
- added a note on README about tests that may fail.
- use a slightly different density formula 
  for calculating the first element of a set.
  This should give a better distribution for 
  $set->next($dt) on an unbounded, uncached set -
  but only the first time it is called (this is 
  still in the TODO list)

 view all matches for this distribution


DateTime-Lite

 view release on metacpan or  search on metacpan

lib/DateTime/Lite.pm  view on Meta::CPAN

}

sub week_number { ( $_[0]->week )[1] }

# ISO: first week of the month is the first week containing a Thursday.
# Direct formula - no clone, no add(), no recursion.
# NOTE: week_of_month is autoloaded

sub week_year { ( $_[0]->week )[0] }

# NOTE: weekday_of_month is autoloaded

 view all matches for this distribution


DateTime-Locale

 view release on metacpan or  search on metacpan

lib/DateTime/Locale/Data.pm  view on Meta::CPAN

  "1694ACAD" => "Early Modern French",
  1901 => "Traditional German orthography",
  "1959ACAD" => "Academic",
  1994 => "Standardized Resian orthography",
  1996 => "German orthography of 1996",
  ABL1943 => "Orthographic formulation of 1943",
  ALALC97 => "ALA-LC Romanization, 1997 edition",
  ALUKU => "Aluku dialect",
  AO1990 => "Portuguese Language Orthographic Agreement of 1990",
  AREVELA => "Eastern Armenian",
  AREVMDA => "Western Armenian",

 view all matches for this distribution


DateTime-Util-Calc

 view release on metacpan or  search on metacpan

lib/DateTime/Util/Calc.pm  view on Meta::CPAN

iteration.

=head2 search_next(%opts)

Performs a "linear" search until some condition is met. This is a generalized
version of the formula defined in [1] p.22. The basic idea is :

  x = base
  while (! check(x) ) {
     x = next(x);
  }

 view all matches for this distribution


DateTime

 view release on metacpan or  search on metacpan

lib/DateTime.pm  view on Meta::CPAN

free from DST-related complications.

=item * $dt->subtract_datetime and $dt->add_duration

You must convert your datetime objects to the UTC time zone before doing date
math if you want to make sure that the following formulas are always true:

    $dt2 - $dt1 = $dur
    $dt1 + $dur = $dt2
    $dt2 - $dur = $dt1

Note that using C<< $dt->delta_days >> ensures that this formula always works,
regardless of the time zones of the objects involved, as does using C<<
$dt->subtract_datetime_absolute >>. Other methods of subtraction are not always
reversible.

=item * never do math on two objects where only one is in the floating time zone

 view all matches for this distribution


DayOfNthWeek

 view release on metacpan or  search on metacpan

DayOfNthWeek.pm  view on Meta::CPAN

sub tomorrow { print "Meeting is tomorrow\n";  }
sub tonight  { print "Meeting is tonight\n";   }

=head2 FORMULA

The formula for calculating the week is:

(int(((Day of the Month - 1)+ Day of the Week)/7))+1


	my %hash = ();

 view all matches for this distribution


Deco

 view release on metacpan or  search on metacpan

lib/Deco/Tissue.pm  view on Meta::CPAN

    $self->{time}->{lastdepthchange} = 0;

    # oxygen exposure tracking through OTU's
    $self->{otu}   = 0;

    # haldane formula for current parameters, returns a ref to a sub
    $self->{haldane} = $self->_haldanePressure();

    return $self;
}

lib/Deco/Tissue.pm  view on Meta::CPAN

	
	# remember this depthchange on the time scale
	$self->{time}->{lastdepthchange} = $self->{time}->{current};
	#print "Time of last depth change is: " . $self->{time}->{lastdepthchange} ."\n";

	# when depth changes we need to recalculate the Haldane formula
	$self->{haldane} = $self->_haldanePressure();
    }

    return $self->{depth};
}

lib/Deco/Tissue.pm  view on Meta::CPAN

    my $depth = shift;
    my $press =  $depth  * $self->{waterfactor} / 10;
    return $press;
}

# use haldanian formula to solve the current pressure in tissue
# as long as the depth remains constant, this formula is still valid
sub _haldanePressure {
    my $self = shift;
    my $gas  = lc(shift) || 'n2';
    croak "Asking for unsupported gas $gas" unless exists $GASES{$gas};

    # we need the current tissure pressure, at t=0 for the depth
    my $tissue_press0 = $self->{$gas}->{pressure};
    #print "recalculating haldane formula. tissue pressure at t0 = $tissue_press0\n";

    # and the alveolar pressure
    my $alveolar = $self->_alveolarPressure( depth => $self->{depth} );

    # the time in minutes we have been at this depth, note that internal times are in seconds!

 view all matches for this distribution


Deliantra

 view release on metacpan or  search on metacpan

Deliantra/Data.pm  view on Meta::CPAN

	}
      ],
      [
	'is_cauldron',
	{
	  desc => 'If set, the container can be used as alchemy-cauldron. The player can put ingredients inside, close it, cast alchemy and if his formulae is true, he\'ll get what he longed for.',
	  name => 'alchemy cauldron',
	  type => 'bool'
	}
      ],
      [

 view all matches for this distribution


Devel-Debug-DBGp

 view release on metacpan or  search on metacpan

DB/DbgrProperties.pm  view on Meta::CPAN


=head1 postconditions

This function does one of three things:

1. Throw an exception: let the caller deal with it, and formulate
an error message.

2. Assign a value to a local value if it's a non-top-level stack
Return undef

 view all matches for this distribution


Devel-Declare

 view release on metacpan or  search on metacpan

stolen_chunk_of_toke.c  view on Meta::CPAN


#if !defined(PERL_5_9_PLUS) && defined(PERL_IMPLICIT_CONTEXT)
/* These two are not exported from the core on Windows.  With 5.9+
   it's not an issue, because they're part of the PL_parser structure,
   which is exported.  On multiplicity/thread builds we can work
   around the lack of export by this formulation, where we provide
   a substitute implementation of the unexported accessor functions.
   On single-interpreter builds we can't, because access is directly
   via symbols that are not exported.  */
# define Perl_Ilinestart_ptr my_Ilinestart_ptr
char **my_Ilinestart_ptr(pTHX) { return &(aTHX->Ilinestart); }

 view all matches for this distribution


Device-Chip-BME280

 view release on metacpan or  search on metacpan

lib/Device/Chip/BME280.pm  view on Meta::CPAN

      unpack( "L>", "\x00" . $bytesT ) >> 4,
      unpack( "S>",          $bytesH ),
   );
}

# Compensation formulae directly from BME280 datasheet section 8.1

field $_t_fine;

field @_dig_T;

 view all matches for this distribution


Device-LPS331AP

 view release on metacpan or  search on metacpan

lib/Device/Altimeter/LPS331AP.pm  view on Meta::CPAN

Get pressure in inches of mercury

=head2 getPressureToAltitudeMeters

converts pressure in mbar to altitude in meters, using 1976 US
Standard Atmosphere model (note that this formula only applies to a
height of 11 km, or about 36000 ft)
If altimeter setting (QNH, barometric pressure adjusted to sea
level) is given, this function returns an indicated altitude
compensated for actual regional pressure; otherwise, it returns
the pressure altitude above the standard pressure level of 1013.25

 view all matches for this distribution


Device-LaCrosse-WS23xx

 view release on metacpan or  search on metacpan

memory_map_2300.PL  view on Meta::CPAN

	# strip it off.
	$line =~ s/\s*\([^\(]+\)$//;

	# Is it a definition line?
	if ($line =~ m!^\|\s+([^ 0-9].*?)\s*:\s*(.*)!) {
	    my ($desc, $formula) = ($1, $2);
	    push @map, {
			desc => $desc,
			name => _canonical_name($desc),
			address => $address,
			length => 1,
			   };

	    # FIXME: formula
	    $formula =~ s{<(\S+)>}{
		my $key = $1;
		defined $macro{$key}
		  or die "$mapfile:$.: Undefined macro <$key>";
		$macro{$key};
	    }ge;

	    if ($formula =~ s/\s*\[(.*)\]\s*//) {
		$map[-1]->{units} = $1;
	    }

	    $map[-1]->{formula} = $formula;
	}
	elsif ($line =~ m!^_/!) {
	    my $l = $address - $map[-1]->{address} + 1;
	    if ($l > 10) {
		die "$mapfile:$.: preposterous length";

memory_map_2300.PL  view on Meta::CPAN

    if (my $units = $entry->{units}) {
	$name .= " [$units]";
    }

    printf { $mmap_fh } "%04X:%-2d %-40s %s\n", @{$entry}{"address","length"},
      $name, $entry->{formula};
}

print { $mmap_fh } <<'END_MMAP_REST';
END_MEMORY_MAP

 view all matches for this distribution


Device-LabJack

 view release on metacpan or  search on metacpan

LabJack.xs  view on Meta::CPAN

//			*overVoltage	-If >0, an overvoltage has been detected on
//					 at least one sample of at least one of the
//					 analog inputs (I32).
//
//	Time:	The execution time of this function, in milliseconds, can be
//		estimated with the below formulas.  The actual number of scans
//		collected and transferred by the LabJack is the smallest power
//		of 2 from 64 to 4096 which is at least as big as numScans.  This
//		is represented below as numScansActual.
//		Normal => 30+(1000*numScansActual/scanRate)+(2.5*numScansActual)
//		Turbo  => 30+(1000*numScansActual/scanRate)+(0.4*numScansActual)

 view all matches for this distribution


Device-MegaSquirt

 view release on metacpan or  search on metacpan

doc/devdoc/RS232_MS2_E.htm  view on Meta::CPAN

  <p><strong>Units</strong> are the human readable units. ADC means the value 
    from the analog to digital converter before they are scaled. ADC units typically 
    represent 0-5V max using 0-255 </p>
  <p align="left">The scaling is done with a multiplier (<strong>scale</strong>) 
    and an offset (<strong>translate</strong>) to get to user units (in the above 
    example AFR) use this formula: <br>
    userValue = (msValue + translate) * scale.</p>
  <p align="left"> The<strong> lo</strong> and<strong> hi</strong> value indicate 
    the range of the values. In this example for an input of 0-5V (Innovate 0-5V 
    LC-1) the user units will range from an AFR of 10 to 20. The scaling values 
    will be different for different sensor settings. </p>

 view all matches for this distribution


Device-TNC

 view release on metacpan or  search on metacpan

lib/Device/TNC/KISS.pm  view on Meta::CPAN

                                (i.e., 500 ms).

   2           P                The next byte  is  the  persistence
                                parameter,  p, scaled to the range
                                0 - 255 with the following
                                formula:

                                         P = p * 256 - 1

                                The  default  value  is  P  =  63
                                (i.e.,  p  =  0.25).

 view all matches for this distribution


Device-USB-PCSensor-HidTEMPer

 view release on metacpan or  search on metacpan

lib/Device/USB/PCSensor/HidTEMPer/NTC/External.pm  view on Meta::CPAN

    # Calculate key
    $key = $self->_volt_7705_calibration( $volt );
    
=pod

The formula used to calculate value based on a calibrated key value is
created using the Eureqa tool from Cornell Computational Synthesis Lab,
http://ccsl.mae.cornell.edu/eureqa.

Resulting in the use of this formula instead of the provided number list:
f(y)=66.7348/(66.7275/(67.8088 - 9.70353*log(0.000251309 + y*y)) - 0.21651)

If you find another formula that is more accurate please drop me a line. 
The data used can be found in the source code of this file.

=cut 

    $temperature = 66.7348 

 view all matches for this distribution


Device-Velleman-K8055-Fuse

 view release on metacpan or  search on metacpan

lib/Device/Velleman/K8055/Fuse.pm  view on Meta::CPAN

This outputs $value to the analog channel indicated by $channel.

The indicated 8-bit Digital to Analogue Converter channel is altered according to the new value.
This means that the value corresponds to a specific voltage. The value 0 corresponds to a
minimum output voltage (0 Volt) and the value 255 corresponds to a maximum output voltage (+5V).
A value of $value lying in between these extremes can be translated by the following formula :
$value / 255 * 5V.

See also SetAnalogChannel() and SetAllAnalog()

=cut

 view all matches for this distribution


Device-Velleman-K8055-libk8055

 view release on metacpan or  search on metacpan

lib/Device/Velleman/K8055/libk8055.pm  view on Meta::CPAN


This outputs $data to the analog channel indicated by $channel.
The indicated 8-bit Digital to Analogue Converter channel is altered according to the new data.
This means that the data corresponds to a specific voltage. The value 0 corresponds to a
minimum output voltage (0 Volt) and the value 255 corresponds to a maximum output voltage (+5V).
A value of $data lying in between these extremes can be translated by the following formula :
$data / 255 * 5V.

=head2 OutputAllAnalog($data1, $data2);

This outputs $data1 to the first analog channel, and $data2 to the

 view all matches for this distribution


Device-Velleman-K8055

 view release on metacpan or  search on metacpan

lib/Device/Velleman/K8055.pm  view on Meta::CPAN


This outputs $data to the analog channel indicated by $channel.
The indicated 8-bit Digital to Analogue Converter channel is altered according to the new data.
This means that the data corresponds to a specific voltage. The value 0 corresponds to a
minimum output voltage (0 Volt) and the value 255 corresponds to a maximum output voltage (+5V).
A value of $data lying in between these extremes can be translated by the following formula :
$data / 255 * 5V.

=head2 OutputAllAnalog($data1, $data2);

This outputs $data1 to the first analog channel, and $data2 to the

 view all matches for this distribution


( run in 1.330 second using v1.01-cache-2.11-cpan-39bf76dae61 )