BASIC Program
BASIC Program
(OP)
I need to write a program that will send out the Modified Julian Date to a part marker. I will use the PLC date to calculate MJD.
I am thinking of using a lookup table, but want to field a few suggestions first.
Any ideas anyone.
I am thinking of using a lookup table, but want to field a few suggestions first.
Any ideas anyone.





RE: BASIC Program
RE: BASIC Program
The only concern I have for counter is if the processor is placed in program mode during the time the date should change.
RE: BASIC Program
RE: BASIC Program
Thanks
RE: BASIC Program
RE: BASIC Program
RE: BASIC Program
The module used was the 1746-BAS T module, using PBASE to program. PBASE has a nice translation feature that allows the program to be writen without line numbers. This was usefull in that the source code is easier to understand.
There is supposed to be a C translator available but I couldn't find it, C is much better to write code with.
Thanks to all for feedback.
RE: BASIC Program
convertible to Julian) :
Nd ( # of day for Sun. to Sat.) = 0 to 6
Nm ( # of month, Jan to Dec, 1 digit ea. )
= 400 351 362 402 spaced for readability.
Ny ( # of year, 0 to 6 ) e.g. for 1949 and 2005 = 1
''' After each year and in a leapyear after Feb. 29, too
Ny=Ny+1: if Ny>6 then Ny=Ny-7
Nd = (Ny +Nm + D) mod 7
e.g. Nd(12/25/2005) = (1+2+25) mod 7 =28 mod 7=0 => Sunday
<nbucska@pcperipherals DOT com> subj: eng-tips