Added jet linkage for co_emco, co_oxco, and co_roco. Added templates for co jets.

This commit is contained in:
Luke Patmore 2014-06-02 11:48:16 -07:00
parent b76b207bd2
commit a97db340ce
5 changed files with 143 additions and 0 deletions

View File

@ -162,6 +162,7 @@ J164_4_OFILES=\
J164_5_OFILES=\
gen164/5/aesc.o \
gen164/5/co.o \
gen164/5/cue.o \
gen164/5/ed.o \
gen164/5/jam.o \
@ -178,6 +179,11 @@ J164_5_OFILES=\
gen164/5/tape.o \
gen164/5/trip.o
J164_5_OFILES_CO=\
gen164/5/co_emco.o \
gen164/5/co_oxco.o \
gen164/5/co_roco.o
J164_5_OFILES_ED=\
gen164/5/ed_puck.o \
gen164/5/ed_sign.o \
@ -241,6 +247,7 @@ J164_OFILES=\
$(J164_3_OFILES) \
$(J164_4_OFILES) \
$(J164_5_OFILES) \
$(J164_5_OFILES_CO) \
$(J164_5_OFILES_ED) \
$(J164_6_OFILES) \
$(J164_6_OFILES_UT) \

61
gen164/5/co_emco.c Normal file
View File

@ -0,0 +1,61 @@
/* gen164/5/co_emco.c
**
** This file is in the public domain.
*/
#include "all.h"
#include "../pit.h"
/* functions
*/
/* parameters
[[bas=@ min=@] [par=$+([? @ tape] tape)]]
*/
u2_weak
j2_md(Pt5, coco, co, emco)(u2_wire wir_r,
u2_noun cor)
{
u2_atom bas, min;
u2_noun rex;
u2_noun par;
u2_atom hol = 0;
mpz_t bas_mp, dar_mp, hol_mp, rad_mp;
if ( u2_no == u2_mean(cor, u2_cv_sam_4, &bas,
u2_cv_sam_5, &min,
u2_cv_sam_3, &par,
u2_cv_sam_6, &rex,
0) )
{
return u2_bl_bail(wir_r, c3__exit);
}
while ( 1 ) {
if ( !hol && !min ) {
return rex;
}
u2_mp(bas_mp, bas);
u2_mp(hol_mp, hol);
mpz_tdiv_q(rad_mp, hol_mp, bas_mp);
mpz_tdiv_r(dar_mp, hol_mp, bas_mp);
if ( min ) {
min--;
}
u2_rl_mp(hol, dar_mp);
// rex (par =(0 dar) rad rex)
}
}
/* structures
*/
u2_ho_jet
j2_mdj(Pt5, coco, co, emco)[] = {
{ ".2", c3__lite, j2_md(Pt5, coco, co, emco), u2_jet_dead, u2_none, u2_none },
{ }
};

33
gen164/5/co_oxco.c Normal file
View File

@ -0,0 +1,33 @@
/* gen164/5/co_oxco.c
**
** This file is in the public domain.
*/
#include "all.h"
#include "../pit.h"
/* functions
*/
u2_weak
j2_md(Pt5, coco, co, oxco)(u2_wire wir_r,
u2_noun cor)
{
u2_atom bas, gop;
u2_noun dug;
if ( u2_no == u2_mean(cor, u2_cv_sam_4, &bas,
u2_cv_sam_5, &gop,
u2_cv_sam_3, &dug,
0) )
{
return u2_bl_bail(wir_r, c3__exit);
}
return 0;
}
/* structures
*/
u2_ho_jet
j2_mdj(Pt5, coco, co, oxco)[] = {
{ ".2", c3__lite, j2_md(Pt5, coco, co, oxco), u2_jet_dead, u2_none, u2_none },
{ }
};

40
gen164/5/co_roco.c Normal file
View File

@ -0,0 +1,40 @@
/* gen164/5/co_roco.c
**
** This file is in the public domain.
*/
#include "all.h"
#include "../pit.h"
/* functions
*/
u2_weak
j2_md(Pt5, coco, co, roco)(u2_wire wir_r,
u2_noun cor)
{
u2_atom buz, bas, dop;
u2_noun dug;
/* tree axes */
/* buz => 4 */
/* bas => 10 */
/* dop => 11 */
/* dug => 3 */
/* if ( u2_no == u2_mean(cor, u2_cv_sam_4, &bas, */
/* u2_cv_sam_5, &min, */
/* u2_cv_sam_3, &par, */
/* 0) ) */
/* { */
/* return u2_bl_bail(wir_r, c3__exit); */
/* } */
return 0;
}
/* structures
*/
u2_ho_jet
j2_mdj(Pt5, coco, co, roco)[] = {
{ ".2", c3__lite, j2_md(Pt5, coco, co, roco), u2_jet_dead, u2_none, u2_none },
{ }
};

View File

@ -103,6 +103,7 @@
extern u2_ho_driver j2_mbd(Pt5, comp)[];
extern u2_ho_driver j2_mbd(Pt5, cook)[];
extern u2_ho_driver j2_mbd(Pt5, easy)[];
extern u2_ho_driver j2_mbd(Pt5, coco)[];
extern u2_ho_driver j2_mbd(Pt5, coed)[];
extern u2_ho_driver j2_mbd(Pt5, glue)[];
extern u2_ho_driver j2_mbd(Pt5, here)[];
@ -219,6 +220,7 @@
{ j2_sb(Pt4, by), 0, j2_mbd(Pt4, by), 0, u2_none },
{ j2_sb(Pt5, aesc), 0, j2_mbd(Pt5, aesc), 0, u2_none },
{ j2_sb(Pt5, bend), 0, j2_mbd(Pt5, bend), 0, u2_none },
{ j2_sb(Pt5, coco), 0, j2_mbd(Pt5, coco), 0, u2_none },
{ j2_sb(Pt5, coed), 0, j2_mbd(Pt5, coed), 0, u2_none },
{ j2_sb(Pt5, cold), 0, j2_mbd(Pt5, cold), 0, u2_none },
{ j2_sb(Pt5, comp), 0, j2_mbd(Pt5, comp), 0, u2_none },