Guanylate cyclase involved in the production of the second messenger cGMP (PubMed:24015261). In addition, regulates cGMP levels by controlling the transcription of 3',5'-cyclic phosphodiesterase pde-1 and pde-5 mRNAs (PubMed:19489741, PubMed:24015261). Involved in the olfactory, light and pheromone sensing pathways. Part of the chemosensory mechanism of the ASJ sensory neuron that controls dauer formation and dauer recovery (PubMed:1732156, PubMed:8893028, PubMed:21304598). Promotes the calcium flux in ASJ sensory neurons in response to onset and removal of a nitric oxide (NO) stimulus and is thereby required for the behavioral avoidance response to NO-producing organisms like P.aeruginosa (PubMed:30014846). In ASI and ASJ sensory neurons, controls dauer formation and behavioral response to P.aeruginosa by up-regulating the transcription of daf-7, a member of the TGF-beta family (PubMed:11677050, PubMed:25303524). Required for the chemotaxis responses to non-volatile and volatile attractants mediated by the sensory neurons ASE and AWC respectively (PubMed:7828815, PubMed:10790386). Required in ASJ neurons for phototransduction downstream of G protein coupled-photoreceptor lite-1 (PubMed:20436480). Plays a role in the development of ASJ sensory neuron axons during late larval stages and in the maintenance of normal axon morphology in adults (PubMed:9486798). Required to maintain the expression of putative olfactory receptor str-2 in one of the two AWC neurons in adults (PubMed:10571181). Regulates, via the production of cGMP, lifespan (in some environmental conditions), sensitivity to oxidative stress and entry into quiescence triggered by satiety (PubMed:18316030, PubMed:19489741, PubMed:24015261). In AWB and AWC sensory neurons, mediates the recognition of food odors which subsequently allows for the detection of preferred food sources (PubMed:25009271). GTP = 3',5'-cyclic GMP + diphosphate Expressed preferentially in ciliated endings of sensory neurons (PubMed:10790386). Cilium localization is regulated by daf-25 (PubMed:21124868). Expressed in sensory neurons including ASI, ASJ, ASK, AWB and AWC. Expressed in ASJ neurons in the dauer stage. The protein kinase domain is predicted to be catalytically inactive. RNAi-mediated knockdown in AWB and AWC sensory neurons results in a defective preference between different food odors. Belongs to the adenylyl cyclase class-4/guanylyl cyclase family.